LessCompiler icon indicating copy to clipboard operation
LessCompiler copied to clipboard

Exception

Open davegardner opened this issue 8 years ago • 2 comments

Installed product versions

  • Visual Studio: 2017 Community
  • This extension: 0.9.38

Description

Argument Exception: Illegal characters in path

Steps to recreate

  1. Install Bootstrap
  2. Open any less file
  3. Save it

Current behavior

See exception below. The path of the current less file where this exception was thrown is: C:\Users\dave\Source\Repos\Orchard\src\Orchard.Web\Themes\Cascade.Bootstrap\Styles\bootstrap\less\buttons.less

15/12/2017 6:32:10 AM: System.ArgumentException: Illegal characters in path. at System.Security.Permissions.FileIOPermission.EmulateFileIOPermissionChecks(String fullPath) at System.Security.Permissions.FileIOPermission.QuickDemand(FileIOPermissionAccess access, String fullPath, Boolean checkForDuplicates, Boolean needFullPath) at System.IO.FileInfo.Init(String fileName, Boolean checkHost) at System.IO.FileInfo..ctor(String fileName) at LessCompiler.ProjectMap.<AddOption>d__11.MoveNext() in C:\projects\lesscompiler\src\Compiler\ProjectMap.cs:line 96 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at LessCompiler.ProjectMap.<AddFile>d__10.MoveNext() in C:\projects\lesscompiler\src\Compiler\ProjectMap.cs:line 86 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at LessCompiler.ProjectMap.<BuildMap>d__7.MoveNext() in C:\projects\lesscompiler\src\Compiler\ProjectMap.cs:line 43 --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at LessCompiler.LessCatalog.<EnsureCatalog>d__6.MoveNext() in C:\projects\lesscompiler\src\Compiler\LessCatalog.cs:line 38

Expected behavior

More info needed on why path is illegal. Error makes no sense in a project that otherwise compiles and runs.

davegardner avatar Dec 14 '17 20:12 davegardner

Replicated on Visual Studio Pro 2017 15.7.4 Less Complier v 0.9.38 Upon opening any LESS file in the web project produces the above exception

OzBob avatar Jul 16 '18 06:07 OzBob

When LESS file contains an import that has url("//file.less") Where the path in the url can not be used to create a FileInfo object an exception of type System.ArgumentException is thrown.

OzBob avatar Aug 28 '18 07:08 OzBob