Pylint fixes
This commit is contained in:
parent
b46e36771c
commit
b0bc43b6d4
2 changed files with 31 additions and 29 deletions
|
@ -1,6 +1,6 @@
|
|||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_album.py patched/api_album.py
|
||||
--- original/api_album.py 2013-08-12 18:02:57.510877000 +0100
|
||||
+++ patched/api_album.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/api_album.py 2013-08-16 18:12:30.434212000 +0100
|
||||
+++ patched/api_album.py 2013-08-16 18:13:29.678506001 +0100
|
||||
@@ -3,7 +3,7 @@
|
||||
"""
|
||||
from .objects import Album
|
||||
|
@ -20,8 +20,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_album.
|
|||
self._client = client
|
||||
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_photo.py patched/api_photo.py
|
||||
--- original/api_photo.py 2013-08-12 18:02:57.510877000 +0100
|
||||
+++ patched/api_photo.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/api_photo.py 2013-08-16 18:12:30.434212000 +0100
|
||||
+++ patched/api_photo.py 2013-08-16 18:13:29.678506001 +0100
|
||||
@@ -20,7 +20,7 @@
|
||||
ids.append(photo)
|
||||
return ids
|
||||
|
@ -41,8 +41,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_photo.
|
|||
self._client = client
|
||||
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_tag.py patched/api_tag.py
|
||||
--- original/api_tag.py 2013-08-12 18:02:57.510877000 +0100
|
||||
+++ patched/api_tag.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/api_tag.py 2013-08-16 18:12:30.434212000 +0100
|
||||
+++ patched/api_tag.py 2013-08-16 18:13:29.678506001 +0100
|
||||
@@ -3,7 +3,7 @@
|
||||
"""
|
||||
from .objects import Tag
|
||||
|
@ -61,9 +61,9 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/api_tag.py
|
|||
def __init__(self, client):
|
||||
self._client = client
|
||||
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/config.py patched/config.py
|
||||
--- original/config.py 2013-08-12 18:02:57.510877000 +0100
|
||||
+++ patched/config.py 2013-08-12 18:03:40.123088539 +0100
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/auth.py patched/auth.py
|
||||
--- original/auth.py 2013-08-16 18:13:24.966482000 +0100
|
||||
+++ patched/auth.py 2013-08-16 18:13:51.766615537 +0100
|
||||
@@ -4,7 +4,7 @@
|
||||
from __future__ import unicode_literals
|
||||
import os
|
||||
|
@ -73,18 +73,19 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/config.py
|
|||
except ImportError:
|
||||
from ConfigParser import SafeConfigParser as ConfigParser # Python2
|
||||
try:
|
||||
@@ -12,8 +12,8 @@
|
||||
@@ -12,9 +12,9 @@
|
||||
except ImportError:
|
||||
import StringIO as io # Python2
|
||||
|
||||
-class Config(object):
|
||||
-class Auth(object):
|
||||
+class Auth(object): # pylint: disable=R0903
|
||||
"""OAuth secrets"""
|
||||
- def __init__(self, config_file, host,
|
||||
+class Config(object): # pylint: disable=R0903,C0111
|
||||
+ def __init__(self, config_file, host, # pylint: disable=R0913
|
||||
consumer_key, consumer_secret,
|
||||
token, token_secret):
|
||||
if host is None:
|
||||
@@ -68,7 +68,7 @@
|
||||
@@ -69,7 +69,7 @@
|
||||
parser = ConfigParser()
|
||||
parser.optionxform = str # Case-sensitive options
|
||||
try:
|
||||
|
@ -94,8 +95,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/config.py
|
|||
parser.readfp(buf) # Python2
|
||||
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/http.py patched/http.py
|
||||
--- original/http.py 2013-08-12 18:02:57.510877000 +0100
|
||||
+++ patched/http.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/http.py 2013-08-16 17:54:30.688858000 +0100
|
||||
+++ patched/http.py 2013-08-16 18:14:14.106726301 +0100
|
||||
@@ -7,18 +7,18 @@
|
||||
import requests_oauthlib
|
||||
import logging
|
||||
|
@ -108,7 +109,7 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/http.py pa
|
|||
from .objects import TroveboxObject
|
||||
-from .errors import *
|
||||
+from .errors import * # pylint: disable=W0401
|
||||
from .config import Config
|
||||
from .auth import Auth
|
||||
|
||||
if sys.version < '3':
|
||||
- TEXT_TYPE = unicode
|
||||
|
@ -119,18 +120,18 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/http.py pa
|
|||
|
||||
DUPLICATE_RESPONSE = {"code": 409,
|
||||
"message": "This photo already exists"}
|
||||
@@ -35,7 +35,7 @@
|
||||
This should be used to ensure that your application will continue to work
|
||||
even if the Trovebox API is updated to a new revision.
|
||||
"""
|
||||
@@ -37,7 +37,7 @@
|
||||
"ssl_verify" : True,
|
||||
}
|
||||
|
||||
- def __init__(self, config_file=None, host=None,
|
||||
+ def __init__(self, config_file=None, host=None, # pylint: disable=R0913
|
||||
consumer_key='', consumer_secret='',
|
||||
token='', token_secret='', api_version=None):
|
||||
self._api_version = api_version
|
||||
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/__init__.py patched/__init__.py
|
||||
--- original/__init__.py 2013-08-12 18:02:57.514877000 +0100
|
||||
+++ patched/__init__.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/__init__.py 2013-08-16 18:12:30.438212000 +0100
|
||||
+++ patched/__init__.py 2013-08-16 18:13:29.678506001 +0100
|
||||
@@ -2,7 +2,7 @@
|
||||
__init__.py : Trovebox package top level
|
||||
"""
|
||||
|
@ -150,8 +151,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/__init__.p
|
|||
token='', token_secret='',
|
||||
api_version=None):
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/main.py patched/main.py
|
||||
--- original/main.py 2013-08-12 18:02:57.514877000 +0100
|
||||
+++ patched/main.py 2013-08-12 18:03:40.123088539 +0100
|
||||
--- original/main.py 2013-08-16 18:12:30.438212000 +0100
|
||||
+++ patched/main.py 2013-08-16 18:13:29.678506001 +0100
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
#################################################################
|
||||
|
@ -179,8 +180,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/main.py pa
|
|||
|
||||
if options.verbose:
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/objects.py patched/objects.py
|
||||
--- original/objects.py 2013-08-12 18:03:37.079073000 +0100
|
||||
+++ patched/objects.py 2013-08-12 18:04:00.723190687 +0100
|
||||
--- original/objects.py 2013-08-16 18:12:30.438212000 +0100
|
||||
+++ patched/objects.py 2013-08-16 18:13:29.682506021 +0100
|
||||
@@ -2,16 +2,16 @@
|
||||
objects.py : Basic Trovebox API Objects
|
||||
"""
|
||||
|
@ -229,8 +230,8 @@ diff --unified --recursive '--exclude=.pylint-ignores.patch' original/objects.py
|
|||
self.photos = None
|
||||
self.cover = None
|
||||
diff --unified --recursive '--exclude=.pylint-ignores.patch' original/_version.py patched/_version.py
|
||||
--- original/_version.py 2013-08-12 18:02:57.514877000 +0100
|
||||
+++ patched/_version.py 2013-08-12 18:03:40.127088555 +0100
|
||||
--- original/_version.py 2013-08-16 18:12:30.438212000 +0100
|
||||
+++ patched/_version.py 2013-08-16 18:13:29.682506021 +0100
|
||||
@@ -1,2 +1,2 @@
|
||||
-
|
||||
+ # pylint: disable=C0111
|
||||
|
|
|
@ -13,6 +13,7 @@ except ImportError:
|
|||
import StringIO as io # Python2
|
||||
|
||||
class Auth(object):
|
||||
"""OAuth secrets"""
|
||||
def __init__(self, config_file, host,
|
||||
consumer_key, consumer_secret,
|
||||
token, token_secret):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue