Problem/Motivation
drupal-check report against 8.x-4.x at commit 2a4b0e4f640219bb7d0bb6622fa502e842fe5516
$ drupal-check .
79/79 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓] 100%
------ --------------------------------------------------------------------------
Line src/Entities/AccessTokenEntity.php
------ --------------------------------------------------------------------------
30 Call to deprecated method set() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setAudience() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setExpiration() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setId() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setIssuedAt() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setNotBefore() of class Lcobucci\JWT\Builder:
This method will be removed on v4
30 Call to deprecated method setSubject() of class Lcobucci\JWT\Builder:
This method will be removed on v4
40 Call to deprecated method set() of class Lcobucci\JWT\Builder:
This method will be removed on v4
44 Call to deprecated method sign() of class Lcobucci\JWT\Builder:
This method will be removed on v4
------ --------------------------------------------------------------------------
[ERROR] Found 9 errorsProposed resolution
Fix the deprecation notice so drupal-check comes back green
Remaining tasks
Create a patch.
User interface changes
None.
API changes
None.
Data model changes
None.
Release notes snippet
None.
| Comment | File | Size | Author |
|---|---|---|---|
| #7 | 3088546-7.patch | 6.65 KB | phenaproxima |
| #4 | deprecated_code-3088546-4.patch | 1.11 KB | katherined |
Comments
Comment #2
sephster commentedThe deprecated functions have been patched in the OAuth2-Server. I expect to release this in the next minor version which should be in a couple of weeks tops. Hope this helps!
Comment #3
kristen polPer a Slack discussion with Gábor Hojtsy regarding usage of D9 tags (Drupal 9, Drupal 9 compatibility, Drupal 9 readiness, etc.), "Drupal 9 compatibility" should be used for contributed projects that need updating and "Drupal 9" was the old tag for D8 issues before the D9 branch was ready. Doing tag cleanup here based on that discussion.
Comment #4
katherinedThis should fix the following:
Comment #5
berdirThat does require PHP 7, so the module either needs to require Drupal 8.8 or php7 (might be the easier option to get it committed now?
I also get this one with latest drupal-check:
Also needs the core_version_requirement key in all modules.
Comment #6
berdirAnd, running the tests gives me these:
The getCurrentUserId is fun, apparently this module copied over the owner definition from user and uses its default value callback. Not sure if this is a case for EntityOwnerInterface/EntityOwnerTrait, that would also require an update function. We could start with just using the trait for the default value callback?
Comment #7
phenaproximaThis should fix all remaining deprecations, including the runtime test ones.
Comment #9
phenaproximaThe test failure was a pre-existing random failure; see https://www.drupal.org/pift-ci-job/1561409. I was able to confirm this locally by running the test 30 times; it passed 29 of those times, and failed once with that same "undefined index" notice.
I think it's pretty clear that the problem is not being introduced by this patch, so back to "needs review" we go.
Comment #10
e0ipsoThanks for the patch! I did not see anything concerning, only good stuff.
Comment #12
e0ipso