Drupal 11 Compatibility

Created on 16 June 2024, 10 months ago

Problem/Motivation

Drupal 11 Compatibility

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

๐Ÿ“Œ Task
Status

Active

Version

4.1

Component

Base system

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @naveenvalecha
  • Status changed to Needs review 10 months ago
  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia sarwan_verma

    Hi@naveenvalecha,

    I have fixed this issue "Drupal 11 compatibility fixes for devel_entity_updates" and also attached patch,
    please review and verify .

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    Patch from #3 does not apply anymore.

    Also I don't think watchdog_exception should be exchanged in drush8 command.
    It would basically make drush8 command useless. As new alternative is available only on from drupal >10.1. But not totally sure. Someone else should check it.

    Anyway, tested this patch on drush 13 and drupal 11, works like expected.

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96
  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    I guess I am not allowed to move my own patch to reviewed and tested. But got to say I have developed significant amount of custom entities and fields with no issues.

  • ๐Ÿ‡ง๐Ÿ‡ชBelgium flyke

    The patch applies, and I see no errors on my (Drupal 10.3.2) project.
    But thats all testing I could do, I'm trying to make every module in that project D11 compatible and I have a long way to go still.

  • Merge request !4D11 compatibility โ†’ (Open) created by flyke
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium flyke

    To use, add this in the repositories section of your projects composer.json file:

        "repositories": [
            {
                "type": "git",
                "url": "https://git.drupalcode.org/issue/devel_entity_updates-3454902.git"
            },

    Then include like this:
    composer require drupal/devel_entity_updates:"dev-3454902-d11 as 4.2.x-dev" -W

  • Status changed to Needs work 7 months ago
  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin
  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    recommendation in #9 is partly misleading. In most cases you should leave out the part "as 4.2.x-dev" as long as no other module depends on this project version and at the drupal core repo should be added "canonical:false" to prevent overriding on composer updates. Patch needs to be implemented in MR.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    dqd โ†’ changed the visibility of the branch 3454902-d11 to hidden.

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    I just assumed there is no way you can use Drush 8 commands in Drupal >10.1. But I guess my assumption was wrong...

  • Merge request !5Resolve #3454902 "Drupal 11 compatibility" โ†’ (Open) created by dqd
  • Pipeline finished with Success
    7 months ago
    Total: 136s
    #279591
  • Status changed to Needs review 7 months ago
  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    No worries, the file name is def. misleading but it is a common Drupalism that some things are named like this which indicates a file in the after Druapl 7 era.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    Add this

    "repositories": [
            {
                "type": "git",
                "url": "https://git.drupalcode.org/issue/devel_entity_updates-3454902.git"
            },
    

    to your composer.json under repositories and run

    composer require drupal/devel_entity_updates:dev-3454902-drupal-11-compatibility

    until this has been merged into an upcoming release or dev branch.

  • Pipeline finished with Success
    7 months ago
    Total: 128s
    #279729
  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    Btw I think target branch is wrong it should be 4.2.x.
    4.1.x will not be compatible with Drush 13, as mentioned in release.

    We can either fix both, or 4.2.x

  • Status changed to Needs work 7 months ago
  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96
  • naveenvalecha โ†’ changed the visibility of the branch 3454902-d11 to active.

  • naveenvalecha โ†’ changed the visibility of the branch 3454902-drupal-11-compatibility to hidden.

  • Pinged @plach over slack about the Drupal core compatibility across devel_entity_updates 4.2.x version.

    if 4.2.x is only for drush 13 then we need to bump core requirements to ^10.3
    Please advice.

  • ๐Ÿ‡ฎ๐Ÿ‡นItaly plach Venezia

    4.2.x targets all versions of Drush >= 11

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    I would go back to my original solution

    @naveenvalecha Only thing that is questionable for me is described in #4. But I guess file should be removed. Because minimum Drush version is 11 anyway.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    I find it very confusing that we now play hide and seek with the branches? Regarding the increasing MR numbers it would have been more useful to co-work/change and move forward on MR5 instead of hiding it again and making the prev branch visible again.

    I do not remember yet why I had to create another one previously (too many issues to be fixed atm on too many contrib projects), which I would avoid if ever possible. There was surely a reason for that, but apart from that, the common branch name for such issues is issueID-drupal-11-compatibility. Especially in case users added this to composer lately. Maybe I am missing something here ... in my night shifts.

    @holo96: what was your previous solution? You just changed the version requirement tags. Or am I missing something? And #4 has been answered in #11 which still holds up since this is documented on d.org. Or am I wrong?

    @holo96 at #17 you are absolutely right, but from what I saw the issue was already targeted to 4.2.x-dev. I am confused ...

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    Oh wait! Oh no - WTF ... now I see, I accidentally created the MR against 4.1.x ... sh* How does that happened!? *facepalm*

    I see now whats going on.

  • Pipeline finished with Success
    6 months ago
    Total: 138s
    #301897
  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    @naveenvalecha please let us keep working on latest MR in case anything else needs to be done. It already has a gitlab-ci file which I have added previously while working on it and has the common naming in sync with the issue.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    dqd โ†’ changed the visibility of the branch 3454902-d11 to hidden.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    dqd โ†’ changed the visibility of the branch 3454902-drupal-11-compatibility to active.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin
  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96
  • @naveenvalecha please let us keep working on latest MR in case anything else needs to be done.

    I toggled to the other PR because this issue is targeted for the 4.2.x and the Drupal 11 support will be catered in 4.2.x See my previous comment ๐Ÿ“Œ Drupal 11 compatibility fixes for devel_entity_updates Needs work . The good thing now you have changed the target branch of MR 5 is 4.2.x which bring issue to the right direction.
    Now there's no need to hide the other PR https://git.drupalcode.org/project/devel_entity_updates/-/merge_requests/4 you could close it.

    Good progress during holidays. Issue is RTBC

  • ๐Ÿ‡ฎ๐Ÿ‡นItaly plach Venezia
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly plach Venezia
  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    If we drop support for Drupal 9, which makes sense, we should probably drop support for Drush < 12 as well, see the Drush compatibility table. That is, we should drop drush/devel_entity_updates.drush8.inc entirely, rather than updating it.

    This is what I was trying to say.
    Maybe if we leave out changes in drush/devel_entity_updates.drush8.inc, you don't have to drop drupal 9 support at all.
    But if it has to be changed, it can only be removed.

  • ๐Ÿ‡ฎ๐Ÿ‡นItaly plach Venezia

    Sorry for the belated feedback :)

    We have plenty of versions supporting all sorts of combinations of legacy versions of Drush and Drupal. I think for Drupal 11 it makes sense to drop support for the older stuff.

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    Agreed.

  • ๐Ÿ‡ง๐Ÿ‡ชBelgium flyke

    shouldn't the 5.0.x branch support drupal/core ^11 also ? Currently I see this:

        "require": {
            "drupal/core": "^9.2 || ^10",
            "drush/drush": "^11 || ^12 || ^13"
        },
  • ๐Ÿ‡ฎ๐Ÿ‡นItaly plach Venezia

    That's what we are changing here, so far 5.0.x is just a copy of 4.2.x.

  • ๐Ÿ‡ง๐Ÿ‡ชBelgium flyke

    My bad, I'll patiently await a D11 compatible release. We still have lots of other contrib modules where we are waiting on a D11 release too, so updating our projects to D11 will not happen soon anyway. A big thank you for your ongoing work on this module.

  • ๐Ÿ‡ซ๐Ÿ‡ทFrance dqd London | N.Y.C | Paris | Hamburg | Berlin

    drop drush/devel_entity_updates.drush8.inc entirely...
    ... This is what I was trying to say.

    Gotcha. That's what I missed in the comment queue later on somehow. And why I previously "somewhat defended" the #3 new users @sarwan_verma attempt. Since the starting point was different for the user back then. And not wrong in that moment.

    Perhaps if we omit the changes in drush/devel_entity_updates.drush8.inc, we won't need to drop support for Drupal 9 at all.

    Rather tend to vote for removal then, like commented by all previously.

    I toggled to the other PR because... [...]

    I know why you did it ;) I just realized later that my MR accidentally has been targeted 4.1 (open tabs / Gitlab UI issue).

    Now there's no need to hide the other PR, you could close it.

    I know I could ;-) But it was not my fork/branch. Generally it is rather up to the original creator to close it, if wanted. But let me suggest to you: Keep in mind, there is a chance that users took that branch into their composer repos depending from where they came and when they joined the issue, so hiding is generally the better choice.

    Agreed with #35, #38. and the commits @ 7 October 2024 at 09:34 #, @plach +1

    #30 ๐Ÿ“Œ Drupal 11 compatibility fixes for devel_entity_updates Needs work : This RTBC was far too early.

    #39, @flyke: I fully feel with you :-) but for us as maintainers of multiple contrib projects it is hard to keep track with core releases sometimes. Lucky enough, this project does not require too much refactoring of deprecated code. But there are others which will take time and many night shifts. So all input and help in the issues is very much appreciated.

    Thanks at all in here helping to move on!

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    @dqd Will you apply suggested changes?

  • First commit to issue fork.
  • Pipeline finished with Canceled
    5 months ago
    Total: 131s
    #342317
  • Pipeline finished with Success
    5 months ago
    Total: 129s
    #342321
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium JeroenT ๐Ÿ‡ง๐Ÿ‡ช

    I made the changes suggested by the maintainer to the MR.

    @naveenvalecha, since you created the MR, can you edit the target branch to 5.0.x?

  • First commit to issue fork.
  • Pipeline finished with Success
    4 months ago
    Total: 131s
    #344188
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium JeroenT ๐Ÿ‡ง๐Ÿ‡ช

    I made a mistake in my previous comment. @dqd, you are the owner of the MR, can you edit the target branch to 5.0.x?

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    Maybe we should open another merge request, as there arenโ€™t many changes

  • ๐Ÿ‡ง๐Ÿ‡ชBelgium flyke

    I am now using drupal lenient to be able to use D10 modules that have a D11 compatible patch in aD11 project.

    Add the patch in your composer.json patches section.

                "drupal/devel_entity_updates": {
                    "#3454902 D11": "https://git.drupalcode.org/project/devel_entity_updates/-/merge_requests/5.diff"
                }

    If you don't have composer-drupal-lenient yet, add it to your project first:
    composer require mglaman/composer-drupal-lenient
    If your minimum stability is not set to dev yet, you need to do that first:
    composer config minimum-stability dev
    Add this module to the lenient allowed list:
    composer config --merge --json extra.drupal-lenient.allowed-list '["drupal/devel_entity_updates"]'
    Now you can add the latest dev with this patch to your project=
    composer require 'drupal/devel_entity_updates:5.0.x-dev@dev'

  • ๐Ÿ‡ท๐Ÿ‡ธSerbia holo96

    Yes, I use it too, but I would prefer if we resolve this issue :)

  • Status changed to RTBC 2 months ago
  • ๐Ÿ‡จ๐Ÿ‡ฆCanada geekygnr Waterloo

    Two people are already using this as a patch with lenient so I am going to say this is RTBC.

  • ๐Ÿ‡ง๐Ÿ‡ชBelgium JeroenT ๐Ÿ‡ง๐Ÿ‡ช

    I created a new branch, that has 5.0.x as target branch:

    https://git.drupalcode.org/project/devel_entity_updates/-/merge_requests/6

  • Pipeline finished with Success
    2 months ago
    Total: 140s
    #407057
Production build 0.71.5 2024