I’m trying to upload a NuGet package from TeamCity (using NuGet 3.4.3) and I’m getting this error:
Unhandled error on request: http://localhost:89/nuget/packages/ by HLindestaf : Illegal characters in path.
System.ArgumentException: Illegal characters in path.
at System.IO.Path.CheckInvalidPathChars(String path, Boolean checkAdditional)
at System.IO.FileStream.Init(String path, FileMode mode, FileAccess access, Int32 rights, Boolean useRights, FileShare share, Int32 bufferSize, FileOptions options, SECURITY_ATTRIBUTES secAttrs, String msgPath, Boolean bFromProxy, Boolean useLongPath, Boolean checkHost)
at System.IO.FileStream…ctor(String path, FileMode mode, FileAccess access, FileShare share)
at Octopus.Shared.Util.OctopusPhysicalFileSystem.OpenFile(String path, FileMode mode, FileAccess access, FileShare share) in Y:\work\refs\tags\3.3.9\source\Octopus.Shared\Util\OctopusPhysicalFileSystem.cs:line 184
at Octopus.Shared.Util.OctopusPhysicalFileSystem.CreateTemporaryFile(String filename, String& path) in Y:\work\refs\tags\3.3.9\source\Octopus.Shared\Util\OctopusPhysicalFileSystem.cs:line 210
at Octopus.Server.Web.Api.NuGet.PackagePushActionBase1.SaveToTemporaryLocation(HttpFile packageFile) in Y:\work\refs\tags\3.3.9\source\Octopus.Server\Web\Api\NuGet\PackagePushActionBase.cs:line 117 at Octopus.Server.Web.Api.NuGet.PackagePushActionBase
1.Execute() in Y:\work\refs\tags\3.3.9\source\Octopus.Server\Web\Api\NuGet\PackagePushActionBase.cs:line 58
at Octopus.Server.Web.Infrastructure.Api.Responder`1.Respond(TDescriptor options, NancyContext context) in Y:\work\refs\tags\3.3.9\source\Octopus.Server\Web\Infrastructure\Api\Responder.cs:line 162
at System.Dynamic.UpdateDelegates.UpdateAndExecute3[T0,T1,T2,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2)
at Octopus.Server.Web.Api.OctopusRestApiModule.<>c__DisplayClass0_0.<.ctor>b__0(Object o) in Y:\work\refs\tags\3.3.9\source\Octopus.Server\Web\Api\OctopusRestApiModule.cs:line 46
at Nancy.Routing.Route.<>c__DisplayClass4.b__3(Object parameters, CancellationToken context)