On 05/07/07, Brion Vibber brion@wikimedia.org wrote:
This raw edit save will reset the last-seen timestamps for all watched pages, which could hurt a bit for people using email notification.
Doing an array diff and only adding/removing the changed items should work cleaner for that case, plus save some DB activity when making small changes to a large watchlist.
Done. I've also optimised for the case where users blank the box and hit submit to clear. Following the discussion we had in IRC after I did that, I've since changed the code to pass around strings internally, since they're a hell of a lot lighter than Title objects.
If you pass a Special: or Media: title, it accepts them and treats them as an article-talk pair. Interwiki titles are also accepted, treated as normal pages.
Dealt with; these titles are now ditched.
I'd also recommend moving the low-level DB routines over to WatchedItem, which IIRC already has some batch-change functions.
Will consider doing this in a moment...
The makeTitleSafe() reminds me of the possibility of invalid entries in the watchlist table; those may not roundtrip nicely through the raw edit form. Just something to consider... automatic cleanup (for instance when namespaces change in weird ways) might be appropriate.
We talked about this a little, and as I see it, there are two major issues; to make scripts such as maintenance/namespaceDupes.php handle the watchlist (and really, any other place where we're storing a namespace/key pair, though these less-important tables could be batched up and done in low priority mode or somesuch), and to possibly introduce some sort of quick watchlist sweep job which can be queued up if we "spot" something odd in passing.
The mode links here feel buried in the UI text to me; it's not obvious to me that it's there. It might be interesting to try a more tab-like link here, maybe just simple links like on Special:Allmessages
Added navigation links at the top of the page. I toyed with a list in the main body, but it didn't really look right, although that's just me. :)
I may clear up a few of the old messages and perhaps some of the new ones, yet.
Rob Church