-
Notifications
You must be signed in to change notification settings - Fork 224
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
Figure.subplot: Fix strange positioning issues after exiting subplot #2427
Merged
Merged
Changes from 4 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
d67810d
Use separate sessions for 'subplot begin' and 'subplot end'
seisman f262b0c
Improve the comments
seisman a9eb8fb
Update the grdgradient_shading example to use 'JBC' to position color…
seisman 7e7bf6b
Add a unit test
seisman 0a39369
Minor changes due to different gs versions
seisman aa40f9c
Update pygmt/tests/test_subplot.py
seisman dc0fec4
Update baseline image
seisman File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 4 additions & 0 deletions
4
pygmt/tests/baseline/test_subplot_outside_plotting_positioning.png.dvc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
outs: | ||
- md5: 14da5db0ab63addd8a6d52d6746d9da2 | ||
size: 12124 | ||
path: test_subplot_outside_plotting_positioning.png |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does the plot need updating? The unit test is failing at https://github.com/GenericMappingTools/pygmt/actions/runs/4427893754/jobs/7766176078#step:11:704:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor differences are likely due to different gs versions, but I'm using gs 9.54.0 from conda-forge on macOS and the test passes for me locally:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you using a dev version of GMT? Can you show your
pygmt.show_versions()
? This is the one from CI at https://github.com/GenericMappingTools/pygmt/actions/runs/4427893754/jobs/7766177139#step:11:16 which is also using ghostscript 9.54.0:There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
aha, you're right. I'm using GMT master.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, now the GMT Dev Tests are failing on the main branch at https://github.com/GenericMappingTools/pygmt/actions/runs/4443039566/jobs/7799909484#step:17:718 🙃 Should we set an
@pytest.mark.xfail
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about increase the RMS diff threshold to 4.0
@pytest.mark.mpl_image_compare(tolerance=4.0)
?