Adding both core and core_version_requirement with anything other than core_version_requirement: ^8 || ^9 will result in an exception.
For example, a module/theme that is compatible with Drupal 8 versions after Drupal 8.8.0 and also Drupal 9 will need to use the following line in its .info.yml file.
core_version_requirement: ^8.8 || ^9
In the rare occasions the module/theme is also compatible with Drupal 10, its .info.yml file should use the following line.
core_version_requirement: ^8.8 || ^9 || ^10
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | 3375430_5.patch | 417 bytes | rohitsharma401 |
Issue fork views_any_route-3375430
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
Comment #2
harshita mehna commentedHello Maintainers,
I have provided a patch or an MR !3 to fix this issue.
Please review it.
Thanks!
Comment #4
avpadernoSince
coreis removed,core_version_requirementneeds to be changed tocore_version_requirement: ^8.8 || ^9 || ^10. Earlier Drupal 8 releases do not recognizecore_version_requirement; the module is not installable on those releases, if it uses justcore_version_requirement.Comment #5
rohitsharma401 commentedComment #6
avpadernoThe MR contains changes that are not related to this issue.
The patch is not correct.
Since
core_version_requirementis changed,coremust be removed.Comment #7
avpadernoComment #8
harshita mehna commented@apaderno, The core key is removed now please check the commit 239ce263.
Putting the issue in needs review again please review.
Comment #9
avpadernoThis is a change only maintainers can decide to do.
It has been introduced the compatibility with Drupal 10, but I doubt maintainers want to keep the code compatible with three different Drupal versions.
Also, nothing is wrong in using
core: 8xtogethercore_version_requirement: ^8 || ^9. Drupal core allows it and it is also shown in New 'core_version_requirement' key in info.yml files for modules, themes and profiles allows Composer semantic version constraints including specifying multiple major versions of core, which states:Comment #12
laboratory.mikeI'm starting to do some updates for VAR, and went ahead and included the existing commits and move to support D9/D10 in the 2.0.x version. Thanks all for the feedback and working through this.