Problem/Motivation

Adding both core and core_version_requirement with anything other than core_version_requirement: ^8 || ^9 || ^10 will result in an exception. This is not valid because the core: key would include versions that do not recognize the core_version_requirement: key.

Steps to reproduce

For example, a theme that is compatible with Drupal 8 versions after Drupal 8.8.0 and also Drupal 9 will need an info.yml file like this:

name: My Module
type: module
core_version_requirement: ^8 || ^9 || ^10

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

Harshita mehna created an issue. See original summary.

harshita mehna’s picture

Status: Active » Needs review
StatusFileSize
new371 bytes

Hello Maintainers,
I have provided a patch to fix this issue.
To get more information visit https://www.drupal.org/node/3070687
Please review it.

Thanks!

priya_degwekar’s picture

StatusFileSize
new86.84 KB

Verified and tested the #4 patch on 2.0.x , core key is removed cleanly. Added screenshot for reference.

Can be moved to RTBC+1.

priya_degwekar’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new74.34 KB
new75.37 KB
avpaderno’s picture

Title: [Drupal 10] Do not allow core: 8.x in info.yml file. » Remove "core: 8.x" from the .info.yml file
Category: Bug report » Task
Priority: Normal » Minor
Status: Reviewed & tested by the community » Needs work
configure: block_class.settings
-core: 8.x
 core_version_requirement: ^8 || ^9 || ^10

^8 must be replaced with ^8.8.

avpaderno’s picture

As a side note, it is not helpful to show a screenshot as a prove the patch applies. The patch could apply, but the changes be wrong.
Also a screenshot that shows how the changed files become is not helpful and it is not a reason for changing the status to Reviewed & tested by the community. In fact, the changes done from the patch are wrong and the correct status should be Needs work.

harshita mehna’s picture

Status: Needs work » Needs review
StatusFileSize
new416 bytes

@apaderno, I have updated the patch update-3370129.patch please review.

avpaderno’s picture

Status: Needs review » Reviewed & tested by the community

The last patch is correct.

renatog’s picture

Status: Reviewed & tested by the community » Needs work
Issue tags: +Novice, +Needs merge request

could someone create a MR based on #12, please?

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

bharath-kondeti made their first commit to this issue’s fork.

sakthi_dev’s picture

Status: Needs work » Needs review

Updated composer as well. Please review.

renatog’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -Novice, -Needs merge request

Thank you so much everyone

renatog’s picture

Status: Reviewed & tested by the community » Fixed

thanks everyone

Status: Fixed » Closed (fixed)

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