Page MenuHomePhabricator

Reference check should not suggest references in headings
Closed, ResolvedPublicBUG REPORT

Description

Steps to replicate the issue:

What happens?:

  • Some headings are annotated with "Add a citation"

What should have happened instead?:

  • Nothing. Headings don't get citations. They are meant to summarize the content within.

image.png (815×1 px, 187 KB)

Event Timeline

There's presumably a difference between the range created by getModifiedRanges for suggestion mode (which just grabs the ranges for all direct children of the document node) and the range created by adding a heading normally and then getting the range from the squashed transactions...

Change #1215170 had a related patch set uploaded (by Zoe; author: Zoe):

[mediawiki/extensions/VisualEditor@master] Filter out headings from AddReferenceEditCheck

https://gerrit.wikimedia.org/r/1215170

Change #1215170 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@master] Filter out headings from AddReferenceEditCheck

https://gerrit.wikimedia.org/r/1215170

zoe changed the task status from Open to In Progress.Dec 4 2025, 4:32 PM

⚠️ Creating a heading with pasted content triggers "Pasted Content" but Pasting content with heading doesn't

image.png (1×2 px, 317 KB)

@EAkinloose this change was to AddReferenceEditCheck and I can't see how it could have affected paste check behaviour – could we file this as a separate bug?

Also, that one is probably because the paste check requires a run of at least 50 characters to trigger, and each run of the annotation is evaluated separately for that.