Using Octopus Deploy Command Line Tool, version 4.2.4+Branch.master.Sha.9f1cbaa1e9e143553779896d25b25587bbb0f703
When I try to run octo.exe pack --id=abc
, I get the error:
System.ArgumentException: Value cannot be null or an empty string.
Parameter name: value
at NuGet.Versioning.NuGetVersion.Parse(String value)
at Octopus.Cli.Commands.PackCommand.<>c__DisplayClass17_0.<Execute>b__0()
at System.Threading.Tasks.Task.InnerInvoke()
at System.Threading.Tasks.Task.Execute()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Octopus.Cli.Program.Run(String[] args)
It works if I specify --version explicitly.
Digging into the source code, I found the following starting on line 111 in Octo.Commands.PackCommand:
var metadata = new ManifestMetadata
{
Id = id,
Authors = authors,
Description = description,
Version = NuGetVersion.Parse(version.OriginalString)
};
Here version.OriginalString
is null, even though version
is not.