Background
We are unable to reliably ship features in the mobile site to only logged out users. We should fix that!
From T388036 - we were surprised to see that setting a configuration of
'wgMinervaDonateBanner' => [ 'default' => [ 'base' => true, 'loggedin' => false, 'amc' => false, ], ],
did not correctly disable the feature for logged in users as we had expected. There is further discussion in that ticket (in particular https://phabricator.wikimedia.org/T388036#10608151), but the summary is that base is itself a conditional which is true for all non-beta users, which means this configuration is targeting all non-beta users (functionally all users now), and the loggedin => false section is ignored
Additional note: It does work when $wgEnableBeta is set to true o_o
User story
As a member of the web team, I want to be able to target anonymous users specifically using our feature management system
Requirements
- there is a mechanism by which we can target logged out users using our feature management system
Acceptance criteria
- we are satisfied that future releases can be deployed to logged out users only via the feature management system
- For the purpose of this task, provide an explict logged_out and logged_in key that replace base and loggedin. Logic for beta can be left alone for the purpose of this task. loggedin and base remain as aliases for logged_in and logged_out.
- Confirm feature flag configuration supports explicitly logged out users.
- Confirm logged-in users do not receive features targeted only to logged users.
- Verify logged-out users receive features targeted to them, regardless of $wgEnableBeta state.
- Tests are in place to verify correct behavior and prevent regressions for logged out users
- Documentation includes examples and notes on targeting logged out users.
Rollback plan
Depends on implementation, which hasn't yet been nailed down - presumably if we are changing the inner workings of the system rather than adding a logged out user mode we will have a revert plan incase it has unintended effects on the existing features