Skip to content
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

Started agrssive PEP8 reformatting, whitespace and local variable names. #296

Merged
merged 3 commits into from
Jan 3, 2018

Conversation

awiebe
Copy link
Contributor

@awiebe awiebe commented Jan 3, 2018

I've started trying to make the naming conventions in the project consistent with:
https://www.python.org/dev/peps/pep-0008/

So far I've just run over the code with pyCharm and renamed a number of local variables to use the python standard variable_name syntax.

I haven't changed function names yet

Function names should be lowercase, with words separated by underscores as necessary to improve readability.

mixedCase is allowed only in contexts where that's already the prevailing style (e.g. threading.py), to retain backwards compatibility.

I'm not sure whether to go with mixed case everywhere or convert to underscored lowercase. What's important is that the naming conventions are consistent in modules, and preferably consistent across PixivUtil.

@Nandaka Nandaka merged commit 31d2d0e into Nandaka:master Jan 3, 2018
@Nandaka
Copy link
Owner

Nandaka commented Jan 3, 2018

addheaders is from the mechanize.Browers libs, you shouldn't change it.

@@ -79,20 +79,20 @@ def _configureBrowser(self, config):
PixivHelper.GetLogger().info('Debug HTTP enabled.')

# self.visit_response
self.addheaders = [('User-agent', config.useragent)]
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should not be changed, as it is from the mechanize library

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants