Skip to content

Install failed: An internal error occurred with error 0x800700B7 #1097

Closed

Description

@AskAlice

Brief description of your issue

winget install wingetcreate fails

Steps to reproduce

not really sure. All i did was run winget install wingetcreate

Found Windows Package Manager Manifest Creator [Microsoft.WingetCreate]
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Successfully verified installer hash
Starting package install...
  ██████████████████████████████  96%
Install failed: An internal error occurred with error 0x800700B7. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.
0x800700b7 : Cannot create a file when that file already exists.

Expected behavior

it didn't fail.

Actual behavior

it failed.

 💖❯  winget install wingetcreate       
Found Windows Package Manager Manifest Creator [Microsoft.WingetCreate]
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Successfully verified installer hash
Starting package install...
  ██████████████████████████████  96%
Install failed: An internal error occurred with error 0x800700B7. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.
0x800700b7 : Cannot create a file when that file already exists.
 💖❯  Get-Command wingetcreate
Get-Command : The term 'wingetcreate' is not recognized as the name of a cmdlet, function, script file, or operable program. Check
the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ Get-Command wingetcreate
+ ~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (wingetcreate:String) [Get-Command], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException,Microsoft.PowerShell.Commands.GetCommandCommand

Environment

Windows Package Manager Manifest Creator version? (wingetcreate.exe -?)
n/a
Any other software?
Windows 10 Build 21390.1

