question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

dotnet build doesn't correctly handle special chars in project paths

See original GitHub issue

Steps to reproduce

Create a new folder containing accents/special chars (e.g I love special chars - éèàôöç) Run dotnet new to initialize a new project. Run dotnet restore. Run dotnet run.

Expected behavior

Hello World!

Actual behavior

PS G:\I love special chars - éèàôöç> dotnet new
Created new C# project in G:\I love special chars - éèàôöç.

PS G:\I love special chars - éèàôöç> dotnet restore
log  : Restoring packages for G:\I love special chars - éèàôöç\project.json...
info : Committing restore...
log  : Writing lock file to disk. Path: G:\I love special chars - éèàôöç\project.lock.json
log  : G:\I love special chars - éèàôöç\project.json
log  : Restore completed in 1395ms.

NuGet Config files used:
    G:\I love special chars - éèàôöç\NuGet.Config
    C:\Users\Chalet Kévin\AppData\Roaming\NuGet\NuGet.Config

Feeds used:
    https://dotnet.myget.org/F/dotnet-core/api/v3/index.json
    https://api.nuget.org/v3/index.json

PS G:\I love special chars - éèàôöç> dotnet run
Compiling I love special chars - éèàôöç for .NETStandard,Version=v1.5
dotnet : Response file 'G:\I love special chars - éèàôöç\obj\Debug\netstandard1.5\dotnet-compile.rsp' doesn't exist.
At line:1 char:1
+ dotnet build
+ ~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (Response file '... doesn't exist.:String) [], RemoteException
    + FullyQualifiedErrorId : NativeCommandError

C:\Program Files\dotnet\dotnet.exe compile-csc "@G:\I love special chars - éèàôöç\obj\Debug\netstandard1.5\dotnet-compile.rsp" returned Exit Code 1

Compilation failed.
    0 Warning(s)
    0 Error(s)

Time elapsed 00:00:00.1348554

Environment data

dotnet --info output:

.NET Command Line Tools (1.0.0-beta-002202)

Product Information: Version: 1.0.0-beta-002202 Commit Sha: 60b23d5115

Runtime Environment: OS Name: Windows OS Version: 6.1.7601 OS Platform: Windows RID: win7-x64

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
kevinchaletcommented, Apr 19, 2016
0reactions
kevinchaletcommented, Apr 19, 2016

Closing, since https://github.com/dotnet/cli/issues/2486 is already triaged (even if this thread is older 😄).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Version 16.4.4 does not support special characters in ...
Create a C# Class Library project under path: C:\Users\v-zhajin\source\repos\ÅÖÄÂydy which contain the special character; Build the project
Read more >
How to remove illegal characters from path and filenames?
The best way to remove illegal character from user input is to replace illegal character using Regex class, create method in code behind...
Read more >
Path.Combine Method (System.IO)
This method is intended to concatenate individual strings into a single string that represents a file path. However, if an argument other than...
Read more >
Path Class (System.IO)
Performs operations on String instances that contain file or directory path information. These operations are performed in a cross-platform manner.
Read more >
NET SDK error list - .NET CLI
A complete list of NETSDKxxxx errors, with links to more info where more info is available.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found