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

Fix the base_format list. #349

Merged
merged 4 commits into from
Nov 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The in progress ASDF Standard is v1.6.0
The stable ASDF Standard is v1.5.0

- Add new ``quantity-1.2.0`` schema to support ``datatype`` option. [#351]

- Bugfix for ``base_format`` in ``time-1.2.0`` schema. [#349]

1.0.3 (2022-08-08)
------------------
Expand Down
32 changes: 24 additions & 8 deletions resources/schemas/stsci.edu/asdf/time/time-1.2.0.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -178,24 +178,38 @@ definitions:
do for the purposes of ASDF?]

enum:
- iso
- yday
- byear
- jyear
- cxcsec
- decimalyear
- gps
- iso
- jd
- jyear
- mjd
- gps
- unix
- cxcsec
- unix_tai
- yday

other_format:
description: |
The other formats supported by astropy.time:
https://docs.astropy.org/en/latest/time/index.html#time-format

enum:
- byear_str
- datetime
- fits
- isot
- jyear_str
- plot_date
- ymdhms
- datetime64

anyOf:
- $ref: "#/definitions/string_formats"

- $ref: "#/definitions/array_of_strings"

- $ref: "../core/ndarray-1.0.0#/anyOf/1"

- type: object
properties:
value:
Expand All @@ -222,7 +236,9 @@ anyOf:
description: |
The original format of the time object

$ref: "#/definitions/format"
oneOf:
- $ref: "#/definitions/format"
- $ref: "#/definitions/other_format"

scale:
description: |
Expand Down