saleor-app-framework-python icon indicating copy to clipboard operation
saleor-app-framework-python copied to clipboard

Fix require_permission dependency

Open przlada opened this issue 2 years ago • 3 comments

I want to merge this change because it fixes require_permission dependency.

przlada avatar Jul 28 '22 14:07 przlada

Thanks, please tell me, what was broken here, I can't seem to make sense of it.

pkucmus avatar Jul 29 '22 19:07 pkucmus

@pkucmus this line wasn't working for me:

jwt_payload = jwt.decode(saleor_token, verify=False)

it should be

jwt_payload = jwt.JWT().decode(token, do_verify=False)

from what I found

przlada avatar Jul 29 '22 20:07 przlada

That's not good. I wonder if we have fallen into the https://pyjwt.readthedocs.io/en/latest/ vs https://pypi.org/project/jwt/ trap here, I need to look deeper.

pkucmus avatar Jul 30 '22 08:07 pkucmus