2017-07-14 72 views
0

我目前在Visual Studio 2017(企業版)中使用Python->發佈功能時出現此錯誤。Django應用程序構建失敗與Visual Studio 2017

Severity Code Description Project File Line Suppression State 
Error  Cannot evaluate the item metadata "%(FullPath)". The item metadata "%(FullPath)" cannot be applied to the path "C:\"path to static files"/static 
Illegal characters in path. C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\MSBuild\Microsoft\VisualStudio\v15.0\Python Tools\Microsoft.PythonTools.Django.targets 105 

它是由這條線進來Microsoft.PythonTools.Django.targets <FilesForPackagingFromProject Include="@(_DjangoStaticFiles)" Condition="'%(FullPath)' != ''">

這似乎是目標文件有麻煩收集靜態文件。

任何幫助將是偉大的!謝謝。

回答

0

不願意改變Python工具文件,但這個改變奏效。

來源:

<FilesForPackagingFromProject Include="@(_DjangoStaticFiles)" Condition="'%(FullPath)' != ''"> 

要:

<DestinationRelativePath>$([System.IO.Path]::Combine(`a`, `b`))</DestinationRelativePath> 
相關問題