This message was deleted.
# python
s
This message was deleted.
b
Hi Piotr! Fancy seeing you here! Normally, you’d pass an ID so the chain of dependencies is very clear. This is also how most Pulumi objects would do it. Can you let me know why you would want to pass the entire object?
a
Hi @billowy-engine-58246. Lets say my
Bar
Resource needs 3 parameters related to
Foo
resource. Then I think it will be more user friendly to write:
Copy code
Bar(
    name="my_resource_name",
    foo_object=foo_resource,
)
rather than
Copy code
Bar(
    name="my_resource_name",
    foo_input_1=foo_resource.foo_out_1,
    foo_input_2=foo_resource.foo_out_2,
    foo_input_3=foo_resource.foo_out_3,
)
Maybe I am wrong and this is an anti pattern? What are a good practices here?