-
Notifications
You must be signed in to change notification settings - Fork 884
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
Cannot Install Packages - 400 Error #1130
Comments
Run with |
PS C:\Windows\system32> choco install notepadplusplus -dv NOTE: Hiding sensitive configuration data! Please double and triple Information.Is64Bit='True'|Information.IsInteractive='True'| Chocolatey installed 0/1 packages. 1 packages failed. Failures
|
Since this is only being seen with your environment, if you can install Fiddler and run that when you try this again, that would be most helpful. That likely it is something with a proxy in your environment or something limiting traffic. If you are running this from a VirtualBox VM, ensure you have 5.1.9+ installed (5.1.8 had issues). |
Just had the same issue on a new Win 10 company laptop.
|
Just did some tests in company network...
Strange behavior - still not knowing if it's the proxy, some weired network configuration or chocolatey. |
I'm experiencing the same issue with our current server hosting several packages.. I setup a second simple chocolatey server with just one package (curl). There's no proxy between the client and server. This is the output from the client:
Using Wireshark I see the client getting /chocolatey/Packages. After that the client requests /chocolatey/Packages/$metadata. This triggers the 400 error. The servers responds with:
@ferventcoder Is requesting $metadata in the URI valid? Or is this actually a variable that wasn't interpolated? Both client and server are running Windows 2012 R2 with recent patches. |
@GerbenWelter Your source should be "http://chocolatey.server/chocolatey" and nothing more. HTH |
This certainly helps. Now it works again. The old source url has worked since we started with Chocolatey over half a year ago, so something must have changed. Anyway thank you @ferventcoder for the quick pointer. |
Ah, now I see why. The source url was wrong in chocolatey.config but was getting overrided by Puppet with the correct one. Using choco from the cli made the error surface. Sorry, for the noise. |
I still have random 400 errors. Source listed in chocolatey.config is |
In my current setup this issue only appears with the package nodejs.install. It's a company laptop behind a proxy. This is the output with -dv:
The URL My config has the following source entry: <source id="chocolatey" value="https://chocolatey.org/api/v2/" disabled="false" priority="0" /> No explicit proxy settings (But I tried with no avail). Just using system settings as explained here: Wiki All other packages are working. For example: openvpn, git or keepass The nodejs package works without a proxy. Thanks in advance. |
Okay, weird that it flips it over to http instead of https. |
This makes it seem like the issue actually lies over in https://github.com/chocolatey/chocolatey.org/issues - at least what you found @zech |
I don't know if I get this. I used the command i searched the issue to make sure this is not already solved or my mistake and found this open issue. the best relating issue i can find in your linked list is this one here https://github.com/chocolatey/chocolatey.org/issues/324 but it doesn't help much as well. do you have any ideas what i can do further? |
Both of these issues could actually be issues with the community repository (a package source, but not the only packaging source available when it comes to Chocolatey) and not the choco.exe client. Since it is discovering the url from the community package repository (https://chocolatey.org/api/v2), it appears to be getting the wrong url (https://rs.http3.lol/index.php?q=aHR0cHM6Ly9naXRodWIuY29tL2Nob2NvbGF0ZXkvY2hvY28vaXNzdWVzL0hUVFAgaW5zdGVhZCBvZiBIVFRQUw). Does that make more sense? |
Thanks, now I understand. So would you recommend to open a new issue there? |
I'm also experiencing problems installing some packages. Others work without a problem. Packages which don't work are for example: As far as I understand the last post, it is not a problem of choco itself but the packages?
|
I still have this issue. No proxy. Several different computers. Its a real pain. |
More likely the caching in the community repository encounters an error. It typically resolves itself within a small amount of time. The site does receive a large number of requests per day (20+ million), so caching for some period of time is a necessity. It does mean if there is an update for an app, it may take it out of the picture for a bit. It rarely happens, but over 20 million requests per day, that rarely could be like 10 times a day. And it's not the only reason a person may not be able to receive packages:
|
I personally don't think this is a caching issue. Each and every time I try to install nodejs i have to go online via mobile hotspot as a workaround for the corporate proxy. Even though that http and https connections are totally fine. For most other packages too. But for nodejs it errors out every time i try to install. git for example will install just fine through proxy. |
Hi @zech, is your error with seeing the package or are you getting an issue with downloading the software once it has received the package? This particular issue is with receiving the package, not the non-redistributable software that a package on a public repository would need to download at runtime (unlike an internal repo where you can just embed all software in the Chocolatey packages). For your case, I would see if there is something with your corporate proxy that blocks the NodeJS website where that nodejs package downloads the software from at runtime. |
@zech have you seen https://chocolatey.org/security#servers-ip-addresses? |
@ferventcoder its the same as i posted here with every version: #1130 (comment)
Chocolatey is not blocked as well because every other package I use works.
Maybe I don't understand the differences between packages enough but from my point of view they're the same. |
Okay, I saw that work when I went to the HTTP address in the browser. Can you produce a Fiddler report for this? Send to my github username at gmail dot com. Thanks! |
Okay. I can do that on monday. |
@ferventcoder I've just sent you the reports. |
I just want to give some feedback again:
I was able to install other packages without changing the system or chocolatey.
|
@ferventcoder Did it help? |
I also faced this problem. The issue seems to be that requests are done via http instead of https. I don't know where the http URLs come from, maybe they are contained in an incorrect feed retrieved by an earlier request (so that could explain why the problem exists only for some packages). For what it's worth, I noted that the following request fails from the choco client but works from Postman and the browser (using identical proxy configuration):
My solution to the problem was to convert all requests to http://chocolatey.org to https://chocolatey.org using a custom Fiddler rule:
|
Is anyone else still getting this? I just set up a new PC and was able to install several packages and then all of a sudden, every package I try just fails:
I thought it might have been a temporary problem or outage, but it's been like this for a week now UPDATE UPDATE UPDATE I was having SSL issues on other sites as well. It turns out that it was the network drivers for the NIC on my motherboard (MSI z370 and the "Killer" network drivers). When I uninstalled those and reverted to use the built-in Windows drivers, everything worked. |
I still get it randomly on freshly imaged pc's as well as older installs
David King
david@kingitconsultingco.com
…On Jan 22, 2018 3:06 PM, "Chad Myers" ***@***.***> wrote:
Is anyone else still getting this? I just set up a new PC and was able to
install several packages and then all of a sudden, every package I try just
fails:
Chocolatey v0.10.8
Installing the following packages:
firefox
By installing you accept licenses for the packages.
[NuGet] An error occurred while loading packages from 'https://chocolatey.org/api/v2/': The underlying connection was closed: An unexpected error occurred on a send.
firefox not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "https://chocolatey.org/api/v2/"
Chocolatey installed 0/1 packages. 1 packages failed.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Failures
- firefox - firefox not installed. The package was not found with the source(s) listed.
If you specified a particular version and are receiving this message, it is possible that the package name exists but the version does not.
Version: ""
Source(s): "https://chocolatey.org/api/v2/"
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1130 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFhDdRJIkLmg6oFr00fnKao0bLIjRtWoks5tNOpOgaJpZM4LejbB>
.
|
@davidking727 What helped me realize it wasn't chocolatey but my PC was when I tried to go to https://www.mozilla.org and got a CONNECTION_RESET because it couldn't establish SSL. When I uninstalled the network drivers and reverted, I could then use both chocolatey and hit https://www.mozilla.org Have you tried hitting https://www.mozilla.org in Chrome to see if you get a CONNECTION_RESET error? |
I don't know if all those errors are related but I'm getting this error for all packages now. I don't really know since when but this is the output for git if i trace with fiddler: Request
Response
Calling the same address with a browser downloads the nupkg just fine. No issue here. |
I am facing the same problem. Here's my output with
|
I ran into a similar issue today.
I upgraded my VirtualBox to the latest release and that resolved my issue. |
Howdy folks, some of you may be running into an issue due to IPv6 as we've found on other tickets. We are not sure why it effects PowerShell downloading badly yet, but that it does. For those that have a proxy, you may need to ensure your proxy allows more than just *.chocolatey.org as the packages there are subject to distribution rights (public repo), so the packages must download the software from the official locations. |
Cannot install packages. New install of Window 10 Pro. Used NotepadPlusPlus as example, but ALL packages return 400 error
PS C:\Windows\system32> choco search notepadplusplus
Chocolatey v0.10.3
jivkok.dev1 1.1.0.8
notepadplusplus 7.3 [Approved]
notepadplusplus.install 7.3 [Approved]
notepadplusplus.commandline 7.3 [Approved]
Notepadplusplus.Settings 1.0.0.20141029 [Approved] - Possibly broken
5 packages found.
PS C:\Windows\system32> choco install notepadplusplus -y
Chocolatey v0.10.3
Installing the following packages:
notepadplusplus
By installing you accept licenses for the packages.
notepadplusplus not installed. An error occurred during installation:
The remote server returned an error: (400) Bad Request.
notepadplusplus package files install completed. Performing other installation steps.
The install of notepadplusplus was NOT successful.
notepadplusplus not installed. An error occurred during installation:
The remote server returned an error: (400) Bad Request.
Chocolatey installed 0/1 packages. 1 packages failed.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Failures
The remote server returned an error: (400) Bad Request.
PS C:\Windows\system32> choco install notepadplusplus -d -v
Chocolatey v0.10.3
Chocolatey is running on Windows v 10.0.14393.0
Attempting to delete file "C:/ProgramData/chocolatey/choco.exe.old".
Attempting to delete file "C:\ProgramData\chocolatey\choco.exe.old".
Command line: "C:\ProgramData\chocolatey\choco.exe" install notepadplusplus -d -v
Received arguments: install notepadplusplus -d -v
RemovePendingPackagesTask is now ready and waiting for PreRunMessage.
Sending message 'PreRunMessage' out if there are subscribers...
[Pending] Removing all pending packages that should not be considered installed...
The source 'https://chocolatey.org/api/v2/' evaluated to a 'normal' source type
NOTE: Hiding sensitive configuration data! Please double and triple
check to be sure no sensitive data is shown, especially if copying
output to a gist for review.
Configuration: CommandName='install'|
CacheLocation='C:\Users\dking\AppData\Local\Temp\chocolatey'|
ContainsLegacyPackageInstalls='True'|
CommandExecutionTimeoutSeconds='2700'|WebRequestTimeoutSeconds='30'|
Sources='https://chocolatey.org/api/v2/'|SourceType='normal'|
Debug='True'|Verbose='True'|Force='False'|Noop='False'|
HelpRequested='False'|RegularOutput='True'|QuietOutput='False'|
PromptForConfirmation='True'|AcceptLicense='False'|
AllowUnofficialBuild='False'|Input='notepadplusplus'|
AllVersions='False'|SkipPackageInstallProvider='False'|
PackageNames='notepadplusplus'|Prerelease='False'|ForceX86='False'|
OverrideArguments='False'|NotSilent='False'|
ApplyPackageParametersToDependencies='False'|
ApplyInstallArgumentsToDependencies='False'|IgnoreDependencies='False'|
AllowMultipleVersions='False'|AllowDowngrade='False'|
ForceDependencies='False'|Information.PlatformType='Windows'|
Information.PlatformVersion='10.0.14393.0'|
Information.PlatformName='Windows'|
Information.ChocolateyVersion='0.10.3.0'|
Information.ChocolateyProductVersion='0.10.3'|
Information.FullName='choco, Version=0.10.3.0, Culture=neutral, PublicKeyToken=79d02ea9cad655eb'|
Information.Is64Bit='True'|Information.IsInteractive='True'|
Information.IsUserAdministrator='True'|
Information.IsProcessElevated='True'|
Information.IsLicensedVersion='False'|Information.LicenseType='Foss'|
Features.AutoUninstaller='True'|Features.ChecksumFiles='True'|
Features.AllowEmptyChecksums='False'|
Features.AllowEmptyChecksumsSecure='True'|
Features.FailOnAutoUninstaller='False'|
Features.FailOnStandardError='False'|Features.UsePowerShellHost='True'|
Features.LogEnvironmentValues='False'|Features.VirusCheck='False'|
Features.FailOnInvalidOrMissingLicense='False'|
Features.IgnoreInvalidOptionsSwitches='True'|
Features.UsePackageExitCodes='True'|
Features.UseFipsCompliantChecksums='False'|
Features.ScriptsCheckLastExitCode='False'|
ListCommand.LocalOnly='False'|
ListCommand.IncludeRegistryPrograms='False'|ListCommand.PageSize='25'|
ListCommand.Exact='False'|ListCommand.ByIdOnly='False'|
ListCommand.IdStartsWith='False'|ListCommand.OrderByPopularity='False'|
ListCommand.ApprovedOnly='False'|
ListCommand.DownloadCacheAvailable='False'|
ListCommand.NotBroken='False'|UpgradeCommand.FailOnUnfound='False'|
UpgradeCommand.FailOnNotInstalled='False'|
UpgradeCommand.NotifyOnlyAvailableUpgrades='False'|
NewCommand.AutomaticPackage='False'|
NewCommand.UseOriginalTemplate='False'|SourceCommand.Command='unknown'|
SourceCommand.Priority='0'|FeatureCommand.Command='unknown'|
ConfigCommand.Command='unknown'|PinCommand.Command='unknown'|
_ Chocolatey:ChocolateyInstallCommand - Normal Run Mode _
Installing the following packages:
notepadplusplus
By installing you accept licenses for the packages.
[NuGet] Attempting to resolve dependency 'notepadplusplus.install (= 7.3)'.
notepadplusplus not installed. An error occurred during installation:
The remote server returned an error: (400) Bad Request.
notepadplusplus package files install completed. Performing other installation steps.
No package information as package is null.
No package information to save as package is null.
Sending message 'HandlePackageResultCompletedMessage' out if there are subscribers...
The install of notepadplusplus was NOT successful.
notepadplusplus not installed. An error occurred during installation:
The remote server returned an error: (400) Bad Request.
Chocolatey installed 0/1 packages. 1 packages failed.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Failures
The remote server returned an error: (400) Bad Request.
Sending message 'PostRunMessage' out if there are subscribers...
Exiting with 1
PS C:\Windows\system32> ^M
The text was updated successfully, but these errors were encountered: