{"action":"created","issue":{"url":"https://api.github.com/repos/pycontribs/jira/issues/117","labels_url":"https://api.github.com/repos/pycontribs/jira/issues/117/labels{/name}","comments_url":"https://api.github.com/repos/pycontribs/jira/issues/117/comments","events_url":"https://api.github.com/repos/pycontribs/jira/issues/117/events","html_url":"https://github.com/pycontribs/jira/issues/117","id":100715884,"number":117,"title":"oauth: ValueError: Only unicode objects are escapable","user":{"login":"muffl0n","id":927904,"avatar_url":"https://avatars.githubusercontent.com/u/927904?v=3","gravatar_id":"","url":"https://api.github.com/users/muffl0n","html_url":"https://github.com/muffl0n","followers_url":"https://api.github.com/users/muffl0n/followers","following_url":"https://api.github.com/users/muffl0n/following{/other_user}","gists_url":"https://api.github.com/users/muffl0n/gists{/gist_id}","starred_url":"https://api.github.com/users/muffl0n/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/muffl0n/subscriptions","organizations_url":"https://api.github.com/users/muffl0n/orgs","repos_url":"https://api.github.com/users/muffl0n/repos","events_url":"https://api.github.com/users/muffl0n/events{/privacy}","received_events_url":"https://api.github.com/users/muffl0n/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-08-13T08:45:15Z","updated_at":"2015-10-04T13:35:52Z","closed_at":"2015-10-04T13:35:52Z","body":"I'm trying to do the \"oauth dance\" with jirashell. Unfortunately I get this error:\r\n```\r\n$ jirashell -s http://jira.example.com -u foo -p bar -od\r\nTraceback (most recent call last):\r\n  File \"/tmp/jira_client/venv/bin/jirashell\", line 11, in <module>\r\n    sys.exit(main())\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/jira/jirashell.py\", line 244, in main\r\n    options['server'], oauth['consumer_key'], oauth['key_cert'], oauth['print_tokens'], options['verify'])\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/jira/jirashell.py\", line 40, in oauth_dance\r\n    server + '/plugins/servlet/oauth/request-token', verify=verify, auth=oauth)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/api.py\", line 109, in post\r\n    return request('post', url, data=data, json=json, **kwargs)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/api.py\", line 50, in request\r\n    response = session.request(method=method, url=url, **kwargs)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/sessions.py\", line 451, in request\r\n    prep = self.prepare_request(req)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/sessions.py\", line 382, in prepare_request\r\n    hooks=merge_hooks(request.hooks, self.hooks),\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/models.py\", line 308, in prepare\r\n    self.prepare_auth(auth, url)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests/models.py\", line 496, in prepare_auth\r\n    r = auth(self)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/requests_oauthlib/oauth1_auth.py\", line 87, in __call__\r\n    unicode(r.url), unicode(r.method), None, r.headers)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/__init__.py\", line 313, in sign\r\n    ('oauth_signature', self.get_oauth_signature(request)))\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/__init__.py\", line 128, in get_oauth_signature\r\n    uri, headers, body = self._render(request)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/__init__.py\", line 210, in _render\r\n    request.oauth_params, request.headers, realm=realm)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/utils.py\", line 31, in wrapper\r\n    return target(params, *args, **kwargs)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/parameters.py\", line 57, in prepare_headers\r\n    escaped_value = utils.escape(value)\r\n  File \"/tmp/jira_client/venv/lib64/python3.4/site-packages/oauthlib/oauth1/rfc5849/utils.py\", line 56, in escape\r\n    'Got %s of type %s.' % (u, type(u)))\r\nValueError: Only unicode objects are escapable. Got None of type <class 'NoneType'>.\r\n```\r\n\r\nI'm not quite sure where to start debugging this. Is it an error in jirashell? Or in oauth?\r\n\r\nLogging in with ``jirashell -s http://jira.example.com -u foo -p bar`` works like a charm.\r\n\r\n<bountysource-plugin>\r\n---\r\nWant to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/25715700-valueerror-only-unicode-objects-are-escapable?utm_campaign=plugin&utm_content=tracker%2F3650997&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F3650997&utm_medium=issues&utm_source=github).\r\n</bountysource-plugin>"},"comment":{"url":"https://api.github.com/repos/pycontribs/jira/issues/comments/145350635","html_url":"https://github.com/pycontribs/jira/issues/117#issuecomment-145350635","issue_url":"https://api.github.com/repos/pycontribs/jira/issues/117","id":145350635,"user":{"login":"ssbarnea","id":102495,"avatar_url":"https://avatars.githubusercontent.com/u/102495?v=3","gravatar_id":"","url":"https://api.github.com/users/ssbarnea","html_url":"https://github.com/ssbarnea","followers_url":"https://api.github.com/users/ssbarnea/followers","following_url":"https://api.github.com/users/ssbarnea/following{/other_user}","gists_url":"https://api.github.com/users/ssbarnea/gists{/gist_id}","starred_url":"https://api.github.com/users/ssbarnea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ssbarnea/subscriptions","organizations_url":"https://api.github.com/users/ssbarnea/orgs","repos_url":"https://api.github.com/users/ssbarnea/repos","events_url":"https://api.github.com/users/ssbarnea/events{/privacy}","received_events_url":"https://api.github.com/users/ssbarnea/received_events","type":"User","site_admin":false},"created_at":"2015-10-04T13:35:52Z","updated_at":"2015-10-04T13:35:52Z","body":"Please add a test (inside tests.py) that replicates the problem against our test instance. I will try to fix it if I have a test on it, otherwise I will keep this closed and consider oauth unsupported. "}}