We currently hook into MediaWiki to detect changes in visibility attributes for a revision, including whether the author's name should be visible. However, RESTBase is unaware of when a user is blocked/suppressed across the entire wiki, and continues to make this information available.
This issue has a lot of moving pieces, so I'm going to start laying them out, and creating subtasks as necessary:
== Define events ==
[[https://github.com/wikimedia/mediawiki-event-schemas/|Event schemas]] needs to be defined, and added to the event service topic config.
There are a couple of possible approaches here, we could a) define general purpose block/unblock events (with attributes to cover account creation, sending email, editing talk pages, etc), or b) limit the scope of the events to simple suppression/un-suppression of author information. The former seems like the Right Thing to do, but is a bit more complicated as it requires dealing with block list entries that should expire after some duration (whereas block list entries that suppress the username are required to be indefinite).
== Produce events ==
MediaWiki needs to produce the above event(s), (via the EventBus extension for the time being).
The [[https://www.mediawiki.org/wiki/Manual:Hooks/BlockIpComplete|BlockIpComplete]] hook should be adequate for propagating new block list entries (and edits), but a new hook will need to be added to cover administrative un-blocks (//UnblockIpComplete//, for example).
== Consume events, persist a suppression set ==
As events are produced, a consumer will be needed to update a set of hidden users. Lookups against this set must be fast (they will be in-lined with every request that exposes author information).
See: https://en.wikipedia.org/wiki/Bloom_filter
== Suppress user information ==
#RESTBase will need to be updated to utilize the suppression set, and filter out user information accordingly.