Page MenuHomePhabricator

Need a mechanism / process to purge invalid / stale entries from the Linter database
Open, MediumPublic

Description

T165070, T162920, and T163549 are all examples where the underlying linter data are invalid and should be removed from the database. Separately, T148609 saw a revert of Linter on large wikis. Any existing linter data for those wikis will likely be stale / invalid when the linter is re-enabled on those wikis.

So, we need some mechanism of isolating those entries and clearing them from the db. Maybe this is simply someone running a database query to delete relevant entries. The filter is different in each case. It is not clear what a good solution is. But, filing this task to brainstorm some solutions / strategies.

One obvious harmless query would be to purge all entries for titles where the revision id for the linter data is no longer the most recent id for the title.

Event Timeline

This came up again in https://www.mediawiki.org/wiki/Topic:Uabwjm0wagfw9l4c and @Legoktm said we can write a maintenance script for this.

ssastry lowered the priority of this task from High to Medium.

Not currently working on this.

Two tasks address some of these stale linter data issues:
Delete lint error records when content model changes from wikitext
https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Linter/+/761070
and
Delete lint errors when blank page saved... (the title of this ticket implies content model change also needed but only requirement is saving a blank page regardless of content model.
https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Linter/+/766872

Part of this should be resolved by T165538 - gerrit 761070 when content model changes.

Clearing the linter table of orphaned "stale" records needs a maintenance script to be implemented.

Does anyone deal with this? Has the bug been known for 7 years and will we have to wait another 7 or 77 years?

Can't the problem be corrected at least temporarily in the database? A month ago I reported the problem in T363682 and apparently it was "resolved", but the errors are still there.

Can't the problem be corrected at least temporarily in the database? A month ago I reported the problem in T363682 and apparently it was "resolved", but the errors are still there.

Sorry, see T363682#9846661