330 |
329 |
331 # step 2: determine from used Python interpreter (pylupdate is test object) |
330 # step 2: determine from used Python interpreter (pylupdate is test object) |
332 if not toolsPath: |
331 if not toolsPath: |
333 program = "pylupdate{0}".format(version) |
332 program = "pylupdate{0}".format(version) |
334 if venvName: |
333 if venvName: |
335 from eric7.EricWidgets.EricApplication import ericApp |
|
336 |
|
337 venvManager = ericApp().getObject("VirtualEnvManager") |
334 venvManager = ericApp().getObject("VirtualEnvManager") |
338 dirName = venvManager.getVirtualenvDirectory(venvName) |
335 dirName = venvManager.getVirtualenvDirectory(venvName) |
339 else: |
336 else: |
340 dirName = os.path.dirname(sys.executable) |
337 dirName = os.path.dirname(sys.executable) |
341 |
338 |
382 |
379 |
383 # step 2: try the qt6_applications package |
380 # step 2: try the qt6_applications package |
384 if not binPath: |
381 if not binPath: |
385 with contextlib.suppress(ImportError): |
382 with contextlib.suppress(ImportError): |
386 # if qt6-applications is not installed just go to the next step |
383 # if qt6-applications is not installed just go to the next step |
387 import qt6_applications |
384 import qt6_applications # __IGNORE_WARNING_I10__ |
388 |
385 |
389 if libexec: |
386 if libexec: |
390 binPath = os.path.join( |
387 binPath = os.path.join( |
391 os.path.dirname(qt6_applications.__file__), "Qt", "libexec" |
388 os.path.dirname(qt6_applications.__file__), "Qt", "libexec" |
392 ) |
389 ) |
618 @return string indicating the supported web browser variant ("QtWebEngine", |
615 @return string indicating the supported web browser variant ("QtWebEngine", |
619 or "None") |
616 or "None") |
620 @rtype str |
617 @rtype str |
621 """ |
618 """ |
622 try: |
619 try: |
623 from eric7.eric7config import getConfig |
620 from eric7.eric7config import getConfig # __IGNORE_WARNING_I101__ |
624 except ImportError: |
621 except ImportError: |
625 from eric7config import getConfig |
622 from eric7config import getConfig # __IGNORE_WARNING_I10__ |
626 |
623 |
627 scriptPath = os.path.join(getConfig("ericDir"), "Tools", "webBrowserSupport.py") |
624 scriptPath = os.path.join(getConfig("ericDir"), "Tools", "webBrowserSupport.py") |
628 proc = QProcess() |
625 proc = QProcess() |
629 proc.start(getPythonExecutable(), [scriptPath, qVersion()]) |
626 proc.start(getPythonExecutable(), [scriptPath, qVersion()]) |
630 variant = ( |
627 variant = ( |