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

deprecation asdf.extension legacy functions #1409

Conversation

braingram
Copy link
Contributor

deprecates several helper functions/attributes exposed via asdf.extensions that are related to only the legacy extension api:

  • default_extensions
  • get_default_resolver
  • get_cached_asdf_extension_list

@github-actions github-actions bot added this to the 2.15 milestone Feb 20, 2023
@braingram braingram force-pushed the deprecate/legacy_extension_functions branch from 7925b8c to 556ca26 Compare February 20, 2023 20:15
@braingram braingram marked this pull request as ready for review February 20, 2023 20:56
@braingram braingram requested a review from a team as a code owner February 20, 2023 20:56
@braingram braingram force-pushed the deprecate/legacy_extension_functions branch from 3db9378 to 3644b9d Compare February 21, 2023 21:21
Copy link
Contributor

@WilliamJamieson WilliamJamieson left a comment

Choose a reason for hiding this comment

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

I have a simplifying thought

asdf/extension/_legacy.py Outdated Show resolved Hide resolved
asdf/extension/_legacy.py Outdated Show resolved Hide resolved
asdf/extension/_legacy.py Outdated Show resolved Hide resolved
asdf/extension/_legacy.py Outdated Show resolved Hide resolved
asdf/tests/helpers.py Outdated Show resolved Hide resolved
tox.ini Outdated Show resolved Hide resolved
@braingram braingram force-pushed the deprecate/legacy_extension_functions branch from 3644b9d to 9872c60 Compare February 22, 2023 14:28
deprecates:
- default_extensions
- get_default_resolver
- get_cached_asdf_extension_list
pytest_asdf was accessing asdf.extensions.default_extensions
and then accessing the resolver attribute and passing it to
load_schema as the resolver argument. This produces a resolver
argument that is identical to the default. This commit removes
the uneeded work and instead allows use of the identical default.
astropy tests named test_backwards_compat in
astropy/io/misc/asdf/tags/fits/tests/test_fits.py
and
astropy/io/misc/asdf/tags/table/tests/test_table.py
fail due to use of default_extensions
in astropy/io/misc/asdf/tags/tests/helpers.py
@braingram braingram force-pushed the deprecate/legacy_extension_functions branch from 9872c60 to 67eb3f3 Compare February 22, 2023 14:37
@WilliamJamieson
Copy link
Contributor

To avoid confusion in astropy can we wait to merge this until astropy/astropy#14429 is merged? That PR is fixing the deprecation warning from #1401.

@braingram
Copy link
Contributor Author

To avoid confusion in astropy can we wait to merge this until astropy/astropy#14429 is merged? That PR is fixing the deprecation warning from #1401.

At the moment I don't object to waiting.

I started #1429 based off the changes included in this PR. Are there changes requested? If not, I will mark #1429 as ready for review and update #1361 based off the changes in #1429.

@WilliamJamieson
Copy link
Contributor

This is ready aside from waiting for the astropy PR to clear.

@braingram braingram deleted the deprecate/legacy_extension_functions branch February 22, 2023 20:01
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.

None yet

2 participants