Page MenuHomePhabricator

Read user agent strings from the cu_useragent table in Special:Investigate
Closed, ResolvedPublic

Description

Special:Investigate needs to be updated to read the user agent string from the cu_useragent table using the agent_id columns in each result table to find the associated rows.

This could be done by joining the cu_useragent table to each query to the result tables (cu_changes, cu_log_event, and cu_private_event) or performing a separate query to lookup the user agent strings after the results have been selected.

Doing the latter may be more a better solution, as it should avoid making the query yet more complicated by avoiding the need to add a join. However, the former would likely involve less code changes (as the cuua_text column could be aliased as cuc_agent, cule_agent, or cupe_agent).

Acceptance criteria
  • Code that currently reads from the agent column in Special:Investigate will read the user agent string from the cu_useragent table if the schema migration config is set to SCHEMA_COMPAT_READ_NEW.
  • If the schema migration is set to SCHEMA_COMPAT_READ_OLD, the code should continue to get the user agent string from the agent column (for example, cuc_agent)

Related Objects

StatusSubtypeAssignedTask
Resolved TBolliger
OpenNone
OpenNone
OpenNone
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedDreamy_Jazz
ResolvedMarostegui
DeclinedNone
ResolvedPapaul
Resolvedtaavi
ResolvedMarostegui
ResolvedSnwachukwu

Event Timeline

Change #1223720 had a related patch set uploaded (by Dreamy Jazz; author: Dreamy Jazz):

[mediawiki/extensions/CheckUser@master] [WIP] Add user agent table read new support for Special:Investigate

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

Change #1223720 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] Add user agent table read new support for Special:Investigate

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