- Merge request !535Issue #2924782: Missing @var annotation for arrays that provide default values โ (Closed) created by spokje
- Merge request !3689Issue #2924782: Fix remaining VariableComment.MissingVar annotation โ (Open) created by quietone
- ๐ณ๐ฟNew Zealand quietone
Implementing sniffs are not bugs, they are tasks.
The failing test is not related to these changes, I am retesting.
- Status changed to Needs review
5 months ago 8:28am 11 August 2024 - ๐ณ๐ฟNew Zealand quietone
Changing the scope to make the change set smaller and easier to review.
- Status changed to RTBC
5 months ago 6:12pm 11 August 2024 - ๐บ๐ธUnited States smustgrave
Reviewed the updates and changes appear correct.
- Status changed to Needs work
5 months ago 5:23pm 22 August 2024 - ๐ณ๐ฟNew Zealand quietone
quietone โ changed the visibility of the branch 2924782-missing-var-annotation to hidden.
- Status changed to Needs review
5 months ago 1:17am 23 August 2024 - Status changed to RTBC
5 months ago 12:06pm 23 August 2024 - ๐ณ๐ฟNew Zealand quietone
Rebased and changed the instance in \Drupal\FunctionalTests\Update\UpdatePathTestBase to an {@inheritdoc}.
- First commit to issue fork.
- ๐ฌ๐งUnited Kingdom longwave UK
MR has a merge conflict and a question about the change to phpcs.xml.dist.
Also, the release note snippet in the IS seems wrong, as we are enabling that in the parent issue - not here.
- ๐ณ๐ฟNew Zealand quietone
Rebased and had to fix mistakes so setting to NR.
- ๐ฌ๐งUnited Kingdom alexpott ๐ช๐บ๐
I think we should be changing phpcs.xml to enable the rule no? Also I think removing the @var when there is a default value is really odd.
- ๐ณ๐ฟNew Zealand quietone
@alexpott, thanks for the review.
Unfortunately, the scoping on this is unusual and the sniff can't be modified to cover this set of changes. However, I did enable the sniff for some file patterns. In the parent issue the remaining 50 errors in 32 files can be fixed and the sniff enable for all files.
- Status changed to Needs work
2 months ago 10:27am 8 November 2024 The Needs Review Queue Bot โ tested this issue. It no longer applies to Drupal core. 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.
- ๐ฌ๐งUnited Kingdom alexpott ๐ช๐บ๐
This change confuses me because it's removing @var from stuff... also if I only apply the changes to the phpcs.xml.dist and run PHPCS the other error that's found is:
> phpcs --standard=core/phpcs.xml.dist --parallel="$( (nproc || sysctl -n hw.logicalcpu || echo 4) 2>/dev/null)" -- 'core' FILE: /Volumes/dev/drupal/core/modules/block/tests/src/Kernel/NewDefaultThemeBlocksTest.php ------------------------------------------------------------------------------------------- FOUND 1 ERROR AFFECTING 1 LINE ------------------------------------------------------------------------------------------- 37 | ERROR | Missing @var tag in member variable comment ------------------------------------------------------------------------------------------- Time: 26.72 secs; Memory: 12MB
So the rule changes are not covering the changes being made here.
- ๐ณ๐ฟNew Zealand quietone
The 'Overview' in the MR does not reflect the actual changes and it quite confusing. There were also truly unexpected errors on my part that I can't quite figure out how they happened. So, I started over and it turns out that this can now enable the sniff as well.
So, I am closing the parent as a duplicate, changing the title and moving credit.
- ๐ณ๐ฑNetherlands daffie
All the documentation changes look good to me.
The remark of @alexpott has been addressed.
For me it is RTBC. - ๐ฆ๐บAustralia larowlan ๐ฆ๐บ๐.au GMT+10
Couple of minor issues in the MR, also needs a reroll
Thanks for working on this.
- ๐ฎ๐ณIndia kulpratap2002
kul.pratap โ made their first commit to this issueโs fork.
- ๐ณ๐ฟNew Zealand quietone
@kul.pratap, Welcome to Drupal! Thanks for working on this. I made a few comments in the MR. Also, This is failing the pre commit checks. It is good practice to Run core development checks โ locally before submitting a change.
There have been recent commits that are causing more errors. I don't think the sniff can be enabled here. This will have to go back to doing a subset of files. I'll look into that now.
- ๐ฎ๐ณIndia kulpratap2002
@quietone Thank you for the feedback. I will review the comments in the MR and address them.
- ๐ณ๐ฟNew Zealand quietone
@kul.pratap, thanks. I just added another change to exclude files in 'Plugin' directories. That should help here.
Updating title for the new scope.
I'll work on an issue for the changes in the 'Plugin' directories.
- ๐ฎ๐ณIndia kulpratap2002
@quieton Should I resolve the unresolved issues in the MR as mentioned by you?
- ๐ณ๐ฟNew Zealand quietone
@kul.pratap, Thanks for asking! The suggested changes to phpcs.xml.dist should exclude the files that have just started to cause violations from being checked by phpcs. Without those being checked that will bet this back on track to where only the feedback from larowlan and myself need to be resolved.
The files that have just started to cause the violations are going to be fixed in the parent issue, along with enabling the sniff on all of core. I've already set that up and postponed that on this issue.
I hope that all make sense.
- ๐บ๐ธUnited States smustgrave
Pipeline has errors. Would recommend verifying that everything passes before putting into review please.
- ๐ณ๐ฟNew Zealand quietone
@kul.pratap, thanks for reverting those changes.
I was concerned that the number of files to change would make the MR here larger that our recommended size. So, I've updated phpcs.xml.dist to ignore Plugin files, which agrees with the title here. There are still about 25 files to edit.