Nekmo / amazon-dash

Hack your Amazon Dash to run what you want.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

unexpected long (1m) delays out of nowhere...?

88gts opened this issue · comments

commented

What is the purpose of your issue?

  • [x ] Bug report (encountered problems with amazon-dash)
  • amazon-dash version: Amazon-dash v1.4.0
  • Python version: Python 3.4.2
    But seeing this on various systems
  • [x ] The pip install or setup install command has been completed without errors
  • [x ] The python -m amazon_dash.install command has been completed without errors
  • [x ] The amazon-dash discovery command works without errors
  • [x ] I have created/edited the configuration file
  • [ x] Amazon-dash service or amazon-dash --debug run works

Description

I have been noticing some long delays with amazon-dash recently, i thought it was a server issue but i tried two additional hosts. tried multiple buttons, nothing changed in my environment. running on very low latency hosts. amazon-dash is taking up to a minute to register a button press. figured id ask if anyone else is seeing this issue as ive tried moving around to different environments with the severe lag persisting. rebooted my network but still seeing a long delay...

2022-01-07 21:52:43,036 - amazon-dash - DEBUG - Accent device executed (mac b4:7c:9c:f8:8f:8a)

commented

Maybe it's a problem with your computer. What machine is Amazon Dash running on?

commented

Nope, just seeing a ton of timeouts.

Traceback (most recent call last):
  File "/usr/local/lib/python3.4/dist-packages/requests/adapters.py", line 449, in send
    timeout=timeout
  File "/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py", line 638, in urlopen
    _stacktrace=sys.exc_info()[2])
  File "/usr/local/lib/python3.4/dist-packages/urllib3/util/retry.py", line 368, in increment
    raise six.reraise(type(error), error, _stacktrace)
  File "/usr/local/lib/python3.4/dist-packages/urllib3/packages/six.py", line 686, in reraise
    raise value
  File "/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py", line 600, in urlopen
    chunked=chunked)
  File "/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py", line 386, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
  File "/usr/local/lib/python3.4/dist-packages/urllib3/connectionpool.py", line 306, in _raise_timeout
    raise ReadTimeoutError(self, url, "Read timed out. (read timeout=%s)" % timeout_value)
urllib3.exceptions.ReadTimeoutError: HTTPConnectionPool(host='XXX', port=80): Read timed out. (read timeout=15)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.4/dist-packages/amazon_dash/execute.py", line 218, in execute
    **kwargs)
  File "/usr/local/lib/python3.4/dist-packages/requests/api.py", line 60, in request
    return session.request(method=method, url=url, **kwargs)
  File "/usr/local/lib/python3.4/dist-packages/requests/sessions.py", line 533, in request
    resp = self.send(prep, **send_kwargs)
  File "/usr/local/lib/python3.4/dist-packages/requests/sessions.py", line 646, in send
    r = adapter.send(request, **kwargs)
  File "/usr/local/lib/python3.4/dist-packages/requests/adapters.py", line 529, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPConnectionPool(host='XXX, port=80): Read timed out. (read timeout=15)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3.4/threading.py", line 920, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.4/threading.py", line 868, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/local/lib/python3.4/dist-packages/amazon_dash/listener.py", line 84, in execute
    result = self.execute_instance.execute(root_allowed)
  File "/usr/local/lib/python3.4/dist-packages/amazon_dash/execute.py", line 220, in execute
    raise ExecuteError('Exception on request to {}: {}'.format(self.data['url'], e))
amazon_dash.exceptions.ExecuteError: Exception on request to http://XXX/public/dashAccent.php: HTTPConnectionPool(host='XXX', port=80): Read timed out. (read timeout=15)
commented

@88gts those errors are probably network errors for your connection. Try making the same request with curl.

$ curl <url>
commented

Closed due to inactivity.