Page MenuHomePhabricator

Only allow specific country selection on Wiki Loves campaigns
Closed, ResolvedPublic

Description

We need to force the user to select an option from the country dropdown on a Wiki Loves campaign.
While the country options are loading, the dropdown will show "loading..." text and the "Get started" button will be disabled.
Once the options load, the first option is selected by default.

If the unknown country" category has been found in any of the selected campaign categories, this will be the first option (and selected by default).

The previous "all countries" option will be removed.

Reason for change

We need to ensure a country is known for all contributions to Wiki Loves campaigns.
The "all countries" option we had previously did not record any country data, so country stats were completely misleading.

Event Timeline

NavinoEvans renamed this task from Determine country of general wiki loves edit to Only allow specific country selection on Wiki Loves campaigns.Aug 5 2019, 3:10 PM
NavinoEvans updated the task description. (Show Details)
NavinoEvans triaged this task as Medium priority.
NavinoEvans moved this task from Incoming Bugs to Pending on the ISA board.
NavinoEvans moved this task from Pending to Review on the ISA board.

@Anthere this feature is live now, but I've noticed that it prevents any contributions happening if someone selects "wiki loves campaign" with categories of the wrong format.

Example on live: https://tools.wmflabs.org/isa/campaigns/7

The drop down is present, but with no options. It then tries to start a participate session with country=Null and finds no images.

We're currently adding some more detailed instructions and guidance on the CREATE campaign page to avoid the wrong selection from happening as much as possible. But it will of course happen, so we need to choose what to do when the country drop down does not find any options at all.

The simplest thing to do is to default back to "all images" mode if no options have been found (i.e. just ignore the dropdown and treat it as a 'non-WikiLoves' campaign).
But ideally we should check the syntax on the Create campaign page, and stop creation if the manager has made incorrect selections.

Any thoughts or preferences?

I'd say checking syntax and stoping creation if wrong selections might be the best...

I think that makes sense. I'll see if it's something I can setup relatively easily now.

If that works out well then we should leave fixing T231259: WLX campaign 7 is broken

That will be the only campaign we have set incorrectly and there shouldn't be a way to add an new ones after the change. Alex is the manager so we can ask him nicely to change his campaigns settings for the anomaly :)

Awesome. Can you ask Alex then ?