You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently all parameters that a user provides to run a specific task are treated as strings. When these values are passed to the task during its invocation, they are still strings.
e.g.: in leverage task1[3,cleaup=True], task1 will be invoked with arguments "3" and cleanup: "True"
The burden of interpreting these string values correctly is up to the developer that writes such tasks.
The same happens with values loaded from .env files when using conf.load() in a task.
The proposal is to try and cast these input values into their correct data type.
To avoid challenging border cases maybe only a couple of types could be initially supported, such as booleans, integers and floats, and let everything that cannot be converted into these types be a string.
Why
It will ease the tasks developer job since it is a very repeatitive and error prone chore.
The text was updated successfully, but these errors were encountered:
What
Currently all parameters that a user provides to run a specific task are treated as strings. When these values are passed to the task during its invocation, they are still strings.
e.g.: in
leverage task1[3,cleaup=True]
,task1
will be invoked with arguments"3"
andcleanup: "True"
The burden of interpreting these string values correctly is up to the developer that writes such tasks.
The same happens with values loaded from
.env
files when usingconf.load()
in a task.The proposal is to try and cast these input values into their correct data type.
To avoid challenging border cases maybe only a couple of types could be initially supported, such as booleans, integers and floats, and let everything that cannot be converted into these types be a string.
Why
It will ease the tasks developer job since it is a very repeatitive and error prone chore.
The text was updated successfully, but these errors were encountered: