gpt4 book ai didi

powershell - 在 Windows 10 上安装 Ganache.appx

转载 作者:行者123 更新时间:2023-12-02 22:39:37 27 4
gpt4 key购买 nike

我在 PowerShell 中使用以下命令在我的 Windows 10 机器上安装 Truffle 的 Ganache:

Add-AppxPackage -Path "C:\Users\mabel\Downloads\Ganache.appx"

每当我运行该命令时,都会出现以下错误:
    Add-AppxPackage : Deployment failed with HRESULT: 0x80073CFD, A Prerequisite for an install could not be satisfied.
Deployment Add operation with target volume C: on Package Ganache_1.0.1.0_x64__zh355ej5cj694 from: (Ganache.appx)
failed with error 0x80073CFD. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment
issues.
NOTE: For additional information, look for [ActivityId] 1e4d6f55-8379-0000-3191-4d1e7983d301 in the Event Log or use
the command line Get-AppxLog -ActivityID 1e4d6f55-8379-0000-3191-4d1e7983d301
At line:1 char:1
+ Add-AppxPackage -Path "C:\Users\mabel\Downloads\Ganache.appx"
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (C:\Users\mabel\Downloads\Ganache.appx:String) [Add-AppxPackage], Exceptio
n
+ FullyQualifiedErrorId : DeploymentError,Microsoft.Windows.Appx.PackageManager.Commands.AddAppxPackageCommand

我深入挖掘了诊断并运行命令 Get-AppxLog -ActivityID 1e4d6f55-8379-0000-3191-4d1e7983d301,并获得以下日志详细信息:
Time                      ID           Message
---- -- -------
1/1/2018 8:13:38 PM 301 The calling process is powershell.exe
1/1/2018 8:13:38 PM 603 Started deployment Add operation on a package with main parameter: Ganache.appx and
Options: 0. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app
deployment issues.
1/1/2018 8:13:41 PM 157 The app package signature was validated for core content of the app package published
by CN=Consensys Inc, O=Consensys Inc, L=New York, S=New York, C=US. Payload won't be
validated until the files are read.
1/1/2018 8:13:42 PM 170 The streaming reader was created successfully for app package
Ganache_1.0.1.0_x64__zh355ej5cj694.
1/1/2018 8:13:42 PM 10002 Creating Resiliency File C:\ProgramData\Microsoft\Windows\AppRepository\edc8d325-87ef-
46b9-93c2-cf029ff3f8f4_S-1-5-21-2104190792-3376611798-3824734217-1001_1.rslc for Add
Operation on Package Ganache_1.0.1.0_x64__zh355ej5cj694.
1/1/2018 8:13:42 PM 607 Deployment Add operation on package Ganache_1.0.1.0_x64__zh355ej5cj694 has been
de-queued and is running for user DESKTOP-8NHB92D\mabel.
1/1/2018 8:13:42 PM 613 Adding uri to the list of Uris: file:///C:/Users/mabel/Downloads/Ganache.appx.
1/1/2018 8:13:42 PM 605 The last successful state reached was BundleProcessed. Failure occurred before
reaching the next state Indexed.
1/1/2018 8:13:42 PM 401 Deployment Add operation with target volume C: on Package
Ganache_1.0.1.0_x64__zh355ej5cj694 from: (Ganache.appx) failed with error
0x80073CFD. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app
deployment issues.
1/1/2018 8:13:42 PM 404 AppX Deployment operation failed for package Ganache_1.0.1.0_x64__zh355ej5cj694 with
error 0x80073CFD. The specific error text for this failure is: Deployment Add
operation with target volume C: on Package Ganache_1.0.1.0_x64__zh355ej5cj694 from:
(Ganache.appx) failed with error 0x80073CFD. See
http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment
issues.

Windows 论坛建议我确保 Windows 已完全更新,我上次更新它是在一小时前。

错误中的链接显示“无法满足指定的安装先决条件”。我拥有安装和运行 testrpc/ganache cmd 行的所有先决条件。在安装 Ganache UI 之前,我需要采取任何步骤吗?

最佳答案

我遇到了同样的错误,因为我的 Windows 版本没有更新。

将 .appx 文件作为 zip 文件打开
根目录中有一个文件:AppxManifest.xml

有一个关于先决条件的可选部分。
但在此之前是具有最低 Windows 版本的依赖项条目。
<Dependencies>
<TargetDeviceFamily Name="Windows.Desktop" MinVersion="10.0.14316.0" MaxVersionTested="10.0.14316.0" />
</Dependencies>

然后我检查了 powershell 以获取我的 dot 版本:

PS C:\Users\XXXXX\> [System.Environment]::OSVersion.Version

Major Minor Build Revision
----- ----- ----- --------
10 0 10240 0

14316 > 10240,所以我的操作系统太旧了。

关于powershell - 在 Windows 10 上安装 Ganache.appx,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48055608/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com