SASS Compiler Error on Windows Only

Hello,

I have a project where it compiles and runs just fine on mac/linux and WSL inside windows. But running on Windows, I get errors relating to “SASS Compiler Error” and there appear to be paths that are being transformed and injected somewhere, but wrongly or incompletely. New to meteor, trying to figure out where to even look to debug. Again, the exact same project compiles and works no issue on *nix. I have tried with meteor 3.0.4, 3.0.2, and currently 3.0.3 and no difference on Windows or Linux.

=> Started proxy.
=> Started HMR server.
=> Meteor 3.0.4 is available. Check the changelog https://docs.meteor.com/history.html and update this project with 'meteor update'.
C:\Users\XXX\AppData\Local\.meteor\packages\meteor-tool\3.0.3\mt-os.windows.x86_64\tools\runners\run-app.js:380
        throw e;
        ^

Error: _get "data" called for file with pending errors | ERROR: {"message":"SASS Compiler Error: Error: File to import: XDOTX/stylesXDOTXscss not found in file: /C/Users/XXX/Documents/YYY/repos/PROJECT-NAME/{}/imports/ui/scss/root.scss\n  ╷\n1 │ @import 'XDOTX/stylesXDOTXscss';\n  │         ^^^^^^^^^^^^^^^^^^^^^^^\n  ╵\n  {}\\imports\\ui\\scss\\root.scss 1:9  root stylesheet\n","info":{"file":"/imports/ui/scss/root.scss"}}
    at CssOutputResource._get (C:\tools\isobuild\compiler-plugin.js:980:13)
    at CompilerPluginProcessor.minifyCssResource (C:\tools\isobuild\bundler.js:1129:14)
    at C:\tools\isobuild\compiler-plugin.js:735:19
    at JsOutputResource.finalize (C:\tools\isobuild\compiler-plugin.js:938:7)
    at JsOutputResource.hasPendingErrors (C:\tools\isobuild\compiler-plugin.js:943:5)
    at JsOutputResource.reportPendingErrors (C:\tools\isobuild\compiler-plugin.js:948:9)
    at ImportScanner.scanFile (C:\Users\XXX\AppData\Local\.meteor\packages\meteor-tool\3.0.3\mt-os.windows.x86_64\tools\isobuild\tools\isobuild\import-scanner.ts:1085:9)
    at ImportScanner.scanFile (C:\Users\XXX\AppData\Local\.meteor\packages\meteor-tool\3.0.3\mt-os.windows.x86_64\tools\isobuild\tools\isobuild\import-scanner.ts:1144:9)
    at ImportScanner.scanImports (C:\Users\XXX\AppData\Local\.meteor\packages\meteor-tool\3.0.3\mt-os.windows.x86_64\tools\isobuild\tools\isobuild\import-scanner.ts:741:9)
    at Function.computeJsOutputFilesMap (C:\tools\isobuild\compiler-plugin.js:1404:9)
    at ClientTarget._emitResources (C:\tools\isobuild\bundler.js:1166:30)
    at C:\tools\isobuild\bundler.js:861:7
    at Object.enterJob (C:\tools\utils\buildmessage.js:387:12)
    at ClientTarget.make (C:\tools\isobuild\bundler.js:849:5)
    at C:\tools\isobuild\bundler.js:3293:7
    at C:\tools\isobuild\bundler.js:3452:25
    at Object.capture (C:\tools\utils\buildmessage.js:282:5)
    at bundle (C:\tools\isobuild\bundler.js:3274:18)
    at bundleApp (C:\tools\runners\run-app.js:584:26)
    at AppRunner._runOnce (C:\tools\runners\run-app.js:629:35)
    at AppRunner._runApp (C:\tools\runners\run-app.js:951:23)

Node.js v20.17.0

Any help would be appreciated.

Ok, if you have this file and you import all other scss/sass files in it, try to comment all imports and see if you get through. If you don’t get further errors, uncomment your imports 1 by 1 until you get this error again.
Chances are that one of your styling files has errors.

I would suggest opening an issue in the Meteor repo. Meteor should show the original scss error and wait for you to change a file instead of crashing.

The error indicates a bug in Meteor’s error handling for css resources. The new error handling added in Meteor 3 probably runs too late for or doesn’t handle lazy css resources.

If anyone ever sees the Meteor tool crash with a stack trace, it indicates a bug in the Meteor tool or somewhere it needs to have better error handling. The Meteor tool was designed so this only happens when there was an unexpected error.