src/eric7/VirtualEnv/VirtualenvManager.py

branch
server
changeset 10770
8b4ff92221da
parent 10766
d35d6f96c24b
child 10931
56f41b1e163a
equal deleted inserted replaced
10769:33edb81a63b4 10770:8b4ff92221da
734 through an eric-ide server. 734 through an eric-ide server.
735 735
736 @param venvName logical name of the virtual environment 736 @param venvName logical name of the virtual environment
737 @type str 737 @type str
738 @param host name of the host to check for or empty string to just check for 738 @param host name of the host to check for or empty string to just check for
739 an eric-ide server environment 739 an eric-ide server environment (defaults to "")
740 @type str (optional)
740 @return flag indicating an eric-ide server environment 741 @return flag indicating an eric-ide server environment
741 @rtype bool 742 @rtype bool
742 """ 743 """
743 try: 744 try:
744 if host: 745 if host:
745 return ( 746 return self.__virtualEnvironments[
746 self.__virtualEnvironments[venvName].is_eric_server 747 venvName
747 and self.__virtualEnvironments[venvName].eric_server.startswith( 748 ].is_eric_server and self.__virtualEnvironments[
748 f"{host}:" 749 venvName
749 ) 750 ].eric_server.startswith(
751 f"{host}:"
750 ) 752 )
751 else: 753 else:
752 return self.__virtualEnvironments[venvName].is_eric_server 754 return self.__virtualEnvironments[venvName].is_eric_server
753 except KeyError: 755 except KeyError:
754 return False 756 return False

eric ide

mercurial