You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The fx.Dotgraph displayed when visualizing the dependency graph is incorrect when using the new fx.Private variable.
To Reproduce
For the following code it prints as expected "foo\nbar" meaning ModuleB has a dependency on ModuleA and ModuleC has a dependency on AnotherModuleA.
Yet the fx.DotGraph printed looks like this where the incorrect edge is highlighted in red.
Expected behavior
My expectation is the dotgraph look like this again the corrected edge is highlighted in red.
Additional Context
While this bug is a subtle point, the visualization helps a lot when using new features like fx.Private to determine usage is correctly understood and seeing an incorrect visualization creates confusion and makes the user think they are the ones doing something wrong.
The text was updated successfully, but these errors were encountered:
rossb83
changed the title
fx.Private yields incorrect fx.Dotgraph
fx.Private yields incorrect fx.Dotgraph visualization
Jan 5, 2023
Thanks for reporting this. There are actually a couple issues with the graph visualization in addition to this at the moment. For example, decorators aren't represented, and neither are modules. I've reproduced your bug and filed an internal ticket to update the graph visualization code and fix these issues, ref: GO-1797.
Describe the bug
The
fx.Dotgraph
displayed when visualizing the dependency graph is incorrect when using the newfx.Private
variable.To Reproduce
For the following code it prints as expected "foo\nbar" meaning
ModuleB
has a dependency onModuleA
andModuleC
has a dependency onAnotherModuleA
.Yet the
fx.DotGraph
printed looks like this where the incorrect edge is highlighted in red.Expected behavior
My expectation is the dotgraph look like this again the corrected edge is highlighted in red.
Additional Context
While this bug is a subtle point, the visualization helps a lot when using new features like
fx.Private
to determine usage is correctly understood and seeing an incorrect visualization creates confusion and makes the user think they are the ones doing something wrong.The text was updated successfully, but these errors were encountered: