What is the problem?
When looking up information about System and Composite blocks via the API, it does not return blockanononly.
This means, for example, mobile messages always treat them as softblocks, even if they aren't (T259774#6411299).
Steps to reproduce problem
- Create an anonymous system or composite block, e.g.
- 2 anon. IP block ranges covering the same IP
- $wgSoftBlockRanges, if you have access to the wiki's config.
- On the blocked IP, visit /w/api.php?action=query&format=json&formatversion=2&prop=revisions|info&rvprop=content|timestamp&titles=Vnphyyblfr24&intestactions=edit&intestactionsdetail=full and look at the blockinfo array
Expected behavior: See blockanononly in the array
Observed behavior: Don't see blockanononly in the array
Environment
Wiki(s): https://en.wikipedia.beta.wmflabs.org MediaWiki 1.36.0-alpha (0e9937c) 07:48, 31 August 2020.
Proposed Solution
- Move DatabaseBlock::isHardblock() to AbstractBlock::isHardblock() and return a default value of false. (Deprecate/Remove the setter at the same time?)
- Update ComposeiteBlock to handle isHardblock()
- Update various SystemBlocks to correctly report their hardblock status (i.e. check proxy and tor blocks).