Closed (fixed)
Project:
Drupal core
Version:
9.4.x-dev
Component:
javascript
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
27 Oct 2021 at 14:16 UTC
Updated:
2 Mar 2022 at 01:39 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #3
longwaveNW to deal with the many new rules.
Comment #4
longwaveI either disabled or reconfigured the failing rules so stylelint should now pass, but it's probably worth discussing if we want to fix some of these instead of disabling them.
Comment #5
longwaveFixed two hopefully uncontroversial rules.
Comment #7
alexpottI think we can do that in follow-ups.
Comment #8
longwaveRerolled for 9.4.x and 10.0.x and bumped to latest versions of stylelint and related packages.
Comment #9
alexpottThese look great. Thanks @longwave
Comment #10
lauriiiAre the
commit-code-check.shchanges working? I tried checking the DrupalCI output and it looks like only files that were changed by the patch were actually tested.Comment #11
longwaveYes:
The first "stylelint: passed" is a full run, this is newly added by these patches.
The individual lines later on are a run against each changed file in turn. I guess we should drop the individual runs if we are doing a full run anyway?
Comment #12
alexpottLet's open a follow-up to discuss how to stop individual checks when a general scan all the things has occurred. We have this for JS and PHPCS too so a generic solution might be better.
Comment #13
lauriiiAhh makes sense. Could someone file follow-up for #12?
Comment #14
alexpottCreated #3260373: Only scan individual files for PHPCS / eslint / Stylelint if necessary
Comment #17
lauriiiCommitted f1a00d1 and pushed to 10.0.x. Also committed the 9.x patch to 9.4.x. Thanks!
I think we should backport this to 9.3.x too to make backporting patches easier. Any thoughts on that?
Comment #18
longwave9.4.x patch applies straight to 9.3.x, so I guess we might as well as it's only a core development dependency. But also it's not that important because as far as I can see any patch that passes Stylelint 14 should also pass in the earlier version.
Comment #20
lauriiiDiscussed with @longwave and @catch and we didn't see that there would be problem cherry-picking to 9.3.x since Stylelint is a dev dependency. There are couple of CSS changes so I think it's better to have the active branches as consistent as possible so that backports remain straight forward.
Comment #21
xjmHEAD has been failing on 9.3.x and 9.4.x with PHP 7.3 since Jan. 26.
This is the only issue that was committed to 9.3.x between Dec. 29 and yesterday, so it seems like the only possible cause unless there was an upstream change on CI that is causing the fail.Edit: That was a git log weirdness, from a commit being cherry-picked much later.
https://www.drupal.org/pift-ci-job/2305316
So, here's a revert to test whether HEAD will pass.
Additionally, this issue should not have been backported to 9.3.x under our allowed changes policy, because even dev dependency updates disrupt build pipelines. Especially since it's a major version update. Normally we would only do such an update in the production branch if there were a security issue. So regardless of whether this is the cause of the HEAD fail, it should probably be reverted from 9.3.x and not re-committed there.
Comment #22
xjmThe CI output for #21 does not make any sense -- it says that custom commands failed, but then all the checks individually are listed as passing. Running
sh ./core/scripts/dev/commit-code-check.shlocally also passes.Comment #23
xjmOnly other thing I can think of is to revert both commits that have been made on 9.3.x in January, in case there's some Stylelint 14-compatible changes in the more recent CKE5 commit that are somehow not being reported correctly on CI.
If this also fails with weirdness then I might just revert both commits and see what happens. Since HEAD is failing anyways it can't get worse. We can always recommit them.
Comment #26
xjmOK, the "Custom commands failed" also failed in HEAD with this reverted (even with the issue after it reverted too), so I recommitted both of them. Reading over the console output, this is the only actual error message:
I don't know why that is happening with #21 and #23 both when they are the two most recent commits on the branch and it didn't happen until I reverted them, but we need to figure out how to fix it so that this can be reverted from 9.3.x per the second paragraph of #21.
(Meanwhile, I found the actual probable source of the PHP 7.3 regressions in #3172166: Element::properties() produces notices if given an array with integer keys -- just missed it in the git log because of weird commit date ordering from cherry-picks being out of order vs. 9.4.x. Sorry for the noise about that part, but we still do need to make this 9.4.x only.) :)
Comment #27
lauriiiWe need to keep the
--allow-empty-inputargument in the stylelint command for the stylelint command to pass when CSS files copied from Classy are being changed in Claro and Olivero.Comment #28
longwaveShould we keep the .css changes for consistency and only revert .stylelintrc.json and yarn.lock? Even the commit script changes are an improvement that can stay in 9.3.x?
Comment #29
xjm@longwave Can you file a followup for that? I just want to get this reverted now so that we're not committing to it with no way to back out in a patch release today.
Comment #30
longwaveOK!
Opened #3262025: Backport Stylelint 14 related changes to 9.3.x
Comment #31
xjmAlright, committed the revert patch to 9.3.x after comparing it with a local revert. Thanks @longwave!
In the future, it might be better to split an issue like this into those sorts of separate scopes to begin with.
Finally, all dependency updates should be tagged for the release notes, especially if it's outside the normal expectations of what would get a dependency update in a given release. So even if we agreed the whole enchilada should go in 9.3.3, the issue should have had both the "9.4.0 release notes and "9.3.3 release notes") issue tags. Thanks!
Comment #32
xjmRestoring original title and 9.4.x branch now that the revert's in.
Comment #34
xjmDependency update should also always be in the release notes. It sounds like this might want a CR too, for the improvements to linting etc.?
Comment #35
longwaveWrote a CR, updated release note snippet in IS.
Comment #36
xjmThanks @longwave!
This is also a change from 10.0.0-alpha1, so adding it to the alpha2 release notes list.
Comment #37
xjm