sugarlabs / sugar-toolkit-gtk3

Sugar Learning Environment, Activity Toolkit, GTK 3.
GNU Lesser General Public License v2.1
21 stars 80 forks source link

flake8 fixes #418

Closed Aniket21mathur closed 5 years ago

quozl commented 5 years ago

Briefly reviewed;

Aniket21mathur commented 5 years ago
* doc/conf.py is an upstream file, and changing it creates unnecessary difference, so please exclude it from flake8 and changes

Changed.

* the appstream metadata for screenshots might not be capable of being split in that fashion, please explain how you tested this,

I reverted the changes. Thanks for pointing out.

* line 1381 of icon.py loses whitespace that is correct english usage.

Thanks. Fixed!

quozl commented 5 years ago

Thanks. Tested with flake8 on Python 2 and Python 3; these remain;

./tests/test_lru.py:6:12: E999 SyntaxError: invalid syntax
./src/sugar3/logger.py:195:23: F821 undefined name 'long'
./src/sugar3/bundle/__init__.py:161:80: E501 line too long (137 > 79 characters)
./src/sugar3/activity/activityinstance.py:25:5: F821 undefined name 'reload'

and doc/conf.py is not excluded.

Aniket21mathur commented 5 years ago

./src/sugar3/bundle/init.py:161:80: E501 line too long (137 > 79 characters)

Because of Appstream metadeta of screenshots.

./src/sugar3/logger.py:195:23: F821 undefined name 'long'

Use of six introduced it, please see

if six.PY2:
        _TYPES.append(long)

./src/sugar3/activity/activityinstance.py:25:5: F821 undefined name 'reload'

Again resulted from use of six.

./tests/test_lru.py:6:12: E999 SyntaxError: invalid syntax

Sorry, but I am not able to find any such file in the toolkit, nor does it exist on github, as I have check now.

doc/conf.py is not excluded.

Reviewed the changes again, sorry I am not able to find any changes in it.

Thanks!

quozl commented 5 years ago

Thanks for checking. test_lru.py was a local file in my repository. doc/conf.py ought to be excluded by .flake8 somehow, but it can be done later.