Page MenuHomePhabricator

Fix issue line highlighting in the linter
Closed, ResolvedPublic1 Estimated Story PointsBUG REPORT

Description

The linter highlights incorrect lines related to a given issue in the linted OAD. All lines seem to be offset by 1.

Steps to reproduce

  1. Lint the current version of the OAD example.
  2. Sort the list of issues by severity.
  3. Note the line numbers in the Lines column and check whether they correspond to the correct lines in the linted OAD.

Example 1

In the line with Code: wikimedia-response-schema-properties-description, the Lines column contains "428-436" but should contain "429-437". The corresponding highlight in the Linter Results box is also offset by 1.

Example 2

In the line with Code: oas3-valid-media-example, the Lines column contains "638-638" but should contain "639-639", or (even better) "639". The corresponding highlight in the Linter Results box is also offset by 1.

Example 3

In the line with Code: wikimedia-paths-parameter-example-exists (last warning on the sorted list), the Lines column contains "609-623" but should contain "610-624". The corresponding highlight in the Linter Results box is also offset by 1.

Event Timeline

KineticPelagic subscribed.

As part of my Clinic Duty rotation, I am moving this task to the "To Estimate" column of our MWI workboard and assigning "Medium" priority because:

  • An internal MediaWiki team member identified the issue.
  • The detail makes the task ready for estimation and for a team member to begin work.
  • Highlighting incorrect lines can be a bit confusing or irritating to developers.
  • I have observed this issue myself in production when working with the linter.
HCoplin-WMF set the point value for this task to 1.May 14 2026, 3:33 PM