azure-functions-templates
azure-functions-templates copied to clipboard
[Visual Studio] NuGet packages and base Function files fail to load if project folder contains ‘%20’ in the folder path
From @mcollier on September 28, 2017 18:54
If the project folder contains ‘%20’ in the path, NuGet packages dependencies for Microsoft.NET.Sdk.Functions (1.0.2) fail to load. Additionally, base Function files such as local.settings.json, host.json, and .gitignore fail to be load. The local.settings.json, host.json, and .gitignore files are generated/available on the file system.
With %20 in folder path
With no %20 in folder path
Build Error Additionally, when a build is attempted, the build fails with the following error message:
Restoring NuGet packages... To prevent NuGet from restoring packages during build, open the Visual Studio Options dialog, click on the Package Manager node and uncheck 'Allow NuGet to download missing packages during build.' 1>------ Rebuild All started: Project: FunctionApp1, Configuration: Debug Any CPU ------ 1>C:\Program Files\dotnet\sdk\2.0.2-vspre-006949\Sdks\Microsoft.NET.Sdk\build\Microsoft.PackageDependencyResolution.targets(323,5): error : Assets file 'C:\Projects\Demos\contoso insurance\FunctionApp1\FunctionApp1\obj\project.assets.json' not found. Run a NuGet package restore to generate this file. 1>C:\Program Files\dotnet\sdk\2.0.2-vspre-006949\Sdks\Microsoft.NET.Sdk\build\Microsoft.PackageDependencyResolution.targets(165,5): error : Assets file 'C:\Projects\Demos\contoso insurance\FunctionApp1\FunctionApp1\obj\project.assets.json' not found. Run a NuGet package restore to generate this file. 1>Done building project "FunctionApp1.csproj" -- FAILED. ========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
This was using Azure Functions and Web Jobs Tools (version 15.0.30901.0).
Visual Studio Information Microsoft Visual Studio Enterprise 2017 Version 15.3.5 VisualStudio.15.Release/15.3.5+26730.16 Microsoft .NET Framework Version 4.7.02046
Installed Version: Enterprise
Architecture Diagrams and Analysis Tools 00369-60000-00001-AA929 Microsoft Architecture Diagrams and Analysis Tools
Visual Basic 2017 00369-60000-00001-AA929 Microsoft Visual Basic 2017
Visual C# 2017 00369-60000-00001-AA929 Microsoft Visual C# 2017
Visual C++ 2017 00369-60000-00001-AA929 Microsoft Visual C++ 2017
Application Insights Tools for Visual Studio Package 8.8.00712.1 Application Insights Tools for Visual Studio
ASP.NET and Web Tools 2017 15.0.30726.0 ASP.NET and Web Tools 2017
ASP.NET Core Razor Language Services 1.0 Provides languages services for ASP.NET Core Razor.
ASP.NET Template Engine 2017 15.0.30726.0 ASP.NET Template Engine 2017
ASP.NET Web Frameworks and Tools 2017 5.2.50601.0 For additional information, visit https://www.asp.net/
Azure App Service Tools v3.0.0 15.0.30728.0 Azure App Service Tools v3.0.0
Azure Data Lake Node 1.0 This package contains the Data Lake integration nodes for Server Explorer.
Azure Data Lake Tools for Visual Studio 2.3.0000.0 Microsoft Azure Data Lake Tools for Visual Studio
Azure Data Lake Tools for Visual Studio 2.3.0000.0 Microsoft Azure Data Lake Tools for Visual Studio
Common Azure Tools 1.10 Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.
Fabric.DiagnosticEvents 1.0 Fabric Diagnostic Events
JavaScript Language Service 2.0 JavaScript Language Service
JavaScript Project System 2.0 JavaScript Project System
Microsoft Azure HDInsight Azure Node 2.2.8000.0 HDInsight Node under Azure Node
Microsoft Azure Hive Query Language Service 2.3.0000.0 Language service for Hive query
Microsoft Azure Service Fabric Tools for Visual Studio 1.7 Microsoft Azure Service Fabric Tools for Visual Studio
Microsoft Azure Stream Analytics Language Service 2.3.0000.0 Language service for Azure Stream Analytics
Microsoft Azure Stream Analytics Node 1.0 Azure Stream Analytics Node under Azure Node
Microsoft Azure Tools 2.9 Microsoft Azure Tools for Microsoft Visual Studio 2017 - v2.9.50719.1
Microsoft Continuous Delivery Tools for Visual Studio 0.3 Simplifying the configuration of continuous build integration and continuous build delivery from within the Visual Studio IDE.
Microsoft JVM Debugger 1.0 Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines
Microsoft MI-Based Debugger 1.0 Provides support for connecting Visual Studio to MI compatible debuggers
Microsoft Visual C++ Wizards 1.0 Microsoft Visual C++ Wizards
Microsoft Visual Studio VC Package 1.0 Microsoft Visual Studio VC Package
Node.js Tools 1.0.0.0 Adds support for developing and debugging Node.js apps in Visual Studio
NuGet Package Manager 4.3.1 NuGet Package Manager in Visual Studio. For more information about NuGet, visit http://docs.nuget.org/.
Office Developer Tools for Visual Studio 2017 ENU 15.0.26712 Microsoft Office Developer Tools for Visual Studio 2017 ENU
SQL Server Data Tools 15.1.61707.200 Microsoft SQL Server Data Tools
ToolWindowHostedEditor 1.0 Hosting json editor into a tool window
TypeScript 2.3.4.0 TypeScript tools for Visual Studio
Visual Studio Code Debug Adapter Host Package 1.0 Interop layer for hosting Visual Studio Code debug adapters in Visual Studio
WebJobs Tools v1.0.0 15.0.30901.0 WebJobs Tools v1.0.0
Workflow Manager Tools 1.0 1.0 This package contains the necessary Visual Studio integration components for Workflow Manager.
Copied from original issue: Azure/Azure-Functions#514
This issue was moved to Azure/azure-functions-vs-build-sdk#295
Reverting move, tracking here.
This is known issue and needs a fix on the VS side. I think this breaks the namespace naming rules and was causing compile errors.