Skip to content

dhall-to-yaml and dhall-to-yaml-ng quote inconsistently #1516

@sjakobi

Description

@sjakobi
dhall-yaml
  ./tasty/data/quoted
    HsYAML:     OK
    aeson-yaml: FAIL
      tasty/Main.hs:59:
      Conversion to YAML did not generate the expected output
      expected: "'bool_value': true\n'int_value': 1\n'string_value': '2000-01-01'\n'text': |\n  Plain text\n'yes': 'y'\n"
       but got: "'bool_value': true\n'int_value': 1\n'string_value': \"2000-01-01\"\n'text': |\n  Plain text\n'yes': 'y'\n"

According to @patrickmn, aeson-yaml

single-quote[s] "safe" strings and double-quote unsafe, and number/dates are part of the unsafes.

which seems reasonable to me. So if a fix in aeson-yaml turns out to be very tricky, IMHO we could also try adjusting the HsYAML-based code to follow the same scheme.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions