Problem/Motivation

Hello project maintainers,

This is an automated issue to help make this module compatible with Drupal 11.

Changes will periodically be added to this issue that remove deprecated API uses. To stop further changes from being posted, change the status to anything other than Active, Needs review, Needs work or Reviewed and tested by the community. Alternatively, you can remove the "ProjectUpdateBotD11" tag from the issue to stop the bot from posting updates.

The changes will be posted by the Project Update Bot official user account. This account will not receive any issue credit contributions for itself or any company.

Proposed resolution

You have a few options for how to use this issue:

  1. Accept automated changes until this issue is closed

    If this issue is left open (status of Active, Needs review, Needs work or Reviewed and tested by the community) and the "ProjectUpdateBotD11" tag is left on this issue, new changes will be posted periodically if new deprecation fixes are needed.

    As the Drupal Rector project improves and is able to fix more deprecated API uses, the changes posted here will cover more of the deprecated API uses in the module.

    Patches and/or merge requests posted by others are ignored by the bot, and general human interactions in the issue do not stop the bot from posting updates, so feel free to use this issue to refine bot changes. The bot will still post new changes then if there is a change in the new generated patch compared to the changes that the bot posted last. Those changes are then up to humans to integrate.

  2. Leave open but stop new automated changes.

    If you want to use this issue as a starting point to remove deprecated API uses but then don't want new automated changes, remove the "ProjectUpdateBotD11" tag from the issue and use it like any other issue (the status does not matter then). If you want to receive automated changes again, add back the "ProjectUpdateBotD11" tag.

  3. Close it and don't use it

    If the maintainers of this project don't find this issue useful, they can close this issue (any status besides Active, Needs review, Needs work and Reviewed and tested by the community) and no more automated changes will be posted here.

    If the issue is reopened, then new automated changes will be posted.

    If you are using another issue(s) to work on Drupal 11 compatibility it would be very useful to other contributors to add those issues as "Related issues" when closing this issue.

Remaining tasks

Using the patches

  1. Apply the latest patch in the comments by Project Update Bot or human contributors that made it better.
  2. Thoroughly test the patch. These patches are automatically generated so they haven't been tested manually or automatically.
  3. Provide feedback about how the testing went. If you can improve the patch, post an updated patch here.

Using the merge request

  1. Review the merge request and test it.
  2. Thoroughly test the changes. These changes are automatically generated so they haven't been tested manually or automatically.
  3. Provide feedback about how the testing went. If you can improve the merge request, create a new branch and merge request and work from there.

Warning: The 'project-update-bot-only' branch will always be overwritten. Do not work in that branch!

Providing feedback

If there are problems with one of the changes posted by the Project Update Bot, such as it does not correctly replace a deprecation, you can file an issue in the Drupal Rector issue queue. For other issues with the bot, for instance if the issue summary created by the bot is unclear, use the Project analysis issue queue.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Project Update Bot created an issue. See original summary.

project update bot’s picture

Status: Active » Needs review
StatusFileSize
new809 bytes
new7.23 KB

This is an automated patch generated using Upgrade Status and Drupal Rector. Please see the issue summary for more details. A merge request (MR) is also openend and updated.

It is important that any automated tests available are run and that you manually test the changes.

Drupal 11 Compatibility

According to the Upgrade Status module, even with these changes, this module is not yet compatible with Drupal 11.

Currently Drupal Rector, version 0.20.1, cannot fix all Drupal 11 compatibility problems.

Therefore these changes did not update the info.yml file for Drupal 11 compatibility.

The compatibility issues that Upgrade Status found after the Drupal Rector fixes were applied are attached to help you resolve them manually.

Leaving this issue open, even after committing the current patch or merging the MR, will allow the Project Update Bot to post additional Drupal 11 compatibility fixes as they become available in Drupal Rector.

Debug information

Bot run #11-127659

These packages were used to generate the fixes:

  1. drupal/upgrade_status: 4.1.0
  2. mglaman/phpstan-drupal: 1.2.9
  3. palantirnet/drupal-rector: 0.20.1

john franklin’s picture

Issue summary: View changes

There is one patch from Project Update Bot to replace a call to file_save_data() that is already in the 3.x branch. The other items cited are deprecations against OpenID Connect itself. Near as I can tell, all that needs to be done to be Drupal 11 ready is to tag this module as such in the .info.yml file. (So far as we can tell at the Drupal 11.0-alpha1 point, anyway.)

project update bot’s picture

Version: 8.x-1.4 » 8.x-1.x-dev
Issue summary: View changes
StatusFileSize
new676 bytes
new1.68 KB
new9.71 KB

This is an automated patch generated using Upgrade Status and Drupal Rector. Please see the issue summary for more details. A merge request (MR) is also openend and updated.

It is important that any automated tests available are run and that you manually test the changes.

Drupal 11 Compatibility

According to the Upgrade Status module, even with these changes, this module is not yet compatible with Drupal 11.

Currently Drupal Rector, version 0.20.3, cannot fix all Drupal 11 compatibility problems.

Therefore, these changes did not update the info.yml file for Drupal 11 compatibility.

The compatibility issues that Upgrade Status found after the Drupal Rector fixes were applied are attached to help you resolve them manually.

Leaving this issue open, even after committing the current patch or merging the MR, will allow the Project Update Bot to post additional Drupal 11 compatibility fixes as they become available in Drupal Rector.

Debug information

Bot run #11-199781

These packages were used to generate the fixes:

  1. drupal/upgrade_status: 4.3.2
  2. mglaman/phpstan-drupal: 1.2.11
  3. palantirnet/drupal-rector: 0.20.3
solideogloria’s picture

Version: 8.x-1.x-dev » 3.x-dev
Issue summary: View changes

Target 3.x, as that's the branch that would support D11

acbramley made their first commit to this issue’s fork.

acbramley changed the visibility of the branch project-update-bot-only to hidden.

acbramley changed the visibility of the branch 3433705-automated-drupal-11 to hidden.

acbramley’s picture

Status: Needs review » Needs work

I've rolled updates against 3.x and attempted to fix all the phpunit deprecations. The following failures need to be investigated (I've tried but these are extremely complicated unit tests so I'm not sure if I've broken something or something has changed):

1. OpenIDConnectTest::testCompleteAuthorization - only the 4th test case is failing. This is because preAuthorize is set to FALSE which means none of the config gets mocked.
2. OpenIDConnectTest::testConnectCurrentUser - All test cases are failing here because for some reason the email is getting set twice. I tried to debug this but have no idea why this is happening.

acbramley’s picture

mstrelan’s picture

I did some debugging for OpenIDConnectTest::testCompleteAuthorization in Drupal 10.3.x with a breakpoint in \Drupal\openid_connect\OpenIDConnect::completeAuthorization. In the 3.x branch the $context variable is FALSE so we never try to access the config, so never get the fail, but in the branch for this MR the context is an array with the account object set. I'll dig a little deeper as to why that might be different.

mstrelan’s picture

Further debugging found that in \Drupal\openid_connect\OpenIDConnect::buildContext the invocation of openid_connect_pre_authorize yields different results between branches. In 3.x it returns an array but in this branch it returns NULL. So most likely one of the changes to withConsecutive has broken this test.

mstrelan’s picture

Status: Needs work » Needs review
benstallings’s picture

Status: Needs review » Reviewed & tested by the community

I can't vouch for all of the functionality, but I was able to enable the module in Drupal 11 without error.

jcnventura made their first commit to this issue’s fork.

  • jcnventura committed 772f39b1 on 3.x authored by acbramley
    Issue #3433705 by project update bot, mstrelan, acbramley, benstallings...
jcnventura’s picture

Status: Reviewed & tested by the community » Fixed
jmagunia’s picture

jmagunia’s picture

Status: Fixed » Needs work

mstrelan’s picture

@pmagunia probably best to open a separate issue for that. Left feedback regardless.

jcnventura’s picture

Let's keep this here, it makes no sense now to move this back to "Fixed".

jmagunia’s picture

Thanks @mstrelan.

I just corrected my previous commit.

jmagunia’s picture

Status: Needs work » Needs review

  • jcnventura committed 1c1f25f3 on 3.x authored by pmagunia
    Issue #3433705 by mstrelan, pmagunia, jcnventura: Add missing access...
jcnventura’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

moshe weitzman’s picture

Any chance we can roll a D11 compatible release?

mstrelan’s picture

This has been included in the 3.0.0-alpha4 release.