pyyaml icon indicating copy to clipboard operation
pyyaml copied to clipboard

YAML 1.2 Core Schema support (about yes/no, on/off, 07 vs 08)

Open perlpunk opened this issue 4 years ago • 2 comments

... or how to get rid of the no(rway) problem

Issue to track necessary changes for supporting the YAML 1.2 Core schema.

Suggested steps

  • Add a test for YAML 1.1 types that can be easily extended for 1.2 testing https://github.com/yaml/pyyaml/pull/483
  • Move around methods from SafeLoader to BaseLoader, and add methods to load a whole group of tags, so that users can choose tags in a more modular way
  • Add methods for loading 1.2 Core tags. Since 1.1 and 1.2 share some tags, the previous step will be helpful to save some code (The same has to be done for the Dumper/Representer of course) https://github.com/yaml/pyyaml/issues/555

Users will then be able to explicitly choose between the classic, default 1.1 SafeLoader and the Core Loader. Ideally things like merge keys and other tags (that are now on by default and can't be turned off) can be chosen optionally.

Related issues

The following issues/PRs are more or less related to 1.2, and some can simply be fixed when the users have the possibility to choose 1.2 Core instead of 1.1.

  • https://github.com/yaml/pyyaml/issues/19
  • https://github.com/yaml/pyyaml/issues/53
  • https://github.com/yaml/pyyaml/issues/89
  • https://github.com/yaml/pyyaml/issues/98
  • https://github.com/yaml/pyyaml/issues/116
  • https://github.com/yaml/pyyaml/issues/168
  • https://github.com/yaml/pyyaml/issues/173
  • https://github.com/yaml/pyyaml/pull/174
  • https://github.com/yaml/pyyaml/issues/247
  • https://github.com/yaml/pyyaml/pull/248
  • https://github.com/yaml/pyyaml/issues/414
  • https://github.com/yaml/pyyaml/issues/470
  • https://github.com/yaml/pyyaml/issues/473
  • https://github.com/yaml/pyyaml/issues/524
  • https://github.com/yaml/pyyaml/issues/577
  • https://github.com/yaml/pyyaml/issues/608
  • https://github.com/yaml/pyyaml/issues/613
  • https://github.com/yaml/pyyaml/issues/661
  • https://github.com/yaml/pyyaml/issues/667
  • https://github.com/yaml/pyyaml/issues/679
  • https://github.com/yaml/pyyaml/issues/696
  • https://github.com/yaml/pyyaml/issues/697
  • https://github.com/yaml/pyyaml/issues/740
  • https://github.com/yaml/pyyaml/issues/741
  • https://github.com/yaml/pyyaml/issues/744
  • https://github.com/yaml/pyyaml/issues/773
  • https://github.com/yaml/pyyaml/issues/774
  • https://github.com/yaml/pyyaml/issues/794
  • https://github.com/yaml/pyyaml/issues/807
  • https://github.com/yaml/pyyaml/issues/826

perlpunk avatar Jan 29 '21 16:01 perlpunk

https://github.com/yaml/pyyaml/pull/512 adds CoreLoader/CoreDumper, JSONLoader/JSONDumper

perlpunk avatar Mar 26 '21 19:03 perlpunk