-
Notifications
You must be signed in to change notification settings - Fork 29.9k
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
Git input validation got broken in 1.85.0 #200419
Comments
Observed the same. |
Does #185606 (comment) help? @lszomoru changed defaults are often controversial and if this didn't get called out prominently in release notes it's even more likely to catch people out. |
Oh interesting. Yeah, the changing of that default could have been handled/communicated a little better probably. Some feedback, then:
|
And yes, the fact that "always" mode covers the Commit button is pretty problematic! |
Encountered the same issue.
or
solves my issue. |
Yes. But when Instead of the validation message in a floating box that covers other buttons (unfriendly to mouse users), the Commit Message box itself should expand to make room for the validation message box to be contained entirely within the Commit Message box. |
@chrisant996, thank you very much for filing this issue. We did indeed change the default setting for validation in the latest release. I agree that I should have done a better job and documenting the change. I will make sure to update the release notes retroactively so that others can find the change more easily. As far as the current validation UI, I do agree with all of you that it is less than ideal that it overlaps the primary action button. Since the commit message input is a full-fledged Monaco editor, I have been exploring using diagnostics information in order to signal a validation error (see the existing UI vs. the one based on diagnostics): |
Ooo, that would be very nice indeed. No more fiddling to figure out where to manually apply wordwrap; the red squiggles would show exactly where at a glance. |
Not only that, but this would also enable us to create a "code action" to wrap the text. |
Similarly, it would be very nice if "warn" (& "always"?) would continue to show the first error if there is one, even if we leave the current interface. I'd always assumed overlapping the button with an easily closable (tap anywhere) message was intentionally discouraging too-long commit messages when a length limit had been set. Additional, perhaps setting a limit should automatically turn the validation on, if there's a good way to do that? |
Does that mean the message would be automatically formatted according to the line length settings? 🥹 |
This is a weird default to want to change to off. Wouldn't it be better to have the default to 'warn' like previous to nudge people to follow the standard? I know when I first started I did not know git commit messages usually have a 50 character first line. Without this I would be blasting huge commit messages everywhere. |
The default setting was "warn", right? It's beneficial to remind developers to summarise their commit title to less than 50 (or another reasonable length) so the title can be fully displayed everywhere without ellipsis. It also helps display a clean and neat commit log when you do VS code is widely used, I think this default setting is instructive for most developers. If VS code doesn't do this validation by default there will be more and more people writing long commit messages which are difficult to read. @lszomoru why did the team make this decision to change the default setting of this? |
@lszomoru If it's a full-fledged Monaco editor, would it be possible to render ruler lines at the git input validation widths? |
@rikkiprince, you can do that using language specific editor settings. See #93150 (comment) |
Won't word wrapping interfere? If the commit description editor width is narrower than the validation width(s), then word wrapping occurs. And so the input validation width can be at a different pixel position on each individual line. Even if Monaco editors put the ruler lines at the right pixel position on a per-line basis, there will be rule lines all over the place and they won't align. |
I strongly agree that the default setting should be restored. |
This is a matter of being a good git citizen. It doesn't make sense why vscode has changed to use different defaults than git itself does. If the issue was that the warning UI wasn't up to standards, then a preferable fix would be to improve the UI (e.g. any of the ways that have been discussed in this issue). Turning off the validation goes too far and is counter productive in the bigger picture of being a good git citizen. |
@lszomoru, fwiw, methinks this "updating the release notes" didn't get done - at least I found no mention of it. (Didn't help things that I was vacationing for a long time and didn't come across this til 1.86, but even so, couldn't find anything about it in the 1.85 relNotes.) |
@lszomoru For the past couple of months, I have been tearing my hair out why does the commit validation not work anymore? I have finally found a StackOverflow post relating to this which explained that this has been turned off. I am very happy to have it back on. |
Today's VS Code Insiders release (version details below) contains a new setting (
|
The |
I'm confused. This issue reported that a setting's default changed unexpectedly. How come you're asking for feedback on a new implementation of the setting under this issue's comments? Maybe I'm misunderstanding something. Does the new implementation address the concern this issue was trying to bring up? Has the default value been reverted to its expected value ( Edit: Got it! Didn't realize the new feature was a blocker for this issue. |
@lszomoru the new input validation feedback is nice! But 2 questions:
For example, here is what it just showed me a moment ago: From what had been discussed here, I was expected to see the squiggle underline only apply to the characters that exceed the validation limit. Highlighting the entire line means I still manually do a binary search to find where I want to wrap it. Yes, I realize I could press Ctrl-. plus Enter to have it auto-wrap. But that's not ideal because sometimes I want to wrap differently to achieve a more pleasing view. Highlighting the actual overage would be very welcome. UPDATE: I spoke too soon -- the new approach looks nice, but in practice it's actually worse than before, for me: previously it showed the count of characters over limit. Now it only shows the count if I move the mouse and hover over the squiggle and wait a second. So it takes more time and effort now, to apply wrapping. It's only a few seconds per line, but it adds up and it feels like swimming upstream. Thanks for listening and for investing in improvements here! |
@lszomoru Ok after using it for a couple of days, I still don't fully love it, but I've been able to change how I do things to compensate. Having changed how I form and capture my thoughts which typing specifically in that box, I'm able to reduce the effect so it's not as disruptive as it was at first. I still think it would be much better to squiggle-underline only the characters that are over, though. I've adapted, but it's still slower and takes more cognitive concentration, which distracts from coming with content. I.e. I used to focus on content, and then reformat after. But if I focus primarily on formatting and catch overages within a few letters, then I can minimize the time cost. But it distracts me from the content itself, and that's not great. Just trying to share the thought process I experience, for context, in case that's helpful for choosing further refinements. |
Thank you for the feedback. We will continue to listen to additional feedback and adjust the validation UX based on feedback. @GrantGryczan, yes we have discussed reverting the default value of the setting but there are still couple of issues that need to be sorted out. |
I actually preferred the previous dismissable message box as displayed in the image below, thanks to this SO post for the image. It was always on display as a reminder. As @chrisant996 pointed out the new squiggle underline takes time to hover over it, to even see what's wrong with it. The squiggle doesn't immediately convey the error. It could be any kind of error, like a spelling error etc. What's very strange to me is that this change has only occurred recently, at least for me. I'm pretty sure I saw the old message box just last week. And what's more, it is very unprofessional to change the UI very suddenly without warning, or consulting it's users via the software's interface (not everyone keeps updated on these issues!). There was absolutely nothing wrong with the message box, and I highly recommend you reinstate it. If you want, make it an option to change the styling of error, letting us users decide whether to use the message box or the awful (in my opinion) squiggle underline. |
Same here I really preferred the dismissable message box. Please could you bring it back. Why change something that was working and everyone loved it? |
What were the problems with the warning message box that led to removing it? I think the following would be nice:
|
I prefer the display a warning box under the commit input box either. I'm using Code Spell Checker it can help me correct the typos in the commit message. Displaying a warning box in the area might not be the best solution however it works for a long time and is pretty handy. |
I think it would be great if it only underlined the portion of the text that exceeds the line's limit. Then you wouldn't need to hover to see the length! And it would be more convenient than the old design, since it would actually show where you need to wrap or shorten text, as opposed to needing to figure it out by trial and error, counting characters, or guessing. The previous comment would also be less of a problem, since an underline would only appear over the last part of the text. |
Please bring the message box back 🙏 |
Type: Bug
The git commit message input validation coloring and messages no longer show up. This was working a couple days ago, and stopped working when the editor auto-upgraded to v1.85.0.
Repro steps:
Expected:
git.inputValidationSubjectLength
length should be highlighted in red, as they used to be.git.inputValidationLength
then a message should be shown in the Message box indicating the number of extra characters past the validation length.Actual:
It's like the git input validation feature has been completely removed. I didn't see anything in the release notes about that, and the settings still exist, so it seems like an unintentional regression.
My git input validation length settings are the following:
VS Code version: Code 1.85.0 (af28b32, 2023-12-06T20:48:09.019Z)
OS version: Windows_NT x64 10.0.19045
Modes:
System Info
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
A/B Experiments
The text was updated successfully, but these errors were encountered: