Date
1 - 3 of 3
ImportError overriding an appModule
Alberto Buffolino
Hi,
writing a scratchPad appModule for explorer, I get this error from ColumnsReview, where there is an import from core appModules.explorer: ERROR - globalPluginHandler.listPlugins (13:15:28.215) - MainThread (7452): Error importing global plugin columnsReview Traceback (most recent call last): File "globalPluginHandler.pyc", line 23, in listPlugins File "importlib\__init__.pyc", line 127, in import_module File "<frozen importlib._bootstrap>", line 1006, in _gcd_import File "<frozen importlib._bootstrap>", line 983, in _find_and_load File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 677, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 728, in exec_module File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed File "C:\Users\Admin\AppData\Roaming\nvda\addons\columnsReview\globalPlugins\columnsReview\__init__.py", line 22, in <module> from appModules.explorer import GridTileElement, GridListTileElement # Specific for Start Screen tiles. ImportError: cannot import name 'GridTileElement' from 'appModules.explorer' (C:\Users\Admin\AppData\Roaming\nvda\scratchpad\appModules\explorer.py) *** I tried with: from appModules.explorer import * in my explorer.py, but nothing changes. So, is there a solution? Alberto
|
|
Rui Fontes
In zExplorer addon I import explorer.py this way:
toggle quoted messageShow quoted text
if hasattr (appModules, "wintenApps"): from wintenApps.explorer import * else: from nvdaBuiltin.appModules.explorer import * I have to use this because sometimes Win10apps include a explorer.py... Rui Fontes NVDA portuguese team Às 12:22 de 26/10/2020, Alberto Buffolino escreveu:
Hi,
|
|
Alberto Buffolino
Rui Fontes, il 29/10/2020 13.47, ha scritto:
from nvdaBuiltin.appModules.explorer import *Alberto: Hi Rui, thanks, tis is exactly what I was looking for! Alberto
|
|