mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-03-16 22:10:26 +00:00
Remove unneeded pass statements
This commit is contained in:
parent
737c61cd67
commit
1f58419322
5 changed files with 0 additions and 13 deletions
|
|
@ -88,7 +88,6 @@ class FtpUrl(internpaturl.InternPatternUrl, proxysupport.ProxySupport):
|
|||
# note that the info may change every time a user logs in,
|
||||
# so don't add it to the url_data info.
|
||||
log.debug(LOG_CHECK, "FTP info %s", info)
|
||||
pass
|
||||
else:
|
||||
raise LinkCheckerError(_("Got no answer from FTP server"))
|
||||
except EOFError as msg:
|
||||
|
|
@ -103,7 +102,6 @@ class FtpUrl(internpaturl.InternPatternUrl, proxysupport.ProxySupport):
|
|||
features = self.url_connection.sendcmd("FEAT")
|
||||
except ftplib.error_perm as msg:
|
||||
log.debug(LOG_CHECK, "Ignoring error when getting FTP features: %s" % msg)
|
||||
pass
|
||||
else:
|
||||
log.debug(LOG_CHECK, "FTP features %s", features)
|
||||
if " UTF-8" in features.splitlines():
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@ class ItmsServicesUrl(urlbase.UrlBase):
|
|||
def local_check(self):
|
||||
"""Disable content checks."""
|
||||
log.debug(LOG_CHECK, "Checking %s", self)
|
||||
pass
|
||||
|
||||
def check_content(self):
|
||||
"""Allow recursion to check the url CGI param."""
|
||||
|
|
|
|||
|
|
@ -363,7 +363,6 @@ class MailtoUrl(urlbase.UrlBase):
|
|||
log.debug(LOG_CHECK, "found %d MX mailhosts:", len(answers))
|
||||
for preference, host in mxdata:
|
||||
log.debug(LOG_CHECK, "MX host %r, preference %d", host, preference)
|
||||
pass
|
||||
self.set_result(_("Valid mail address syntax"))
|
||||
|
||||
def set_cache_url(self):
|
||||
|
|
|
|||
|
|
@ -470,7 +470,6 @@ def get_gnome_proxy(protocol="HTTP"):
|
|||
return "%s:%d" % (host, port)
|
||||
except Exception as msg:
|
||||
log.debug(LOG_CHECK, "error getting %s proxy from GNOME: %s", (protocol, msg))
|
||||
pass
|
||||
return None
|
||||
|
||||
|
||||
|
|
@ -481,7 +480,6 @@ def get_kde_http_proxy():
|
|||
return data.get("http_proxy")
|
||||
except Exception as msg:
|
||||
log.debug(LOG_CHECK, "error getting HTTP proxy from KDE: %s", msg)
|
||||
pass
|
||||
|
||||
|
||||
def get_kde_ftp_proxy():
|
||||
|
|
@ -491,7 +489,6 @@ def get_kde_ftp_proxy():
|
|||
return data.get("ftp_proxy")
|
||||
except Exception as msg:
|
||||
log.debug(LOG_CHECK, "error getting FTP proxy from KDE: %s", msg)
|
||||
pass
|
||||
|
||||
|
||||
# The following KDE functions are largely ported and ajusted from
|
||||
|
|
|
|||
|
|
@ -197,7 +197,6 @@ class RobotFileParser:
|
|||
self.url,
|
||||
linenumber,
|
||||
)
|
||||
pass
|
||||
else:
|
||||
entry.rulelines.append(RuleLine(line[1], False))
|
||||
state = 2
|
||||
|
|
@ -209,7 +208,6 @@ class RobotFileParser:
|
|||
self.url,
|
||||
linenumber,
|
||||
)
|
||||
pass
|
||||
else:
|
||||
entry.rulelines.append(RuleLine(line[1], True))
|
||||
state = 2
|
||||
|
|
@ -221,7 +219,6 @@ class RobotFileParser:
|
|||
self.url,
|
||||
linenumber,
|
||||
)
|
||||
pass
|
||||
else:
|
||||
try:
|
||||
entry.crawldelay = max(0, int(line[1]))
|
||||
|
|
@ -234,7 +231,6 @@ class RobotFileParser:
|
|||
linenumber,
|
||||
line[1],
|
||||
)
|
||||
pass
|
||||
elif line[0] == "sitemap":
|
||||
# Note that sitemap URLs must be absolute according to
|
||||
# http://www.sitemaps.org/protocol.html#submit_robots
|
||||
|
|
@ -248,7 +244,6 @@ class RobotFileParser:
|
|||
linenumber,
|
||||
line[0],
|
||||
)
|
||||
pass
|
||||
else:
|
||||
log.debug(
|
||||
LOG_CHECK,
|
||||
|
|
@ -257,7 +252,6 @@ class RobotFileParser:
|
|||
linenumber,
|
||||
line,
|
||||
)
|
||||
pass
|
||||
if state in (1, 2):
|
||||
self.entries.append(entry)
|
||||
self.modified()
|
||||
|
|
|
|||
Loading…
Reference in a new issue