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

Error in psconvert #341

Closed
xumi1993 opened this issue Oct 10, 2019 · 3 comments
Closed

Error in psconvert #341

xumi1993 opened this issue Oct 10, 2019 · 3 comments

Comments

@xumi1993
Copy link

xumi1993 commented Oct 10, 2019

Description of the problem

I wanna simply plot the coastlines as following codes. An error raised as the Full error message when execute the Figure.savefig, although, the correct image will still be generated. After checking the source code, I printed the arguments of lib.call_module in Figure.psconvert as

'-A -Ftest -Qg2 -Qt2 -Tf'

Full code that generated the error

fig = pygmt.Figure()
fig.coast(shorelines="1/0.5p", B='a', region=[-180, 180, -60, 60], projection="M10i")
fig.savefig('test.pdf')

Full error message

psconvert [ERROR]: Syntax error: Modern GMT mode requires the -F option
end [ERROR]: Failed to call psconvert
end [ERROR]: process_figures returned error 71

System information

  • Operating system: Centos 7.3
  • Python installation (Anaconda, system, ETS): Miniconda
  • Version of GMT: 6.0.0rc4
  • Version of Python: 3.7.4
  • Version of this package: pygmt-0.0.1a0+38.g5122397.dirty
  • If using conda, paste the output of conda list below:
output of conda list
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main    defaults
backcall                  0.1.0                    py37_0    defaults
ca-certificates           2019.8.28                     0    defaults
certifi                   2019.9.11                py37_0    defaults
cftime                    1.0.3.4                  pypi_0    pypi
decorator                 4.4.0                    py37_1    defaults
entrypoints               0.3                      py37_0    defaults
flake8                    3.7.8                    py37_1    defaults
ipython                   7.8.0            py37h39e3cac_0    defaults
ipython_genutils          0.2.0                    py37_0    defaults
jedi                      0.15.1                   py37_0    defaults
libedit                   3.1.20181209         hc058e9b_0    defaults
libffi                    3.2.1                hd88cf55_4    defaults
libgcc-ng                 9.1.0                hdf63c60_0    defaults
libstdcxx-ng              9.1.0                hdf63c60_0    defaults
mccabe                    0.6.1                    py37_1    defaults
ncurses                   6.1                  he6710b0_1    defaults
netcdf4                   1.5.2                    pypi_0    pypi
numpy                     1.17.2                   pypi_0    pypi
openssl                   1.1.1d               h7b6447c_2    defaults
packaging                 19.2                     pypi_0    pypi
pandas                    0.25.1                   pypi_0    pypi
parso                     0.5.1                      py_0    defaults
pexpect                   4.7.0                    py37_0    defaults
pickleshare               0.7.5                    py37_0    defaults
pip                       19.2.3                   py37_0    defaults
prompt_toolkit            2.0.10                     py_0    defaults
ptyprocess                0.6.0                    py37_0    defaults
pycodestyle               2.5.0                    py37_0    defaults
pyflakes                  2.1.1                    py37_0    defaults
pygments                  2.4.2                      py_0    defaults
pygmt                     0.0.1a0+38.g5122397.dirty          pypi_0    pypi
pyparsing                 2.4.2                    pypi_0    pypi
python                    3.7.4                h265db76_1    defaults
python-dateutil           2.8.0                    pypi_0    pypi
pytz                      2019.3                   pypi_0    pypi
readline                  7.0                  h7b6447c_5    defaults
setuptools                41.4.0                   py37_0    defaults
six                       1.12.0                   pypi_0    pypi
sqlite                    3.30.0               h7b6447c_0    defaults
tk                        8.6.8                hbc83047_0    defaults
traitlets                 4.3.3                    py37_0    defaults
wcwidth                   0.1.7                    py37_0    defaults
wheel                     0.33.6                   py37_0    defaults
xarray                    0.13.0                   pypi_0    pypi
xz                        5.2.4                h14c3975_4    defaults
zlib                      1.2.11               h7b6447c_3    defaults
@welcome
Copy link

welcome bot commented Oct 10, 2019

👋 Thanks for opening your first issue here! Please make sure you filled out the template with as much detail as possible. You might also want to take a look at our contributing guidelines and code of conduct.

@seisman
Copy link
Member

seisman commented Oct 10, 2019

The error is caused by a bug in GMT 6.0.0rc4. The bug was reported to GMT and has already been fixed. Unfortunately, there is no 6.0.0rc5 or 6.0.0 released since then, but the GMT 6.0.0rc4 provided by conda-forge doesn't have the bug since we already applied the patch.

It seems you're using the official GMT 6.0.0rc4. Now you have two options:

  1. Install the GMT 6.0.0rc4 provided by conda-forge, which has been patched.
  2. Build the lastest 6.0 branch of GMT source codes.

@xumi1993
Copy link
Author

Thank you for your recommend. The error has disappeared after I build the lasted GMT from source code 👍 .

@seisman seisman closed this as completed Oct 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants