Visual Studio 2019 上的 DotVVM 扩展安装错误

发布于 2025-01-20 00:57:16 字数 1782 浏览 4 评论 0 原文

我正在尝试在 Visual Studio 2019 中安装 DotVVM。现在,当我“管理扩展”时,我可以找到它,并且它下载和安装时不会出现错误。但是,当我在安装后重新启动 Visual Studio 时,收到一条错误消息,指出“DotVVM 包未正确加载”,并指向一个 xml 输出文件。该文件的内容显示:

SetSite 包 [DotvvmPackage] 失败 来源:System.ComponentModel.Composition 描述:该构图产生了多个构图错误,有 3 个根本原因。下面提供了根本原因。查看 CompositionException.Errors 属性以获取更多详细信息

  1. 未找到与约束匹配的导出:ContractName DotVVM.Integration.VisualStudio.Dialogs.DialogFactory requiredTypeIdentity DotVVM.Integration.VisualStudio.Dialogs.DialogFactory 结果:无法设置 import DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependency.DialogFactory ( ContractName='DotVVM.Integration.VisualStudio.DialogFactory') 上部分DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependency.Element:DotVVM.Integration.VisualStudio.VsPackages.DotvvmDependency.DialogFactory(ContractName ='DotVVM.Integration.VisualStudio.Dialogs.DialogFactory')DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependency
  • 未找到与约束匹配的导出: 几乎相同的错误,除了谈论“DotVVM.Integration.VisualStudio.Common.Licensing.ILoginProvider”
  • 未找到与约束匹配的导出:* 同样的错误,除了谈论“DotVVM.Integration.VisualStudio.Services.CommandService”
  • 现在我一直在尝试寻找其他主题,并遇到许多说要删除(或重命名)“%appData%”/Local/Microsoft/VisualStudio /16.0/ComponentModelCache' 文件夹,我尝试过但没有成功。也将其从每个 VisualStudio 版本文件夹中删除。当然之后重新启动了 Visual Studio。该文件夹确实会自行重建,但我再次遇到相同的错误。

    我也尝试过卸载并重新安装它。厌倦了以管理员身份运行 Visual Studio。甚至直接下载了 DotVVM.Integration.VisualStudio.2019.RTM.vsix 文件(4.0.534 和 4.0.539)并以这种方式安装,但没有成功。

    我还尝试完全卸载并重新安装 Visual Studio 2019,但没有成功。我确保整个 VisualStudio/16.0 文件夹在安装之间也消失了。

    我已经能够安装其他扩展了,只是为了看看。

    尝试安装时,我似乎丢失了某些内容或某些文件,但我不知道是什么。有什么想法吗?

    I'm attempting to install DotVVM in Visual Studio 2019. Right now I can find it when I 'manage extensions' and it downloads and installs without error. However when I restart Visual Studio post installation I get an error stating 'The DotVVM package did not load correctly' and points me to an xml output file. The contents of said file shows:

    SetSite failed for package [DotvvmPackage]
    Source: System.ComponentModel.Composition
    Description: The composition produced multiple composition errors, with 3 root causes. The root causes are provided below. Review the CompositionException.Errors property for more detailed information

    1. No exports were found that match the constraint: ContractName DotVVM.Integration.VisualStudio.Dialogs.DialogFactory RequiredTypeIdentity DotVVM.Integration.VisualStudio.Dialogs.DialogFactory Resulting in: Cannot set import DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependencies.DialogFactory (ContractName='DotVVM.Integration.VisualStudio.DialogFactory') on part DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependencies.Element: DotVVM.Integration.VisualStudio.VsPackages.DotvvmDependencies.DialogFactory (ContractName='DotVVM.Integration.VisualStudio.Dialogs.DialogFactory') DotVVM.Integration.VisualStudio.VsPackages.DotvvmPackageDependencies
    1. No exports were found that match the constraint:
      Pretty much the same error except it's talking about 'DotVVM.Integration.VisualStudio.Common.Licensing.ILoginProvider'
    1. No exports were found that match the constraint:*
      Same error except it's talking about 'DotVVM.Integration.VisualStudio.Services.CommandService'

    Now I have been trying to find other topics and came across many that said to delete (or rename) the '%appData%'/Local/Microsoft/VisualStudio/16.0/ComponentModelCache' folder which I've tried with no luck. Removed it out of every VisualStudio version folders as well. Restarted Visual Studio of course after. That folder did rebuild itself but I got the same error again.

    I've also tried uninstalling and reinstalling it as well. Tired with running Visual Studio as an admin for kicks. Even downloaded the DotVVM.Integration.VisualStudio.2019.RTM.vsix file directly (both 4.0.534 and 4.0.539) and installing it that way with no luck.

    I also tried fully uninstalling and reinstalling Visual Studio 2019 all together with no luck. I made sure the entire VisualStudio/16.0 folder was also gone between installs.

    I have been able to install other extensions alright just to see.

    It seems like I'm missing something or some files when it's trying to install, but I can't figure out what. Any ideas?

    如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

    扫码二维码加入Web技术交流群

    发布评论

    需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

    评论(1

    不打扰别人 2025-01-27 00:57:16

    事实证明,我的Visual Studio版本是问题所在。我的合作环境将我锁定到16.10.2,这不是最新版本。 Visual Studio更新声称我是最新的,但我不是。

    DOTVVM(4.0.539)的版本不支持Visual Studio的版本16.10.2,因此错误。我确实找到了DOTVVM(2.5.254)的较旧版本,该版本确实支持该版本的Visual Studio,并且效果很好。

    Turns out my version of Visual Studio was the issue. My cooperate environment locks me to 16.10.2 which is not the latest version. Visual Studio updates claims I'm up to date but I am not.

    The version of DotVVM (4.0.539) doesn't support version 16.10.2 of visual studio, hence the error. I did find an older version of DotVVM (2.5.254) that does support that version of visual studio and that worked fine.

    ~没有更多了~
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文