You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a different issue to #38. If an invalid oauth token is used, you get the very cryptic error:
if: Wrong type argument: listp, "https://developer.github.com/v3"
For some reason setting debug-on-error and debug-on-signal both to t didn't help obtain a backtrace of this, so not knowing any better way, I had to spend several hours with Edebug and macrostep before tracking it down. The HTTP response body is:
gh-url-response-init obtains the HTTP response status code (401) but then ignores the fact that the API call failed, and ploughs on regardless, invoking gh-url-response-set-data in a vain attempt to parse the response via gh-object-read-into. In the case where the bug was triggered via magit-gh-pulls-reload, this results in (gh-read data 'url) being evaluated where data is (documentation_url . "https://developer.github.com/v3"), which is not a list; hence the listp failure. However, the error is caught by the condition-case in gh-url-set-response, which made it a lot harder to pin down the real cause:
This is a different issue to #38. If an invalid oauth token is used, you get the very cryptic error:
For some reason setting
debug-on-error
anddebug-on-signal
both tot
didn't help obtain a backtrace of this, so not knowing any better way, I had to spend several hours with Edebug andmacrostep
before tracking it down. The HTTP response body is:gh-url-response-init
obtains the HTTP response status code (401) but then ignores the fact that the API call failed, and ploughs on regardless, invokinggh-url-response-set-data
in a vain attempt to parse the response viagh-object-read-into
. In the case where the bug was triggered viamagit-gh-pulls-reload
, this results in(gh-read data 'url)
being evaluated wheredata
is(documentation_url . "https://developer.github.com/v3")
, which is not a list; hence thelistp
failure. However, the error is caught by thecondition-case
ingh-url-set-response
, which made it a lot harder to pin down the real cause:The text was updated successfully, but these errors were encountered: