2 ms·
It is around where CircularWiringError is thrown from the implementation of topological sort. If the instantiation of the objects was not lazy, the topological
by compressedgas 10mo ago
It is around where CircularWiringError is thrown from the implementation of topological sort. If the instantiation of the objects was not lazy, the topological sort would have been applied to the entire dependency graph. As it is lazy, with objects being created when they are accessed CircularWiringError can be thrown upon access. I think this should never happen as it should be checked for in the Wiring constructor though the application of the topological sort.
- gaigalas 10mo agoYou are right, that is an overlook on my part. Throwing on the constructor makes much more sense than upon access. Thanks!
- gaigalas 10mo agoAgain, thanks for your feedback. Moving the topological sort not only yileded a better experience but actually simplified the code and thread model. I've made the changes and they'll be on the next version.