Skip to content

Add variables setter to datacube extension #699

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

Merged

Conversation

duckontheweb
Copy link
Contributor

@duckontheweb duckontheweb commented Jan 5, 2022

Related Issue(s):

Description:

Adds a setter for the DatacubeExtension.variables property and adds a Variable.to_dict method. Also adds tests for getting and setting DatacubeExtension.variables.

PR Checklist:

  • Code is formatted (run pre-commit run --all-files)
  • Tests pass (run scripts/test)
  • Documentation has been updated to reflect changes, if applicable
  • This PR maintains or improves overall codebase code coverage.
  • Changes are added to the CHANGELOG. See the docs for information about adding to the changelog.

@duckontheweb duckontheweb requested a review from lossyrob January 5, 2022 18:45
@duckontheweb
Copy link
Contributor Author

@TomAugspurger it would be great to get your review on this as well.

@duckontheweb duckontheweb added this to the 1.3.0 milestone Jan 5, 2022
@codecov-commenter
Copy link

Codecov Report

Merging #699 (cda8a98) into main (f68cf81) will increase coverage by 0.04%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #699      +/-   ##
==========================================
+ Coverage   94.20%   94.25%   +0.04%     
==========================================
  Files          77       77              
  Lines       11120    11140      +20     
  Branches     1337     1339       +2     
==========================================
+ Hits        10476    10500      +24     
+ Misses        466      461       -5     
- Partials      178      179       +1     
Impacted Files Coverage Δ
pystac/extensions/datacube.py 65.67% <100.00%> (+1.73%) ⬆️
tests/extensions/test_datacube.py 100.00% <100.00%> (ø)

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 f68cf81...cda8a98. Read the comment docs.

duckontheweb added a commit to duckontheweb/pystac that referenced this pull request Jan 5, 2022
duckontheweb added a commit to duckontheweb/pystac that referenced this pull request Jan 14, 2022
@duckontheweb duckontheweb force-pushed the fix/681-datacube-variables-setter branch from caf9b05 to 6f6950c Compare January 14, 2022 15:07
@duckontheweb duckontheweb force-pushed the fix/681-datacube-variables-setter branch from 6f6950c to 4295254 Compare January 14, 2022 16:02
@duckontheweb duckontheweb merged commit ddafad4 into stac-utils:main Jan 14, 2022
@duckontheweb duckontheweb deleted the fix/681-datacube-variables-setter branch January 14, 2022 16:06
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.

DatacubeExtension.variables doesn't have a setter
4 participants