22

In the question:

Why does this use, in Java, of regular expressions throw an "Unclosed character class" exception at runtime?

The OP has nothing that needs to be changed in regards to content. However, they didn't format any of their source. I want to just edit the source and call it done, but there is a 6-character limit for suggested edits.

Does the limit make sense in this case?

7
  • 8
    No. For trivial edits, leave it to users who have privilege to edit directly (not suggesting edit). And it seems that it's been done. Edit: well, I think you can use 4-spaces "trick" to format the code instead. Given there are 4 instances that can be used, you can pass the requirement to suggest edit.
    – Andrew T.
    Commented May 6, 2014 at 3:53
  • There was quite a bit further to change. Commented May 6, 2014 at 4:14
  • Considering how many edits were going on all at the same time I wished to edit it, I don't think that its fair to give me a downvote. Whose revision was I really looking at?
    – avgvstvs
    Commented May 6, 2014 at 11:18
  • 4
    See also: meta.stackoverflow.com/questions/265763 a pretty popular question, without a really satisfactory resolution (IMHO). I just tried to fix a syntax error in an answer and was rejected on the 6-chars minimum limit. How can we make it easier for good caring editors to fix real code errors that are small?
    – arielf
    Commented Jan 7, 2015 at 14:37
  • I too find this limit silly. stackoverflow.com/questions/20963419/…
    – Joncom
    Commented Oct 3, 2015 at 16:03
  • I also think this is arbitrary. I found a copy-paste answer which solved my problem, but had a typo. I wanted to improve the answer's quality by fixing this typo. stackoverflow.com/questions/3903817/…
    – kilojoules
    Commented Jun 25, 2016 at 19:54
  • 1
    I've come across a few answers where a single word is misspelled, which could change the interpretation of the answer for less experienced users that don't know what the poster meant to say. Being unable to quickly remedy this, especially in older answers, is frustrating.
    – Sean
    Commented Oct 25, 2018 at 16:23

3 Answers 3

21

I have no major problem with edits that consist entirely of fixing code formatting, given how irritating it is to try and read unformatted code.

But rare is the post full of unformatted code that doesn't cry out for additional cleanup. The question you linked to is a perfect example, currently up to 8 revisions with multiple editors fixing multiple serious problems in the original.

Posts that cannot be improved by changing more than 6 characters are something of a mythical creature, but if you do stumble upon one just leave a comment, something along the lines of

Select your code and press Ctrl+K to format it

...and then move on to a different post. There is no shortage of posts needing edits.

7
  • 15
    Bad idea. You're suggesting it's a good idea to try and delegate something when it would take more time to do the delegation than it would take to make the edit. It would be faster to just make the minor fix myself, rather than leave a comment to explain the change. Then I could 'move on to a different post' more quickly and be done with it.
    – ChatGPT
    Commented Jun 6, 2014 at 5:29
  • 6
    @MaxHodges The edit review queue is already flooded with robo editors who're doing the absolute minimum needed to earn 2 rep points while leaving a mess of other unfixed items in 99/100 posts they touch. This is a much larger burden than the extremely rare post that requires <6 chars of editing to be fixed. Opening the flood gates even wider would cause far more harm than the current constraint prevents. Commented Jul 16, 2014 at 18:49
  • 6
    So you value preventing people from earning points unfairly more than people's ability to correct mistakes?
    – ChatGPT
    Commented Jul 25, 2014 at 18:03
  • I re-read this answer twice and did a search - there's nothing about points in it, @Max. Perhaps it was too short and you inadvertently read something else without realizing you'd moved on? If so, you can find a much longer explanation here.
    – Shog9
    Commented Jul 25, 2014 at 18:08
  • In the comment above mine you can find the word "points" between "rep" and "while". keep searching
    – ChatGPT
    Commented Jul 26, 2014 at 0:13
  • 3
    So your comment was addressed at Dan then, @Max? You might want to read the rest of his comment, the bit where he talks about folks ignoring mistakes. Which, incidentally, turns out to be what's going on just about every time someone complains about this restriction.
    – Shog9
    Commented Jul 26, 2014 at 0:36
  • 1
    @Shog9 I think it was pretty evident that max was addressing Dan's comment. And Dan brings up a good point, if that is a serious issue then that's a problem. But the appropriate solution to that problem is not constricting a persons editing capabilities. There are cases when a singly character can completely change a programs logic. And other times when a single character can make one have to re-read a sentence a couple times to understand what's being said. You call them a rare, and a mythical creature, but I entirely disagree. This happens to me quite frequently while reading posts
    – csga5000
    Commented Jan 19, 2016 at 19:25
17

Yes, Stack Overflow users can and should fix this problem. A few characters can make a big difference in a piece of code. I'm not talking about minor spelling, formatting and grammar issues. The whole purpose of this site is to find solutions to programming problems. So it's a disservice to the community that we cannot make an edit that would transform a broken piece of code into a working solution.

Example, in this post, the original poster has the wrong variable, it should be dateFromFilter not dateFilter. This is the kind of thing that someone could easily miss and waste lot of time over troubleshooting.

2
  • 15
    Perhaps the restriction of 6 characters edits could be disabled for code blocks.
    – Matthias M
    Commented Nov 18, 2014 at 20:37
  • 2
    I realize it's not nearly so important but I still wish I could correct "different" to "difference"
    – csga5000
    Commented Jan 19, 2016 at 19:29
10

Maybe one should distinguish between edit of the text and edit of the code. I tried to fix invalid XML (two slashes missing) and I failed. So I would vote for even a 1 character change in a code block if it’s a legitimate one.

1
  • Exactly. I was trying to fix one small, but very important error in the snippet in this question: stackoverflow.com/a/38660324/1426035. Instead of _, the OP used x, which caused that snippet to error out. Fixing that small thing required me to type an additional paragraph which wasn't really necessary. Seems very weird to me. Commented Mar 29, 2017 at 12:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .