Skip to content

Commit d18c043

Browse files
committed
Include the yaml content that failed to parse
1 parent 7736e1b commit d18c043

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

rewrite-yaml/src/main/java/org/openrewrite/yaml/MergeYaml.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,6 @@ private static Optional<Yaml.Block> maybeParse(@Language("yml") String yaml) {
278278

279279
static Yaml parse(@Language("yml") String yaml) {
280280
return maybeParse(yaml)
281-
.orElseThrow(() -> new IllegalArgumentException("Could not parse as YAML"));
281+
.orElseThrow(() -> new IllegalArgumentException("Could not parse as YAML:\n" + yaml));
282282
}
283283
}

0 commit comments

Comments
 (0)