Activity

  1. denelon commented on Jun 3, 2021

    @denelon
    Collaborator

    Alice Knag (@AskAlice) can you share the output from winget --info. I'm wondering what version of the client you have.

  2. ghost added
    Needs-Triage
    on Jun 3, 2021
  3. added
    Issue-Bug
    Needs-Author-Feedback
    and removed
    Needs-Triage
    on Jun 3, 2021
  4. iDolmatov commented on Jun 3, 2021

    @iDolmatov

    What about similar commands?
    winget list --id wingetcreate
    winget upgrade wingetcreate
    winget uninstall wingetcreate

  5. denelon commented on Jun 3, 2021

    @denelon
    Collaborator

    Долматов Алексей (@iDolmatov) winget list doesn't support "filtering" by manifest metadata yet. There is a feature on the backlog.

  6. iDolmatov commented on Jun 3, 2021

    @iDolmatov

    Долматов Алексей (@iDolmatov) winget list doesn't support "filtering" by manifest metadata yet. There is a feature on the backlog.

    image

    If the application is missing or removed, then this is how:

    PS C:\Users\Dolma> winget uninstall wingetcreate
    Найдено Windows Package Manager Manifest Creator [Microsoft.WingetCreate]
    Запуск удаления пакета...
    ██████████████████████████████ 100%
    Удалено
    PS C:\Users\Dolma> winget list --id wingetcreate
    Не найдены установленные пакеты, соответствующие введенным условиям.

  7. denelon commented on Jun 3, 2021

    @denelon
    Collaborator

    Долматов Алексей (@iDolmatov) I stand corrected and very happy!

    I think the team may have forgotten to update the status on the feature 😃. I'll go double check and update if it's complete.

  8. AskAlice commented on Jun 3, 2021

    @AskAlice
    Author
     💖❯  winget --info
    Windows Package Manager v1.0.11451
    Copyright (c) Microsoft Corporation. All rights reserved.
    
    Windows: Windows.Desktop v10.0.21390.1
    Package: Microsoft.DesktopAppInstaller v1.11.11451.0
    
    Logs: %LOCALAPPDATA%\Packages\Microsoft.DesktopAppInstaller_8wekyb3d8bbwe\LocalState\DiagOutputDir
    
    Links
    --------------------------------------------------------
    Privacy Statement   https://aka.ms/winget-privacy
    License Agreement   https://aka.ms/winget-license
    Third Party Notices https://aka.ms/winget-3rdPartyNotice
    Homepage            https://aka.ms/winget
     💖❯  winget uninstall wingetcreate
    No installed package found matching input criteria.
    
  9. ghost added
    Needs-Attention
    on Jun 3, 2021
  10. ghost removed
    Needs-Author-Feedback
    on Jun 3, 2021
  11. removed
    Needs-Attention
    on Jun 3, 2021
  12. denelon commented on Jun 3, 2021

    @denelon
    Collaborator

    Alice Knag (@AskAlice) OK, so you are on the current version. What do you get from winget list wingetcreate? On my machine with the tool installed, I see:

    PS C:\Users\denelon> winget list wingetcreate
    Name                                     Id                     Version
    -----------------------------------------------------------------------
    Windows Package Manager Manifest Creator Microsoft.WingetCreate 0.1.0.1
    
  13. 1 remaining item

  14. AskAlice commented on Jun 3, 2021

    @AskAlice
    Author
    2021-06-03 17:37:44.168 [CORE] Subkey 'Software\Policies\Microsoft\Windows\AppInstaller' was not found
    2021-06-03 17:37:44.168 [CORE] Setting action: Get, Type: UserFile, Name: settings.json
    2021-06-03 17:37:44.175 [CORE] Setting action: Get, Type: UserFile, Name: settings.json.backup
    2021-06-03 17:37:44.182 [CORE] Valid settings file not found. Using default values.
    2021-06-03 17:37:44.182 [CORE] WinGet, version [1.0.11451], activity [{01DC6B3F-6071-4D6A-BD19-95EC43294C55}]
    2021-06-03 17:37:44.183 [CORE] OS: Windows.Desktop v10.0.21390.1
    2021-06-03 17:37:44.183 [CORE] Command line Args: "C:\Users\alice\AppData\Local\Microsoft\WindowsApps\winget.exe" install wingetcreate
    2021-06-03 17:37:44.183 [CORE] Package: Microsoft.DesktopAppInstaller v1.11.11451.0
    2021-06-03 17:37:44.187 [CLI ] WinGet invoked with arguments: 'install' 'wingetcreate'
    2021-06-03 17:37:44.188 [CLI ] Found subcommand: install
    2021-06-03 17:37:44.188 [CLI ] Leaf command to execute: root:install
    2021-06-03 17:37:44.188 [CLI ] Executing command: install
    2021-06-03 17:37:44.188 [CORE] Setting action: Get, Type: Secure, Name: user_sources
    2021-06-03 17:37:44.193 [CORE] Setting action: Get, Type: Standard, Name: sources_metadata
    2021-06-03 17:37:44.193 [REPO] Default source requested, only 1 source available, using the only source: winget
    2021-06-03 17:37:44.193 [CORE] Setting action: Get, Type: Secure, Name: user_sources
    2021-06-03 17:37:44.193 [CORE] Setting action: Get, Type: Standard, Name: sources_metadata
    2021-06-03 17:37:44.193 [REPO] Named source requested, found: winget
    2021-06-03 17:37:44.207 [CORE] Examining extension: PFN = Microsoft.Winget.Source_8wekyb3d8bbwe, ID = IndexDB
    2021-06-03 17:37:44.207 [CORE] Found matching extension.
    2021-06-03 17:37:44.240 [REPO] Opening SQLite Index for ImmutableRead at 'C:\Program Files\WindowsApps\Microsoft.Winget.Source_2021.603.2323.258_neutral__8wekyb3d8bbwe\Public\index.db'
    2021-06-03 17:37:44.240 [SQL ] Opening SQLite connection: 'file:/C:/Program Files/WindowsApps/Microsoft.Winget.Source_2021.603.2323.258_neutral__8wekyb3d8bbwe/Public/index.db?immutable=1' [1, 40]
    2021-06-03 17:37:44.241 [REPO] Opened SQLite Index with version [1.3], last write [2021-06-03 16:23:18.000]
    2021-06-03 17:37:44.294 [CLI ] Found one app. App id: Microsoft.WingetCreate App name: Windows Package Manager Manifest Creator
    2021-06-03 17:37:44.296 [REPO] Downloading manifest
    2021-06-03 17:37:44.296 [CORE] WinINet downloading from url: https://winget.azureedge.net/cache/manifests/m/Microsoft/WingetCreate/0.1.0.1/d664-Microsoft.WingetCreate.yaml
    2021-06-03 17:37:44.559 [CORE] Download hash: 9ee911b968d22ad12ab1a59944d0ec2ab3d7063c6bd36b15b77a35abd2f3e25c
    2021-06-03 17:37:44.559 [CORE] Download completed.
    2021-06-03 17:37:44.560 [CLI ] Manifest fields: Name [Windows Package Manager Manifest Creator], Version [0.1.0.1]
    2021-06-03 17:37:44.562 [CLI ] Starting installer selection.
    2021-06-03 17:37:44.562 [CLI ] Completed installer selection.
    2021-06-03 17:37:46.781 [CLI ] Installer hash verified
    2021-06-03 17:37:46.781 [CORE] Starting AddPackage operation #0: https://github.com/microsoft/winget-create/releases/download/v0.1.0.1-preview/Microsoft.WindowsPackageManagerManifestCreator_0.1.0.1_8wekyb3d8bbwe.msixbundleSkipSmartScreen: 1
    2021-06-03 17:37:46.784 [CORE] Begin waiting for deployment #0
    2021-06-03 17:37:46.784 [CORE] Begin blocking for deployment #0
    2021-06-03 17:37:56.590 [CORE] Deployment failed #0: An internal error occurred with error 0x800700B7. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.
    2021-06-03 17:37:56.590 [FAIL] C:\BA\311\s\external\pkg\src\AppInstallerCommonCore\Deployment.cpp(50)\AppInstallerCLI.exe!00007FF6FC64D949: (caller: 00007FF6FC64E0C9) Exception(1) tid(ec54) 800700B7 Cannot create a file when that file already exists.
    
        Msg:[Install failed: An internal error occurred with error 0x800700B7. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.] 
    
    2021-06-03 17:37:56.591 [CLI ] MSIX installer failed: 2147942583
    2021-06-03 17:37:56.591 [CLI ] Terminating context: 0x800700b7 at C:\BA\311\s\external\pkg\src\AppInstallerCLICore\Workflows\InstallFlow.cpp:168
    

    hopefully C:\BA\311\s\external\pkg\src\AppInstallerCLICore\Workflows\InstallFlow.cpp:168 you can find the source for in private microsoft repos, or maybe the C:\BA\311\s\external\pkg\src\AppInstallerCommonCore\Deployment.cpp(50)

    It is possible some of the ACLs in my microsoft store package folders are messed up. Regardless this is an unhelpful error as I can't figure out where in the filesystem it's failing. I was hoping winget would have circumvented all of the ridiculousness that is UWP and microsoft store, I guess I was wrong.

    Perhaps there is a way of using process hacker to figure out the last file it tries to access before it hits this fault?

  15. denelon commented on Jun 4, 2021

    @denelon
    Collaborator

    Alice Knag (@AskAlice) thank you so much for the logs! I'll share this with both teams to see if we can figure out what is happening. Can you download and double-click the wingetcreate installer from the GitHub release page, or di you get the same error?

  16. AskAlice commented on Jun 4, 2021

    @AskAlice
    Author

    Alice Knag (@AskAlice) thank you so much for the logs! I'll share this with both teams to see if we can figure out what is happening. Can you download and double-click the wingetcreate installer from the GitHub release page, or di you get the same error?

    The MSIX fails,

    and the binary runs here but fails due to deps

     💖❯  .\wingetcreate.exe
    The required library C:\Program Files\dotnet\host\fxr\3.1.13\hostfxr.dll does not support single-file apps.
      _ To run this application, you need to install a newer version of .NET Core.
    
      - https://aka.ms/dotnet-core-applaunch?missing_runtime=true&arch=x64&rid=win10-x64&apphost_version=5.0.5
    
  17. palenshus commented on Jun 4, 2021

    @palenshus
    Contributor

    Thanks! Regarding running the exe directly, you do need to have the .NET 5 runtime installed. Per microsoft/winget-create#38 we do plan to release another standalone exe which is entirely self-contained. In the meantime you should be able to install .NET to get unblocked.

    Hopefully your MSIX install issue will be figured out soon too!

  18. AskAlice commented on Jun 4, 2021

    @AskAlice
    Author

    Thanks! Regarding running the exe directly, you do need to have the .NET 5 runtime installed. Per microsoft/winget-create#38 we do plan to release another standalone exe which is entirely self-contained. In the meantime you should be able to install .NET to get unblocked.

    Hopefully your MSIX install issue will be figured out soon too!

    Yeah i got the .net 5 and it works directly.

    The MSIX issue has been plaguing my windows install for some time. I realize this may not be an issue with winget-cli directly, but rather the AppInstallerCommonCore or AppInstallerCLICore, which are not open source to my knowledge. I have considered reinstalling but I would love to have this fixed. I have tried using a SYSTEM elevated shell to run icacls to reset the ACLs on certain microsoft store package directories with little success. If the error told me which file it failed to edit that would be super useful.

  19. Guiorgy commented on Jun 5, 2021

    @Guiorgy

    PS > winget upgrade
    Failed to open the predefined source; please report to winget maintainers.
    An unexpected error occurred while executing the command:
    0x800700b7 : Cannot create a file when that file already exists.

    Tried manually updating .Net 5 (as Windows update was failing with 0x80070643), and still no luck.
    A subsequent reboot of Windows solved the issue!

  20. AskAlice commented on Jun 5, 2021

    @AskAlice
    Author

    PS > winget upgrade
    Failed to open the predefined source; please report to winget maintainers.
    An unexpected error occurred while executing the command:
    0x800700b7 : Cannot create a file when that file already exists.

    Tried manually updating .Net 5 (as Windows update was failing with 0x80070643), and still no luck.
    A subsequent reboot of Windows solved the issue!

    my issue persists through reboots

    It doesn't happen with every package, i suspect only those that are appxpackages internally.

    running winget upgrade shows a list of upgradeable packages for me.

     💖❯  winget install vim
    Found Vim [vim.vim]
    This application is licensed to you by its owner.
    Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
    Downloading https://github.com/vim/vim-win32-installer/releases/download/v8.2.2929/gvim_8.2.2929_x64.exe
      ██████████████████████████████  9.19 MB / 9.19 MB
    Successfully verified installer hash
    Starting package install...
    Successfully installed
    
  21. Guiorgy commented on Jun 6, 2021

    @Guiorgy

    Alice Knag (@AskAlice), I did manually update to the latest .Net 5 SDK, Desktop Runtime, and Runtime before rebooting ¯\(ツ)/¯

  22. AskAlice commented on Jun 6, 2021

    @AskAlice
    Author

    Alice Knag (@AskAlice), I did manually update to the latest .Net 5 SDK, Desktop Runtime, and Runtime before rebooting ¯\(ツ)/¯

    I'm already on it

  23. adamsmith34 commented on Jun 15, 2021

    @adamsmith34

    Was getting 0x800700b7 : Cannot create a file when that file already exists. when issuing winget list or winget upgrade. Applied 21H1, rebooted. Resolved.

  24. AskAlice commented on Jun 19, 2021

    @AskAlice
    Author

    Was getting 0x800700b7 : Cannot create a file when that file already exists. when issuing winget list or winget upgrade. Applied 21H1, rebooted. Resolved.

    I'm on the latest insider dev channel build so I can't easily switch over there lol :(

  25. denelon commented on Oct 1, 2021

    @denelon
    Collaborator

    Alice Knag (@AskAlice)

    We've published the v1.1 release candidate and updated our troubleshooting guide. We've also got a new release for the Windows Package Manager Manifest Creator https://github.com/microsoft/winget-create/releases/tag/v0.4.1.1-preview.

    Can you confirm if this is still happening?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue-Bug

    Type

    No type

    Projects

    • Status
      Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions