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

depr: deprecate utils.archives in favor of Dataset.extract() #1028

Open
wants to merge 16 commits into
base: main
Choose a base branch
from

Conversation

dkrako
Copy link
Contributor

@dkrako dkrako commented Mar 13, 2025

⚠️ Deprecation

utils.archives is deprecated. please use Dataset.extract() instead.
utils.archives will be removed in pymovements v0.26.0

Description

Deprecate utils.archives in favor of Dataset.extract()

The following warning is printed:

DeprecationWarning: Call to deprecated function (or staticmethod) extract_archive. (Please use Dataset.extract() instead. This function will be removed in v0.26.0.) -- Deprecated since version v0.21.0.

partly resolves #999

blocked by #1029

Implemented changes

  • moved utils/archives.py to dataset/_utils/_archives.py and adjusted to new location
  • use dataset._utils.archives in dataset.dataset_download
  • created deprecated function in utils/archives.py
  • moved tests/unit/utils/archives_test.py to tests/unit/dataset/_utils/_archives_test.py
  • add test that function is correctly deprecated
  • add test that function is removed in planned version

Copy link

codecov bot commented Mar 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (21d539f) to head (5e1389c).

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1028   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           80        81    +1     
  Lines         3602      3609    +7     
  Branches       646       646           
=========================================
+ Hits          3602      3609    +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@dkrako dkrako force-pushed the depr/utils-archives branch from bef6670 to 0a591a5 Compare March 13, 2025 14:20
Copy link
Member

@SiQube SiQube left a comment

Choose a reason for hiding this comment

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

thank you for cleaning up the repo structure. I think there is one PR to split up and some minor changes.

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.

deprecate utils modules that are not intended for end-users
2 participants