Closed Bug 1979117 Opened 3 months ago Closed 2 months ago

Introduce the conccept of "rollouts" to our custom Stylelint plugin

Categories

(Developer Infrastructure :: Lint and Formatting, task)

Tracking

(firefox144 fixed)

RESOLVED FIXED
144 Branch
Tracking Status
firefox144 --- fixed

People

(Reporter: hjones, Assigned: jooliver)

References

(Blocks 1 open bug)

Details

(Whiteboard: [recomp][acorntractors])

Attachments

(1 file)

In order to get our custom design tokens rules enabled without needing to fix all of the existing violations we should introduce the concept of "rollouts," which we've already implemented for our custom eslint plugin. Because Stylelint is configured differently the rollouts implementation will likely be even simpler. It will likely take the form of just disabling the rule for any files (or maybe folders?) with preexisting violations. There's another POC commit for what this looks like here. I used the following script to generate the list of invalid filenames (you'll need to replace /Users/hjones/Projects/firefox/ with your path to the project):

./mach lint -l stylelint \
  | grep "error" -B 1 \
  | awk 'NR==1 || /^\/.*\.css$/ {print}' \
  | sort -u \
  | sed 's|/Users/hjones/Projects/firefox/||'

Having rollouts in place should enable us to turn on new rules and start enforcing them for any new code that gets added and in any files that don't already have violations. We will likely need to do this work alongside whatever custom design tokens Stylelint rule we implement first.

Blocks: 1979115
Assignee: nobody → jooliver
Status: NEW → ASSIGNED

Adds a configuration file to support temporarily disabling new stylelint rules for existing files.

Pushed by mkennedy@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/7aa43f07a052 https://hg.mozilla.org/integration/autoland/rev/d17d285e23db add rollout config for stylelint rules r=reusable-components-reviewer-rotation,Standard8,hjones

Backed out for causing linting failures.

Flags: needinfo?(jooliver)
Status: ASSIGNED → RESOLVED
Closed: 2 months ago
Resolution: --- → FIXED
Target Milestone: --- → 144 Branch
Blocks: 1983938
Pushed by mkennedy@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/b33fbd34c004 https://hg.mozilla.org/integration/autoland/rev/c4e65b78b3c9 add rollout config for stylelint rules r=reusable-components-reviewer-rotation,Standard8,hjones
Flags: needinfo?(jooliver)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: