Hey all,
Last Friday, the mw.Title rewrite landed in master. Here's a brief summary of the changes.
TL:DR;
* New static constructor mw.Title.newFromText (returns mw.Title or null).
* New internal title parser (uses wgLegalTitleChars and mirrors most of Title::secureAndSplit).
* Bugs like [[.com]] throwing have been fixed.
* Big thanks to David Chan!
New: Static constructor mw.Title.newFromText
Unlike the regular constructor, this one does not throw exceptions on invalid input. Instead it returns null. This should make using mw.Title less awkward.
As a reminder, you are still required to account for invalid input. Where you previously wrapped `new mw.Title` it in a try/catch (which many users forgot), one may now use mw.Title.newFromText and check the result for truthiness.
Examples:
```php
$title = Title::newFromText( $input );
if ( $title ) { .. }
```
```js
title = mw.Title.newFromText( input );
if ( title ) { .. }
```
Regular constructor (old pattern):
```js
try {
title = new mw.Title( input );
} catch ( e ) { .. }
if ( title ) { .. }
```
New: Title parser
Previously mw.Title had a very basic processor for the text input. It was designed to be looser than its PHP counterpart so that it is fast and defaults to considering something valid. It is indeed more important to not consider something invalid when it is is in fact valid, than the other way around. Clients should never be blocking an action and it'll have to go through the server anyway at some point. Though that design is good, it is not what it really was.
In practice mw.Title's old processor considered various things invalid that were valid. And it had certain side-effects that weren't very intuitive (it removed certain invalid characters so that the title would become valid;in other cases it would throw an exception).
The new parser uses wgLegalTitleChars [2] and mirrors most of Title::secureAndSplit. For this we had to convert the character sequences in wgLegalTitleChars from bytes to Unicode. Big thanks to David Chan for making this work!
A full list of bugs fixed and patterns now properly recognised as valid and invalid can be found in the commit message[1] and by examining the added test cases.
Various bugs have been fixed (e.g. titles starting with dots, such as [[.com]], throwing an exception).
Documentation: https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw.Title
-- Timo
[1]
https://gerrit.wikimedia.org/r/#/c/83047/https://github.com/wikimedia/mediawiki-core/commit/4894793ab60ea0a245372cb4…
[2]
https://gerrit.wikimedia.org/r/#/c/82040/https://github.com/wikimedia/mediawiki-core/commit/dc9c9ee7fc6d96f957e15b4f…
[3] https://doc.wikimedia.org/mediawiki-core/master/js/#!/api/mw.Title
I have just posted a new draft RFC on changing the thumbnail storage
and caching pipeline for Wikimedia projects [0].
This RFC was started as part of the Multimedia tech debt project.
Aaron, Faidon and I would like to move discussion forward on the issue
of the thumbnail caching layer in general and specifically would like
to find consensus on a reasonable change to address some of the
shortfalls of the current system in place for upload.wikimedia.org and
related wikis.
The core problem has been discussed on list previously [1], namely
that scaled media files (aka thumbnails) take up a lot of space in the
storage servers. This RFC proposes following a course of action
proposed in that prior discussion [2] to customize the Varnish hashing
configuration for thumbs such that a single HTCP purge would
invalidate all size variations for a given file. It attempts to
document some of the benefits and drawbacks of that proposal as well
as present a few related variations.
Any and all feedback from this group would be greatly appreciated in
vetting the core idea and determining reasonable next steps towards a
viable long term solution.
[0]: https://www.mediawiki.org/wiki/Requests_for_comment/Simplify_Thumbnail_Cache
[1]: http://wikimedia.7.x6.nabble.com/scaled-media-thumbs-as-temporary-files-not…
[2]: http://wikimedia.7.x6.nabble.com/scaled-media-thumbs-as-temporary-files-not…
Bryan
--
Bryan Davis Wikimedia Foundation <bd808(a)wikimedia.org>
[[m:User:BDavis_(WMF)]] Sr Software Engineer Boise, ID
irc: bd808 v:415.839.6885 x6855
Might be of interest!
---------- Forwarded message ----------
From: Jon Robson <jrobson(a)wikimedia.org>
Date: Tue, Oct 8, 2013 at 12:06 AM
Subject: [WikimediaMobile] Mobile team upcoming changes
To: Operations Engineers <ops(a)lists.wikimedia.org>, mobile-l
<mobile-l(a)lists.wikimedia.org>
The MobileFrontend extension will see 2 changes within the next 3
weeks that will result in more API requests. I wanted to bring these
to the attention of ops to give you an opportunity to raise any
concerns.
The first makes the mobile uploads page exhibit infinite scroll. You
can see what this does if you compare the existing version [1] with
the beta version [2] and scroll to the bottom of the page. You will be
able to see the additional requests such a feature makes.
The second change will make Echo notifications load in mobile via
JavaScript avoiding a request to
https://en.m.wikipedia.org/wiki/Special:Notifications (this is no
different from the desktop version of the site)
You can track these changes on Mingle [3,4]. Based on the teams
existing velocity they are likely to be made and deployed no sooner
than Thursday 23rd to test wiki in that week's deployment train,
however there is a small chance they could make it a week early.
Please let us know if this could cause any issues.
[1] https://en.m.wikipedia.org/wiki/Special:Uploads/Kaldari
[2] https://en.m.wikipedia.org/wiki/Special:Uploads/Kaldari?mobileaction=beta
[3] https://wikimedia.mingle.thoughtworks.com/projects/mobile/cards/1282
[4] https://wikimedia.mingle.thoughtworks.com/projects/mobile/cards/1283
_______________________________________________
Mobile-l mailing list
Mobile-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mobile-l
--
Yuvi Panda T
http://yuvi.in/blog
Hey,
When constructing an SQL string, how should the following things be
escaped, if at all?
* Field names
* Index names
It looks like when doing a select using the Database MW thing, the field
names provided do not get escaped at all.
Cheers
--
Jeroen De Dauw
http://www.bn2vs.com
Don't panic. Don't be evil. ~=[,,_,,]:3
--
I'm trying to port a template from wikitext to lua. The template [1]
is quite simple, but it gets repeated hundreds of times in some pages.
Getting the logic to work was not complicated (the modified version is
at [2]), but I'm seeing huge performance variation in the lua version:
parsing [3] takes anywhere from 15 to 20s, while the wikitext version
is stable between 18.5 and 19s (I'm testing using the "preview in
page" option).
Is this something to be expected from the lua interpreter? How can I
minimize the problem?
Thanks,
Strainu
[1] https://ro.wikipedia.org/wiki/Format:ElementLMI
[2] https://ro.wikipedia.org/wiki/Utilizator:Strainu/testlmi
[3] https://ro.wikipedia.org/wiki/Lista_monumentelor_istorice_din_Bucure%C8%99t…
Hello,
I'm lost. L
Since 2 weeks, I experience some problems : the site runs very fast, and
suddenly runs slow for a couple of seconds (let say 15/20 seconds to load a
single page), then back to normal. When the problem occurs, I see this in
the Apache access.log (see line with error 408. Apache error for Request
time out.):
192.168.75.1 - - [02/Oct/2013:16:05:34 -0400] "GET /sites/mediawiki001/
HTTP/1.1" 301 575 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0;
rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:05:34 -0400] "POST
/sites/mediawiki001/index.php?action=ajax HTTP/1.1" 200 430
"http://euswebsrv01/sites/mediawiki001/index.php?title=Topics:Operating_syst
ems/Microsoft_Windows_8/Start_Screen" "Mozilla/5.0 (Windows NT 6.1; WOW64;
Trident/7.0; rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:05:34 -0400] "GET
/sites/mediawiki001/index.php?title=Main_Page HTTP/1.1" 200 8279 "-"
"Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:05:50 -0400] "-" 408 0 "-" "-"
192.168.75.1 - - [02/Oct/2013:16:05:50 -0400] "-" 408 0 "-" "-"
192.168.75.1 - - [02/Oct/2013:16:05:51 -0400] "-" 408 0 "-" "-"
192.168.75.1 - - [02/Oct/2013:16:05:51 -0400] "-" 408 0 "-" "-"
127.0.0.1 - - [02/Oct/2013:16:05:54 -0400] "OPTIONS * HTTP/1.0" 200 126 "-"
"Apache/2.2.22 (Ubuntu) (internal dummy connection)"
192.168.75.1 - - [02/Oct/2013:16:07:16 -0400] "GET
/sites/mediawiki001/index.php?title=File:Topics:windows-8_1-start-screen.png
HTTP/1.1" 200 7294
"http://euswebsrv01/sites/mediawiki001/index.php?title=Topics:Operating_syst
ems/Microsoft_Windows_8/Start_Screen" "Mozilla/5.0 (Windows NT 6.1; WOW64;
Trident/7.0; rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:07:17 -0400] "GET
/sites/mediawiki001/img_auth.php/thumb/500/5/5b/windows-8_1-start-screen.png
/120px-windows-8_1-start-screen.png HTTP/1.1" 200 13178
"http://euswebsrv01/sites/mediawiki001/index.php?title=File:Topics:windows-8
_1-start-screen.png" "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0;
rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:07:17 -0400] "GET
/sites/mediawiki001/img_auth.php/500/5/5b/windows-8_1-start-screen.png
HTTP/1.1" 200 189786
"http://euswebsrv01/sites/mediawiki001/index.php?title=File:Topics:windows-8
_1-start-screen.png" "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0;
rv:11.0) like Gecko"
192.168.75.1 - - [02/Oct/2013:16:07:17 -0400] "GET /sites/mediawiki001/
HTTP/1.1" 301 575 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0;
rv:11.0) like Gecko"
General config:
VMware Workstation 10 running on Win7 SP1 x64
Web server: Ubuntu 12.04 Server x64, installed on a VMware machine, with 2
Go of RAM.
Apache/2.2.22 (Ubuntu)
MySQL 5.5.29
PHP Version 5.3.10-1ubuntu3.7
APC 3.1.13
No, I haven't change anything in my config since many weeks. I'm the only
one who access the site.
On the server, I have the following structure:
/var/www/index.html (to choose if I want to access Mediawiki site or PHPBB
site - see below)
/var/www/sites/mediawiki001 (Mediawiki site)
/var/www/sites/phpbb001 (PHPBB site)
When I access the PHPBB site, all is very rapid. issue occurs only with
Mediawiki.
I have try to read on the web. but I'm completely lost with this one. still
a newbie J
You will probably need more info (php.ini ? LocalSettings.php ? extension
list ?...) : just tell me.
Thanks in advance !
Pierre
Hello all!
It's been an absolute pleasure working with this community for GSoC 2013.
I've had a really good experience and it was really nice to get to know you
all.
I've written a blog post to summarize my experience over this summer as
well as discuss my plans for the project in the future.
http://blog.pragunbhutani.in/articles/google-summer-of-code-2013-wrap-up/
Please check it out, and if you find the project interesting and would like
to contribute to it: Don't bother knocking, come on in! :)
Cheers,
--
Pragun Bhutani
http://pragunbhutani.in
Skype : pragun.bhutani
Hello!
You know the drill.
Full schedule:
https://wikitech.wikimedia.org/wiki/Deployments#Week_of_October_7th
== Monday ==
* VisualEditor turned on by default for the following 26 wikis for all
users:
Bulgarian (bg), Catalan (ca), Cebuano (ceb), Czech (cs), Danish (da),
Estonian (et), Basque (eu), Finnish (fi), Galician (gl), Croatian
(hr), Hungarian (hu), Indonesian (id), Latvian (lv), Malay (ms),
Norwegian - Nynorsk (nn), Norwegian - Bokmål (no), Simple English
(simple), Slovak (sk), Slovenian (sl), Turkish (tr), Ukrainian (uk),
Volapük (vo), Waray-Waray (war), Modern Greek (el), Neopolitan (nap),
Venetian (vec), Sicilian (scn)
* GettingStarted/GuidedTour bug fix
== MediaWiki Train ==
* Normal MediaWiki 'train' of upgrades. 1.22wmf20 to non-Wikipedia sites
(Commons, Wiktionaries, etc) on Monday. 1.22wmf20 to all Wikipedias on
Thursday. 1.22wmf21 branched and deployed to test wikis on Thursday.
See:
https://www.mediawiki.org/wiki/MediaWiki_1.22/Roadmap#Schedule_for_the_depl…
Note: Yes, there isn't a whole lot of non-standard deploys next week,
hence only the call out of Monday's deploys.
Greg
--
| Greg Grossmeier GPG: B2FA 27B1 F7EB D327 6B8E |
| identi.ca: @greg A18D 1138 8E47 FAC8 1C7D |
(reposting: held in moderation because of recipient list)
I am posting this to wikitech-l, ee-l, and will cross-post this to https://bugzilla.wikimedia.org/show_bug.cgi?id=35306 because it's important to keep frank discussions in the open.
When I use to loaded words like "back-dooring" etc, I believe that no malice was intended and the discussions so far have been in good faith from all parties. I think people have a valid concern and want it addressed and are wondering honestly how decisions have been made. In particular, my decision to not allow the MassMessage Extension to roll out onto MediaWiki last week, since that occurred during a meeting that didn't even involve or derive have consultation (except ex-post-facto) with any product manager or engineer here.
Here is why I am inijating this thread:
1) https://wikitech.wikimedia.org/w/index.php?title=Deployments&diff=83188&old…
2) On Sep 30, 2013, at 4:25 PM, MZMcBride <z(a)mzmcbride.com> wrote:
> Hi Fabrice, Terry, and Howie,
>
> https://bugzilla.wikimedia.org/show_bug.cgi?id=35306#c19 is awaiting feedback (if you have any).
>
> MZ
3) https://wikitech.wikimedia.org/w/index.php?title=Deployments&diff=84903&old…
…
We have two separate but related bugs here:
https://bugzilla.wikimedia.org/show_bug.cgi?id=35306https://bugzilla.wikimedia.org/show_bug.cgi?id=52723
bug 35306 is an tracking bug MZMcBride posted for a solution to deal with EdwardsBot. I believe it dates to around the time I was first employed almost two years ago.
bug 52723 is a recent bug to deploy Legoktm's MassMessage extension as a solution to bug 35306, it is less than a month old there has been little public discussion, and until it appeared on the deploy calendar last week, I wasn't even aware of its existence.
The problem with moving on bug 52723 as a solution to bug 35306 is it commits Features Engineering to maintaining an extension that is a stop gap solution with no or very little discussion in a manner that doesn't serve a broad strategic goal about how messages, notifications, etc. should be handled on the wikis. To the first, maybe there is something wrong with my e-mail client, but I have yet to find this discussion on wikitech-l or anywhere outside the bug.
Because of the above, my view is that this solution is being back-doored in and just moves the "technical debt" from one sheet (the community and tool labs) to another that has even less capability. I am biased against that because the latter sheet (WMF Features Engineering) is my responsibility. This is just my view, I'm open for us coming to consensus on a solution for this bug, but what I have seen is not consensus.
It is along these lines that, I asked to remove MassMessage from the deploy calendar when it was added to the deploy calendar without discussion from Features, Design, or Product last week. After discussion during that Friday meeting among the EPMs, I compromised to let it to go out on two test wikis, but not on mediawiki. Nobody made the case that it should go out on mediawiki. I demurred because no person at the WMF, including me as Director of Features Engineering, should fiat a decision when unaware of the status of discussions involved.
But let frank: if this had been a WMF employee writing this extension, it wouldn't have made it to even the test wikis by a country mile. In fact, a lot of extensions have been written by employees and either have extensive discussion, review, and buy-in (e.g. GuidedTours), or have not been deployed (e.g. Etherpad, the org chart, BetaFeatures) even though much more work has been done on them.
I also don't like that WMF resources in Platform and Design are being spent to review something that has had no adequate discussion over in the annual plan, in anyone's 20% time, in any cross-team discussion, or public discussion on wikitech-l (There was a last minute thread in the Design list, I am not on the design list, nor should I be, and the Creative Director is new and the team is just trying to get their sea legs and some consideration to that needs to be done here). Furthermore, after further discussion, nearly all of Product felt I should not have compromised earlier because the following situation might occur: Having gotten it onto "the cluster" people would then move to back-door it into deployment on the basis that it's already on the cluster. Their prediction is occurring right now. This is a bogus argument because nobody agreed this should be on the cluster, it's just that nobody has reviewed it in a thorough enough manner to shout "NO!"
If necessary, I'm going to shout "NO!" at this moment.
Having said that, there is the larger issue of bug 35306 which has been sitting there unsolved for a while as well as the smaller issue of the month's work Legoktm and MZMcBride have already put into Bug 52723 and [[mw:Extension:MassMessage]] possibly going to waste if I keep blocking it. Besides, MZ is sitting there trying to hold everything up on his own shoulders with EdwardsBot, and we all know it.
…
Let me address the functionality overlap with Echo:
LanguageEngineering built their own parallel message/notification system before Echo that lives on Meta today. They commit to supporting their own parallel message/notification system, and I'm okay with it living outside Echo (where it currently does), but there is an understanding that they've basically committed to that work with no support from Features for the duration that it does live outside Echo.
In those lines, I'm glad that Platform has helped out here, but unless Platform is committing to support MassMessage indefinitely into the future and not just provide one-time security and deploy assistance, I'm not okay with them adding to Features work even though they've been super helpful to MZMcBride and Legoktm. If Dan Garry is willing to commit Platform to support MassMessage, I'll think the same precedent we've done with LE applies here.
Furthermore, before *in-echo, outside-echo, use-echo) for a solution to be bug 35306, it needs to actually exhibit product discipline. The WMF gets panned for having a "agile processes" but not actually doing so, but we do have some process and we need to at least apply the same product discipline that we apply everywhere else to this bug.
For example, features in MassMessage and EdwardsBot need to be addressed in a Must-Have, Should-Have, Could-Have, Won't-Have (MoSCoW) framework. Features like "mass delivery from a list" are probably a Must-Have; features like "cross-wiki notification" are probably a should-have, other features like "public over private notifications", "page-centric over user-centric" or "longer stream notifications" are either not a must-have or could have or are should-haves to be done outside Echo by a different service (bot) using the Echo API or some extension thereof. All that is a product issue, and I nor anyone in my team is in product. Those decisions should be done in discussion with the Product team and they should not be disintermediated from it, which they have been.
I understand that many people would like to see a solution to Bug 35306 would be great to have. I'd like to see a better Signpost notification system and a more generalized solution for newsletter delivery also! I'd also like a pony. But we have already committed resources and continue to commit resources without discussion from the people (Product Design, not Features Engineering) who have been tasked with this responsibility and are very good at these sort of thing. I hope everyone participating on this bug can see that dropping this bomb on a newly hired associate product manager is simply not cool on so many levels.
…
Here is my suggestion:
(This is thinking, not a directive so don't think of this as definitive or final, I'm seeking consensus here.)
First, bug 35306 is a long-standing request. I think it's important we get headway on this, but I hope others will be understanding if it doesn't happen immediately, so long as there is a commitment for this to happen.
(For perspective, Flow was first proposed years ago, and was added to the annual plan almost two years ago before their first actual development sprint was completed (end of this week!). Echo was first deployed almost 8 months ago and is still not out on all the wikis. BetaFeatures has been in discussion for months and is still not deployed, nor is the commitment to maintain inside Features and that has caused a lot of issues. Fixing things right right takes time because consensus takes time and open discussion.)
There is an RfP for student developer time for legoktm for things like this (Finding a solution for Bug 35306 but not [[mw:Extension:MassMessage]] because MassMessage would not be deployed if it was my own engineer). Benny Situ has been spending all his time supporting [[mw:Extension:Echo]] when he should balancing [[mw:Flow]] development time into Echo bug fixes and needs to spend at least one sprint (two weeks) solely getting up to speed on Flow before doing enhancements for [[wm:Echo]]. Furthermore, Echo is not deployed everywhere yet and is still rolling out (though I've been pushing up the timetable on this as I feel we're too slow here), so it can't reach the places that EdwardsBot cat.
After the above happen, I'd like Benny and Kunal to work together to add some of the functionality of EdwardsBot into Echo for mass message delivery. Because of this, I'm moving bug 35306 into Echo as an enhancement and raising it's priority.
In the meantime I'll be OK with leaving MassMessage on test and test2 wikis because the alternative would be to remove it from the cluster entirely. The experiences and code Kunal derives by that can inform the enhancement to Echo, as well as things it already does that find themselves outside Echo (Echo does not and should not post to talk pages). So I figure two stages:
1) wait for some things to happen: legoktm to get an RfP, Echo to be on all wikis, and Benny to do an entire Flow only sprint and balancing his time more effectively wrt Echo.
2) MoSCoW other features of MassMessage/EdwardsBot for integration into Echo
3) Enhance and deploy a first pass to Echo to allow some sort of mass notification from a wiki list
4) Some sort of cross wiki notification enhancement (requires a design pass)
5) Discuss how to implement must-have or should-have features of EdwardsBot that can't live in Echo (permanent log of events)?
6) Add those to plan and be done.
The above can occur independently or in parallel to the above. If Product thinks it cool to commit Platform's constrained engineering resources to deploying and supporting MassMessage Extension forever and use it to take advantage of Echo when the features roll out in some undefined future, consider this thinking moot or at least orthogonal to MassMessage. IMO, it is bad enough that something important like BetaFeatures is without a home, but my answer from Features is "No" for MassMessage. If this was my own engineer, I'd raise hell with them for this and yell at their Product Manager for not being a good steward of Platform's time.
Take care,
terry
terry chay 최태리
Director of Features Engineering
Wikimedia Foundation
“Imagine a world in which every single human being can freely share in the sum of all knowledge. That's our commitment.”
p: +1 (415) 839-6885 x6832
m: +1 (408) 480-8902
e: tchay(a)wikimedia.org
i: http://terrychay.com/
w: http://meta.wikimedia.org/wiki/User:Tychay
aim: terrychay