Commit Graph

3 Commits

Author SHA1 Message Date
Fraser Waters dd35a2a94f Fix diff display partially parsing JSON/YAML
Fixes https://github.com/pulumi/pulumi/issues/10312

When attempting to decode a string property value as JSON or YAML the
decoder would return a partial parse as valid. This resulted in strings
like "{} stuff" being reported as an empty JSON object, rather than the
literal string "{} stuff".

This also fixes the decoder to ignore whitespace around the value so for
example "   [1, 2]   " is now treated as a JSON array, not a string
literal.
2023-06-22 09:31:10 +01:00
Fraser Waters d1fedb0405 Don't print large integers in scientfic notation
Fixes https://github.com/pulumi/pulumi/issues/13016
2023-06-20 12:44:15 +01:00
Pat Gavlin f8f4b932cb [cli/diff] Tighten the YAML value heuristic
Only attempt to decode _multi-line_ strings as YAML values. This avoids
decoding simple strings like "foo: bar" or "-" as YAML.

Fixes .
2023-03-09 17:21:35 -08:00