-
Notifications
You must be signed in to change notification settings - Fork 902
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dependecy issues after upgrade to v2 #3234
Comments
Thanks for raising this @tivanov-qb. Wanted to link to the Discord chat too for more context. |
Similar issues for me since upgrade to 2.0.0 |
I am having a similar issue related to this unresolved dependency constraint message. I am trying to upgrade my packages but it fails with this message:
It refuses to move past this until the dependency constraint is resolved. Here is where it gets messy. Trying to upgrade obs-studio.install actually tells me that it's not even installed. Then it proceeds to try installing it like normal, but then fails with the same error above, for its own dependency constraint:
So that's really odd and confusing. Looking at my installed packages, it's not listed (which makes sense given the above). But I do have just "obs-studio":
So I thought what if I try to do
For some reason, it doesn't show a pin for obs-studio. Yet when I proceeded with Sure enough after removing this pin, the packages then successfully upgrade.
Summary: For some reason, an "invisible" pin for obs-studio was causing a dependency constraint for the package obs-studio.install which I did not have installed. Please let me know if this should be opened as a separate bug. I'm not sure if it should be or not? |
As part of the 2.1.0 release, https://docs.chocolatey.org/en-us/choco/release-notes#june-29-2023, there was a bug fixed around the removal of a pin for a package, and I am wondering if this could be related to the problem that you are seeing here. So no, I don't think we need another issue raised, not unless the issue comes up again. I am glad to hear that you got a solution though! |
@tivanov-qb @francoisaudic I just wanted to reach out again to check to see if you were still having issues? The introduction of the dependency resolution checks is something that has concerned a lot of people since the release of Chocolatey CLI v2.0.0, but normally there is a path to get back to a valid state. This is something that we are aiming to increase documentation around in the near future. |
I have added a documentation issue here: chocolatey/docs#773 so that we can track getting this added to our docs, with steps to proceed with getting a resolution to the problem. |
I still have some issues, but I have found a way to get over it with --ignore-dependecies in CLI |
@gep13 I also have same issues.. --ignore-dependencies may cause additional issues for non-working software, so i prefer not to use it.. 2023-07-14 07:32:32,718 2468 [ERROR] - - dotnet-5.0-windowshosting - Unable to resolve dependency 'KB2919442': Unable to find a version o If I add --ignore-dependencies flag, I can install below packages 10:40:46 1689320439,,ui,message, amazon-ebs: C:\Users\vagrant>choco install dotnet-5.0-windowshosting -y --ignore-dependencies however.. dotnet-7.0-runtime and dotnet-7.0-aspnetruntime are failing due to dependency with dotnetcore-3.1-windowshosting Unable to resolve dependency: Unable to find a version of 'chocolatey-core.extension' that is compatible with 'dotnet-7.0-runtime 7.0.9 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnet-aspnetcoremodule-v2 13.1.22321 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnetcore-3.1-aspnetruntime 3.1.32 constraint: chocolatey-core.extension (>= 1.1.0)'%!(PACKER_COMMA) 'dotnetcore-3.1-runtime 3.1.32 constraint: chocolatey-core.extension (>= 1.1.0)'%!(PACKER_COMMA) 'powershell-core 7.3.5 constraint: chocolatey-core.extension'. Unable to resolve dependency: Unable to find a version of 'chocolatey-core.extension' that is compatible with 'dotnet-7.0-aspnetruntime 7.0.9 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnet-aspnetcoremodule-v2 13.1.22321 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnetcore-3.1-aspnetruntime 3.1.32 constraint: chocolatey-core.extension (>= 1.1.0)'%!(PACKER_COMMA) 'dotnetcore-3.1-runtime 3.1.32 constraint: chocolatey-core.extension (>= 1.1.0)'%!(PACKER_COMMA) 'powershell-core 7.3.5 constraint: chocolatey-core.extension'. to conclude.. using version 1.3.1 of choco has no such issues :( |
@gep13 dotnet-aspnetcoremodule-v2 13.1.22321 is not compatible with dotnet-5.0-windowshosting uninstalling dotnetcore-3.1-windowshosting allows me to install dotnet-5.0-windowshosting and dotnet-aspnetcoremodule-v2 is bumped to 15.0.22105 then trying to install dotnet-7.0-windowshosting fails because of dotnet-aspnetcoremodule-v2 15.0.22105 uninstalling dotnet-5.0-windowshosting allows installation of dotnet-7.0-windowshosting with dotnet-aspnetcoremodule-v2 17.0.23172 so this is like a circular dependency, but worse :D looks like we no longer have the possibility to support multiple dotnet-x.x-windowshosting versions ? |
@tivanov-qb can you provide a complete set of reproducible steps to get a system into a state where you are no longer to install/upgrade packages due to dependency resolution warnings/errors. If we can get that information, that may help us in providing insight on whether this is something that needs to be resolved at the package level, or whether this is something that needs to be corrected in Chocolatey CLI itself. Thanks |
"choco install dotnetcore-3.1-windowshosting -y", these are the commands I've found causing issues so far.. 2023-07-14 07:32:32,718 2468 [ERROR] - - dotnet-5.0-windowshosting - Unable to resolve dependency 'KB2919442': Unable to find a version o installing dotnet-5.0-windowshosting:
uninstalling dotnet-3.1-windowshosting allows me to install dotnet-5.0-windowshosting successfully. then, i'm trying to install dotnet-7.0-windowshosting on top of dotnet-5.0-windowshosting: PS C:\Windows\system32> choco install dotnet-7.0-windowshosting -y Chocolatey installed 0/1 packages. 1 packages failed. dotnet-aspnetcoremodule-v2 15.0.22105 is installed with with dotnet-5.0-windowshosting causing dependency issues for dotnet-7.0-windowshosting uninstalling dotnet-5.0-windowshosting allows me to install dotnet-7.0-windowshosting I hope this helps |
@tivanov-qb if I am reading the note from the package maintainer correctly, this is working as expected? Correct? Have you tried installing them directly using the non-meta packages? |
Looks like you guys are onto something here. I am getting a ton of error messages like the following since the update: I dont seem to understand tivanov's solution. Do you understand what is happening here? Is there a workaround? EDIT: To me, the problem seems to lie in the alphabetic order of updating via "choco upgrade all" -> if the dependent package is alphabetically later some might fail. Accordingly my problems have been solved with repeating calls of "choco upgrade all" as an easy, general solution. |
@carsten-engelke we actually just published a document on this type of error. You may want to take a look at it: https://docs.chocolatey.org/en-us/choco/troubleshooting/dependency-troubles. From that error, i think you may want to look at Example 2. |
@gep13 yup, i think this works as expected now. We got the path to fix dependencies for dotnet. thanks for the help! happy to close this if you are good with it. |
I'm going to go ahead and close this, but we can reopen it if necessary. |
@corbob See the post above. A "choco upgrade -y --force resharper-platform" (the force was important) seemed to upgrade dotcover, dotmemory correctly and fix this issue (until the next upgrade). After that I could also upgrade vscode normally (without force). Does this make any sense to you, seems more a problem with package resharper-platform, doesn't it? |
@Cyber1000 Please see the documentation page on this issue. |
Checklist
What You Are Seeing?
Unable to resolve dependency: Unable to find a version of 'chocolatey-core.extension' that is compatible with 'dotnet-aspnetcoremodule-v2 13.1.22321 constraint: chocolatey-core.extension (>= 1.3.5.1)'.
Unable to resolve dependency: Unable to find a version of 'chocolatey-core.extension' that is compatible with 'dotnet-7.0-aspnetruntime 7.0.8 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnet-7.0-runtime 7.0.8 constraint: chocolatey-core.extension (>= 1.3.5.1)'%!(PACKER_COMMA) 'dotnet-aspnetcoremodule-v2 13.1.22321 constraint: chocolatey-core.extension (>= 1.3.5.1)'.
What is Expected?
Choco to work like it used to work with 1.4 version
How Did You Get This To Happen?
I install choco:
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
This results into version 2.
Then installing same packages that I used to install with 1.4 version causes dependency issues as mentioned above.
choco upgrade chocolatey-core.extension
Chocolatey v2.0.0
Upgrading the following packages:
chocolatey-core.extension
By upgrading, you accept licenses for the packages.
chocolatey-core.extension v1.4.0 is the latest version available based on your source(s).
Chocolatey upgraded 0/1 packages.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
the only possible workaround to get dotnet-5/7.0-windowshosting installed is: choco upgrade chocolatey --version 1.4.0 --allow-downgrade -y --force
System Details
Installed Packages
Output Log
Additional Context
No response
The text was updated successfully, but these errors were encountered: