Commit graph

2139 commits

Author SHA1 Message Date
DaSch
e9e24cbfe7 Add git HEAD date to Special:Version for core and extensions
The patch adds the localised commit date of i) core and ii) extensions
in the Special:Version page tables. It requires the Git version control
system being installed, which is checked during the installation.

Introduces a new parameter for the git binary in DefaultSettings.php:
$wgGitBin = '/usr/bin/git';

Patch authored by DaSch <dasch@daschmedia.de> and updated and fixed
by Wikinaut<mail@tgries.de>.

Bug: 38783
Change-Id: I0931400ecacf91ed2ab4fc7aa46dceac17661768
2013-04-15 20:47:15 +00:00
Aaron Schulz
6d44eb2bab Removed old cache update b/c code from 2007.
Change-Id: Ia19062cb48f7748501c061544b2949bf3beaba4d
2013-04-15 00:08:14 +00:00
jenkins-bot
dfd1efa0f4 Merge "Revised design of Special:Userlogin" 2013-04-11 23:31:51 +00:00
S Page
b809d516db Revised design of Special:Userlogin
If a global variable is set or if you add ?useNew=1 to the query string,
Special:Userlogin loads a different login template (UserloginVForm.php)
with the new Vertical Form appearance and different messaging.
Otherwise the current unchanged template renders so that wikis can cut
over to the new look when ready (with messages and links). Once they do
so, the variable and flag will be retired.

The new template applies mw-ui-vform and mw-ui-button styles defined in
a new 'mediawiki.ui' CSS module in core to create a compact vertical
form.  The mw-ui styles specify a Helvetica font stack (that we tested
in the Account creation experiment) in the form area, but NOT if the
user is using some other skin than Vector.

The CSS code is developed using Sass. The patch includes the
Sass scss files, along with a Makefile that uses their Compass build
configuration (config.rb).

The redesigned Special:Userlogin also:

* Displays a "secure login" link if HTTPS is available.
* Loads additional CSS for its form features (e.g. more attractive
  errorbox, "Join wiki" messaging).
* Defines new "userlogin-xx" messages; many are the same as
  existing messages but without ':' on the end.
* Uses a distinct title for Login instead of generic "Log in /
  Create account".
* Removes the [mailmypassword] code branch from its login template as it
  is never executed.

Bug: 44628
Change-Id: I489042c50aa060c90ca18b05097dbe25c4ae6395
2013-04-11 22:26:45 +00:00
Chad Horohoe
4be6236352 Remove externaledit/externaldiff preference
Change-Id: Ic3791d188688f556753ab5556a4d9733bbf2e85e
2013-04-11 09:20:36 -04:00
rahul21
721ea54c7e Vector: Move 'editwarning' feature from Vector extension
* Created a new Resource Loader module
* Created an entry for the RL module in the Resources.php
* Added messages to languages/MessagesEn.php and languages/MessagesQqq.php
* Called the new RL module from the EditPage.php
* Added required entries in the messages.inc, DefaultSettings.php

Corresponding change in the Vector extension: I164f17255bc927

Bug: 46514
Change-Id: I7bdbd09f4083ccb316156307400ccfacdfec79e1
2013-04-10 20:40:08 +02:00
Tim Starling
3c3ba5e03e Fix message cache expiry semantics
* Use the stale message cache while the new one is being generated
* Revert I811755d4 (make message cache load failure fatal). This
  escalated several very plausible temporary site issues from barely
  noticeable to complete downtime -- for example, memcached being down
  on a site with only one memcached server.
* Remove $wgLocalMessageCacheSerialized, it's always been pointless
* Clarify a couple of comments.
* Increased lock wait timeout to 30s
* Make lock() fail immediately on memcached connection refused

Tests done:
* With local cache enabled: normal cold refill; refill local from
  global cache; use stale local cache during remote refill; use stale
  global cache during remote refill; cold cache wait for remote refill;
  saveToCaches() failure; memcached connection refused.
* With local cache disabled: saveToCaches() failure; cache disabled due
  to "error" status key; memcached connection refused.

Setting a 1-day expiry in memcached, with a ~10s CPU cost to replace, is
not the best idea since it inevitably leads to a cache stampede. Dealing
with the stampede by waiting for a lock is not ideal, even if it were
implemented properly, since it's not necessary to deliver perfectly
fresh message cache data to all clients.

This is especially obvious when you note that barring bugs, expiry and
regeneration always gives you back the exact same data, because we have
incremental updates (MessageCache::replace()). Keeping all clients
waiting for 10s just to give them the data they have already is pretty
pointless.

So, continue to serve the site from the stale message cache while the
new one is being generated.

One caveat: if local caching enabled, when the message cache becomes
stale, a sudden spike in network bandwidth may result due to the full
array (also typically stale) being fetched from the shared cache.

Bug: 43516
Change-Id: Ia145fd90da33956d8aac127634606aaecfaa176b
2013-04-09 20:40:20 -07:00
MatmaRex
a8fbbcf98d Remove the "Quickbar" feature and all things related to it
"Quickbar" was a feature of the Standard and CologneBlue skins that
allowed the sidebar to be displayed on left or right side of the page,
floated or fixed, and hidden on diff pages.

Standard was removed (Ia6d73c2d), and CologneBlue doesn't support this
anymore (bug 41246), so all things quickbar can now be safely removed.

* Removed user prefs option + interface
* Removed related messages
* Removed code for this in SkinLegacy
* Removed dead code in DifferenceEngine and Language

Change-Id: I5e6f7d48d6904a052a3a11547d3ebe6161463018
2013-04-07 04:08:05 +02:00
Chad Horohoe
36cade5fe8 Remove ExternalUser authentication code
This was an experimental authentication system intoduced a couple
of years ago with a pretty narrow use-case. It's been pretty much
ignored since introduction, and makes login more complicated than
it needs to be.

I didn't drop the external_user table on the off-chance someone
out there actually has data in it, but they should use AuthPlugin
for their external authentication needs.

Change-Id: I794338dbb75961ee033d41fa44bb7aa22e54f447
2013-04-04 10:09:34 -04:00
Chad Horohoe
f9e54577af Remove completely unused $wgRedirectScript/redirect.php
Change-Id: Ia624d65fbb1c787293054e12162b1444ab7c1edc
2013-04-01 18:29:42 +00:00
Skizzerz
d99bda6ee6 Apply IP blocks to X-Forwarded-For header
Adds a new configuration variable ($wgApplyIpBlocksToXff), which when
enabled will scan the XFF header for IP addresses and check if any of
them have been blocked. $wgApplyIpBlocksToXff is disabled by default.

Bug: 23343
Change-Id: I3faa9c3e8107c6e46cdf21f8c18adda1f42890d7
2013-03-30 05:51:46 -07:00
Aaron Schulz
fb096ec339 Merge "Revert "Apply IP blocks to X-Forwarded-For header"" 2013-03-29 19:57:35 +00:00
Aaron Schulz
4ba66e41b5 Revert "Apply IP blocks to X-Forwarded-For header"
Test are now starting to fail for everything.

This reverts commit a5d70e3ae6

Change-Id: I30c9eb9c00be12ff080e85452e17c2a310f03bd3
2013-03-29 19:13:35 +00:00
jenkins-bot
8b3108fe77 Merge "Apply IP blocks to X-Forwarded-For header" 2013-03-29 18:42:50 +00:00
Skizzerz
a5d70e3ae6 Apply IP blocks to X-Forwarded-For header
Adds a new configuration variable ($wgApplyIpBlocksToXff), which when
enabled will scan the XFF header for IP addresses and check if any of
them have been blocked. $wgApplyIpBlocksToXff is disabled by default.

Bug: 23343
Change-Id: I3e38b94d10600a60d2d4857de54307f34c4662c4
2013-03-29 11:29:17 -07:00
Reedy
dca6a220a0 Bump 1.22
Change-Id: Ib257f41b18764e7363d2e4aac661da76bed67413
2013-03-28 23:50:18 +00:00
Daniel Friesen
55f9ec1742 Enable $wgVectorUseIconWatch by default.
The usability testing for this feature is over. We've had it enabled on the largest
family of wiki in existence for ages. People are generally expecting to see this
enabled when they install a new MediaWiki wiki.

Change-Id: I6e7f4cf6c874fe9e34cc141c4305a6808c1fe576
2013-03-28 14:17:30 -07:00
umherirrender
e78a8701df DefaultSettings: Remove some empty lines
Add a missing comment - text taken from
https://www.mediawiki.org/wiki/Manual:$wgProxyMemcExpiry

Change-Id: Ifccf920e1e6d1312d8adb39f83eef59f33cc148b
2013-03-22 20:50:19 +01:00
Matmarex
cd41591445 Revert "Change login/createaccount forms to new appearance"
The code did not go through a proper review process, and - quite
simply - it is unacceptable by core standards (or by any standards, to
be honest).

* It "[u]ses JavaScript to munge the create account CAPTCHA", to quote
  the commit message
* It is littered with TODOs and FIXMEs, as well as messages from one
  coder to the other and commented-out code
* It modifies some HTTPS-related logic for no obvious reason (it's not
  documented or even mentioned *at all* in a otherwise front-end
  changeset)
* It happily disregards code conventions (trailing spaces, #-comments,
  CSS formatting)
* It includes different CSS font-family rules that the entire rest of
  software uses for display, creating design inconsistency
* It hardcodes links in the format "/wiki/XXX"
* It hardcodes English-language link hrefs

This reverts commit 92bb00d356

Conflicts:

	languages/messages/MessagesEn.php

Change-Id: I00d72fe157e697d5cf926e75bcea5db0bee153e5
2013-03-19 20:10:19 +00:00
jenkins-bot
269b1c89d3 Merge "Change login/createaccount forms to new appearance" 2013-03-19 18:33:42 +00:00
S Page
92bb00d356 Change login/createaccount forms to new appearance
If a global variable is set or if you add ?useAgora=1 to the query
string, Special:Userlogin loads a different login or create account
template (Userlogin-/UsercreateAgora.php) with an Agora look and
different messaging.  Otherwise the current form is unchanged so
that wikis can cut over to the new look when desired.

These new templates apply mw-ui-formlist and mw-ui-button styles defined
in a new 'mediawiki.ui' CSS module in core (copied from Extension:Agora).

In useAgora mode, Special:Userlogin also:
* Adds new modules with some additional CSS for new form features
  ("Join wiki", benefits of creating an account).
* Defines new "userlogin/usercreate-xx" messages, many are the same as
  existing messages but without ':' on the end.
* Uses a distinct title for each mode instead of generic "Log in /
  Create account".
* Uses JavaScript to munge the create account CAPTCHA.
* Outputs checkboxes using UserloginTemplateAgora::labelledCheck()
* Displays a benefits column of wiki edits/users/contributor numbers.

TODO:
- Restyle/reposition language selector
- Munge CAPTCHA in PHP not JavaScript, i18n of new CAPTCHA messages.
- Identify the subset of Agora appropriate for non-Vector skins and
  create mediawiki.ui.default.css from that.

Patch set 18: Agora styles now in core.

Bug: 44628
Change-Id: I859edab4fc4fa9fe35fdef15fc429ae19a95305d
2013-03-18 21:12:03 -07:00
Ed Sanders
8f62c73203 (bug 45054) Fix rsvg converter command line when thumbnailing.
Change-Id: Ia6c1d4e5d61629e9651495ee92fe1c7298a50ef1
2013-03-18 02:15:30 +00:00
Daniel Kinzler
b929f19df9 Merge "Default $wgContentHandlerUseDB to true" 2013-03-16 14:33:30 +00:00
Timo Tijhof
88791a2dce DefaultSettings: Add @since annotations.
Based on information from:
- https://www.mediawiki.org/wiki/Manual:$wgConf
- https://www.mediawiki.org/wiki/Manual:$wgVersion
- https://www.mediawiki.org/wiki/Manual:$wgCanonicalServer
- https://www.mediawiki.org/wiki/Manual:$wgUsePathInfo
- etc.

Change-Id: If359c57493de8efa3beb92b75e2ece9ca4a3a828
2013-03-15 11:52:39 +00:00
jenkins-bot
7f4e344b24 Merge "servers => serves" 2013-03-13 19:48:08 +00:00
Reedy
605de54e11 servers => serves
Change-Id: Idff55d11850fe68c2ba0938e5944dfe53beee390
2013-03-13 19:39:10 +00:00
Yuri Astrakhan
9506e3d812 Spellchecked /includes directory
* Ran spell-checker over code comments in /includes/
* A few spellchecking fixes for wfDebug() calls

Found one very strange (NOOP?) line in Linker.php - see "TODO: BUG?"

Change-Id: Ibb86b51073b980eda9ecce2cf0b8dd33f058adbf
2013-03-13 03:42:41 -04:00
Alexandre Emsenhuber
acddbd2288 (bug 44719) Remove mention of non-existing script in DefaultSettings.php
maintenance/migrateCurStubs.php does not exist; and I was unable to find
any script that would achieve that functionnality.

Bug: 44719
Change-Id: I78d8a8aa95a5406bf5a979867bc12a9bb34907f6
2013-03-12 16:34:21 +01:00
Yuri Astrakhan
27d83878c0 Lots of spelling mistakes and phpdoc attributes
@throw->@throws
@returns->@return
@seealso->@see
@cover->@covers
etc

Change-Id: I9ae6bc3034e9790e2d66cd96473b923fe9ee7953
2013-03-10 23:16:28 -04:00
jenkins-bot
5a63f70843 Merge "Add SpecialPage::getGroupName and use it" 2013-03-08 06:59:00 +00:00
Jan Gerber
e288e4036c (bug 33186) image rotate api
add api action imagerotate to rotate images.
	rotations are stored as a new version of the image.

Change-Id: Id15a92d19cda8256917e7e1e5ee4241012214102
2013-03-07 21:38:10 +00:00
umherirrender
96a5486ed0 Add SpecialPage::getGroupName and use it
Having all group mapping for Special:SpecialPages in the global
$wgSpecialPageGroups is not a good OO style.
Created a method SpecialPage::getGroupName, which than can be overridden
by each subclasses to the featured group name.

Added also SpecialPage::getFinalGroupName to get the groupname on
Special:SpecialPages to handle the customization and
to keep $wgSpecialPageGroups for b/c

Change-Id: I1de3a186f0a59ec5ecb8996c5f805cf164e9637f
2013-03-07 21:15:54 +01:00
umherirrender
d63121016d fix some spacing
Added/removed spaces around logical/arithmetic operator
Reduced multiple empty lines to one empty line
Removed wrong tabs before comments at end of line
Removed too many spaces in assigments

Change-Id: I2bba4e72f9b5f88c53324d7b70e6042f1aad8f6b
2013-03-07 17:53:21 +01:00
jenkins-bot
53b4dcd2b8 Merge "Use American English spelling for behavior" 2013-03-06 09:00:26 +00:00
Waldir Pimenta
158bf7cb55 normalize filenames of maintenance scripts
Use lowerCamelCase.php format for all files (per [[mw:CC#File_naming]]),
and make filenames more specific:
- clear_stats.php -> clearCacheStats.php
- clear_interwiki_cache.php -> clearInterwikiCache.php
- initStats.php -> initSiteStats.php
- proxy_check.php -> proxyCheck.php
- stats.php -> showCacheStats.php
- showStats.php -> showSiteStats.php

Also changed the class names accordingly (per [[mw:CC/PHP#Naming]]),
and make class names more specific:
- clear_stats -> ClearCacheStats
- InitStats -> InitSiteStats
- CacheStats -> ShowCacheStats
- ShowStats -> ShowSiteStats

Updated files that made references to the changed files/classes:
- DefaultSettings.php and SpecialBlockme.php (proxy_check.php -> proxyCheck.php)
- maintenance/showSiteStats.php (initStats.php -> initSiteStats.php)
- maintenance/README and docs/memcached.txt (stats.php -> showCacheStats.php)
- docs/maintenance.txt and docs/memcached.txt (clear_stats.php -> clearCacheStats.php)

Thanks Hashar for the initial help and encouragement :)

Change-Id: I60f76fc971e06e1b710dcda35f9c2d931b93bdd7
2013-03-06 03:57:54 +00:00
Aaron Schulz
04c610200f [JobQueue] Throttle refreshLinks2 jobs based on finishing the refreshLinks jobs.
* This should lower the rate of queue activity when major templates change.
* Also fixed a broken array_diff() call in nextJobDB.php.
* Additionally removed checkJob from nextJobDB.php. This is redundant to
  runJobs.php de-listing queues via JobQueueGroup::pop() when the queue
  is empty.

Change-Id: I1518a0de9e7ada22350d9993dd7ffe5f2ce23745
2013-03-05 23:28:55 +00:00
Reedy
586e8fb7ec Revert "Commit of various live hacks"
This reverts commit 3d6851f662.

Change-Id: I26c418d631047783ba945e6b6a7f707d876b3146
2013-03-04 18:39:51 +00:00
Reedy
26ea93a831 Revert "Applied patches to new WMF 1.21wmf11 branch"
This reverts commit 855d049c75.

Change-Id: I68f75d9e9cb942f6dc4bdef97a5d5458c9b89875
2013-03-04 18:39:47 +00:00
Reedy
855d049c75 Applied patches to new WMF 1.21wmf11 branch 2013-03-04 18:03:40 +00:00
Reedy
3d6851f662 Commit of various live hacks
Disable of MessageBlobStore clear

Reset $wgAutopromote (should be moved to a config change!!)

Disable setting of wgStyleSheetPath

Throttle page_touched

Add apc htcp packet numbers to SquidUpdate

Disable set names binary/utf8

Commment out searchindex table indexes

Was c532e81d583d3d0439fe76eea4d105d675461b56

Original revision Change-Id I42c4f859e55eb198f6c6841e582b3552aad7b31f
https://gerrit.wikimedia.org/r/#/c/7606

Change-Id: I5ec8dd53188e9e4128f99ceaff38ebf9dcf570bb
2013-03-04 18:03:39 +00:00
Siebrand Mazeland
9b7889b84b Use American English spelling for behavior
Spotted in ipbreason-dropdown by Shirayuki.

Change-Id: I576ed4bc0abe5ab980aaee3fb9f9e4b43087311f
2013-03-04 10:24:57 +01:00
Brad Jorsch
b16f5bf88e (bug 44244) Add number of watchers to API prop=info
Following up I1cb6ee22, which added this information to each page's
action=info, this adds inprop=watchers to query the number of people
watching the page. It is subject to the same limitations (user has
unwatchedpages or watchers >= $wgUnwatchedPageThreshold) as action=info.

Also, update doc for $wgUnwatchedPageThreshold to match reality.

Bug: 44244
Change-Id: Ideaac1d84bbe0349154ffe96ba54d74305e3da1d
2013-03-03 20:29:03 -05:00
Reedy
465957fb00 Default $wgContentHandlerUseDB to true
Change-Id: I830ec04e7f7f853bf7752262105a067fb9723145
2013-03-01 18:45:56 +00:00
jenkins-bot
96eb68f39f Merge "[Upload] Moved async upload stuff to the job queue." 2013-02-26 23:58:32 +00:00
jeroendedauw
2578bb06a8 Extend ... magic to also work when "others" is linked somewhere
Change-Id: I8c6657c95061b066ed48f115e771889a507bd268
2013-02-26 10:28:56 +00:00
Brad Jorsch
307ac55e50 Add PagesWithProp special page and API module
It would be useful to be able to list pages using a particular page
property, particularly in light of the new Disambiguator extension.

This adds a special page Special:PagesWithProp and an API query module
list=pageswithprop to do just this. It also adds an API query module
list=pagepropnames to list the prop names currently in use on the wiki.

Change-Id: Ib0d4e17f22b8d0cb9894eac6095962315480e809
2013-02-26 00:24:31 +00:00
Aaron Schulz
7013da720b Small tweaks to $wgLockManagers documentation.
Change-Id: Ib9678e303a1360ccb1e9005ac919ed75e4e45705
2013-02-21 06:38:37 +00:00
Aaron Schulz
9cc7e6a39a [JobQueue] Cleanups for JobQueueRedis.
* Cleaned up 'server' option to not fragment the pool.
  Also made it actually match the documentation.
* Made it use doGetPeriodicTasks() for job recycling.
* Made it so that other job queue classes can be tested.
* Renamed "redisConf" => "redisConfig".
* Tweaked comments about the "random" order option.

Change-Id: I7823d90010e6bc9d581435c3be92830c5ba68480
2013-02-21 05:38:01 +00:00
Aaron Schulz
d0985f4f04 [JobQueue] Added aggregate empty/non-empty queue caching.
* The default class is JobQueueAggregatorMemc.
  This essentially has the logic that nextJobDB.php used.
* Also created a JobQueueAggregatorRedis class.
  This is much more efficient and more responsive.
* This can speed up calls to getQueuesWithJobs().
* Removed unused getDefaultQueuesWithJobs() function.

Change-Id: Ifb3c6c881decd643da1b662956ded69db4b39431
2013-02-20 17:34:14 -08:00
Yuri Astrakhan
96a9603eea API Remove $wgAPIGeneratorModules - it's dynamic now
* $wgAPIGeneratorModules is now obsolete and will be ignored
* Removed generator tests - obsolete because there is no more list

Change-Id: I014260a42226854a2178345dc3cd0f50b41b3c08
2013-02-19 11:27:13 -05:00