-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Support for YAML 1.2 #8970
Comments
Is anyone from |
@taldcroft - would you think we could just swap the usage of pyyaml with |
Supporting both is not good I think. Because if you have a plain yaml file, it will depend on the library if it is interpreted as 1.1 or 1.2 file. I found that ruamel.yaml could just be used as a drop in replacement. The usage of the things that got removed from 1.1 to 1.2 is pretty rare I think. You should be able to check if astropy config files even could make use of them. |
I don't think we can just drop pyyaml and say that from now on we have the other without a deprecation period, but if @taldcroft thinks we can do it, I'm OK with it. |
My 2 cents: I'm not sure if switching to Note that I don't know who the The most heavy use of YAML is probably ASDF, so if someone is seriously considering changing Astropy from |
There is an ASDF PR but it is not merged yet; xref asdf-format/asdf#677 |
One thing about That API change might be a good thing in the end, but it seems that right now it might just introduce a lot of churn and trouble for astropy to first transition to the <0.15 API and then we have the mess of possibly supporting <0.15 and 0.15+ tl;dr - I would propose to wait for |
As discussed over at gammapy/gammapy#2218 (comment),
@bsipocz asked me to raise this issue here.
the
pyyaml
library only supports the YAML 1.1 standard from 2005, while only YAML 1.2 added support for scientific notation floating point values.Summary of differences here:
https://yaml.readthedocs.io/en/latest/pyyaml.html
This is why many packages, e.g. conda itself, switch to
ruamel.yaml
:https://yaml.readthedocs.io/en/latest/index.html
The text was updated successfully, but these errors were encountered: