-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Angular 17 with :application executor runs into blocking console issues #22731
Comments
It seems that setting on the executer options the option |
Additional: the ANSI Escape sequence has something to do here: https://en.wikipedia.org/wiki/Escape_sequence The ^[[8; escape sequence is only supported by some terminals. If you are using a terminal that does not support it, the concealed text will be displayed normally. The ^[[8; escape sequence can be used to conceal any type of text, including text that is already colored. The ^[[8; escape sequence can be combined with other ANSI escape sequences to create more complex effects. For example, you could use the ^[[8; escape sequence to conceal text that is also blinking or underlined. |
same issue here. upgrading node from 16 to 20 improved the issue from happening almost-always to decently-often - but it still persists in general. @ErickRodrCodes would you be so nice to elaborate on how/where exactly to put verbose to false in the config? :) |
Sure thing. In your project.json browse: targets -> build -> options, then set an option called "verbose" to be false. that should be enough. also add in your environment variables (powershell): $Env:CI="true"
$Env:FORCE_COLOR=0 to ensure an additional layer of preventing chalk or colors to be in any way rendered on the terminal. I'm seeing it quite persistent with this issue and that helped me also to avoid this issue in some manner. Not ideal, but at least I can work. |
Just to add I'm seeing this on many different monorepos when running different tasks on both React, Nest and .NET (nx-dotnet). It happens with many different targets including build, serve, test and lint, but not every time. It seems to have started with an update about a month ago. I'm on Windows with Node 20. Like @ErickRodrCodes says it looks like an attempt to color or format console text so disabling coloring should work, but I think it might be a bug in some internal Nx utility. |
Hey thanks for the report! This is a known issue and tracked in #22358. |
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context. |
Current Behavior
Environment: Windows 10 Enterprise 22H2
In random cases, when serving Angular 17 with the application executioner, it tends to block the terminal with some incomplete characters:
while this happens the task runner is in a lethargic state:
Only after pressing CTRL + C, the terminal unfreezes, and you can input a serving command as R, Q or H
Note that sometimes it works, and in this case, I had to kill it:
and the worst-case scenario is I have to kill every single node process if CTRL+C doesn't work with
I suspect the issue is located with chalk, other coloring library, or simply the spinner prevents to run something when rendering on the terminal. I even ensured it takes
FORCE_COLOR=0
to prevent any color rendering. Reason I'm suspecting of it is for the similar output I get on build on CI:Expected Behavior
It just should serve. It started to happen after migrating to Angular 17 and set up the executor as
@angular-devkit/build-angular:application
GitHub Repo
No response
Steps to Reproduce
@angular-devkit/build-angular:application
on the codebase. just run in powershellnx serve your-angular-app
and sporadically will show up a blocking set of strings.Nx Report
Failure Logs
Package Manager Version
npm 9.8.1
Operating System
Additional Information
as a preventive measure I tried to run
cross-env FORCE_COLOR=0 CI=true
to ensure coloring won't happen, however something is triggering some strange character that blocks the terminal to continue.The text was updated successfully, but these errors were encountered: