|
3 | 3 | via an ``entry-point`` in the ``pyproject.toml`` file.
|
4 | 4 | """
|
5 | 5 |
|
| 6 | +import asdf_standard |
6 | 7 | from asdf.extension import Extension, ManifestExtension
|
7 | 8 |
|
8 | 9 | from .converters.coordinates.angle import AngleConverter, LatitudeConverter, LongitudeConverter
|
|
499 | 500 |
|
500 | 501 |
|
501 | 502 | _ASTROPY_EXTENSION_MANIFEST_URIS = [
|
| 503 | + "asdf://astropy.org/astropy/manifests/astropy-1.4.0", |
502 | 504 | "asdf://astropy.org/astropy/manifests/astropy-1.3.0",
|
503 | 505 | "asdf://astropy.org/astropy/manifests/astropy-1.2.0",
|
504 | 506 | "asdf://astropy.org/astropy/manifests/astropy-1.1.0",
|
|
543 | 545 |
|
544 | 546 | CORE_CONVERTERS = _FITS_CONVERTERS + _TIME_CONVERTERS + _TABLE_CONVERTERS + _UNIT_CONVERTERS
|
545 | 547 |
|
546 |
| -UNIT_EXTENSIONS = [ |
547 |
| - ManifestExtension.from_uri( |
548 |
| - "asdf://astropy.org/astropy/manifests/units-1.0.0", |
549 |
| - converters=_UNIT_CONVERTERS, |
550 |
| - ), |
| 548 | +ASTROPY_UNIT_MANIFESTS = [ |
| 549 | + "asdf://astropy.org/astropy/manifests/units-1.1.0", |
| 550 | + "asdf://astropy.org/astropy/manifests/units-1.0.0", |
551 | 551 | ]
|
552 | 552 |
|
| 553 | +UNIT_EXTENSIONS = [ManifestExtension.from_uri(u, converters=_UNIT_CONVERTERS) for u in ASTROPY_UNIT_MANIFESTS] |
| 554 | + |
553 | 555 | # up to asdf 1.5.0 many tags supported by asdf-astropy
|
554 | 556 | # were defined in core manifests
|
555 | 557 | CORE_MANIFEST_URIS = [
|
|
561 | 563 | "asdf://asdf-format.org/core/manifests/core-1.1.0",
|
562 | 564 | "asdf://asdf-format.org/core/manifests/core-1.0.0",
|
563 | 565 | ]
|
| 566 | +if asdf_standard.__version__ > "1.1.1": |
| 567 | + CORE_MANIFEST_URIS.insert(0, "asdf://asdf-format.org/astronomy/manifests/astronomy-1.1.0") |
564 | 568 |
|
565 | 569 | CORE_EXTENSIONS = [ManifestExtension.from_uri(u, converters=CORE_CONVERTERS) for u in CORE_MANIFEST_URIS]
|
566 | 570 |
|
|
0 commit comments