release a new version that support jwt.encode returning str (PyJWT 2.0.0)
shikloshi opened this issue · comments
gidgethub
4.2.0 tries to "encode" str type returned from new PyJWT
version
currently get_jwt
in apps.py
tries to:
encoded = jwt.encode(payload, private_key, algorithm="RS256") <-- now really returns a string
bearer_token = encoded.decode("utf-8")
and the new returned type for jwt.encode
is str
and not bytes as it used to be, although this is already fixed on master
it's not been released yet making 4.2.0
potentially broken on newly builded docker images for instance due to the fact it was not pinned under requirements.txt
.
Yes this is fixed in the unreleased v5.0.0. I will cut a release now.
This is done. v5.0.0 is now on PyPI https://pypi.org/project/gidgethub/5.0.0/
GitHub changelog: https://github.com/brettcannon/gidgethub/releases/tag/5.0.0
And thanks for the report!