-
Notifications
You must be signed in to change notification settings - Fork 228
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
Workaround for PyGMT on Windows #431
Comments
Ok, we should add this workaround to the documentation. Probably need to make a |
This comment has been minimized.
This comment has been minimized.
Here are what we should do:
|
The conda GMT package was rebuilt in conda-forge/gmt-feedstock#94. Windows users no longer need to set the variable GMT_SHAREDIR. |
As per the conda documentation:
PyGMT should be able to locate gmt.dll.
|
PyGMT v0.1.1 is released. It's expected to work smoothly on Windows. No workaround is needed anymore. |
Description of the problem
We have several reported issues saying that pygmt can't load the GMT library on Windows, e.g. #46, #285, #353.
Actually, the description of the issues is inaccurate. PyGMT works well with the GMT official installers (i.e., gmt-6.0.0-win64.exe), but doesn't work with the gmt conda package on Windows. We're working on a fix in PR #313, but currently, it's still not clear why the conda windows package is special, and
it may take a long time to make it work(it's almost solved, see #434 and GenericMappingTools/gmt#3353).Update on May 22, 2020
PyGMT v0.1.1 works perfectly on Windows. No workaround is needed.
Please follow the latest install instructions.
Update on May 20, 2020:
We finally find out why PyGMT crashes with the GMT conda package on Windows. The issue was fixed in #434.
Currently, Windows users can install the PyGMT master branch:
so that
import pygmt
will work. We will release PyGMT v0.1.1 in the coming days on PyPI and conda-forge to include the new fixes.and add one environmental variable:GMT_LIBRARY_PATH: path to the gmt.dll path, e.g.,C:\Miniconda\envs\pygmt\Library\bin
GMT_SHAREDIR: path to the GMT's share directory, e.g.,C:\Miniconda\envs\pygmt\Library\share\gmt
More testing from Windows users are welcomed.
Posted on May 17, 2020.
The workaround below is still valid, but please follow the comment above.
For PyGMT users on Windows, the simplest workaround would be:
note: currently, we can't use
conda install pygmt
on Windows, but it should be fixed later.Perhaps also need to set the environmental variable GMT_LIBRARY_PATH to the gmt.dll library path, e.g.,
C:\Miniconda\envs\testing\Library\bin
.I just installed GMT and pygmt following the install instruction above and successfully made a simple plot.
I think this is easier than "building from source" or using "WSL" as suggested in our documentation (https://www.pygmt.org/latest/install.html), and we should recommend this way instead.
The text was updated successfully, but these errors were encountered: