AliSoftware/Dip

Eager singletons recreated when using collaborating containers

zintus opened this issue · 2 comments

Hello and thanks for awesome project!

I'm using number of collaborating containers and i have Main service in one of them and Dependency service in other container, registered as .eagerSingleton.

When i'm resolving instance of Main from container where it's registered, new instance of Dependency is created, thus breaking .eagerSingleton contract. If i move all definitions to single container, everything works as expected.

@zintus can you submit a pr with failing test?

@ilyapuchka pulling issue details from memory i can't write test reproducing the issue.

Let's consider this closed for now.