https://kedro.org/ logo
#random
Title
# random
n

Nok Lam Chan

03/27/2024, 11:45 AM
To my surprise, I forgot to type the
%
but
reload_kedro
seems to behave just like
%reload_kedro
, maybe it's a IPython specific thing?
d

datajoely

03/27/2024, 11:48 AM
huh, surprising
n

Nok Lam Chan

03/27/2024, 11:51 AM
Hm... that's too magical.
reload_kedro(".")
and
reload_kedro .
both run (The former one fail with error but is valid syntax, the latter run successfully as expected)
d

datajoely

03/27/2024, 11:52 AM
what about with quotes?
oh no
yeah the first one is the only thing that makes sense
n

Nok Lam Chan

03/27/2024, 11:54 AM
It seems that
reload_kedro()
is triggering the python function while
reload_kedro .
is triggering the magic instead.
I am not sure how it works, it doesn't get imported to the local namespace.
d

datajoely

03/27/2024, 12:02 PM
Magic is literally in the name
😂 4
j

Juan Luis

03/27/2024, 12:47 PM
yeah IPython is famous for making these kind of decisions to "simplify" scientists workflow... side effect is making everything more confusing
f

FlorianGD

03/27/2024, 4:20 PM
You can also try
ls
(which I think is expanded to
!ls
, or maybe
%ls
and could be confusing also)
👀 1