coala / coala

coala provides a unified command-line interface for linting and fixing all your code, regardless of the programming languages you use.
https://coala.io/
GNU Affero General Public License v3.0
3.55k stars 1.31k forks source link

Coala counting whitespaces pressent aftercode. #6035

Open AayusHTiw opened 5 years ago

AayusHTiw commented 5 years ago

DESCRIPTION Its good to count white unnecessary white spaces present in the code but it will be more practical if Coala counts only those unnecessary whitespaces which are present between the words of the code, not those which are present at the end of the line as those have no effect on the code output as well as on the screen of the user. STEPS TO REPRODUCE Take any general code in account . for example - import sys a = int(input())(SPACE)(SPACE)(SPACE) ACTUAL RESULT Your source code contains trailing whitespaces. Those usually have no meaning. Please consider removing them. EXPECTED RESULT No output statement or not any suggestion from Coala REPRODUCIBILITY 100% ADDITIONAL INFORMATION The code is written on idle (of python) and not tested via any other ide like pycharm or anaconda.

KVGarg commented 5 years ago

@AayusHTiw Thnx for raising an issue but it is an invalid issue, sorry! Generally, we should ensure that good coding practices be followed and adding unnecessarily white spaces at the end of line is never been a good practice. coala will raise a warning if it finds any of the trailing whitespaces. And, you must be using PEP8Bear which is showing you this log. Python by-default follows PEP8 coding standards Moreover, IDEs like pycharm have built-in plugins. They by-default allows users to write python code following PEP8 coding standards. If it is enabled, it will definitely give you a suggestion(:bulb: ) about trailing whitespaces and will ask to remove them.