flake8 cleanup of fauxmo

This commit is contained in:
Emil Lerch 2019-07-19 18:51:38 -07:00
parent 38fcf3fbae
commit 0e534d8d9d
Signed by: lobo
GPG Key ID: CEC5F37C1BE5A481

View File

@ -33,11 +33,8 @@ import socket
import struct
import sys
import time
import urllib
import uuid
# This XML is the minimum needed to define one of our virtual switches
# to the Amazon Echo
@ -57,6 +54,7 @@ SETUP_XML = """<?xml version="1.0"?>
DEBUG = False
def dbg(msg):
global DEBUG
if DEBUG:
@ -124,7 +122,6 @@ class upnp_device(object):
dbg("got local address of %s" % upnp_device.this_host_ip)
return upnp_device.this_host_ip
def __init__(self, listener, poller, port, root_url, server_version, persistent_uuid, other_headers=None, ip_address=None):
self.listener = listener
self.poller = poller
@ -193,7 +190,7 @@ class upnp_device(object):
temp_socket.sendto(message, destination)
# This subclass does the bulk of the work to mimic a WeMo switch on the network.
# This subclass does the bulk of the work to mimic a WeMo switch on the network
class fauxmo(upnp_device):
@staticmethod
@ -420,4 +417,3 @@ while True:
except Exception, e:
dbg(e)
break