runn icon indicating copy to clipboard operation
runn copied to clipboard

Encountering Strange Behavior when upgrading runn

Open okazaki-kk opened this issue 1 year ago • 4 comments

Hello! Thanks for this awesome software !

This is a very rare case and we may not have to take care of it, but I would like to report that when I update runn, the behavior was different and the error message reported strange lines.

In versions up to v0.92, example.yml passes, but in v0.93 and later, an error occurs. Perhaps the backquote on line 7 is recognized as an invalid string, but the error message says line 4 is invalid. This discrepancy is probably caused by the three lines of comments.

example.yml

desc: Example
# comment
# comment
# comment
steps:
  hello:
    desc: '`echo` hello' # ⇦ Single quote followed by backquote, line 7
    dump: "'Hello world!'"

version 0.100 (error)

➜  runn git:(main) runn --version      
runn version 0.100.0
➜  runn git:(main) runn run example.yml
Error: failed to load runbook example.yml: yaml: line 4: found character that cannot start any token

version0.92 (pass)

➜  runn git:(main) runn --version                   
runn version 0.92.0
➜  runn git:(main) ✗ runn run example.yml             
Hello world!
.

1 scenario, 0 skipped, 0 failures

okazaki-kk avatar Mar 27 '24 03:03 okazaki-kk

@okazaki-kk Thank you for your report!

I will see which is the correct behavior.

k1LoW avatar Mar 27 '24 05:03 k1LoW

The behavior of v0.92.0 was found to be correct.

We are currently finding the cause and fixing it.

k1LoW avatar Mar 28 '24 13:03 k1LoW

We will be able to fix this when https://github.com/goccy/go-yaml/pull/440 is merged and released.

k1LoW avatar Apr 10 '24 00:04 k1LoW

@okazaki-kk Fixed at v0.104.0

k1LoW avatar Apr 22 '24 15:04 k1LoW

Fixed https://github.com/goccy/go-yaml/releases/tag/v1.12.0

k1LoW avatar Jul 17 '24 00:07 k1LoW