Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zim can't find dependencies for plugin in PATH in Windows OS #2270

Open
mquan86 opened this issue Dec 29, 2022 · 0 comments
Open

Zim can't find dependencies for plugin in PATH in Windows OS #2270

mquan86 opened this issue Dec 29, 2022 · 0 comments

Comments

@mquan86
Copy link

mquan86 commented Dec 29, 2022

Describe the bug
In Windows OS, any plugin has dependencies is failed to enable even the dependencies already in PATH.

To Reproduce

  1. Windows OS
  2. Install dependencies and make sure it is set in PATH
  3. In Zim > Go to Preference to enable any plugins that require dependencies (for example "Insert diagram" which requires GraphViz)
  4. Can't enable plugin as the dependencies is failed to load

Expected behavior
Should allow to enable plugin as dependencies is available in PATH

Screenshots
image

Environment (please complete the following information):

  • Version 0.75.1 (install as portable mode - not sure if that trigger the bug?)
  • OS: Windows 10

Additional context
Below is the code in Zim for lookup the dependences in PATH and it should see all the exe, bat... in PATH

elif os.name == 'nt':
# Check executable extensions from windows environment
extensions = _split_environ_list(os.environ.get('PATHEXT', '.com;.exe;.bat;.cmd'))
for dir in _split_environ_list(os.environ.get('PATH')):
for ext in extensions:
file = SEP.join((dir, cmd + ext))
if os.path.isfile(file) and os.access(file, os.X_OK):
return file

Workaround: add a execution Windows Batch file (example dot.bat) to same folder of Zim will passed the dependencies requirement, however, there is another bug related to it as well in #2261

@mquan86 mquan86 changed the title Zim can't find dependencies for plugin on PATH in Windows OS Zim can't find dependencies for plugin in PATH in Windows OS Dec 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant