VS 2010 Layer Diagram Validation Error is Showing A Dependency That Doesn't Even Exist (AV0001)
I'm getting the following validation error on my layer diagram:
Error 65 AV0001 : Invalid Dependency : Weld.Interface.Core(Assembly) --> Weld.Interface(Namespace) Layers: Application Framework Core, Application Framework | Dependencies: Namespace Refe开发者_运维知识库rence D:\Projects\Windows Projects\Weld\Weld\ModelingProject1\Weld.layerdiagram 0 0 ModelingProject1
These 2 assemblies are set up as different layers and the assembly name represents the namespace starting point as well.
Weld.Interface.Core: This assembly and namespace does not have a reference to Weld.Interface and only references .NET Framework classes
Weld.Interface: This assembly and namespace does not have a reference to Weld.Interface.Core
There is no dependency between these two layers in the dependency diagram. I am confused why I am getting this error. No dependency in the project or code, and no dependency is even setup in the layer diagram.
Somehow the Validation logic in the layer diagram is seeing a non existent dependency and saying it is an error.
Any ideas what either I might have missed or what is causing this problem?
OK, I figured out what was going on with my situation and thought I'd pass it along here. It appears to be an issue of cached references to assemblies. When the modeling project was originally created, it was in its own solution, separate from the assemblies it's intending to model. As such, it required listing them within the Layer References for the Modeling project.
The project has since been incorporated into the overall solution, but I believe the project references originally declared when separate from the solution kept precedence and, ultimately, was referencing old code. I removed the assemblies from the Layer References of the Modeling project and everything was smooth sailing after that.
精彩评论