#Different behaviour between 0.16.2 and 0.16.3 for output of structs in CLI

1 messages · Page 1 of 1 (latest)

manic siren
#

I am noticing different behaviour between 0.16.2 and 0.16.3 releases when it comes to CLI output. Specifically, when printing structs or slices. For example, code similar to this

type Cycle struct {
    Cycle        string
    Discontinued string
    EOL          string
    Latest       string
    Link         string
    ReleaseDate  string
}

func (m Endoflife) Check(ctx context.Context, product string, cycle string) (Cycle, error) { ... }

0.16.2

$ dagger call check --product ruby --cycle 3.4
...
_type: EndoflifeCycle
cycle: ""
discontinued: ""
eol: "2028-03-31"
latest: 3.4.2
link: ""
releaseDate: "2024-12-24" 

0.16.3

$ dagger call check --product ruby --cycle 3.4
...
EndoflifeCycle@xxh3:8812325f60dacbf6 

Just wondering if this is an intended behaviour change?

#

Different behaviour between 0.16.2 and 0.16.3 for output of structs in CLI

vapid depot
manic siren
#

Thanks! Question, then: is there a different way to quickly inspect struct field values like previously in the cli?

vapid depot
#

Not right now, but we've discussed adding a .print builtin in shell to do that, if there's demand.

#

So you'd do:

dagger -c 'check ruby 3.4 | .print'