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

NuGet.exe push - timeout parameter doesn't work #2785

Closed
skofman1 opened this Issue May 13, 2016 · 7 comments

Comments

Projects
None yet
7 participants
@skofman1

skofman1 commented May 13, 2016

@prestonj wrote in NuGet/NuGetGallery#1094 (comment):
I'm also having this problem but the suggestion for adding the Timeout switch from @maartenba did not fix the issue for me. Seems there is another timeout on the HTTP PUT request that hits after 100 seconds. My command line is basically:

C:\test>nuget push -ApiKey xxx -Timeout 120000 -Source http://nuget.org -Verbosity Detailed mything.nupkg

The output is:
Pushing mything.nupkg to 'http://nuget.org'...
PUT http://nuget.org/api/v2/package/
PUT http://nuget.org/api/v2/package/
PUT http://nuget.org/api/v2/package/
System.AggregateException: One or more errors occurred. ---> System.TimeoutException: The HTTP request to 'PUT http://nuget.org/api/v2/package/' has timed out after 100000ms.
at NuGet.CommandLine.PushCommand.d__16.MoveNext()
--- End of inner exception stack trace ---
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at NuGet.CommandLine.Command.Execute()
at NuGet.CommandLine.Program.MainCore(String workingDirectory, String[] args)
---> (Inner Exception #0) System.TimeoutException: The HTTP request to 'PUT http://nuget.org/api/v2/package/' has timed out after 100000ms.
at NuGet.CommandLine.PushCommand.d__16.MoveNext()<---

I'm using nuget.exe version 3.4.3.855

@yishaigalatzer

This comment has been minimized.

Show comment
Hide comment
@yishaigalatzer

yishaigalatzer May 16, 2016

The fix here is to move to an async stream. We did a similar fix in httpsource to allow downloading very large packages.

You will need to also add a timeout mechanism for when the stream "hangs" and bits no longer transmit, because async streams lack this feature.

CC @spadapet @joelverhagen

yishaigalatzer commented May 16, 2016

The fix here is to move to an async stream. We did a similar fix in httpsource to allow downloading very large packages.

You will need to also add a timeout mechanism for when the stream "hangs" and bits no longer transmit, because async streams lack this feature.

CC @spadapet @joelverhagen

@EgorBo

This comment has been minimized.

Show comment
Hide comment
@EgorBo

EgorBo Jul 29, 2016

Does the latest stable nuget 3.4.4 contain this fix? Because it doesn't work for me. It keeps saying me "has timed out after 100000ms." (for -Timeout 2147483). It used to work in nuget 2.x for the same package on the same network

EgorBo commented Jul 29, 2016

Does the latest stable nuget 3.4.4 contain this fix? Because it doesn't work for me. It keeps saying me "has timed out after 100000ms." (for -Timeout 2147483). It used to work in nuget 2.x for the same package on the same network

@joelverhagen

This comment has been minimized.

Show comment
Hide comment
@joelverhagen

joelverhagen Jul 29, 2016

Member

Nope, 3.4.4 does not have this fix. Switch to version 3.5.0-beta2 of nuget.exe and the fix should be present:
https://dist.nuget.org/win-x86-commandline/v3.5.0-beta2/NuGet.exe

Member

joelverhagen commented Jul 29, 2016

Nope, 3.4.4 does not have this fix. Switch to version 3.5.0-beta2 of nuget.exe and the fix should be present:
https://dist.nuget.org/win-x86-commandline/v3.5.0-beta2/NuGet.exe

@EgorBo

This comment has been minimized.

Show comment
Hide comment
@EgorBo

EgorBo Jul 29, 2016

@joelverhagen thank you! 3.5.0-beta2 works for my case.

EgorBo commented Jul 29, 2016

@joelverhagen thank you! 3.5.0-beta2 works for my case.

@jogerh

This comment has been minimized.

Show comment
Hide comment
@jogerh

jogerh Sep 29, 2016

NuGet Version: 3.5.0.1737 seems to miss this fix, whereas NuGet Version: 3.5.0.1520 seems to work. Is 33a3740 removed from the later builds, or is there a regression?

jogerh commented Sep 29, 2016

NuGet Version: 3.5.0.1737 seems to miss this fix, whereas NuGet Version: 3.5.0.1520 seems to work. Is 33a3740 removed from the later builds, or is there a regression?

@joelverhagen joelverhagen reopened this Sep 29, 2016

@joelverhagen joelverhagen modified the milestones: 3.5 RTM, 3.5 Beta2 Sep 29, 2016

@joelverhagen

This comment has been minimized.

Show comment
Hide comment
@joelverhagen

joelverhagen Sep 29, 2016

Member

Yes, this looks like a regression. I'll take a look.

Member

joelverhagen commented Sep 29, 2016

Yes, this looks like a regression. I'll take a look.

@jogerh

This comment has been minimized.

Show comment
Hide comment
@jogerh

jogerh Sep 29, 2016

Thank you @joelverhagen. I am impressed.

jogerh commented Sep 29, 2016

Thank you @joelverhagen. I am impressed.

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