Closed liamhuber closed 3 months ago
I discovered today that iPython is not playing well with node injection, in particular the GetAttr injection.
GetAttr
This is totally fine:
from pyiron_workflow import Workflow wf = Workflow("tmp") wf.foo = Workflow.create.standard.UserInput("some_value") print(wf.node_labels) >>> ('foo',) wf.foo print(wf.node_labels) >>> ('foo',)
Exactly as expected. But, if you split it into two cells, iPython is doing some attribute access nonsense that winds up injecting an extra node!
Cell 1: as expected
from pyiron_workflow import Workflow wf = Workflow("tmp") wf.foo = Workflow.create.standard.UserInput("some_value") print(wf.node_labels) >>> ('foo',) wf.foo
Cell 2: reveals the problem
print(wf.node_labels) >>> ('foo', 'foo__user_input_GetAttr__ipython_canary_method_should_not_exist_')
This doesn't functionally impact us by breaking anything, because these are just little dead-end nodes, but it is certainly undesirable and bloats storage, etc.
I discovered today that iPython is not playing well with node injection, in particular the
GetAttr
injection.This is totally fine:
Exactly as expected. But, if you split it into two cells, iPython is doing some attribute access nonsense that winds up injecting an extra node!
Cell 1: as expected
Cell 2: reveals the problem
This doesn't functionally impact us by breaking anything, because these are just little dead-end nodes, but it is certainly undesirable and bloats storage, etc.