kurtosis-tech / kurtosis

A platform for packaging and launching ephemeral backend stacks with a focus on approachability for the average developer.
https://docs.kurtosistech.com/
Apache License 2.0
353 stars 52 forks source link

Parsing struct via arguments is broken #2312

Open tedim52 opened 6 months ago

tedim52 commented 6 months ago

What's your CLI version?

0.88.7

Description & steps to reproduce

Running kurtosis run main.star '{"some_parameter": {"_kurtosis_parser": "struct", "some_property": "Property value"}}' against

def run(plan, some_parameter=struct(some_property = "Property Value")):
    plan.print(some_parameter)
    plan.print(some_parameter.some_property)

Outputs:

There was an error interpreting Starlark code
Evaluation error: dict has no .some_property field or method
    at [3:27]: run

Error encountered running Starlark code.

meaning some_parameter is not getting parsed as a struct as describe here: https://docs.kurtosis.com/run/#arguments

Desired behavior

structs are parsed via arguments for --args-file in yaml and json as well.

What is the severity of this bug?

Critical; I am blocked and Kurtosis is unusable for me because of this bug.

What area of the product does this pertain to?

CLI: the Command Line Interface

h4ck3rk3y commented 6 months ago

I wonder if we can just deprecate this flow completely? Who uses this?