https://kedro.org/ logo
#questions
Title
# questions
m

Massinissa Saïdi

02/20/2023, 5:54 PM
Hello kedroids ! Do you know how to pass boolean parameter in CLI ?
kedro run --params key:false
or
kedro run --params key:False
return string
'False' or 'false'
. I know i cant set parameter to 0 or '' to have the false condition but there is a better way ? thx 🙂
d

datajoely

02/20/2023, 5:56 PM
so I’ve just created a ticket for this - for now things will always coerce till strings!
if you really want custom behaviour you can define your own
run
method
m

Massinissa Saïdi

02/20/2023, 5:57 PM
thanks for you quickly answer ! 🙂
I wrote it this morning! another user mentioned this last week
commenting on the issue always helps bump up the priority!
👍 1
m

Massinissa Saïdi

02/20/2023, 5:58 PM
ok perfect 🙂 thx
a

Antony Milne

02/20/2023, 9:02 PM
Just to check, this doesn’t resolve to boolean if you use the new 0.18.5 syntax with
=
instead of
:
?
n

Nok Lam Chan

02/21/2023, 7:08 AM
I am testing with latest version, both syntax resolves the boolean correctly for me
👍 1
This PR https://github.com/kedro-org/kedro/pull/2120/files already solve this problem, I dropped a comment on the metioned GH issue.
@Massinissa Saïdi Can you try upgrading kedro with
pip install kedro==0.18.5
if you are on
0.18.x
versions? We just released it today! Would be great if you can confirm this fix the issue .
👍 1
🥳 1