Description
Details
Project | Branch | Lines +/- | Subject | |
---|---|---|---|---|
mediawiki/extensions/ORES | master | +4 -0 | Not including results when oresm_is_current = 0 |
Related Objects
Event Timeline
I was able to reproduce it, I'm getting a sense why it's happening but I'm not sure how I can fix it.
Change 307870 had a related patch set uploaded (by Ladsgroup):
Not including results when oresm_is_current = 0
Okay,
Imagine we had this in ores_model
oresm_id | oresm_name | oresm_version | oresm_is_current |
1 | damaging | 0.0.1 | 0 |
2 | damaging | 0.0.2 | 1 |
and we have two scores for each model for every revision:
oresc_id | oresc_rev | oresc_model | oresc_score | ... |
12345 | 15 | 1 | 0.06 | ... |
12346 | 15 | 2 | 0.8 | ... |
In this case we would have two rows in user contribs or changes list query because we do LEFT JOIN on ores_model (using other types will lead to omitting cases when we don't have score which not desirable).
So I solved it by explicitly adding a where condition that oresm_is_current != 0.
It will all cases except when the oresc_model id doesn't exist in ores_model (which can happen due to T144195: Check model version replaces every time it runs.) but hopefully we won't see it again since the patch got merged.