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

Bugfix of link_coords #1588

Merged
merged 7 commits into from Mar 25, 2021
Merged

Bugfix of link_coords #1588

merged 7 commits into from Mar 25, 2021

Conversation

zxdawn
Copy link
Member

@zxdawn zxdawn commented Mar 8, 2021

- rename dataset to data
- drop linked coordinates's dimension which is not existed in dataarray
@zxdawn zxdawn requested a review from mraspaud as a code owner March 8, 2021 08:41
@zxdawn zxdawn self-assigned this Mar 8, 2021
@ghost
Copy link

ghost commented Mar 8, 2021

Congratulations 🎉. DeepCode analyzed your code in 2.787 seconds and we found no issues. Enjoy a moment of no bugs ☀️.

👉 View analysis in DeepCode’s Dashboard | Configure the bot

@codecov
Copy link

codecov bot commented Mar 8, 2021

Codecov Report

Merging #1588 (f33b610) into master (d7fbbdf) will increase coverage by 0.73%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1588      +/-   ##
==========================================
+ Coverage   91.62%   92.36%   +0.73%     
==========================================
  Files         246      254       +8     
  Lines       36034    37413    +1379     
==========================================
+ Hits        33016    34555    +1539     
+ Misses       3018     2858     -160     
Flag Coverage Δ
behaviourtests 4.78% <0.00%> (+0.36%) ⬆️
unittests 92.49% <100.00%> (+0.40%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
satpy/tests/writer_tests/test_cf.py 99.69% <100.00%> (+0.02%) ⬆️
satpy/writers/cf_writer.py 95.18% <100.00%> (+1.30%) ⬆️
satpy/tests/test_resample.py 89.26% <0.00%> (-10.06%) ⬇️
satpy/resample.py 80.34% <0.00%> (-9.35%) ⬇️
satpy/tests/utils.py 92.61% <0.00%> (-5.09%) ⬇️
satpy/readers/satpy_cf_nc.py 97.56% <0.00%> (-1.02%) ⬇️
satpy/readers/__init__.py 96.99% <0.00%> (-0.47%) ⬇️
satpy/tests/test_scene.py 99.44% <0.00%> (-0.30%) ⬇️
satpy/tests/test_yaml_reader.py 99.55% <0.00%> (-0.29%) ⬇️
satpy/tests/writer_tests/test_awips_tiled.py 98.23% <0.00%> (-0.26%) ⬇️
... and 83 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d7fbbdf...f33b610. Read the comment docs.

Copy link
Member

@mraspaud mraspaud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking on this issue. It took me a while to understand what was the aim of this PR, I think a simple unit test to accompany this would have made it easier :)
And in any case, for small changes like this, I really recommend writing a failing unit test FIRST, and fix and refactor afterwards.

So, long story short: there is still a unit test to write :)

satpy/writers/cf_writer.py Outdated Show resolved Hide resolved
satpy/writers/cf_writer.py Outdated Show resolved Hide resolved
satpy/writers/cf_writer.py Outdated Show resolved Hide resolved
@mraspaud
Copy link
Member

Looks good! now just the test :)

@zxdawn zxdawn requested a review from djhoese as a code owner March 16, 2021 14:13
Copy link
Member

@mraspaud mraspaud left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for fixing this!

Co-authored-by: Martin Raspaud <martin.raspaud@smhi.se>
@mraspaud mraspaud merged commit 27d5a69 into pytroll:master Mar 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Failed to save tropomi nc file with specific variables loaded
3 participants