TFS octopus push step path too long error

Using the Octopus extension in TFS 2017.1, we are getting an error using the Octopus push step on one specific nuget package:

Starting: Push Packages to Octopus

Task : Push Package(s) to Octopus
Description : Push your NuGet or Zip package to your Octopus Deploy Server
Version : 2.0.135
Author : Octopus Deploy
Help : Version: 2.0.135. More Information

The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters.

When I replace that Octopus push step with a nuget push to with the same nuget package, and to the same octopus package feed, it works fine. That nuget package also uploads manually to Octopus just fine. I’ve examined the package, and there are no file paths over 60 characters. I’ve tried adding the --enableServiceMessages --debug options, but that does not appear to produce any better output.


Hi Layne,

Thanks for getting in touch.

I’m currently looking into this issue for you. I suspect that the problem relates to the full path to the package, including the full directory structure. I’m trying to reproduce the issue locally in a VM, to confirm my suspicion.

Not sure why nuget push works correctly in this case, but there is one more test - we use octo.exe to do the push under the covers of the TFS extension. Are you able to push the package to Octopus using octo.exe directly at the command line? I’d suspect it might fail with a similar message.

Last thing: There might be a quick win, but it depends on what OS you’re running on - there’s an opt-in to long path behaviour described at this link, which is available if you’re on Windows Server 2016/Windows 10.



This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.