Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async def response_handler(request):
assert request.headers["User-Agent"] == f"PythonWLED/{__version__}"
return aresponses.Response(text="TEDDYBEAR", status=200)
self._session = session
self._close_session = False
self.base_path = base_path
self.host = host
self.password = password
self.port = port
self.socketaddr = None
self.request_timeout = request_timeout
self.tls = tls
self.username = username
self.verify_ssl = verify_ssl
self.user_agent = user_agent
if user_agent is None:
self.user_agent = f"PythonWLED/{__version__}"
if self.base_path[-1] != "/":
self.base_path += "/"