Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSascha Silbe <sascha-pgp@silbe.org>2013-08-12 13:29:11 (GMT)
committer Sascha Silbe <sascha-pgp@silbe.org>2013-08-12 13:35:08 (GMT)
commit2015d02c3b329a492ca5c426043a8a119abf8dc4 (patch)
treed50c2a75c079eab23444f61cc014c8c1a65cd207
parent9453bc76c102c2c0785a9b4e046f3339658a9e94 (diff)
Add a few pychecker hints
Squelch pychecker warnings by adding explicit hints. Some are for issues in code we copied from PyWebDAV, others are for cases where pychecker isn't smart enough.
-rwxr-xr-xjournal2webdav8
1 files changed, 8 insertions, 0 deletions
diff --git a/journal2webdav b/journal2webdav
index a75eaf0..9805a88 100755
--- a/journal2webdav
+++ b/journal2webdav
@@ -26,10 +26,12 @@ import time
import urllib
from urlparse import urljoin, urlparse
+__pychecker__ = 'no-miximport'
try:
from pywebdav.lib import propfind
except ImportError:
# pywebdav < 0.9.8
+ __pychecker__ = 'no-reimport'
from DAV import propfind
from DAV.constants import COLLECTION, OBJECT
from DAV.iface import dav_interface
@@ -42,6 +44,7 @@ else:
from pywebdav.lib.iface import dav_interface
from pywebdav.lib.errors import DAV_Error, DAV_NotFound, DAV_Requested_Range_Not_Satisfiable
from pywebdav.lib.WebDAVServer import DAVRequestHandler as DAVAuthHandler
+ __pychecker__ = 'no-reimport'
from xml.parsers.expat import ExpatError
_PYWEBDAV_BUGS = set(['ALLPROP_RECURSE', 'HTTP10_KEEPALIVE'])
@@ -76,6 +79,8 @@ class ThreadedHTTPServer(ThreadingMixIn, HTTPServer):
class PROPFIND(propfind.PROPFIND):
+ __pychecker__ = 'no-override'
+
if 'PROPFIND_NS' in _PYWEBDAV_BUGS:
# pylint: disable=C0324,C0322
def mk_propname_response(self,uri,propnames,doc):
@@ -172,6 +177,7 @@ class WebdavResource(object):
raise NotImplementedError('Not implemented by subclass')
def read(self, length=0):
+ __pychecker__ = 'no-argsused'
raise NotImplementedError('Not implemented by subclass')
@@ -352,6 +358,7 @@ class JournalHandler(dav_interface):
if not child_name in ['.', '..']]
def get_data(self, uri, byte_range=None):
+ __pychecker__ = 'no-returnvalues'
log.debug('get_data %r %r', uri, byte_range)
fs_object = self._lookup_uri(uri)
@@ -540,6 +547,7 @@ class RequestHandler(DAVAuthHandler):
def send_body(self, DATA, code=None, msg=None, desc=None,
ctype='application/octet-stream', headers={}):
""" send a body in one part """
+ __pychecker__ = 'no-argsused no-moddefvalue no-shadowbuiltin'
log.debug("Use send_body method")
if self.request_version != 'HTTP/1.1':