Open myitcv opened 1 month ago
Thanks to @tvandinther for another repro:
env CUE_EXPERIMENT=embed
# export as yaml
exec cue export ./... --out yaml -e json
stdout '^foo: bar$'
# cmd dump
exec cue cmd dump
stdout '^foo: bar$'
-- test.cue --
@extern(embed)
package test
json: _ @embed(file=test.json)
-- test_tool.cue --
package test
import (
"tool/cli"
"encoding/yaml"
)
command: dump: {
task: print: cli.Print & {
text: yaml.Marshal(json)
}
}
-- test.json --
{
"foo": "bar"
}
This test should also pass, but currently fails with:
# export as yaml (0.012s)
# cmd dump (0.010s)
> exec cue cmd dump
[stderr]
command.dump.task.print.text: invalid string argument: non-concrete argument 0:
./test_tool.cue:9:8
./test_tool.cue:10:3
./test_tool.cue:10:9
tool/cli:4:3
[exit status 1]
FAIL: /tmp/testscript382573103/repro.txtar/script.txtar:8: unexpected command failure
What version of CUE are you using (
cue version
)?Does this issue reproduce with the latest release?
Yes
What did you do?
What did you expect to see?
Passing test.
What did you see instead?
Thanks to @seankhliao for reporting.