Quantcast
Channel: bundletransformer Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 698

Closed Unassigned: LibSass: Unhandled Native Exception on multiple .scss style sheets [116]

$
0
0
When I attempt to create a bundle like the following:

```
var styleBundle = new StyleBundle("~/serve/lib/angular-material/1.0.0-rc4/angular-material.min.css");
styleBundle.Include(new string[] {
"~/lib/angular-material/1.0.0-rc4/variables.scss",
"~/lib/angular-material/1.0.0-rc4/mixins.scss",
"~/lib/angular-material/1.0.0-rc4/typography.scss",
"~/lib/angular-material/1.0.0-rc4/structure.scss"
});
styleBundle.Builder = new NullBuilder();
styleBundle.Transforms.Add(new StyleTransformer());
styleBundle.Orderer = new NullOrderer();

```
Accessing the bundle generates an unhandled native exception.

However, if I combine all 4 scss Style Sheets into one in the order of variables -> mixins -> typography -> structure. Then it compiles to css and works as expected.

No matter how I try to split the files up it throws the unhandled native exception. I thought I would be able to build them just like a set of Less files, but doesn't appear to be the case.

I could be doing something wrong (I don't know scss, I'm just trying to build googles scss in .Net), but I think there is still an issue here because the exception doesn't tell me anything and I think it would be really nice if it was a little more specific.

```
Unhandled exception in native code

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Exception: Unhandled exception in native code

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[Exception: Unhandled exception in native code]
LibSassHost.Native.SassNativeCompiler.Compile(SassDataContext dataContext) +1331
LibSassHost.SassCompiler.Compile(String content, String inputPath, String outputPath, CompilationOptions options) +193
BundleTransformer.SassAndScss.Translators.SassAndScssTranslator.InnerTranslate(IAsset asset, SassCompiler sassCompiler, Boolean enableNativeMinification) +264

[AssetTranslationException: During translation of SCSS-code, readed from the file '/lib/angular-material/1.0.0-rc4/variables.scss', to CSS-code error has occurred.
See more details:

Unhandled exception in native code]
BundleTransformer.SassAndScss.Translators.SassAndScssTranslator.InnerTranslate(IAsset asset, SassCompiler sassCompiler, Boolean enableNativeMinification) +829
BundleTransformer.SassAndScss.Translators.SassAndScssTranslator.Translate(IList`1 assets) +416
BundleTransformer.Core.Transformers.TransformerBase.Translate(IList`1 assets, Boolean isDebugMode) +150
BundleTransformer.Core.Transformers.TransformerBase.Transform(IList`1 assets, BundleContext bundleContext, BundleResponse bundleResponse, VirtualPathProvider virtualPathProvider, Boolean isDebugMode) +129
BundleTransformer.Core.Transformers.TransformerBase.Process(BundleContext bundleContext, BundleResponse bundleResponse, Boolean isDebugMode) +548
System.Web.Optimization.Bundle.ApplyTransforms(BundleContext context, String bundleContent, IEnumerable`1 bundleFiles) +302
System.Web.Optimization.Bundle.GetBundleResponse(BundleContext context) +61
System.Web.Optimization.Bundle.ProcessRequest(BundleContext context) +54
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +508
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +92
```


Viewing all articles
Browse latest Browse all 698

Trending Articles