Page MenuHomePhabricator

diff-checker.py should not check lines where only indentation changed
Closed, DeclinedPublic

Description

This diff should not fail like this

Event Timeline

It can be done, but I'm not sure if it's necessary or desired. Diff-checker errors are very easy to fix and I look at this as an opportunity to improve the code. Also git tools like blame and diff will blame you for the change by default, even the blame button on gerrit does that, and diff-checker is using the default, too.

Also, the title of this task is suggesting to ignore long line errors, too. Do we really want that?

@Xqt, what do you think?

Many diff tools ignore indentation, but I would understand if you clouse this task as declined. Maybe some clever test only for line length on lines where only indentation changed would also be a possiblity.

I rethinked also about my other task T183094. I guess the diff checker improves code styling to have a same base currently for unicode literals and code line length and it could be advantageous to improve older code for any change sooner. Sure some coder might have problems with it especially newbies but the gerrit online editor is helpfull in that case except for some like me who have dozens of open commits and the local repository could be messed up.