-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Tymon\JWTAuth\Exceptions\JWTException: Could not create token: Implicit conversion of keys from strings is deprecated. Please use InMemory or LocalFileReference classes. #2059
Comments
Please check this upgrading guide https://lcobucci-jwt.readthedocs.io/en/latest/upgrading/#v3x-to-v4x |
EDIT by @tymondesigns In |
lcobucci/jwt:3.4 has this problem, composer require lcobucci/jwt:3.3 can resolve it. |
How to fix for Lumen ? |
@wasddsaw publish jwt config file and load it in your bootstrap file with |
In the meantime for those like me who uses
|
It's not working for me, the lib used is I received the error: Could not create token: Implicit conversion of keys from strings is deprecated. Please use InMemory or LocalFileReference classes I change my php.ini adding in the |
question is what are the content of your composer.lock for |
Hi @dcyou , thanks for reply, my content in the composer.lock is:
|
I think you don't run that command |
You are now, officially my best friend |
This works, make sure to run |
Any solution for branch 2.0? |
downgrade lcobucci/jwt to 3.3.3 |
Apart from downgrading, what's the longer term solution and does package author need help to implement? Do we need to update the package for compatibility ? |
Hi, i had the same issue and i tested this solutions and now it works fine !!! Thanks a lot for your help |
thanks, it's work! |
I changed this and it' work, But response throw 401 when call refresh token api |
That worked. I am using Laravel 8 👍 |
All Laravel versions override the server I really hope that gets merged and helps you all 👍 |
Just catching up on all this. Looks like an upgrade to v4 is necessary, so will work on that asap. Thanks all! |
@tymondesigns feel free to ping on PRs about this, would gladly help reviewing them 👍 Please check your PHP version requirements, v4 is PHP 7.4+ only. If need to support older PHP versions, you'd need to use |
Thanks, I think the best course of action is to restrict the version to <3.4 for now. I can address the v4 upgrade in the 2.0 branch, where php 7.4 is the minimum. |
Closing as release has been tagged to address this https://github.com/tymondesigns/jwt-auth/releases/tag/1.0.2 |
Thanks @tymondesigns ! |
This works for me as well. Thanks @tai-it 👏 |
Subject of the issue
"lcobucci/jwt": "3.4.0"
https://github.com/lcobucci/jwt/releases/tag/3.4.0
Your environment
The text was updated successfully, but these errors were encountered: