-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make code flake8 complient #19
base: master
Are you sure you want to change the base?
Conversation
$ flake8 *.py ExtractMainContent.py:34:80: E501 line too long (144 > 79 characters) ExtractMainContent.py:48:80: E501 line too long (90 > 79 characters) ExtractMainContent.py:50:80: E501 line too long (90 > 79 characters) ExtractMainContent.py:52:80: E501 line too long (97 > 79 characters) ExtractMainContent.py:55:80: E501 line too long (131 > 79 characters) ExtractMainContent.py:57:80: E501 line too long (101 > 79 characters) Extractor.py:87:80: E501 line too long (84 > 79 characters) Main.py:40:80: E501 line too long (120 > 79 characters) Main.py:59:80: E501 line too long (89 > 79 characters) NewsPulling.py:15:80: E501 line too long (94 > 79 characters) NewsPulling.py:31:80: E501 line too long (113 > 79 characters)
ConfigurationReader.__Limit=cfg['Limit'] | ||
#print ConfigurationReader.__Limit | ||
ConfigurationReader.__WebsiteSupported=cfg['WebsiteSupported'] | ||
#print ConfigurationReader.__WebsiteSupported |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i dont know about the the pep8 . Can u let me know why the comment has been removed?
sys.exit() | ||
if (newsSourceNumber >=len(newsSources)): | ||
print ("Please select the index no less than "+ str(len(newsSources))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removing parenthesis from the print doesn't make it compliant only for the python 2.7 while having it makes it work for both python 2.7 and python 3.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the aim is to make it compatible between python2 and python3, generally either
- 'from future import print_function' is used
Or - six is made a part of the library. Refer http://six.readthedocs.io/ .
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is is better to go with 'from future import print_function' at this point in time.
Sure. Will take care of it in next pull request.
Don't want to take it up in this one.
FWIW, I don't think worrying about python 2 and 3 compatibility is an
issue that should be a point of concern.
Reference:
https://docs.python.org/2/howto/pyporting.html#the-short-explanation
…On Mon, Oct 9, 2017 at 8:55 AM, Ankit Singh ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In Main.py
<#19 (comment)>
:
> sys.exit()
- if (newsSourceNumber >=len(newsSources)):
- print ("Please select the index no less than "+ str(len(newsSources)))
I think it is is better to go with 'from future import print_function' at
this point in time.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#19 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHZWMeHmcsP9mrcDp19ywXk8sC1TsSwLks5sqZJDgaJpZM4PtFa9>
.
|
$ flake8 *.py
ExtractMainContent.py:34:80: E501 line too long (144 > 79 characters)
ExtractMainContent.py:48:80: E501 line too long (90 > 79 characters)
ExtractMainContent.py:50:80: E501 line too long (90 > 79 characters)
ExtractMainContent.py:52:80: E501 line too long (97 > 79 characters)
ExtractMainContent.py:55:80: E501 line too long (131 > 79 characters)
ExtractMainContent.py:57:80: E501 line too long (101 > 79 characters)
Extractor.py:87:80: E501 line too long (84 > 79 characters)
Main.py:40:80: E501 line too long (120 > 79 characters)
Main.py:59:80: E501 line too long (89 > 79 characters)
NewsPulling.py:15:80: E501 line too long (94 > 79 characters)
NewsPulling.py:31:80: E501 line too long (113 > 79 characters)