From d5db9f4df0b4ad77bc5911ab0408435b3ff844d4 Mon Sep 17 00:00:00 2001 From: Steve Barrau Date: Sat, 6 Feb 2016 15:27:10 +0100 Subject: fix deprecated calls - `logging.warn` becomes `logging.warning` - Inherit from `Object` is implicit - `super()` does not need the self reference in py3 --- httpfs/__init__.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/httpfs/__init__.py b/httpfs/__init__.py index b69c26e..1d04bd8 100644 --- a/httpfs/__init__.py +++ b/httpfs/__init__.py @@ -14,7 +14,7 @@ import fuse import requests -class Config(object): +class Config: mountpoint = None timeout = None verify = None @@ -163,7 +163,7 @@ class Server(Directory): elif Config.verify == "system": self.session.verify = Config.system_ca elif Config.verify == "none": - logging.warn("SSL Verification disabled!") + logging.warning("SSL Verification disabled!") self.session.verify = False else: raise SystemExit("Invalid value for ssl verification") @@ -198,7 +198,7 @@ class Root(Directory): class RelativeLinkCollector(HTMLParser): def __init__(self, parent): - super().__init__(self, convert_charrefs=True) + super().__init__(convert_charrefs=True) self.parent = parent self.entries = {} @@ -236,7 +236,7 @@ class Httpfs(fuse.LoggingMixIn, fuse.Operations): for machine in netrc.netrc().hosts.keys(): yield (machine, Server(parent, machine)) except IOError as e: - logging.warn("No .netrc file found, no default machines") + logging.warning("No .netrc file found, no default machines") def getattr(self, path, fh=None): logging.debug("getattr path={}".format(path)) -- cgit v1.2.1