Page MenuHomePhabricator

[regression] Special:EditWatchlist won't save if checked titles aren't currently on watchlist
Closed, ResolvedPublic

Description

Author: reachouttothetruth

Description:
If you check items on Special:EditWatchlist in 1.18+ that are not on your watchlist, submitting will result in a "There are problems with some of your input" error, with "The value you specified is not a valid option." at the bottom of the offending section. As a result the watchlist will not save and the user has to submit the form again for it to work. This error would usually (always?) happen because the user clicked the link to page and unwatched it from there. Since the form is intended to remove pages from one's watchlist, it should not be considered an error if a page has already been removed. It should submit successfully, like it did in 1.17 and earlier.


Version: 1.18.x
Severity: normal

Details

Reference
bz32126

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 12:06 AM
bzimport set Reference to bz32126.

Seems to be a side-effect of switching it to use HTMLForm; the series of checkboxes are made with HTMLMultiSelect which appears to want to validate every input value.

This baffles me generally because MultiSelect would presumably be a <select> listbox with the multiple-selection option enabled. WTF?

I can see a way to add a validation callback to declare things invalid, but not one to declare things as valid.... except by returning a true-ish but !== true value, which looks fragile and may not be a safe interface to use.

Fixed on trunk in r101666 -- marking for merge.