-
Notifications
You must be signed in to change notification settings - Fork 12.8k
[CLI DX] Improve the 'x errors' message in the CLI #45713
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
Comments
I'd be interested to give this a shot if it hasn't been picked up yet. This would be my first foray into the code so I'll look into it as well first. |
Sure, give it a shot there's no need to try and claim the issue - until there's a solid WIP PR it's open for anyone to give it a go. |
@orta Apologies for my new-ness, may I ask about running tests? I've implemented the first part of this ticket (I am yet to implement a breakdown of the errors), but multiple files and single files are handled. When running tests I appear to have a number of them failing with this kind of error:
Is this common? |
This has come good, I found it was due to some baselines that didn't match, or were causing some issues. |
Ace, sorry just read all this - looking good so far 👍🏻 |
* Improve error report summaries (#45713) * fixup! Improve error report summaries (#45713) * fixup! fixup! Improve error report summaries (#45713) * Adds support for handling localization renaming the 'files' header due to localization * fixup! Adds support for handling localization renaming the 'files' header due to localization - Fixed baseline error - Fixed linter error Co-authored-by: Orta <[email protected]> Co-authored-by: Orta Therox <[email protected]>
* Improve error report summaries (microsoft#45713) * fixup! Improve error report summaries (microsoft#45713) * fixup! fixup! Improve error report summaries (microsoft#45713) * Adds support for handling localization renaming the 'files' header due to localization * fixup! Adds support for handling localization renaming the 'files' header due to localization - Fixed baseline error - Fixed linter error Co-authored-by: Orta <[email protected]> Co-authored-by: Orta Therox <[email protected]>
Suggestion
As of 4.4, a run of
tsc
looks like:I propose instead we change this message in two key ways, depending on the number of files are raised with errors:
Single file
Multi file
Reasoning
For single files, it's a nice quick small dx improvement which lets you click directly to the file. For multi-files, it's a way to understand the entire scope of your compiler errors. Today to understand what files and where the general amount of errors come from you need to scan the entire text, and if that has scrolled off the terminal - then this is hard to do.
In both cases we only link to the file and line, having the character on the file isn't that useful at this point.
Exceptions
A PR should not include these changes in watch mode. We think there are third-party apps which rely on the text in watch mode, and we want to make sure we've found those and made sure they can handle the changes to the output. So, to not block PRs we request keeping the watch mode as the same output.
The text was updated successfully, but these errors were encountered: