diff -r 8358c3c95841 -r 29fb6d420a25 eric6/Debugger/DebuggerInterfacePython.py --- a/eric6/Debugger/DebuggerInterfacePython.py Sun Mar 14 19:59:27 2021 +0100 +++ b/eric6/Debugger/DebuggerInterfacePython.py Mon Mar 15 17:55:48 2021 +0100 @@ -153,7 +153,7 @@ return proc def startRemote(self, port, runInConsole, venvName, originalPathString, - workingDir=None): + workingDir=None, configOverride=None): """ Public method to start a remote Python interpreter. @@ -168,6 +168,9 @@ @type str @param workingDir directory to start the debugger client in @type str + @param configOverride dictionary containing the global config override + data + @type dict @return client process object, a flag to indicate a network connection and the name of the interpreter in case of a local execution @rtype tuple of (QProcess, bool, str) @@ -205,7 +208,10 @@ "DebugClients", "Python", "DebugClient.py") - redirect = str(Preferences.getDebugger("Python3Redirect")) + if configOverride and configOverride["enable"]: + redirect = str(configOverride["redirect"]) + else: + redirect = str(Preferences.getDebugger("Python3Redirect")) noencoding = (Preferences.getDebugger("Python3NoEncoding") and '--no-encoding' or '') multiprocessEnabled = ( @@ -328,7 +334,8 @@ return process, self.__isNetworked, interpreter def startRemoteForProject(self, port, runInConsole, venvName, - originalPathString, workingDir=None): + originalPathString, workingDir=None, + configOverride=None): """ Public method to start a remote Python interpreter for a project. @@ -343,6 +350,9 @@ @type str @param workingDir directory to start the debugger client in @type str + @param configOverride dictionary containing the global config override + data + @type dict @return client process object, a flag to indicate a network connection and the name of the interpreter in case of a local execution @rtype tuple of (QProcess, bool, str) @@ -361,7 +371,10 @@ if project.getProjectLanguage() == "Python3": venvName = Preferences.getDebugger("Python3VirtualEnv") - redirect = str(project.getDebugProperty("REDIRECT")) + if configOverride and configOverride["enable"]: + redirect = str(configOverride["redirect"]) + else: + redirect = str(project.getDebugProperty("REDIRECT")) noencoding = ( '--no-encoding' if project.getDebugProperty("NOENCODING") else '' )