1

I've recently suggested this edit. I've removed around 40 redundant empty lines from the code, which was clearly just copied and pasted from somewhere.

I think that the excessive lines make the code as it is very hard to read. However, the edit was unanimously rejected as too minor. Is it in fact? Am I the only one bothered by those long stretches of good-for-nothing new lines?

10
  • 14
    Given the quality of English in your above post, it seems you could certainly have improved the grammar in the edited question as well. Often "too minor" equates to "fixed one thing without attempting to fix others".
    – OGHaza
    Commented Jul 30, 2014 at 8:32
  • 1
    "I have build one application to check" I can spot something to fix in the first seven words of the post, there was more that could've been done.
    – Joe
    Commented Jul 30, 2014 at 8:32
  • As one of those who voted to close: Formatting is rather controversial in general, and there will never-ever be a consensus for certain points. I generally agree that people should try to format their code appropriately (that is, not in a particular way, but consistently and with proper indentation). But removing empty lines does not increase the "value" of the code, and hardly increases the readability in this case. (And BTW: You could spend the rest of your life with formatting edits like this...)
    – Marco13
    Commented Jul 30, 2014 at 8:33
  • 3
    I would have "improved" your post and unchecked the "this edit was useful" box. But to just reject it seems silly... readability is important.
    – Ben
    Commented Jul 30, 2014 at 8:33
  • 6
    Just removing empty lines is only a marginal improvement in this case. The question is still crap along the lines of "here's a huge code dump, I have a NullPointerException somewhere in there". I don't think there is any way an edit by somebody else than OP could improve the question. Don't edit crap questions, get them closed and make OP edit the actual question to something worthwhile, then you can polish the code or fix minor spelling/grammar issues.
    – l4mpi
    Commented Jul 30, 2014 at 8:34
  • 4
    In addition to the above comments, it's hard to actually see in the side by side edits that multiple lines had been removed as the highlighting just shows a single space highlight when multiple lines have been deleted. In a reviewers eyes a a quick glance through, this would simply look too minor. The side by side edits should possibly highlight entire sections in red on the left and a single space on the right to make it clear what's been edited.
    – Tanner
    Commented Jul 30, 2014 at 9:10
  • @Tanner This is true for the "Rendered Output" view, but when selecting the "Markdown" view, the differences are more obvious.
    – Marco13
    Commented Jul 30, 2014 at 10:54
  • @Marco13 you know what, I've never used that but thanks for pointing it out. I wonder how many reviewers use that by default though?
    – Tanner
    Commented Jul 30, 2014 at 10:56
  • 5
    @l4mpi: Agreed. "Too minor" shouldn't just be taken to mean "you didn't make enough changes". You could fix 200 grammar mistakes and turn a huge block of unreadable code into a beautifully formatted masterpiece, but if you don't actually improve the question into something worth keeping, you're wasting your own time and the reviewers' by making such an edit.
    – Wooble
    Commented Jul 30, 2014 at 12:13
  • I usually considere minor an edit of a readable code. Adding the 4 spaces for code indent is not minor, fixing syntax errors in code (unbalanced parentheses) is not minor, but yes, for me editing other spaces or newlines is minor. Commented Jul 30, 2014 at 14:35

1 Answer 1

2

This is what probably was seen by the reviewers:

rendered view

If they use the rendered view they only see some single spaces being removed. As reviewers in the suggested-edit queue are not known for spending a lot of time on each review they will reject such edits.

In the markdown view it isn't much better to see exactly how much you changed to edit the code in the question into shape.

You would probably have had more luck to get the edit past the reviewers if you not only edited the whitespace but also took on the title and the paragraph of text. For example:

On motoX why do I get the error Sensor Event is null for sensor

I have build an application to check the latency and jitter in sensor events. It runs successfully on a Nexus 5.
But when I try to execute the same application on motoX, I get the following error:

"Sensor event is null for sensor"

What is the root cause for this problem and how should I fix that?

I don't think reviewers would have rejected that suggested edit and with that they would have also accepted your whitespace only fix of the code.

You must log in to answer this question.

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