1

Closed

Failed to copy attach_server.py when publishing a project to Azure

description

When publishing a web project to Azure, you might get the following error.

Error 1 Copying file c:\users\x\documents\visual studio 2013\Projects\BottleWebProject13\BottleWebProject13\obj\Debug\attach_server.py to obj\Debug\Package\PackageTmp\ptvsd\attach_server.py failed. Could not find file 'c:\users\x\documents\visual studio 2013\Projects\BottleWebProject13\BottleWebProject13\obj\Debug\attach_server.py'. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\Web\Microsoft.Web.Publishing.targets 2584 5 BottleWebProject13

Config:
  • Win8.1 w/ latest updates
  • VS 2013 Update 3
  • Azure SDK 2.4
  • PTVS 2.1 RC bits (build 20808.00)
To repro:
  1. Create a Bottle Web App (Other framework probably will repro as well)
  2. Publish to Azure
  3. When in the configuration dialog/wizard, select 'debug' for Configuration, do Preview before Publish (there was a case I was able to repro this without preview but not consistently)
  4. Publish
Result:
You get the error listed above.

Workaround:
Try to do Publish one more time. Everything seems to work fine.
Closed Sep 5 at 9:26 PM by jinglou
This has been fixed in the RC release. Also verified this in build 20904.03. Fixed and closing.

comments

Zooba wrote Aug 11 at 5:25 PM

Does it make a difference whether you use virtualenv/venv or not?

Presumably you also need to select the Debug configuration when publishing - I don't see that step listed.