Closed (fixed)
Project:
Drupal core
Version:
11.x-dev
Component:
base system
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
31 Oct 2024 at 12:54 UTC
Updated:
29 Apr 2025 at 09:59 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
mondrakeComment #4
mondrakeComment #5
mondrakeAfter some headache, now found the right regex to have sed adjust the paths of the generated baseline so it can be really just copy/pasted to the branch with no additional edit.
Comment #6
bbralaI actually ran into this issue earlier today by chance (the paths not being correct).
This looks good and will make some things easier, but also allow for a good interface in gitlab for changes as per #3499245: [CI] Report PHPStan baseline statistics in job.
All good, working as intended :)
Comment #7
needs-review-queue-bot commentedThe Needs Review Queue Bot tested this issue. It fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".
This does not mean that the patch necessarily needs to be re-rolled or the MR rebased. Read the Issue Summary, the issue tags and the latest discussion here to determine what needs to be done.
Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.
Comment #8
mondrakePlease, bot, don't boycott.
Comment #9
mondrakeComment #10
bbralaAs per Alex, we need a comment there, i understand it feels fragile, unfortunately a result of how things are run.
Comment #11
mondrakeComment #12
smustgrave commentedActually just reviewed a ticket that could of used this so perfect timing!
Believe feedback for a comment has been added so going to mark it.
Comment #13
longwaveI tried to commit this but it's breaking the pre-commit script:
I think because line 406 has the PHP open tag:
then PHPStan tries to interpret the YAML as PHP and it all goes wrong. Either we need to tell PHPStan to ignore this file, or remove the open tag, or break it up into two parts so PHPStan can't see it?
Comment #14
mondrakeWhy on earth is that script trying to have PHPStan scan
.gitlab-ci.yml?Is
core/scripts/dev/commit-code-check.shthe culprit? If it is, then it's probably because if PHPStan is passed a list of file paths, it's skipping the file discovery based on its configuration and just scan them all. So that script need change to only pass files with php/module/inc/etc. extensions.Comment #15
mondrakeOK, let's revert to prior https://git.drupalcode.org/project/drupal/-/merge_requests/10903/diffs?c... and see if that could fit.
Comment #16
mondrakeComment #17
smustgrave commentedWith all the recent rebasing people have to do around the baseline it would be nice to get this one in please :)
Comment #20
longwaveThis is kinda messy, but I tried some alternatives that didn't work or were more messy, so I think this will have to do.
I am not sure we need all those
$CI_PROJECT_DIRs as we are inconsistent there too, but let's just get this in and solve that elsewhere as we will surely make more changes here in the near future.Committed 655596f and pushed to 11.x. Thanks!