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

Extract method to correctly handle setting properties in Item/Asset for ItemExtensions #272

Merged
merged 3 commits into from
Mar 11, 2021

Conversation

volaya
Copy link
Contributor

@volaya volaya commented Mar 4, 2021

This PR adds a method to the ItemExtension class, that makes it easier and more robust for derived classes to set properties in Assest and/or Items.

Existing extensions needing that mechanism have been refactored to rely on the parent method instead

This was discussed in #270

If this PR is merged, #230 will be no longer needed

volaya added 3 commits March 4, 2021 13:31
Refactored extension to use this parent method instead of locally implementing the same logic repeatedly
…et_property

# Conflicts:
#	pystac/extensions/projection.py
@codecov-io
Copy link

codecov-io commented Mar 4, 2021

Codecov Report

Merging #272 (fbd3004) into develop (eebfe89) will increase coverage by 0.06%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #272      +/-   ##
===========================================
+ Coverage    93.99%   94.05%   +0.06%     
===========================================
  Files           32       32              
  Lines         4010     3956      -54     
===========================================
- Hits          3769     3721      -48     
+ Misses         241      235       -6     
Impacted Files Coverage Δ
pystac/extensions/base.py 84.21% <100.00%> (+0.61%) ⬆️
pystac/extensions/eo.py 90.08% <100.00%> (-0.32%) ⬇️
pystac/extensions/pointcloud.py 82.81% <100.00%> (+1.64%) ⬆️
pystac/extensions/projection.py 97.54% <100.00%> (-0.49%) ⬇️
pystac/extensions/timestamps.py 94.02% <100.00%> (-0.26%) ⬇️
pystac/extensions/view.py 97.82% <100.00%> (-0.22%) ⬇️

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 eebfe89...fbd3004. Read the comment docs.

Copy link

@alkamin alkamin left a comment

Choose a reason for hiding this comment

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

This is a great improvement.

Copy link
Member

@lossyrob lossyrob left a comment

Choose a reason for hiding this comment

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

🎉

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

Successfully merging this pull request may close these issues.

4 participants