code: def _set_environment(self, environ):
          
          if environ:
              q_environ = self._process.processEnvironment()
              for k, v in environ.items():
                  q_environ.insert(k, v)
              self._process.setProcessEnvironment(q_environ)
docs: Set the environment on the QProcess.