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

Deprecate AsdfExtension, AsdfExtensionList, BuiltinExtension #1429

Merged
merged 4 commits into from
Feb 22, 2023

Conversation

braingram
Copy link
Contributor

@braingram braingram commented Feb 22, 2023

Currently based off of #1409 and should not be merged before that PR.

@braingram
Copy link
Contributor Author

braingram commented Feb 22, 2023

Leaving this as draft until #1409 is merged

@braingram braingram marked this pull request as ready for review February 22, 2023 17:35
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.

LGTM

Comment on lines +35 to +43
def __getattr__(name):
if name == "AsdfExtension":
# defer import to only issue deprecation warning when
# asdf.AsdfExtension is used
from asdf import extension

return extension.AsdfExtension
msg = f"module {__name__!r} has no attribute {name!r}"
raise AttributeError(msg)
Copy link
Contributor

Choose a reason for hiding this comment

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

This is nice.

@WilliamJamieson
Copy link
Contributor

How did this not show up in #1433? From the astropy downstream

FAILED astropy/astropy/io/misc/asdf/tags/fits/tests/test_fits.py::test_backwards_compat - asdf.exceptions.AsdfDeprecationWarning: asdf.types.format_tag is deprecated...
FAILED astropy/astropy/io/misc/asdf/tags/table/tests/test_table.py::test_backwards_compat - asdf.exceptions.AsdfDeprecationWarning: asdf.types.format_tag is deprecated...

@WilliamJamieson
Copy link
Contributor

astropy downstream will be fixed by astropy/astropy#14436

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