-
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
Raise GMTInvalidInput exception when required z is missing #1478
Merged
seisman
merged 27 commits into
main
from
raise_GMTInvalidInput_exception_when_z_missing
Sep 15, 2021
Merged
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
dc11bb6
add required_z parameters, and if statement to handle missing z vector
yohaimagen df1b0d5
add required_z parameters and pass it to data_kind
yohaimagen 1b7a8a6
test requierd_z
yohaimagen e471f9e
Update pygmt/helpers/utils.py
yohaimagen 11d98ee
Update pygmt/helpers/utils.py
yohaimagen bcfc03a
Update pygmt/helpers/utils.py
yohaimagen ba73d5b
checks that when required z data matrix has at least 3 columns
yohaimagen ed1419d
[format-command] fixes
actions-bot 166b439
add required_z=True to _blockm
yohaimagen 7675449
add required_z=True to contour
yohaimagen 09c68cd
add required_z=True to plot3d
yohaimagen 8b3eeb2
add required_z=True to surface
yohaimagen 2a77656
reformat
yohaimagen e1d8248
remove unnecessary import
yohaimagen 15a5bf2
Merge branch 'main' into raise_GMTInvalidInput_exception_when_z_missing
yohaimagen 8aa06cf
Merge branch 'main' into raise_GMTInvalidInput_exception_when_z_missing
yohaimagen 306a5c6
add required_z to wiggle
yohaimagen 8451465
remove insuficent data test from test_contour
yohaimagen da51487
add test for sufficent data to test_clib
yohaimagen 4559284
remove test for sufficent data test_plot3d
yohaimagen 6a0042e
remove test for passing z value test_surface
yohaimagen bb51fc5
reformat
yohaimagen 5eb4cc0
remove unused imports
yohaimagen ba10dbb
Apply suggestions from code review
yohaimagen 1639a5b
Merge branch 'main' into raise_GMTInvalidInput_exception_when_z_missing
yohaimagen 15075e8
Apply suggestions from code review
yohaimagen 91c446f
Merge branch 'main' into raise_GMTInvalidInput_exception_when_z_missing
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
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
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
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
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
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.
Checking for
data.shape[1]
fails for xarray.Dataset inputs withAttributeError: 'Dataset' object has no attribute 'shape'
. Theshape
attribute is valid only fornumpy.ndarray
,pandas.DataFrame
, and maybe a few other PyData objects. Will need to create a bugfix and add some extra tests forxarray.Dataset
inputs.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.
I can submit a PR fix since I think that I suggested this. But I feel that we should not label it as a bug since this code has not yet been included in a release, so it might be confusing to list on the changelog as a bugfix relative to v0.4.1.
Edit: Just noticed the comment on the other PR that @weiji14 would fix this. That's also fine.
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.
Ok, I've submitted a bugfix PR at #1523. Have put on the
skip-changelog
label so it won't show up in the changelog :)