← Back to team overview

gtg-contributors team mailing list archive

Re: Pep8ification of code

 

On 02/19/2013 02:07 PM, Nimit Shah wrote:> Hi all,
>      I have pep8ified the codebase of GTG. Due to network policy issues
> of my college, I am unable to push the code on bazaar. Can you please
> review the code here: https://github.com/NimitS1/gtg ?
>      I did not attempt to solve the errors of backends_rtm because rtm
> and twitter are going to be updated soon. So the changes made by
> autopep8 are the only changes made to these libraries
>
> Nimit Shah,
> B Tech 4th year,
> Computer Engineering Department,
> SVNIT Surat
> www.dude-says.blogspot.com <http://www.dude-says.blogspot.com>

Hi Nimit,

I skimmed your changes, it looks pretty good. I agree with your point for RTM plugin, but could you make the code pass `make pep8` without a single error? Right now, I get following errors:

pep8 --statistics --count gtg gtcli gtg_new_task GTG
GTG/backends/backend_evolution.py:158:61: E251 no spaces around keyword / parameter equals GTG/backends/backend_launchpad.py:152:58: E251 no spaces around keyword / parameter equals
GTG/backends/backend_rtm.py:112:80: E501 line too long (105 characters)
GTG/backends/backend_rtm.py:113:80: E501 line too long (96 characters)
GTG/backends/backend_rtm.py:114:80: E501 line too long (102 characters)
GTG/backends/backend_rtm.py:145:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:147:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:193:65: E251 no spaces around keyword / parameter equals GTG/backends/backend_rtm.py:255:19: E711 comparison to None should be 'if cond is None:' GTG/backends/backend_rtm.py:355:19: E711 comparison to None should be 'if cond is None:'
GTG/backends/backend_rtm.py:626:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:644:80: E501 line too long (83 characters)
GTG/backends/backend_rtm.py:645:80: E501 line too long (81 characters)
GTG/backends/backend_rtm.py:654:80: E501 line too long (89 characters)
GTG/backends/backend_rtm.py:708:80: E501 line too long (81 characters)
GTG/backends/backend_rtm.py:740:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:763:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:825:19: E712 comparison to True should be 'if cond is True:' or 'if cond:'
GTG/backends/backend_rtm.py:849:80: E501 line too long (80 characters)
GTG/backends/backend_rtm.py:910:80: E501 line too long (81 characters)
GTG/backends/backend_rtm.py:920:80: E501 line too long (82 characters)
GTG/backends/backend_rtm.py:948:16: E711 comparison to None should be 'if cond is not None:'
GTG/backends/backend_rtm.py:958:80: E501 line too long (81 characters)
GTG/backends/backend_rtm.py:1003:23: E711 comparison to None should be 'if cond is None:' GTG/backends/backend_rtm.py:1009:23: E711 comparison to None should be 'if cond is None:' GTG/gtk/backends_dialog/__init__.py:295:26: E251 no spaces around keyword / parameter equals GTG/gtk/editor/calendar.py:69:66: E502 the backslash is redundant between brackets GTG/plugins/tomboy/tomboy.py:72:49: E251 no spaces around keyword / parameter equals GTG/plugins/tomboy/tomboy.py:190:49: E251 no spaces around keyword / parameter equals GTG/plugins/tomboy/tomboy.py:273:45: E251 no spaces around keyword / parameter equals GTG/tests/test_search_filter.py:74:51: E251 no spaces around keyword / parameter equals GTG/tests/test_search_filter.py:90:52: E251 no spaces around keyword / parameter equals
9       E251 no spaces around keyword / parameter equals
16      E501 line too long (105 characters)
1       E502 the backslash is redundant between brackets
5       E711 comparison to None should be 'if cond is None:'
1       E712 comparison to True should be 'if cond is True:' or 'if cond:'
32

Do you know you can import your branch from github into launchpad bazaar? It is done for liblarch code; it is build into our PPA. You need to have a repository where GTG code is directly at the root of repository (now it is in pep8_auto) and then create imported branch in launchpad.

Read more here: https://help.launchpad.net/Code/Imports

Please, make the code pass `make pep8` and I'll merge it.

Izidor


References