Page MenuHomePhabricator

Fix AutoModerator on testwiki
Closed, ResolvedPublic3 Estimated Story Points

Description

Right now, we're unable to test AutoModerator on testwiki due to an ORES job failing.
The error we're seeing can be found in logstash here.

Acceptance Criteria:

  • AutoModerator working on testwiki
  • Add Fallback to call LiftWing ourselves when ORES jobs fail

Event Timeline

Dillon set the point value for this task to 3.Nov 25 2025, 3:12 PM
Dillon moved this task from To be estimated to Estimated on the Moderator-Tools-Team board.

Upon closer inspection of the code, the issue is happening because the ORES hook is not firing at all therefore our code would never fire because the hook isn't firing.
I filed a bug with the ML team here: T411786: ORES is not working on testwiki.

We could rework the AutoModerator code to not rely on the ORES hook, though I'm not sure I recommend that.
It would be quite a large refactor that I'm not sure we'd like to spend the time on right now, so @Samwalton9-WMF let me know how you'd like me to proceed with that.

Upon closer inspection of the code, the issue is happening because the ORES hook is not firing at all therefore our code would never fire because the hook isn't firing.
I filed a bug with the ML team here: T411786: ORES is not working on testwiki.

We could rework the AutoModerator code to not rely on the ORES hook, though I'm not sure I recommend that.
It would be quite a large refactor that I'm not sure we'd like to spend the time on right now, so @Samwalton9-WMF let me know how you'd like me to proceed with that.

Thanks for uncovering this and filing the ticket!

Can you elaborate a bit on the situation & refactor proposal? I thought we were only using ORES if it was available, and otherwise using LiftWing directly?
In general though, I think I agree, we should expect ORES to work and if it doesn't ORES needs fixing, rather than refactoring for an edge case.

Upon closer inspection of the code, the issue is happening because the ORES hook is not firing at all therefore our code would never fire because the hook isn't firing.
I filed a bug with the ML team here: T411786: ORES is not working on testwiki.

We could rework the AutoModerator code to not rely on the ORES hook, though I'm not sure I recommend that.
It would be quite a large refactor that I'm not sure we'd like to spend the time on right now, so @Samwalton9-WMF let me know how you'd like me to proceed with that.

Thanks for uncovering this and filing the ticket!

Can you elaborate a bit on the situation & refactor proposal? I thought we were only using ORES if it was available, and otherwise using LiftWing directly?
In general though, I think I agree, we should expect ORES to work and if it doesn't ORES needs fixing, rather than refactoring for an edge case.

Of course, right now we're using the hook handler to tell us that we have an ORES score for a revision which then kicks off the process of checking the score against the threshold on AutoModerator's end. If the score is never saved via ORES then this hook will never fire and AutoModerator will do nothing because it's expecting to get scores via this hook.
One edge case you may be thinking of is the case where the score is saved via ORES but AutoMod fails to fetch- then we go to LiftWing.

We are currently only using ORES hook if available, and on testwiki it's available so we're attempting to use it, but it's broken.
We're not handling this particular edge case of when ORES is installed and it's not saving any scores, which I think is ok because it's not a case that should happen.
The refactor that we could do is to remove the ORESRecentChangeScoreSavedHookHandler completely and do all the score fetching after RevisionFromEditCompleteHookHandler is fired.
This would allow us to decouple ourselves from the ORES scores being saved entirely, but again this would be a pretty large refactor.

Got it, yeah I think I agree we don't need to handle this case in Automoderator - if ORES is installed we should be able to expect saved scores.

Kgraessle changed the task status from Open to Stalled.Dec 5 2025, 2:10 PM

Stalling pending engineering weekly discussion around potential workarounds.

Automoderator is now working again: https://test.wikipedia.org/wiki/Special:Contributions/AutoModeratorTest

Add Fallback to call LiftWing ourselves when ORES jobs fail

@Kgraessle Could you file a followup task about this element of the task description?

Scardenasmolinar subscribed.

Since AutoModerator is already working on test wiki, we will close this ticket.