Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unhandled error when enable RTM sync service and no network connection at the same time #63

Open
tkdchen opened this issue Oct 30, 2014 · 1 comment
Labels
bug patch-or-wont-happen Core maintainers would like this, but lack time/energy. Contribute a patch or it won't happen. plugins Plugins and extra backends priority:low

Comments

@tkdchen
Copy link
Contributor

tkdchen commented Oct 30, 2014

Version: devel

Steps to reproduce

  1. Close all network connection, either wireless and wired connection
  2. Launch GTG from command line, then add RTM in synchronization service and enable it
  3. A short time later, check in the terminal, following traceback is printed

Expected result:
Catch this error, then keep silent and stop the authentication request. It's not necessary to let user know such low level errors.

Exception in thread Thread-21:
Traceback (most recent call last):
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 125, in getAuthURL
    frob = self.authInfo.get('frob')
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 74, in get
    raise AuthStateMachine.NoData('No data for <%s>' % state)
GTG.backends.rtm.rtm.NoData: No data for <frob>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib64/python3.3/urllib/request.py", line 1248, in do_open
    h.request(req.get_method(), req.selector, req.data, headers)
  File "/usr/lib64/python3.3/http/client.py", line 1061, in request
    self._send_request(method, url, body, headers)
  File "/usr/lib64/python3.3/http/client.py", line 1099, in _send_request
    self.endheaders(body)
  File "/usr/lib64/python3.3/http/client.py", line 1057, in endheaders
    self._send_output(message_body)
  File "/usr/lib64/python3.3/http/client.py", line 902, in _send_output
    self.send(msg)
  File "/usr/lib64/python3.3/http/client.py", line 840, in send
    self.connect()
  File "/usr/lib64/python3.3/http/client.py", line 818, in connect
    self.timeout, self.source_address)
  File "/usr/lib64/python3.3/socket.py", line 417, in create_connection
    for res in getaddrinfo(host, port, 0, SOCK_STREAM):
socket.gaierror: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib64/python3.3/threading.py", line 637, in _bootstrap_inner
    self.run()
  File "/usr/lib64/python3.3/threading.py", line 594, in run
    self._target(*self._args, **self._kwargs)
  File "/home/chen/git/gtg/GTG/backends/backend_rtm.py", line 567, in _authenticate
    subprocess.Popen(['xdg-open', self.rtm.getAuthURL()])
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 127, in getAuthURL
    frob = self.getNewFrob()
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 119, in getNewFrob
    rsp = self.get(method='rtm.auth.getFrob')
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 103, in get
    json_data = openURL(SERVICE_URL, params).read()
  File "/home/chen/git/gtg/GTG/backends/rtm/rtm.py", line 193, in openURL
    return urllib.request.urlopen(url)
  File "/usr/lib64/python3.3/urllib/request.py", line 156, in urlopen
    return opener.open(url, data, timeout)
  File "/usr/lib64/python3.3/urllib/request.py", line 469, in open
    response = self._open(req, data)
  File "/usr/lib64/python3.3/urllib/request.py", line 487, in _open
    '_open', req)
  File "/usr/lib64/python3.3/urllib/request.py", line 447, in _call_chain
    result = func(*args)
  File "/usr/lib64/python3.3/urllib/request.py", line 1268, in http_open
    return self.do_open(http.client.HTTPConnection, req)
  File "/usr/lib64/python3.3/urllib/request.py", line 1251, in do_open
    raise URLError(err)
urllib.error.URLError: <urlopen error [Errno -2] Name or service not known>
@nekohayo
Copy link
Member

I'm working on putting this project back on its feet with the goal of getting a release out of the door.

This issue here is up for grabs for anyone wanting to see it happen. Please contribute code (or bring in someone who can) to the project for this purpose.

I do not use RTM myself and orphaned code rarely gets better on its own. If nobody steps forward to maintain it, the code may get deactivated or dropped in the long run.

@nekohayo nekohayo added bug patch-or-wont-happen Core maintainers would like this, but lack time/energy. Contribute a patch or it won't happen. priority:low labels Dec 11, 2019
@nekohayo nekohayo added the plugins Plugins and extra backends label May 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug patch-or-wont-happen Core maintainers would like this, but lack time/energy. Contribute a patch or it won't happen. plugins Plugins and extra backends priority:low
Projects
None yet
Development

No branches or pull requests

2 participants