{"action":"created","issue":{"url":"https://api.github.com/repos/NuGet/Home/issues/1282","repository_url":"https://api.github.com/repos/NuGet/Home","labels_url":"https://api.github.com/repos/NuGet/Home/issues/1282/labels{/name}","comments_url":"https://api.github.com/repos/NuGet/Home/issues/1282/comments","events_url":"https://api.github.com/repos/NuGet/Home/issues/1282/events","html_url":"https://github.com/NuGet/Home/issues/1282","id":103807827,"number":1282,"title":"Running `NuGet.exe pack` in parallel causes System.ObjectDisposedException","user":{"login":"deepakaravindr","id":2380340,"avatar_url":"https://avatars.githubusercontent.com/u/2380340?v=3","gravatar_id":"","url":"https://api.github.com/users/deepakaravindr","html_url":"https://github.com/deepakaravindr","followers_url":"https://api.github.com/users/deepakaravindr/followers","following_url":"https://api.github.com/users/deepakaravindr/following{/other_user}","gists_url":"https://api.github.com/users/deepakaravindr/gists{/gist_id}","starred_url":"https://api.github.com/users/deepakaravindr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/deepakaravindr/subscriptions","organizations_url":"https://api.github.com/users/deepakaravindr/orgs","repos_url":"https://api.github.com/users/deepakaravindr/repos","events_url":"https://api.github.com/users/deepakaravindr/events{/privacy}","received_events_url":"https://api.github.com/users/deepakaravindr/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/NuGet/Home/labels/Priority:1","name":"Priority:1","color":"fbca04"},{"url":"https://api.github.com/repos/NuGet/Home/labels/Type:Bug","name":"Type:Bug","color":"207de5"}],"state":"closed","locked":false,"assignee":{"login":"emgarten","id":6381138,"avatar_url":"https://avatars.githubusercontent.com/u/6381138?v=3","gravatar_id":"","url":"https://api.github.com/users/emgarten","html_url":"https://github.com/emgarten","followers_url":"https://api.github.com/users/emgarten/followers","following_url":"https://api.github.com/users/emgarten/following{/other_user}","gists_url":"https://api.github.com/users/emgarten/gists{/gist_id}","starred_url":"https://api.github.com/users/emgarten/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emgarten/subscriptions","organizations_url":"https://api.github.com/users/emgarten/orgs","repos_url":"https://api.github.com/users/emgarten/repos","events_url":"https://api.github.com/users/emgarten/events{/privacy}","received_events_url":"https://api.github.com/users/emgarten/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/NuGet/Home/milestones/24","html_url":"https://github.com/NuGet/Home/milestones/3.4%20RTM","labels_url":"https://api.github.com/repos/NuGet/Home/milestones/24/labels","id":1604346,"number":24,"title":"3.4 RTM","description":"","creator":{"login":"yishaigalatzer","id":1238711,"avatar_url":"https://avatars.githubusercontent.com/u/1238711?v=3","gravatar_id":"","url":"https://api.github.com/users/yishaigalatzer","html_url":"https://github.com/yishaigalatzer","followers_url":"https://api.github.com/users/yishaigalatzer/followers","following_url":"https://api.github.com/users/yishaigalatzer/following{/other_user}","gists_url":"https://api.github.com/users/yishaigalatzer/gists{/gist_id}","starred_url":"https://api.github.com/users/yishaigalatzer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yishaigalatzer/subscriptions","organizations_url":"https://api.github.com/users/yishaigalatzer/orgs","repos_url":"https://api.github.com/users/yishaigalatzer/repos","events_url":"https://api.github.com/users/yishaigalatzer/events{/privacy}","received_events_url":"https://api.github.com/users/yishaigalatzer/received_events","type":"User","site_admin":false},"open_issues":2,"closed_issues":92,"state":"open","created_at":"2016-02-25T02:33:27Z","updated_at":"2016-04-05T17:34:30Z","due_on":"2016-05-01T07:00:00Z","closed_at":null},"comments":14,"created_at":"2015-08-28T22:47:59Z","updated_at":"2016-04-11T05:18:55Z","closed_at":"2016-03-11T07:30:36Z","body":"@zentron\r\n\r\nMoved from https://github.com/NuGet/NuGet.CommandLine/issues/18\r\n\r\nRunning the following pack script against several different packages (note completely different source and destination)\r\n\r\n```\r\n cls\r\n \r\n  $ScriptBlock = {\r\n    param($ver) \r\n    Write-Host \"[processing Package # '$ver' inside the job]\"\r\n    & \"C:\\Temp\\NuGet.exe\" pack \"D:\\Development\\Packages\\Acme.Web$ver\\Acme.Web.nuspec\" -NoPackageAnalysis -BasePath \"D:\\Development\\Packages\\Acme.Web$ver\" -OutputDirectory \"C:\\Temp\" -Version 1.0.$ver -Verbosity Detailed \r\n  }\r\n\r\n#Run 3 Jobs\r\n  for($i=1; $i -le 3; $i++) {\r\n    Start-Job $ScriptBlock -ArgumentList $i\r\n  }\r\n\r\n # Wait for all to complete\r\nWhile (Get-Job -State \"Running\") { Start-Sleep 2 }\r\n\r\n# Display output from all jobs\r\nGet-Job | Receive-Job\r\n\r\nRemove-Job *\r\n```\r\n\r\nResults in 2/3 failing with \r\n```\r\nSystem.ObjectDisposedException: Can not access a closed Stream.\r\n    + CategoryInfo          : NotSpecified: (System.ObjectDi... closed Stream.:String) [], Remote \r\n   Exception\r\n    + FullyQualifiedErrorId : NativeCommandError\r\n    + PSComputerName        : localhost\r\n \r\n   at System.IO.Compression.DeflateStream.EnsureNotDisposed()\r\n   at System.IO.Compression.DeflateStream.Flush()\r\n   at MS.Internal.IO.Packaging.CompressStream.Flush()\r\n   at MS.Internal.IO.Z\r\nip.ProgressiveCrcCalculatingStream.Flush()\r\n   at MS.Internal.IO.Zip.ZipIOLocalFileBlock.FlushExposedStreams()\r\n   at MS.Internal.IO.Zip.ZipIOLocalFileBlock.UpdateReferences(Boolean closingFlag)\r\n   at MS.Internal.IO.Zip.ZipIOBlockManager.SaveContainer(Boolean closingFlag)\r\n   at MS.Internal.IO.Zip.ZipIOBlockManager.SaveStream(ZipIOLocalFileBlock blockRequestingFlush, \r\nBoolean closingFlag)\r\n   at MS.Internal.IO.Zip.ZipIOModeEnforcingStream.Dispose(Boolean disposing)\r\n   at System.IO.Stream.Close()\r\n   at System.IO.Packaging.PackagePart.Close()\r\n   at System.IO.Packaging.Package.DoClose(PackagePart p)\r\n   at System.IO.Packaging.Package.DoOperationOnEachPart(PartOperation operation)\r\n   at System.IO.Packaging.Package.System.IDisposable.Dispose()\r\n   at NuGet.PackageBuilder.Save(Stream stream)\r\n   at NuGet.Commands.PackCommand.BuildPackage(PackageBuilder builder, String outputPath)\r\n   at NuGet.Commands.PackCommand.BuildFromNuspec(String path)\r\n   at NuGet.Commands.PackCommand.BuildPackage(String path)\r\n   at NuGet.Commands.PackCommand.ExecuteCommand()\r\n   at NuGet.Commands.Command.Execute()\r\n   at NuGet.Program.Main(String[] args)\r\n```\r\n\r\nNot sure if there is some limitation or argument not being supplied to get this process to work."},"comment":{"url":"https://api.github.com/repos/NuGet/Home/issues/comments/208167262","html_url":"https://github.com/NuGet/Home/issues/1282#issuecomment-208167262","issue_url":"https://api.github.com/repos/NuGet/Home/issues/1282","id":208167262,"user":{"login":"emgarten","id":6381138,"avatar_url":"https://avatars.githubusercontent.com/u/6381138?v=3","gravatar_id":"","url":"https://api.github.com/users/emgarten","html_url":"https://github.com/emgarten","followers_url":"https://api.github.com/users/emgarten/followers","following_url":"https://api.github.com/users/emgarten/following{/other_user}","gists_url":"https://api.github.com/users/emgarten/gists{/gist_id}","starred_url":"https://api.github.com/users/emgarten/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emgarten/subscriptions","organizations_url":"https://api.github.com/users/emgarten/orgs","repos_url":"https://api.github.com/users/emgarten/repos","events_url":"https://api.github.com/users/emgarten/events{/privacy}","received_events_url":"https://api.github.com/users/emgarten/received_events","type":"User","site_admin":false},"created_at":"2016-04-11T05:18:55Z","updated_at":"2016-04-11T05:18:55Z","body":"@alfnilsson this like a different problem, would you try running with ``-verbosity detailed`` to get a stack trace for this failure and then log a new issue?"}}