[Dependency Issue]: Dependency can't be found by main installer after it's installed
Please confirm these before moving forward
- [X] I have searched for my issue and not found a work-in-progress/duplicate/resolved issue.
- [X] I have not been informed if the issue is resolved in a preview version of the winget client.
Category of the issue
Other
Brief description of your issue
This installer has Git as a dependency. It finds Git in the Windows Path during install to register itself. But the Windows Path in most Command Prompt and PowerShell windows appears to only update at window launch. One window must be opened for the dependency install, and then another window opened for the main package install. Observed in
- https://github.com/microsoft/winget-pkgs/pull/90133
Similar behavior was observed in this PR - the installer completed, but validation failed as it used the same PowerShell window, and thus couldn't find Git in the Windows Path.
- https://github.com/microsoft/winget-pkgs/pull/90517
Steps to reproduce
For 90133 - On new system, modify the package's manifest to have Git.Git as a dependency, then install in a VM.
Actual behavior
The installer will error "Could not find Git; can not register Git LFS."
Expected behavior
Winget could help the client window to update its local Windows Path variable from the registry, so subsequent installers could install successfully, and programs run from the same window could find Git to execute successfully.
Environment
Windows Package Manager (Preview) v1.4.3132-preview
Copyright (c) Microsoft Corporation. All rights reserved.
Windows: Windows.Desktop v10.0.19044.1288
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.19.3132.0
Screenshots and Logs
No response
Related to:
- https://github.com/microsoft/winget-cli/issues/549
@stephengillie thanks for attempting to open an issue. Unfortunately, you didn't write anything in the body which makes it impossible to understand your concern. You are welcome to fix up the issue and try again by opening another issue with the body filled out.