Toolhub/Progress reports/2021-04-23

Report on activities in the Toolhub project for the week ending 2021-04-23.

API for filtering /api/auditlogs results edit

Tracked in Phabricator:
Task T280196

The /api/auditlogs/ endpoint that is used to view audit log events now supports the following filters:

  • ?action={0,1,2} - Action type to show. Can be used multiple times as OR'ing operations.
  • ?after=<ISO 8601 timestamp> - Only show actions after a date time
  • ?before=<ISO 8601 timestamp> - Only show actions before a date time
  • target_type=<string> - Only show actions of the given type. Can be used multiple times as OR'ing operations.
  • user=<username> - Only show actions made by the given user.

Out hope is that we can use these filters to enhance the existing /audit-logs UI to support filtering by these criteria. This will be used to implement a Special:Contributions like feature and a Special:RecentChanges like feature for patrolling.

Wrap up edit

Not a lot of visible progress was made this week. The auditlog filtering addition took longer than originally planned due to some difficulties working with the backend filtering library. Ultimately Bryan gave up on adding the filters the "right" way as the upstream filter code is not properly integrated with the separate but related upstream API code. The main learning from this was really a re-learning: timebox debugging 3rd party libraries or risk falling into the "I will just try one more time with this slightly different usage" tar pit.