Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sass --embedded doesn't reliably exit when closing stdin on Windows #2424

Open
bep opened this issue Nov 1, 2024 · 4 comments
Open

sass --embedded doesn't reliably exit when closing stdin on Windows #2424

bep opened this issue Nov 1, 2024 · 4 comments
Labels
bug embedded Issues about the embedded compiler needs info

Comments

@bep
Copy link

bep commented Nov 1, 2024

This is the same as #2278

This looks like a regression as the tests

  • Pass in 1.63.2
  • Fails in >= 1.77.5 (last tested 1.80.5)

This works fine on other platforms tested: MacOS and Linux.

I see no error output (stderr, log events) while testing this.

bep/godartsass#29

@ntkme
Copy link
Contributor

ntkme commented Nov 1, 2024

I wasn't able to reproduce this using the ruby host implementing the exactly same logic as your failing test running on GitHub Actions, and I don't have access to a local windows dev environment.

@bep Is it possible for you to build dart-sass with the following patch and see if it makes any difference:

diff --git a/lib/src/embedded/isolate_dispatcher.dart b/lib/src/embedded/isolate_dispatcher.dart
index fe79f034..085035fe 100644
--- a/lib/src/embedded/isolate_dispatcher.dart
+++ b/lib/src/embedded/isolate_dispatcher.dart
@@ -97,7 +97,7 @@ class IsolateDispatcher {
       _handleError(error, stackTrace);
     }, onDone: () {
       _closed = true;
-      _allIsolates.stream.listen((isolate) => isolate.kill());
+      exit(exitCode);
     });
   }
 

@bep
Copy link
Author

bep commented Nov 1, 2024

@bep Is it possible for you to build dart-sass with the following patch and see if it makes any difference:

Reading the building from source I see nothing about cross-compiling to Windows, so I would say no. If you could point me to a Windows executable, I can find a way to test it.

@ntkme
Copy link
Contributor

ntkme commented Nov 1, 2024

@nex3 nex3 added bug needs info embedded Issues about the embedded compiler labels Nov 1, 2024
@nex3
Copy link
Contributor

nex3 commented Nov 1, 2024

Dart doesn't support cross-compilation, but you can build from source on Windows itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug embedded Issues about the embedded compiler needs info
Projects
None yet
Development

No branches or pull requests

3 participants