[MediaWiki-commits] [Gerrit] Improvements for UserEditFilterGenerator - change (pywikibot/core)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Improvements for UserEditFilterGenerator
..


Improvements for UserEditFilterGenerator

- add show_filtered parameter to show skipped pages
- enable timestamp as Timestamp or datetime object
- provide starttime/endtime parametes for Page.revisions and
  Page.contributions

Bug: T104265
Change-Id: I57249a9ba28f7031a981104153d584beaac2397a
---
M pywikibot/page.py
M pywikibot/pagegenerators.py
M scripts/template.py
3 files changed, 22 insertions(+), 18 deletions(-)

Approvals:
  John Vandenberg: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/pywikibot/page.py b/pywikibot/page.py
index b47badd..bd867b4 100644
--- a/pywikibot/page.py
+++ b/pywikibot/page.py
@@ -1467,10 +1467,11 @@
 
 @deprecated_args(getText='content', reverseOrder='reverse')
 def revisions(self, reverse=False, step=None, total=None, content=False,
-  rollback=False):
+  rollback=False, starttime=None, endtime=None):
 """Generator which loads the version history as Revision instances."""
 # TODO: Only request uncached revisions
 self.site.loadrevisions(self, getText=content, rvdir=reverse,
+starttime=starttime, endtime=endtime,
 step=step, total=total, rollback=rollback)
 return (self._revisions[rev] for rev in
 sorted(self._revisions, reverse=not reverse)[:total])
@@ -1523,18 +1524,22 @@
   step=step, total=total)
 ]
 
-def contributors(self, step=None, total=None):
+def contributors(self, step=None, total=None,
+ starttime=None, endtime=None):
 """
 Compile contributors of this page with edit counts.
 
 @param step: limit each API call to this number of revisions
 @param total: iterate no more than this number of revisions in total
+@param starttime: retrieve revisions starting at this Timestamp
+@param endtime: retrieve revisions ending at this Timestamp
 
 @return: number of edits for each username
 @rtype: L{collections.Counter}
 """
 return Counter(rev.user for rev in
-   self.revisions(step=step, total=total))
+   self.revisions(step=step, total=total,
+  starttime=starttime, endtime=endtime))
 
 @deprecated('contributors()')
 def contributingUsers(self, step=None, total=None):
diff --git a/pywikibot/pagegenerators.py b/pywikibot/pagegenerators.py
index f00acd1..41c3d88 100644
--- a/pywikibot/pagegenerators.py
+++ b/pywikibot/pagegenerators.py
@@ -1482,7 +1482,7 @@
 
 
 def UserEditFilterGenerator(generator, username, timestamp=None, skip=False,
-max_revision_depth=None):
+max_revision_depth=None, show_filtered=False):
 """
 Generator which will yield Pages modified by username.
 
@@ -1496,28 +1496,26 @@
 @param username: user name which edited the page
 @type username: str
 @param timestamp: ignore edits which are older than this timestamp
-@type timestamp: str (MediaWiki format MMDDhhmmss) or None
+@type timestamp: datetime or str (MediaWiki format MMDDhhmmss) or None
 @param skip: Ignore pages edited by the given user
 @type skip: bool
 @param max_revision_depth: It only looks at the last editors given by
 max_revision_depth
 @type max_revision_depth: int or None
+@param show_filtered: Output a message for each page not yielded
+@type show_filtered: bool
 """
 if timestamp:
-ts = pywikibot.Timestamp.fromtimestampformat(timestamp)
-else:
-ts = pywikibot.Timestamp.min
+if isinstance(timestamp, basestring):
+ts = pywikibot.Timestamp.fromtimestampformat(timestamp)
+else:
+ts = timestamp
 for page in generator:
-found = False
-for ed in page.revisions(total=max_revision_depth):
-if ed.timestamp >= ts:
-if username == ed.user:
-found = True
-break
-else:
-break
-if found != bool(skip):  # xor operation
+contribs = page.contributors(total=max_revision_depth, endtime=ts)
+if bool(contribs[username]) is not bool(skip):  # xor operation
 yield page
+elif show_filtered:
+pywikibot.output(u'Skipping %s' % page.title(asLink=True))
 
 
 def CombinedPageGenerator(generators):
diff --git a/scripts/template.py b/scripts/template.py
index 849f50f..3cec5d9 100755
--- a/scripts/template.py
+++ b/scripts/template.py
@@ -356,7 +356,8 @@
 gen = pagegenerators.DuplicateFilterPageGenerator(gen)
 if user:
 gen = pagegenerators.UserE

[MediaWiki-commits] [Gerrit] [PEP257] prescribes the function or method's effect as a com... - change (pywikibot/core)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: [PEP257] prescribes the function or method's effect as a 
command.
..


[PEP257] prescribes the function or method's effect as a command.

Change-Id: Iced61ca4e26154bf5ea958a62ff1a4d8334113f5
---
M pywikibot/bot.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Ricordisamoa: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/pywikibot/bot.py b/pywikibot/bot.py
index 61b9ab0..489ed80 100644
--- a/pywikibot/bot.py
+++ b/pywikibot/bot.py
@@ -628,7 +628,7 @@
 
 def input_yn(question, default=None, automatic_quit=True, force=False):
 """
-Ask the user a yes/no question and returns the answer as a bool.
+Ask the user a yes/no question and return the answer as a bool.
 
 @param question: The question asked without trailing spaces.
 @type question: basestring

-- 
To view, visit https://gerrit.wikimedia.org/r/222736
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iced61ca4e26154bf5ea958a62ff1a4d8334113f5
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: Merlijn van Deen 
Gerrit-Reviewer: Ricordisamoa 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] [PEP257] prescribes the function or method's effect as a com... - change (pywikibot/core)

2015-07-03 Thread Xqt (Code Review)
Xqt has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222736

Change subject: [PEP257] prescribes the function or method's effect as a 
command.
..

[PEP257] prescribes the function or method's effect as a command.

Change-Id: Iced61ca4e26154bf5ea958a62ff1a4d8334113f5
---
M pywikibot/bot.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/36/222736/1

diff --git a/pywikibot/bot.py b/pywikibot/bot.py
index 61b9ab0..489ed80 100644
--- a/pywikibot/bot.py
+++ b/pywikibot/bot.py
@@ -628,7 +628,7 @@
 
 def input_yn(question, default=None, automatic_quit=True, force=False):
 """
-Ask the user a yes/no question and returns the answer as a bool.
+Ask the user a yes/no question and return the answer as a bool.
 
 @param question: The question asked without trailing spaces.
 @type question: basestring

-- 
To view, visit https://gerrit.wikimedia.org/r/222736
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iced61ca4e26154bf5ea958a62ff1a4d8334113f5
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] archivebot: consistent handling of on-site configuration errors - change (pywikibot/core)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: archivebot: consistent handling of on-site configuration errors
..


archivebot: consistent handling of on-site configuration errors

All ending of a run on a page will cause a sleep, with a configurable duration.

Previously a normal return from run() causes a 10-sec sleep,
while an exception causes no sleep and a stack trace will be printed.

Change-Id: I2cbb4026e331d0e23e07c1c8aef344ca194d
---
M scripts/archivebot.py
1 file changed, 21 insertions(+), 8 deletions(-)

Approvals:
  John Vandenberg: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/scripts/archivebot.py b/scripts/archivebot.py
index 1e82623..37ca904 100755
--- a/scripts/archivebot.py
+++ b/scripts/archivebot.py
@@ -112,12 +112,17 @@
 ZERO = datetime.timedelta(0)
 
 
-class MalformedConfigError(pywikibot.Error):
+class ArchiveBotSiteConfigError(pywikibot.Error):
+
+"""There is an error originated by archivebot's on-site configuration."""
+
+
+class MalformedConfigError(ArchiveBotSiteConfigError):
 
 """There is an error in the configuration template."""
 
 
-class MissingConfigError(pywikibot.Error):
+class MissingConfigError(ArchiveBotSiteConfigError):
 
 """
 The config is missing in the header.
@@ -131,7 +136,7 @@
 """Invalid specification of archiving algorithm."""
 
 
-class ArchiveSecurityError(pywikibot.Error):
+class ArchiveSecurityError(ArchiveBotSiteConfigError):
 
 """
 Page title is not a valid archive of page being archived.
@@ -473,7 +478,7 @@
 else:
 raise MissingConfigError(u'Missing or malformed template')
 if not self.get_attr('algo', ''):
-raise MissingConfigError(u'Missing algo')
+raise MissingConfigError('Missing argument "algo" in template')
 
 def feed_archive(self, archive, thread, max_archive_size, params=None):
 """Feed the thread to one of the archives.
@@ -554,8 +559,9 @@
 rx = re.compile(r'\{\{%s\s*?\n.*?\n\}\}'
 % (template_title_regex(self.tpl).pattern), 
re.DOTALL)
 if not rx.search(self.page.header):
-pywikibot.error("Couldn't find the template in the header")
-return
+raise MalformedConfigError(
+"Couldn't find the template in the header"
+)
 
 pywikibot.output(u'Archiving %d thread(s).' % 
self.archived_threads)
 # Save the archives first (so that bugs don't cause a loss of data)
@@ -595,6 +601,7 @@
 salt = None
 force = False
 calc = None
+sleep = 10
 args = []
 
 def if_arg_value(arg, name):
@@ -624,6 +631,8 @@
 pagename = v
 for v in if_arg_value(arg, '-namespace'):
 namespace = v
+for v in if_arg_value(arg, '-sleep'):
+sleep = int(v)
 if not arg.startswith('-'):
 args.append(arg)
 
@@ -678,11 +687,15 @@
 try:
 archiver = PageArchiver(pg, a, salt, force)
 archiver.run()
-time.sleep(10)
+except ArchiveBotSiteConfigError as e:
+# no stack trace for errors originated by pages on-site
+pywikibot.error('Missing or malformed template in page %s: %s'
+% (pg, e))
 except Exception:
 pywikibot.error(u'Error occurred while processing page %s' % 
pg)
 pywikibot.exception(tb=True)
-
+finally:
+time.sleep(sleep)
 
 if __name__ == '__main__':
 main()

-- 
To view, visit https://gerrit.wikimedia.org/r/222727
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I2cbb4026e331d0e23e07c1c8aef344ca194d
Gerrit-PatchSet: 3
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Whym 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: Merlijn van Deen 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] DOMPostProcessor: Generate only for the final document - change (mediawiki...parsoid)

2015-07-03 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222735

Change subject: DOMPostProcessor: Generate  only for the final document
..

DOMPostProcessor: Generate  only for the final document

Change-Id: Ide54116ca629e1d9083c053b4e691e6be700ff72
---
M lib/mediawiki.DOMPostProcessor.js
1 file changed, 7 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid 
refs/changes/35/222735/1

diff --git a/lib/mediawiki.DOMPostProcessor.js 
b/lib/mediawiki.DOMPostProcessor.js
index 81db9da..17b4280 100644
--- a/lib/mediawiki.DOMPostProcessor.js
+++ b/lib/mediawiki.DOMPostProcessor.js
@@ -262,6 +262,13 @@
}
}
 
+   // For sub-pipeline documents, we are done.
+   // For the top-level document, we generate  and add it.
+   if (!this.atTopLevel) {
+   this.emit( 'document', document );
+   return;
+   }
+
// add  element if it was missing
if (!document.head) {
document.documentElement.

-- 
To view, visit https://gerrit.wikimedia.org/r/222735
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ide54116ca629e1d9083c053b4e691e6be700ff72
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Add rawcontinue to FetchUserContribsTask - change (apps...wikipedia)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add rawcontinue to FetchUserContribsTask
..


Add rawcontinue to FetchUserContribsTask

Change-Id: I963496a11dd2613eec2f5d4e29f703b2af24d13b
---
M 
wikipedia/src/main/java/org/wikipedia/pagehistory/usercontributions/FetchUserContribsTask.java
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  BearND: Looks good to me, approved
  jenkins-bot: Verified



diff --git 
a/wikipedia/src/main/java/org/wikipedia/pagehistory/usercontributions/FetchUserContribsTask.java
 
b/wikipedia/src/main/java/org/wikipedia/pagehistory/usercontributions/FetchUserContribsTask.java
index 61c6541..e45b6cf 100644
--- 
a/wikipedia/src/main/java/org/wikipedia/pagehistory/usercontributions/FetchUserContribsTask.java
+++ 
b/wikipedia/src/main/java/org/wikipedia/pagehistory/usercontributions/FetchUserContribsTask.java
@@ -38,6 +38,7 @@
 .param("list", "usercontribs")
 .param("uclimit", String.valueOf(numberToFetch))
 .param("ucuser", username)
+.param("rawcontinue", "1")
 .param("ucprop", "title|timestamp|comment|sizediff");
 if (queryContinue != null) {
 builder.param("ucstart", queryContinue);

-- 
To view, visit https://gerrit.wikimedia.org/r/222013
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I963496a11dd2613eec2f5d4e29f703b2af24d13b
Gerrit-PatchSet: 3
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Sniedzielski 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Hygiene: add testAll* Gradle tasks - change (apps...wikipedia)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Hygiene: add testAll* Gradle tasks
..


Hygiene: add testAll* Gradle tasks

Add testAll* Gradle tasks that execute both JVM JUnit and Android
instrumentation tests per variant.

Change-Id: I75e660991225b6a09c7a94d61f51bf124e357f76
---
M config/quality.gradle
1 file changed, 27 insertions(+), 0 deletions(-)

Approvals:
  BearND: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/config/quality.gradle b/config/quality.gradle
index 330096b..dba1d02 100644
--- a/config/quality.gradle
+++ b/config/quality.gradle
@@ -13,3 +13,30 @@
 
 classpath = configurations.compile
 }
+
+// --- testAll tasks ---
+// These tasks execute both JVM JUnit and Android instrumentation tests (per 
variant).
+
+def addTestAllTask = { testAllName, jvmJUnitName, androidInstrumentationName ->
+def testAllTask = task (testAllName) {
+// Run JVM JUnit tests and Android instrumentation tests.
+dependsOn ([jvmJUnitName, androidInstrumentationName])
+}
+
+// JVM JUnit tests execute quickest and should be attempted prior to 
Android instrumentation tests.
+testAllTask.shouldRunAfter jvmJUnitName
+}
+
+// Add testAll tasks for each build variant.
+android.applicationVariants.all { variant ->
+def variantName = variant.name.capitalize()
+def testAllName = "testAll${variantName}"
+def jvmJUnitName = "test${variantName}"
+def androidInstrumentationName = "connectedAndroidTest${variantName}"
+
+addTestAllTask(testAllName, jvmJUnitName, androidInstrumentationName)
+}
+
+// Add testAll task for all configurations.
+addTestAllTask('testAll', 'test', 'connectedAndroidTest')
+// --- /testAll ---
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/222062
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I75e660991225b6a09c7a94d61f51bf124e357f76
Gerrit-PatchSet: 3
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Niedzielski 
Gerrit-Reviewer: BearND 
Gerrit-Reviewer: Brion VIBBER 
Gerrit-Reviewer: Dbrant 
Gerrit-Reviewer: Mholloway 
Gerrit-Reviewer: Niedzielski 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Fix "talk" and "contribs" links in results for prefix search - change (labs...guc)

2015-07-03 Thread Krinkle (Code Review)
Krinkle has submitted this change and it was merged.

Change subject: Fix "talk" and "contribs" links in results for prefix search
..


Fix "talk" and "contribs" links in results for prefix search

Follows-up beb5d5b.

They used "user" search instead of "rev_user_text" for the link,
so it pointed to "User_talk:JohnD%" instead of "User_talk:JohnDoe".

Change-Id: Ibc8136b1afa239cb0b62cb6d6ef67f031825c334
---
M lb/wikicontribs.php
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Krinkle: Verified; Looks good to me, approved



diff --git a/lb/wikicontribs.php b/lb/wikicontribs.php
index 7e381b9..345f6f0 100644
--- a/lb/wikicontribs.php
+++ b/lb/wikicontribs.php
@@ -311,8 +311,8 @@
 if ($this->options['isPrefixPattern']) {
 $item[] = 'rev_user_text}")).'">'
 . htmlspecialchars($rc->rev_user_text).''
-. ' (user}")).'">talk |
 '
-. 'user}")).'"
 title="Special:Contributions">contribs)';
+. ' (rev_user_text}")).'">talk |
 '
+. 'rev_user_text}")).'"
 title="Special:Contributions">contribs)';
 $item[] = '. .';
 }
 // Minor edit

-- 
To view, visit https://gerrit.wikimedia.org/r/222732
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibc8136b1afa239cb0b62cb6d6ef67f031825c334
Gerrit-PatchSet: 1
Gerrit-Project: labs/tools/guc
Gerrit-Branch: master
Gerrit-Owner: Krinkle 
Gerrit-Reviewer: Krinkle 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use Site with i18n.tw* - change (pywikibot/core)

2015-07-03 Thread John Vandenberg (Code Review)
John Vandenberg has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222734

Change subject: Use Site with i18n.tw*
..

Use Site with i18n.tw*

Change-Id: I5758346c20b6da33ac40aa3ad62ef74490bb5aca
---
M scripts/catall.py
M scripts/category_redirect.py
M scripts/commonscat.py
M scripts/redirect.py
4 files changed, 12 insertions(+), 12 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/34/222734/1

diff --git a/scripts/catall.py b/scripts/catall.py
index 4998c93..cc065e0 100755
--- a/scripts/catall.py
+++ b/scripts/catall.py
@@ -78,7 +78,7 @@
 pllist.append(pywikibot.Page(site, cattitle))
 page.put_async(textlib.replaceCategoryLinks(page.get(), pllist,
 site=page.site),
-   summary=i18n.twtranslate(site.code, 'catall-changing'))
+   summary=i18n.twtranslate(site, 'catall-changing'))
 
 
 def main(*args):
diff --git a/scripts/category_redirect.py b/scripts/category_redirect.py
index 7860d67..6f0378f 100755
--- a/scripts/category_redirect.py
+++ b/scripts/category_redirect.py
@@ -96,9 +96,9 @@
 self.dbl_redir_comment = 'category_redirect-fix-double'
 self.maint_comment = 'category_redirect-comment'
 self.edit_request_text = i18n.twtranslate(
-self.site.code, 'category_redirect-edit-request') + u'\n'
+self.site, 'category_redirect-edit-request') + u'\n'
 self.edit_request_item = i18n.twtranslate(
-self.site.code, 'category_redirect-edit-request-item')
+self.site, 'category_redirect-edit-request-item')
 
 def get_cat_title(self):
 """Specify the category title."""
@@ -215,7 +215,7 @@
 softredirect template.
 """
 pywikibot.output("Checking hard-redirect category pages.")
-comment = i18n.twtranslate(self.site.code, self.redir_comment)
+comment = i18n.twtranslate(self.site, self.redir_comment)
 
 # generator yields all hard redirect pages in namespace 14
 for page in pagegenerators.PreloadingGenerator(
@@ -303,7 +303,7 @@
 
 self.check_hard_redirect()
 
-comment = i18n.twtranslate(self.site.code, self.move_comment)
+comment = i18n.twtranslate(self.site, self.move_comment)
 counts = {}
 nonemptypages = []
 redircat = pywikibot.Category(pywikibot.Link(self.cat_title, 
self.site))
@@ -405,7 +405,7 @@
 newtext = newtext + oldtext.strip()
 try:
 cat.text = newtext
-cat.save(i18n.twtranslate(self.site.code,
+cat.save(i18n.twtranslate(self.site,
   self.dbl_redir_comment))
 except pywikibot.Error as e:
 self.log_text.append("** Failed: %s" % e)
@@ -436,7 +436,7 @@
 self.log_text.sort()
 self.problems.sort()
 newredirs.sort()
-comment = i18n.twtranslate(self.site.code, self.maint_comment)
+comment = i18n.twtranslate(self.site, self.maint_comment)
 self.log_page.text = (u"\n== %i-%02i-%02iT%02i:%02i:%02iZ ==\n"
   % time.gmtime()[:6] +
   u'\n'.join(self.log_text) +
diff --git a/scripts/commonscat.py b/scripts/commonscat.py
index 64b6b12..2289005 100755
--- a/scripts/commonscat.py
+++ b/scripts/commonscat.py
@@ -365,7 +365,7 @@
 if self.getOption('summary'):
 comment = self.getOption('summary')
 else:
-comment = i18n.twtranslate(page.site.code,
+comment = i18n.twtranslate(page.site,
'commonscat-msg_change',
{'oldcat': oldcat, 'newcat': newcat})
 
diff --git a/scripts/redirect.py b/scripts/redirect.py
index f50e183..e2b53ad 100755
--- a/scripts/redirect.py
+++ b/scripts/redirect.py
@@ -603,17 +603,17 @@
 targetPage.title(withSection=False))
 content = content_page.get(get_redirect=True)
 if i18n.twhas_key(
-targetPage.site.lang,
+targetPage.site,
 'redirect-broken-redirect-template') and \
-i18n.twhas_key(targetPage.site.lang,
+i18n.twhas_key(targetPage.site,
'redirect-remove-loop'):
 pywikibot.output(u"Tagging redirect for deletion")
 # Delete the two redirects
 content = i18n.twtranslate(
-targetPage.site.lang,
+targetPage.site,
 'redirect-broken-redirect-template'
 ) + "\n"

[MediaWiki-commits] [Gerrit] Load jQuery and Bootstrap from cdnjs mirror - change (labs...lists)

2015-07-03 Thread Ricordisamoa (Code Review)
Ricordisamoa has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222733

Change subject: Load jQuery and Bootstrap from cdnjs mirror
..

Load jQuery and Bootstrap from cdnjs mirror

"the CDNJS one is certainly faster than /static was":
https://lists.wikimedia.org/pipermail/labs-l/2015-June/003764.html

Change-Id: I6b1ecb4ae0f6edc71b91bdd74fe391f855241140
---
M app/views/layout.blade.php
1 file changed, 3 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/tools/lists 
refs/changes/33/222733/1

diff --git a/app/views/layout.blade.php b/app/views/layout.blade.php
index 1c5e7c9..db65924 100644
--- a/app/views/layout.blade.php
+++ b/app/views/layout.blade.php
@@ -4,7 +4,7 @@
 
 Lists Project - @yield('title')
 
-
+
 
   body {
 padding-top: 50px;
@@ -13,8 +13,8 @@
 color: #2a6496;
   }
 
-   
-
+   
+
   
   
 

-- 
To view, visit https://gerrit.wikimedia.org/r/222733
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I6b1ecb4ae0f6edc71b91bdd74fe391f855241140
Gerrit-PatchSet: 1
Gerrit-Project: labs/tools/lists
Gerrit-Branch: master
Gerrit-Owner: Ricordisamoa 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Fix "talk" and "contribs" links in results for prefix search - change (labs...guc)

2015-07-03 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222732

Change subject: Fix "talk" and "contribs" links in results for prefix search
..

Fix "talk" and "contribs" links in results for prefix search

Follows-up beb5d5b.

They used "user" search instead of "rev_user_text" for the link,
so it pointed to "User_talk:JohnD%" instead of "User_talk:JohnDoe".

Change-Id: Ibc8136b1afa239cb0b62cb6d6ef67f031825c334
---
M lb/wikicontribs.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/labs/tools/guc 
refs/changes/32/222732/1

diff --git a/lb/wikicontribs.php b/lb/wikicontribs.php
index 7e381b9..345f6f0 100644
--- a/lb/wikicontribs.php
+++ b/lb/wikicontribs.php
@@ -311,8 +311,8 @@
 if ($this->options['isPrefixPattern']) {
 $item[] = 'rev_user_text}")).'">'
 . htmlspecialchars($rc->rev_user_text).''
-. ' (user}")).'">talk |
 '
-. 'user}")).'"
 title="Special:Contributions">contribs)';
+. ' (rev_user_text}")).'">talk |
 '
+. 'rev_user_text}")).'"
 title="Special:Contributions">contribs)';
 $item[] = '. .';
 }
 // Minor edit

-- 
To view, visit https://gerrit.wikimedia.org/r/222732
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibc8136b1afa239cb0b62cb6d6ef67f031825c334
Gerrit-PatchSet: 1
Gerrit-Project: labs/tools/guc
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] robots: Disallow xenon/logs and xenon/svgs - change (performance/docroot)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: robots: Disallow xenon/logs and xenon/svgs
..


robots: Disallow xenon/logs and xenon/svgs

Change-Id: I78a7207f79b1eeba8cb93ab1fd8f9f39efe102fa
---
A public_html/robots.txt
1 file changed, 3 insertions(+), 0 deletions(-)

Approvals:
  Krinkle: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/public_html/robots.txt b/public_html/robots.txt
new file mode 100644
index 000..ae45e84
--- /dev/null
+++ b/public_html/robots.txt
@@ -0,0 +1,3 @@
+User-Agent: *
+Disallow: /xenon/logs/
+Disallow: /xenon/svgs/

-- 
To view, visit https://gerrit.wikimedia.org/r/222731
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I78a7207f79b1eeba8cb93ab1fd8f9f39efe102fa
Gerrit-PatchSet: 1
Gerrit-Project: performance/docroot
Gerrit-Branch: master
Gerrit-Owner: Krinkle 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] robots: Disallow xenon/logs and xenon/svgs - change (performance/docroot)

2015-07-03 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222731

Change subject: robots: Disallow xenon/logs and xenon/svgs
..

robots: Disallow xenon/logs and xenon/svgs

Change-Id: I78a7207f79b1eeba8cb93ab1fd8f9f39efe102fa
---
A public_html/robots.txt
1 file changed, 3 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/performance/docroot 
refs/changes/31/222731/1

diff --git a/public_html/robots.txt b/public_html/robots.txt
new file mode 100644
index 000..ae45e84
--- /dev/null
+++ b/public_html/robots.txt
@@ -0,0 +1,3 @@
+User-Agent: *
+Disallow: /xenon/logs/
+Disallow: /xenon/svgs/

-- 
To view, visit https://gerrit.wikimedia.org/r/222731
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I78a7207f79b1eeba8cb93ab1fd8f9f39efe102fa
Gerrit-PatchSet: 1
Gerrit-Project: performance/docroot
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Fix missing message in Skin.js license generation - change (mediawiki...MobileFrontend)

2015-07-03 Thread Florianschmidtwelzow (Code Review)
Florianschmidtwelzow has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222730

Change subject: Fix missing message in Skin.js license generation
..

Fix missing message in Skin.js license generation

mobile-frontend-editor-terms-link is used in Skin.js, bjt is loaded in other 
modules only.
fox it by loading it in Skin.js module only.

Change-Id: I1234137330632392f7843aaf600a5d5dcaeeeb30
---
M includes/Resources.php
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend 
refs/changes/30/222730/1

diff --git a/includes/Resources.php b/includes/Resources.php
index f5ebd24..d92732a 100644
--- a/includes/Resources.php
+++ b/includes/Resources.php
@@ -516,6 +516,8 @@
// icons.js
'mobile-frontend-loading-message',
'mobile-frontend-console-recruit',
+   // Skin.js
+   'mobile-frontend-editor-terms-link',
),
'styles' => array(
'resources/mobile.startup/panel.less',
@@ -663,7 +665,6 @@
'mobile-frontend-editor-keep-editing',
'mobile-frontend-editor-licensing',
'mobile-frontend-editor-licensing-with-terms',
-   'mobile-frontend-editor-terms-link',
'mobile-frontend-editor-placeholder',
'mobile-frontend-editor-placeholder-new-page',
'mobile-frontend-editor-summary',
@@ -814,7 +815,6 @@
'mobile-frontend-editor-cancel-confirm',
'mobile-frontend-editor-error',
'mobile-frontend-editor-error-conflict',
-   'mobile-frontend-editor-terms-link',
),
),
 

-- 
To view, visit https://gerrit.wikimedia.org/r/222730
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I1234137330632392f7843aaf600a5d5dcaeeeb30
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Florianschmidtwelzow 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] navtiming: Replace page with link to Grafana dashboard - change (performance/docroot)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: navtiming: Replace page with link to Grafana dashboard
..


navtiming: Replace page with link to Grafana dashboard

Change-Id: Iecddf964e886304aeeb733303f17ce7cce947850
---
M public_html/index.html
D public_html/navtiming/index.html
D public_html/src/navtiming.js
3 files changed, 1 insertion(+), 401 deletions(-)

Approvals:
  Krinkle: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/public_html/index.html b/public_html/index.html
index 6a9c5e1..69ce6d4 100644
--- a/public_html/index.html
+++ b/public_html/index.html
@@ -38,7 +38,7 @@
   
 Metrics
 Flame Graphs
-Navigation Timing
+https://grafana.wikimedia.org/#/dashboard/db/navigation-timing";>Navigation
 Timing
   
 
   
diff --git a/public_html/navtiming/index.html b/public_html/navtiming/index.html
deleted file mode 100644
index 5c47f35..000
--- a/public_html/navtiming/index.html
+++ /dev/null
@@ -1,44 +0,0 @@
-
-
-  
-  Navigation Timing — Wikimedia Performance
-  
-  
-.perf-container {
-  min-height: 400px;
-}
-.perf-container label {
-  font-weight: normal;
-}
-.perf-container .pull-right {
-  clear: right;
-}
-.footer {
-  margin-top: 40px;
-  background-color: #f5f5f5;
-  padding: 20px 0;
-}
-  
-  https://www.wikimedia.org/static/favicon/wmf.ico";>
-  
-
-  
-Performance
-
-  
-Metrics
-Flame Graphs
-Navigation Timing
-  
-
-  
-
-
-
-  
-More information at https://wikitech.wikimedia.org/wiki/Performance";>https://wikitech.wikimedia.org/wiki/Performance.
-https://www.wikimedia.org";>https://www.wikimedia.org/static/images/wikimedia-button.png"; 
srcset="https://www.wikimedia.org/static/images/wikimedia-button-2x.png 2x" 
width="88" height="31" alt="Wikimedia Foundation">
-  
-
-
-
diff --git a/public_html/src/navtiming.js b/public_html/src/navtiming.js
deleted file mode 100644
index 52aa097..000
--- a/public_html/src/navtiming.js
+++ /dev/null
@@ -1,356 +0,0 @@
-/**
- * Dashboard for Navigation Timing metrics from Graphite.
- *
- * See .
- *
- * Copyright 2015 Timo Tijhof 
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/*global $ */
-( function () {
-   var conf, state, ui;
-
-   /**
-* @param {string...} Target property
-*/
-   function GraphiteTarget() {
-   var target = [].join.call( arguments, '.' );
-
-   function quote( str ) {
-   return '"' + str + '"';
-   }
-
-   function apply( funcName, args ) {
-   args = args.length ? ',' + [].join.call( args, ',' ) : 
'';
-   target = funcName + '(' + target + args + ')';
-   }
-
-   function call( funcName ) {
-   apply( funcName, [].slice.call( arguments, 1 ) );
-   }
-
-   function factory( funcName ) {
-   return function () {
-   apply( funcName, arguments );
-   return this;
-   };
-   }
-
-   this.aliasByNode = factory( 'aliasByNode' );
-   this.dashed = factory( 'dashed' );
-   this.lineWidth = factory( 'lineWidth' );
-   this.drawAsInfinite = factory( 'drawAsInfinite' );
-
-   this.alias = function ( newName ) {
-   call( 'alias', quote( newName ) );
-   return this;
-   };
-
-   this.movingMedian = function ( windowSize ) {
-   windowSize = $.isNumeric( windowSize ) ? windowSize : 
quote( windowSize );
-   call( 'movingMedian', windowSize );
-   return this;
-   };
-
-   this.color = function ( theColor ) {
-   call( 'color', quote( theColor ) );
-   return this;
-   };
-
-   this.toString = function () {
-   return target;
-   };
-   }
-
-   function getDeployTargets

[MediaWiki-commits] [Gerrit] Replace navtiming page with link to Grafana dashboard - change (performance/docroot)

2015-07-03 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222729

Change subject: Replace navtiming page with link to Grafana dashboard
..

Replace navtiming page with link to Grafana dashboard

Change-Id: Iecddf964e886304aeeb733303f17ce7cce947850
---
M public_html/index.html
D public_html/navtiming/index.html
D public_html/src/navtiming.js
3 files changed, 1 insertion(+), 401 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/performance/docroot 
refs/changes/29/222729/1

diff --git a/public_html/index.html b/public_html/index.html
index 6a9c5e1..69ce6d4 100644
--- a/public_html/index.html
+++ b/public_html/index.html
@@ -38,7 +38,7 @@
   
 Metrics
 Flame Graphs
-Navigation Timing
+https://grafana.wikimedia.org/#/dashboard/db/navigation-timing";>Navigation
 Timing
   
 
   
diff --git a/public_html/navtiming/index.html b/public_html/navtiming/index.html
deleted file mode 100644
index 5c47f35..000
--- a/public_html/navtiming/index.html
+++ /dev/null
@@ -1,44 +0,0 @@
-
-
-  
-  Navigation Timing — Wikimedia Performance
-  
-  
-.perf-container {
-  min-height: 400px;
-}
-.perf-container label {
-  font-weight: normal;
-}
-.perf-container .pull-right {
-  clear: right;
-}
-.footer {
-  margin-top: 40px;
-  background-color: #f5f5f5;
-  padding: 20px 0;
-}
-  
-  https://www.wikimedia.org/static/favicon/wmf.ico";>
-  
-
-  
-Performance
-
-  
-Metrics
-Flame Graphs
-Navigation Timing
-  
-
-  
-
-
-
-  
-More information at https://wikitech.wikimedia.org/wiki/Performance";>https://wikitech.wikimedia.org/wiki/Performance.
-https://www.wikimedia.org";>https://www.wikimedia.org/static/images/wikimedia-button.png"; 
srcset="https://www.wikimedia.org/static/images/wikimedia-button-2x.png 2x" 
width="88" height="31" alt="Wikimedia Foundation">
-  
-
-
-
diff --git a/public_html/src/navtiming.js b/public_html/src/navtiming.js
deleted file mode 100644
index 52aa097..000
--- a/public_html/src/navtiming.js
+++ /dev/null
@@ -1,356 +0,0 @@
-/**
- * Dashboard for Navigation Timing metrics from Graphite.
- *
- * See .
- *
- * Copyright 2015 Timo Tijhof 
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/*global $ */
-( function () {
-   var conf, state, ui;
-
-   /**
-* @param {string...} Target property
-*/
-   function GraphiteTarget() {
-   var target = [].join.call( arguments, '.' );
-
-   function quote( str ) {
-   return '"' + str + '"';
-   }
-
-   function apply( funcName, args ) {
-   args = args.length ? ',' + [].join.call( args, ',' ) : 
'';
-   target = funcName + '(' + target + args + ')';
-   }
-
-   function call( funcName ) {
-   apply( funcName, [].slice.call( arguments, 1 ) );
-   }
-
-   function factory( funcName ) {
-   return function () {
-   apply( funcName, arguments );
-   return this;
-   };
-   }
-
-   this.aliasByNode = factory( 'aliasByNode' );
-   this.dashed = factory( 'dashed' );
-   this.lineWidth = factory( 'lineWidth' );
-   this.drawAsInfinite = factory( 'drawAsInfinite' );
-
-   this.alias = function ( newName ) {
-   call( 'alias', quote( newName ) );
-   return this;
-   };
-
-   this.movingMedian = function ( windowSize ) {
-   windowSize = $.isNumeric( windowSize ) ? windowSize : 
quote( windowSize );
-   call( 'movingMedian', windowSize );
-   return this;
-   };
-
-   this.color = function ( theColor ) {
-   call( 'color', quote( theColor ) );
-   return this;
-   };
-
-   this.toString = function () {
-   return target;
-   };
- 

[MediaWiki-commits] [Gerrit] navtiming: Shuffle input fields to take up less space - change (performance/docroot)

2015-07-03 Thread Krinkle (Code Review)
Krinkle has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222728

Change subject: navtiming: Shuffle input fields to take up less space
..

navtiming: Shuffle input fields to take up less space

* Move platform to the right column.
* Turn checkboxes in a single row.

Change-Id: I5d87729deaed8482197747c5eee009bf14ec0d66
---
M public_html/navtiming/index.html
M public_html/src/navtiming.js
2 files changed, 10 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/performance/docroot 
refs/changes/28/222728/1

diff --git a/public_html/navtiming/index.html b/public_html/navtiming/index.html
index 8659a06..5c47f35 100644
--- a/public_html/navtiming/index.html
+++ b/public_html/navtiming/index.html
@@ -8,9 +8,11 @@
   min-height: 400px;
 }
 .perf-container label {
-  display: block;
   font-weight: normal;
 }
+.perf-container .pull-right {
+  clear: right;
+}
 .footer {
   margin-top: 40px;
   background-color: #f5f5f5;
diff --git a/public_html/src/navtiming.js b/public_html/src/navtiming.js
index 61d3b1b..52aa097 100644
--- a/public_html/src/navtiming.js
+++ b/public_html/src/navtiming.js
@@ -219,7 +219,7 @@
state.platform = this.value;
renderSurface();
} );
-   $output.append( $( 'Platform: ' 
).append( inputs.platform ) );
+   $output.append( $( 'Platform: 
' ).append( inputs.platform ) );
 
inputs.range = ui.createSelect( conf.range, state.range 
)
.on( 'change', function () {
@@ -230,14 +230,14 @@
}
renderSurface();
} );
-   $output.append( $( 'Range: ' ).append( 
inputs.range ) );
+   $output.append( $( 'Range: 
' ).append( inputs.range ) );
 
inputs.step = ui.createSelect( conf.step, state.step )
.on( 'change', function () {
state.step = this.value;
renderSurface();
} );
-   $output.append( $( 'Moving median: ' 
).append( inputs.step ) );
+   $output.append( $( 'Moving 
median: ' ).append( inputs.step ) );
 
inputs.user = $( '' )
.prop( 'checked', state.user )
@@ -247,15 +247,16 @@
state.user = Number( this.checked );
renderSurface();
} );
-   $output.append( $( 'Display user groups: 
' ).append( inputs.user ) );
-
inputs.deploys = $( '' )
.prop( 'checked', state.deploys )
.on( 'change', function () {
state.deploys = Number( this.checked );
renderSurface();
} );
-   $output.append( $( 'Show deployments: ' 
).append( inputs.deploys ) );
+   $output.append( $( '' 
).append(
+   $( ' Show user 
groups' ).prepend( inputs.user ),
+   $( ' Show 
deploys' ).prepend( inputs.deploys )
+   ) );
 
// Initial rendering
renderSurface( 'initial' );

-- 
To view, visit https://gerrit.wikimedia.org/r/222728
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5d87729deaed8482197747c5eee009bf14ec0d66
Gerrit-PatchSet: 1
Gerrit-Project: performance/docroot
Gerrit-Branch: master
Gerrit-Owner: Krinkle 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] navtiming: Shuffle input fields to take up less space - change (performance/docroot)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: navtiming: Shuffle input fields to take up less space
..


navtiming: Shuffle input fields to take up less space

* Move platform to the right column.
* Turn checkboxes in a single row.

Change-Id: I5d87729deaed8482197747c5eee009bf14ec0d66
---
M public_html/navtiming/index.html
M public_html/src/navtiming.js
2 files changed, 10 insertions(+), 7 deletions(-)

Approvals:
  Krinkle: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/public_html/navtiming/index.html b/public_html/navtiming/index.html
index 8659a06..5c47f35 100644
--- a/public_html/navtiming/index.html
+++ b/public_html/navtiming/index.html
@@ -8,9 +8,11 @@
   min-height: 400px;
 }
 .perf-container label {
-  display: block;
   font-weight: normal;
 }
+.perf-container .pull-right {
+  clear: right;
+}
 .footer {
   margin-top: 40px;
   background-color: #f5f5f5;
diff --git a/public_html/src/navtiming.js b/public_html/src/navtiming.js
index 61d3b1b..52aa097 100644
--- a/public_html/src/navtiming.js
+++ b/public_html/src/navtiming.js
@@ -219,7 +219,7 @@
state.platform = this.value;
renderSurface();
} );
-   $output.append( $( 'Platform: ' 
).append( inputs.platform ) );
+   $output.append( $( 'Platform: 
' ).append( inputs.platform ) );
 
inputs.range = ui.createSelect( conf.range, state.range 
)
.on( 'change', function () {
@@ -230,14 +230,14 @@
}
renderSurface();
} );
-   $output.append( $( 'Range: ' ).append( 
inputs.range ) );
+   $output.append( $( 'Range: 
' ).append( inputs.range ) );
 
inputs.step = ui.createSelect( conf.step, state.step )
.on( 'change', function () {
state.step = this.value;
renderSurface();
} );
-   $output.append( $( 'Moving median: ' 
).append( inputs.step ) );
+   $output.append( $( 'Moving 
median: ' ).append( inputs.step ) );
 
inputs.user = $( '' )
.prop( 'checked', state.user )
@@ -247,15 +247,16 @@
state.user = Number( this.checked );
renderSurface();
} );
-   $output.append( $( 'Display user groups: 
' ).append( inputs.user ) );
-
inputs.deploys = $( '' )
.prop( 'checked', state.deploys )
.on( 'change', function () {
state.deploys = Number( this.checked );
renderSurface();
} );
-   $output.append( $( 'Show deployments: ' 
).append( inputs.deploys ) );
+   $output.append( $( '' 
).append(
+   $( ' Show user 
groups' ).prepend( inputs.user ),
+   $( ' Show 
deploys' ).prepend( inputs.deploys )
+   ) );
 
// Initial rendering
renderSurface( 'initial' );

-- 
To view, visit https://gerrit.wikimedia.org/r/222728
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5d87729deaed8482197747c5eee009bf14ec0d66
Gerrit-PatchSet: 1
Gerrit-Project: performance/docroot
Gerrit-Branch: master
Gerrit-Owner: Krinkle 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] archivebot: standardized handling of on-site configuration e... - change (pywikibot/core)

2015-07-03 Thread Whym (Code Review)
Whym has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222727

Change subject: archivebot: standardized handling of on-site configuration 
errors
..

archivebot: standardized handling of on-site configuration errors

All ending of a run on a page will cause a sleep, with a configurable duration.

Previously a normal return from run() causes a 10-sec sleep,
while an exception causes no sleep and a stack trace will be printed.

Change-Id: I2cbb4026e331d0e23e07c1c8aef344ca194d
---
M scripts/archivebot.py
1 file changed, 18 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/27/222727/1

diff --git a/scripts/archivebot.py b/scripts/archivebot.py
index 1e82623..3199e39 100755
--- a/scripts/archivebot.py
+++ b/scripts/archivebot.py
@@ -112,12 +112,17 @@
 ZERO = datetime.timedelta(0)
 
 
-class MalformedConfigError(pywikibot.Error):
+class ArchiveBotSiteConfigError(pywikibot.Error):
+
+"""There is an error originated by archivebot's on-site configuration."""
+
+
+class MalformedConfigError(ArchiveBotSiteConfigError):
 
 """There is an error in the configuration template."""
 
 
-class MissingConfigError(pywikibot.Error):
+class MissingConfigError(ArchiveBotSiteConfigError):
 
 """
 The config is missing in the header.
@@ -131,7 +136,7 @@
 """Invalid specification of archiving algorithm."""
 
 
-class ArchiveSecurityError(pywikibot.Error):
+class ArchiveSecurityError(ArchiveBotSiteConfigError):
 
 """
 Page title is not a valid archive of page being archived.
@@ -473,7 +478,7 @@
 else:
 raise MissingConfigError(u'Missing or malformed template')
 if not self.get_attr('algo', ''):
-raise MissingConfigError(u'Missing algo')
+raise MissingConfigError(u'Missing argument "algo" in template')
 
 def feed_archive(self, archive, thread, max_archive_size, params=None):
 """Feed the thread to one of the archives.
@@ -554,8 +559,7 @@
 rx = re.compile(r'\{\{%s\s*?\n.*?\n\}\}'
 % (template_title_regex(self.tpl).pattern), 
re.DOTALL)
 if not rx.search(self.page.header):
-pywikibot.error("Couldn't find the template in the header")
-return
+raise MalformedConfigError("Couldn't find the template in the 
header")
 
 pywikibot.output(u'Archiving %d thread(s).' % 
self.archived_threads)
 # Save the archives first (so that bugs don't cause a loss of data)
@@ -595,6 +599,7 @@
 salt = None
 force = False
 calc = None
+sleep = 10
 args = []
 
 def if_arg_value(arg, name):
@@ -624,6 +629,8 @@
 pagename = v
 for v in if_arg_value(arg, '-namespace'):
 namespace = v
+for v in if_arg_value(arg, '-sleep'):
+sleep = int(v)
 if not arg.startswith('-'):
 args.append(arg)
 
@@ -678,11 +685,14 @@
 try:
 archiver = PageArchiver(pg, a, salt, force)
 archiver.run()
-time.sleep(10)
+except ArchiveBotSiteConfigError as e:
+# no stack trace for errors originated by pages on-site
+pywikibot.error(u'Missing or malformed template in page %s: 
%s' % (pg, e))
 except Exception:
 pywikibot.error(u'Error occurred while processing page %s' % 
pg)
 pywikibot.exception(tb=True)
-
+finally:
+time.sleep(sleep)
 
 if __name__ == '__main__':
 main()

-- 
To view, visit https://gerrit.wikimedia.org/r/222727
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2cbb4026e331d0e23e07c1c8aef344ca194d
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Whym 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] ApiAddStudents: Use ApiBase::PARAM_ISMULTI - change (mediawiki...EducationProgram)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: ApiAddStudents: Use ApiBase::PARAM_ISMULTI
..


ApiAddStudents: Use ApiBase::PARAM_ISMULTI

Change-Id: Idb6aed82eadf0c6e3389bbba7978ffa0cf347d99
---
M i18n/en.json
M includes/api/ApiAddStudents.php
2 files changed, 3 insertions(+), 3 deletions(-)

Approvals:
  Anomie: Looks good to me, but someone else must approve
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/i18n/en.json b/i18n/en.json
index 4755712..9a9be42 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -721,7 +721,7 @@
"ep-online-add-notification-title-email-subject": "You have been 
{{GENDER:$1|added}} as an online volunteer to $2 by $1.",
"ep-online-add-notification-title-email-body": "You have been 
{{GENDER:$1|added}} as an online volunteer to $2 by $1.",
"apihelp-addstudents-description": "Add multiple students to a course.",
-   "apihelp-addstudents-param-studentusernames": "The usernames of the 
students to add to the course, separated by a \"|\".",
+   "apihelp-addstudents-param-studentusernames": "The usernames of the 
students to add to the course.",
"apihelp-addstudents-param-courseid": "The ID of the course to which 
the students should be added/removed.",
"apihelp-addstudents-example-1": "Add three students to a course",
"apihelp-deleteeducation-description": "Delete Education Program 
objects.",
diff --git a/includes/api/ApiAddStudents.php b/includes/api/ApiAddStudents.php
index bb27c4f..0f34d37 100644
--- a/includes/api/ApiAddStudents.php
+++ b/includes/api/ApiAddStudents.php
@@ -44,7 +44,7 @@
array(
'action' => 'query',
'list' => 'users',
-   'ususers' => $params['studentusernames'] )
+   'ususers' => implode( '|', 
$params['studentusernames'] ) )
);
 
$api = new \ApiMain( $apiParams );
@@ -155,7 +155,7 @@
'studentusernames' => array(
ApiBase::PARAM_TYPE => 'string',
ApiBase::PARAM_REQUIRED => true,
-   /** @todo Why is this not 
ApiBase::PARAM_ISMULTI? */
+   ApiBase::PARAM_ISMULTI => true,
),
'courseid' => array(
ApiBase::PARAM_TYPE => 'integer',

-- 
To view, visit https://gerrit.wikimedia.org/r/171003
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Idb6aed82eadf0c6e3389bbba7978ffa0cf347d99
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/EducationProgram
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: AndyRussG 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Fix compatibility with MW 1.22, PHP 5.4 and Firefox 26 - change (mediawiki...Drafts)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Fix compatibility with MW 1.22, PHP 5.4 and Firefox 26
..


Fix compatibility with MW 1.22, PHP 5.4 and Firefox 26

Corrections needed for the Drafts extension to work in newer environments.

PHP 5.4:
- Parameter passed by reference for the new button

MediaWiki 1.22:
- addHandler is deprecated, bind event handlers with jQuery instead

Firefox 26:
- Save prevented on the draft button

Change-Id: Idc8376ffe3e39851c71298b1306cd6b4e0665628
---
M Drafts.hooks.php
M modules/ext.Drafts.js
2 files changed, 7 insertions(+), 14 deletions(-)

Approvals:
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Drafts.hooks.php b/Drafts.hooks.php
index 0097b2c..21a4a17 100644
--- a/Drafts.hooks.php
+++ b/Drafts.hooks.php
@@ -180,7 +180,7 @@
 * EditPageBeforeEditButtons hook
 * Add draft saving controls
 */
-   public static function onEditPageBeforeEditButtons( EditPage $editpage, 
$buttons, &$tabindex ) {
+   public static function onEditPageBeforeEditButtons( EditPage $editpage, 
&$buttons, &$tabindex ) {
global $egDraftsAutoSaveWait, $egDraftsAutoSaveTimeout, 
$egDraftsAutoSaveInputBased;
 
$context = $editpage->getArticle()->getContext();
diff --git a/modules/ext.Drafts.js b/modules/ext.Drafts.js
index 11d38c0..d761ed5 100644
--- a/modules/ext.Drafts.js
+++ b/modules/ext.Drafts.js
@@ -62,7 +62,8 @@
/**
 * Sends draft data to server to be saved
 */
-   this.save = function() {
+   this.save = function( event ) {
+   event.preventDefault();
// Checks if a save is already taking place
if (state === 'saving') {
// Exits function immediately
@@ -143,20 +144,12 @@
// Check to see that the form and controls exist
if ( form && form.wpDraftSave ) {
// Handle manual draft saving through clicking the save 
draft button
-   addHandler( form.wpDraftSave, 'click', self.save );
+   $j( form.wpDraftSave ).on( 'click', self.save );
// Handle keeping track of state by watching for 
changes to fields
-   addHandler( form.wpTextbox1, 'keypress', self.change );
-   addHandler( form.wpTextbox1, 'keyup', self.change );
-   addHandler( form.wpTextbox1, 'keydown', self.change );
-   addHandler( form.wpTextbox1, 'paste', self.change );
-   addHandler( form.wpTextbox1, 'cut', self.change );
-   addHandler( form.wpSummary, 'keypress', self.change );
-   addHandler( form.wpSummary, 'keyup', self.change );
-   addHandler( form.wpSummary, 'keydown', self.change );
-   addHandler( form.wpSummary, 'paste', self.change );
-   addHandler( form.wpSummary, 'cut', self.change );
+   $j( form.wpTextbox1 ).on( 'keypress keyup keydown paste 
cut', self.change );
+   $j( form.wpSummary ).on( 'keypress keyup keydown paste 
cut', self.change );
if ( form.wpMinoredit ) {
-   addHandler( form.wpMinoredit, 'change', 
self.change );
+   $j( form.wpMinoredit ).on( 'change', 
self.change );
}
// Gets configured specific values
configuration = {

-- 
To view, visit https://gerrit.wikimedia.org/r/105200
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Idc8376ffe3e39851c71298b1306cd6b4e0665628
Gerrit-PatchSet: 6
Gerrit-Project: mediawiki/extensions/Drafts
Gerrit-Branch: master
Gerrit-Owner: Gomoko 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Qgil 
Gerrit-Reviewer: Trevor Parscal 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Get rid of 'mediawiki.api.edit' dependency - change (mediawiki...WikiLove)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Get rid of 'mediawiki.api.edit' dependency
..


Get rid of 'mediawiki.api.edit' dependency

Change-Id: I6a2462e63e1c6495cc91784ac6c0dfc5e2d842f7
---
M WikiLove.php
M resources/ext.wikiLove.core.js
2 files changed, 1 insertion(+), 2 deletions(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikiLove.php b/WikiLove.php
index 2ce3db0..558c2f3 100644
--- a/WikiLove.php
+++ b/WikiLove.php
@@ -279,7 +279,6 @@
),
'dependencies' => array(
'mediawiki.api',
-   'mediawiki.api.edit',
'ext.wikiLove.defaultOptions',
'jquery.ui.dialog',
'mediawiki.ui.button',
diff --git a/resources/ext.wikiLove.core.js b/resources/ext.wikiLove.core.js
index 395a906..de5c1b1 100644
--- a/resources/ext.wikiLove.core.js
+++ b/resources/ext.wikiLove.core.js
@@ -661,7 +661,7 @@
if ( email ) {
sendData.email = email;
}
-   api.postWithEditToken( sendData )
+   api.postWithToken( 'edit', sendData )
.done( function ( data ) {
wikiLoveNumberAttempted++;
if ( wikiLoveNumberAttempted === 
targets.length ) {

-- 
To view, visit https://gerrit.wikimedia.org/r/222061
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6a2462e63e1c6495cc91784ac6c0dfc5e2d842f7
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: Yuvipanda 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Move SiteNoticeAfter hook to separate file - change (mediawiki...DismissableSiteNotice)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Move SiteNoticeAfter hook to separate file
..


Move SiteNoticeAfter hook to separate file

Change-Id: If1a928e522ac9cb420d33d83070255bc74922cf4
---
A DismissableSiteNotice.hooks.php
M DismissableSiteNotice.php
2 files changed, 49 insertions(+), 42 deletions(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/DismissableSiteNotice.hooks.php b/DismissableSiteNotice.hooks.php
new file mode 100644
index 000..86a739b
--- /dev/null
+++ b/DismissableSiteNotice.hooks.php
@@ -0,0 +1,47 @@
+getUser()->isLoggedIn() ) {
+   // Cookie value consists of two parts
+   $major = (int) $wgMajorSiteNoticeID;
+   $minor = (int) $skin->msg( 'sitenotice_id' 
)->inContentLanguage()->text();
+
+   $out = $skin->getOutput();
+   $out->addModules( 'ext.dismissableSiteNotice' );
+   $out->addJsConfigVars( 'wgSiteNoticeId', 
"$major.$minor" );
+
+   $notice = Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice' ),
+   Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice-close' ),
+   $skin->msg( 'sitenotice_close-brackets' 
)
+   ->rawParams(
+   Html::element( 'a', 
array( 'href' => '#' ), $skin->msg( 'sitenotice_close' )->text() )
+   )
+   ->escaped()
+   ) .
+   Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice-body' ), $notice )
+   );
+   }
+
+   if ( $skin->getUser()->isAnon() ) {
+   // Hide the sitenotice from search engines (see bug 
9209 comment 4)
+   // XXX: Does this actually work?
+   $notice = Html::inlineScript( Xml::encodeJsCall( 
'document.write', array( $notice ) ) );
+   }
+
+   return true;
+   }
+}
diff --git a/DismissableSiteNotice.php b/DismissableSiteNotice.php
index a1415e3..afad56c 100644
--- a/DismissableSiteNotice.php
+++ b/DismissableSiteNotice.php
@@ -33,6 +33,7 @@
 );
 
 $wgMessagesDirs['DismissableSiteNotice'] = __DIR__ . '/i18n';
+$wgAutoloadClasses['DismissableSiteNoticeHooks'] = __DIR__ . 
'/DismissableSiteNotice.hooks.php';
 
 $wgResourceModules['ext.dismissableSiteNotice'] = array(
'localBasePath' => __DIR__ . '/modules',
@@ -47,48 +48,7 @@
'position' => 'top',
 );
 
-/**
- * @param string $notice
- * @param Skin $skin
- * @return bool true
- */
-$wgHooks['SiteNoticeAfter'][] = function( &$notice, $skin ) {
-   global $wgMajorSiteNoticeID, $wgDismissableSiteNoticeForAnons;
-
-   if ( !$notice ) {
-   return true;
-   }
-
-   // Dismissal for anons is configurable
-   if ( $wgDismissableSiteNoticeForAnons || $skin->getUser()->isLoggedIn() 
) {
-   // Cookie value consists of two parts
-   $major = (int) $wgMajorSiteNoticeID;
-   $minor = (int) $skin->msg( 'sitenotice_id' 
)->inContentLanguage()->text();
-
-   $out = $skin->getOutput();
-   $out->addModules( 'ext.dismissableSiteNotice' );
-   $out->addJsConfigVars( 'wgSiteNoticeId', "$major.$minor" );
-
-   $notice = Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice' ),
-   Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice-close' ),
-   $skin->msg( 'sitenotice_close-brackets' )
-   ->rawParams(
-   Html::element( 'a', array( 'href' => 
'#' ), $skin->msg( 'sitenotice_close' )->text() )
-   )
-   ->escaped()
-   ) .
-   Html::rawElement( 'div', array( 'class' => 
'mw-dismissable-notice-body' ), $notice )
-   );
-   }
-
-   if ( $skin->getUser()->isAnon() ) {
-   // Hide the sitenotice from search engines (see bug 9209 
comment 4)
-   // XXX: Does this actually work?
-   $notice = Html::inlineScript( Xml::encodeJsCall( 
'document.write', array( $notice ) ) );
-   }
-
-   return true;
-};
+$wgHooks['SiteNoticeAfter'][] = 
'DismissableSiteNoticeHooks::onSiteNoticeAfter';
 
 // Default settings
 $wgMajorSiteNoticeID = 1;

-- 
To view, visit https://gerrit.wikimedia.org/r/194040
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If1a928e522ac9cb420d33d83070255bc74922cf4
Gerrit

[MediaWiki-commits] [Gerrit] Remove unused globals - change (mediawiki...Campaigns)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove unused globals
..


Remove unused globals

Change-Id: Iac4e12aa7869cadecf27d92c97aeba6777c75009
---
M Campaigns.hooks.php
1 file changed, 2 insertions(+), 3 deletions(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Campaigns.hooks.php b/Campaigns.hooks.php
index 6c73821..746a7e5 100644
--- a/Campaigns.hooks.php
+++ b/Campaigns.hooks.php
@@ -2,7 +2,6 @@
 
 class CampaignsHooks {
public static function onUserCreateForm( &$template ) {
-   global $wgCookiePrefix;
$maxCampaignLen = 40;
 
$skin = $template->getSkin();
@@ -27,7 +26,7 @@
}
 
public static function onAddNewAccount( $user, $byEmail ) {
-   global $wgEventLoggingSchemaRevs, $wgRequest, $wgUser, 
$wgCookiePrefix;
+   global $wgRequest, $wgUser, $wgCookiePrefix;
 
$userId = $user->getId();
$creatorUserId = $wgUser->getId();
@@ -74,4 +73,4 @@
 
return true;
}
-}
\ No newline at end of file
+}

-- 
To view, visit https://gerrit.wikimedia.org/r/194018
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iac4e12aa7869cadecf27d92c97aeba6777c75009
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Campaigns
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: AndyRussG 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: Spage 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Revert "Force 'Transfer-Encoding: Chunked' header on 404 res... - change (operations/mediawiki-config)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Revert "Force 'Transfer-Encoding: Chunked' header on 404 
responses"
..


Revert "Force 'Transfer-Encoding: Chunked' header on 404 responses"

This reverts commit 1af04f81542a496026050edd9bd71592b455b1d8.

Change-Id: I4ddb97d0a82939d88038218fcae1a2b4fc18994f
---
M w/404.php
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/w/404.php b/w/404.php
index b5087ed..5922274 100644
--- a/w/404.php
+++ b/w/404.php
@@ -1,5 +1,4 @@
 https://gerrit.wikimedia.org/r/222726
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4ddb97d0a82939d88038218fcae1a2b4fc18994f
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Revert "Force 'Transfer-Encoding: Chunked' header on 404 res... - change (operations/mediawiki-config)

2015-07-03 Thread Ori.livneh (Code Review)
Ori.livneh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222726

Change subject: Revert "Force 'Transfer-Encoding: Chunked' header on 404 
responses"
..

Revert "Force 'Transfer-Encoding: Chunked' header on 404 responses"

This reverts commit 1af04f81542a496026050edd9bd71592b455b1d8.

Change-Id: I4ddb97d0a82939d88038218fcae1a2b4fc18994f
---
M w/404.php
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/26/222726/1

diff --git a/w/404.php b/w/404.php
index b5087ed..5922274 100644
--- a/w/404.php
+++ b/w/404.php
@@ -1,5 +1,4 @@
 https://gerrit.wikimedia.org/r/222726
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4ddb97d0a82939d88038218fcae1a2b4fc18994f
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use upstream codesniffer 2.3.3 - change (mediawiki...codesniffer)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Use upstream codesniffer 2.3.3
..


Use upstream codesniffer 2.3.3

Change-Id: I78cad4734417d74fd81ed2dd83ec6c07479e9115
---
M composer.json
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Reedy: Looks good to me, approved
  Paladox: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/composer.json b/composer.json
index ab7d680..c395aec 100644
--- a/composer.json
+++ b/composer.json
@@ -5,7 +5,7 @@
"homepage": 
"https://www.mediawiki.org/wiki/Manual:Coding_conventions/PHP";,
"license": "GPL-2.0+",
"require": {
-   "squizlabs/php_codesniffer": "2.3.0"
+   "squizlabs/php_codesniffer": "2.3.3"
},
"require-dev": {
"jakub-onderka/php-parallel-lint": "0.8.*",

-- 
To view, visit https://gerrit.wikimedia.org/r/220399
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I78cad4734417d74fd81ed2dd83ec6c07479e9115
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/tools/codesniffer
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Addshore 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check that tables exist before trying to update them in User... - change (mediawiki...Translate)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Check that tables exist before trying to update them in 
UserMerge hooks
..


Check that tables exist before trying to update them in UserMerge hooks

Bug: T104739
Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
(cherry picked from commit c76428dde346776ce51df5f12028df6398cd330a)
---
M TranslateHooks.php
1 file changed, 22 insertions(+), 12 deletions(-)

Approvals:
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/TranslateHooks.php b/TranslateHooks.php
index 6816808..8356af5 100644
--- a/TranslateHooks.php
+++ b/TranslateHooks.php
@@ -534,6 +534,12 @@
return true;
}
 
+   /**
+* Any user of this list should make sure that the tables
+* actually exist, since they may be optional
+*
+* @var array
+*/
private static $userMergeTables = array(
'translate_stash' => 'ts_user',
'translate_reviews' => 'trr_user',
@@ -552,13 +558,15 @@
// Update the non-duplicate rows, we'll just delete
// the duplicate ones later
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->update(
-   $table,
-   array( $field => $newUser->getId() ),
-   array( $field => $oldUser->getId() ),
-   __METHOD__,
-   array( 'IGNORE' )
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->update(
+   $table,
+   array( $field => $newUser->getId() ),
+   array( $field => $oldUser->getId() ),
+   __METHOD__,
+   array( 'IGNORE' )
+   );
+   }
}
 
return true;
@@ -575,11 +583,13 @@
 
// Delete any remaining rows that didn't get merged
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->delete(
-   $table,
-   array( $field => $oldUser->getId() ),
-   __METHOD__
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->delete(
+   $table,
+   array( $field => $oldUser->getId() ),
+   __METHOD__
+   );
+   }
}
 
return true;

-- 
To view, visit https://gerrit.wikimedia.org/r/222725
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check that tables exist before trying to update them in User... - change (mediawiki...Translate)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222725

Change subject: Check that tables exist before trying to update them in 
UserMerge hooks
..

Check that tables exist before trying to update them in UserMerge hooks

Bug: T104739
Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
(cherry picked from commit c76428dde346776ce51df5f12028df6398cd330a)
---
M TranslateHooks.php
1 file changed, 22 insertions(+), 12 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate 
refs/changes/25/222725/1

diff --git a/TranslateHooks.php b/TranslateHooks.php
index 6816808..8356af5 100644
--- a/TranslateHooks.php
+++ b/TranslateHooks.php
@@ -534,6 +534,12 @@
return true;
}
 
+   /**
+* Any user of this list should make sure that the tables
+* actually exist, since they may be optional
+*
+* @var array
+*/
private static $userMergeTables = array(
'translate_stash' => 'ts_user',
'translate_reviews' => 'trr_user',
@@ -552,13 +558,15 @@
// Update the non-duplicate rows, we'll just delete
// the duplicate ones later
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->update(
-   $table,
-   array( $field => $newUser->getId() ),
-   array( $field => $oldUser->getId() ),
-   __METHOD__,
-   array( 'IGNORE' )
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->update(
+   $table,
+   array( $field => $newUser->getId() ),
+   array( $field => $oldUser->getId() ),
+   __METHOD__,
+   array( 'IGNORE' )
+   );
+   }
}
 
return true;
@@ -575,11 +583,13 @@
 
// Delete any remaining rows that didn't get merged
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->delete(
-   $table,
-   array( $field => $oldUser->getId() ),
-   __METHOD__
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->delete(
+   $table,
+   array( $field => $oldUser->getId() ),
+   __METHOD__
+   );
+   }
}
 
return true;

-- 
To view, visit https://gerrit.wikimedia.org/r/222725
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check that tables exist before trying to update them in User... - change (mediawiki...Translate)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Check that tables exist before trying to update them in 
UserMerge hooks
..


Check that tables exist before trying to update them in UserMerge hooks

Bug: T104739
Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
---
M TranslateHooks.php
1 file changed, 22 insertions(+), 12 deletions(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/TranslateHooks.php b/TranslateHooks.php
index 6816808..8356af5 100644
--- a/TranslateHooks.php
+++ b/TranslateHooks.php
@@ -534,6 +534,12 @@
return true;
}
 
+   /**
+* Any user of this list should make sure that the tables
+* actually exist, since they may be optional
+*
+* @var array
+*/
private static $userMergeTables = array(
'translate_stash' => 'ts_user',
'translate_reviews' => 'trr_user',
@@ -552,13 +558,15 @@
// Update the non-duplicate rows, we'll just delete
// the duplicate ones later
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->update(
-   $table,
-   array( $field => $newUser->getId() ),
-   array( $field => $oldUser->getId() ),
-   __METHOD__,
-   array( 'IGNORE' )
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->update(
+   $table,
+   array( $field => $newUser->getId() ),
+   array( $field => $oldUser->getId() ),
+   __METHOD__,
+   array( 'IGNORE' )
+   );
+   }
}
 
return true;
@@ -575,11 +583,13 @@
 
// Delete any remaining rows that didn't get merged
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->delete(
-   $table,
-   array( $field => $oldUser->getId() ),
-   __METHOD__
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->delete(
+   $table,
+   array( $field => $oldUser->getId() ),
+   __METHOD__
+   );
+   }
}
 
return true;

-- 
To view, visit https://gerrit.wikimedia.org/r/222718
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Nikerabbit 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check 'wikilove_log' table exists in UserMerge hooks - change (mediawiki...WikiLove)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Check 'wikilove_log' table exists in UserMerge hooks
..


Check 'wikilove_log' table exists in UserMerge hooks

Bug: T104740
Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
(cherry picked from commit 6fbcb7616ab5724e50ac517a5d02aeb6716da2ea)
---
M WikiLove.hooks.php
1 file changed, 8 insertions(+), 2 deletions(-)

Approvals:
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index cc47c2a..36a298f 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -221,8 +221,14 @@
 * @return bool
 */
public static function onUserMergeAccountFields( array &$updateFields ) 
{
-   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
-   $updateFields[] = array( 'wikilove_log', 'wll_receiver' );
+   global $wgWikiLoveLogging;
+   $dbr = wfGetDB( DB_SLAVE );
+   // FIXME HACK: The extension never actually required the 
'wikilove_log' table
+   // and would suppress db errors if it didn't exist
+   if ( $wgWikiLoveLogging && $dbr->tableExists( 'wikilove_log' ) 
) {
+   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
+   $updateFields[] = array( 'wikilove_log', 'wll_receiver' 
);
+   }
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222724
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check 'wikilove_log' table exists in UserMerge hooks - change (mediawiki...WikiLove)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222724

Change subject: Check 'wikilove_log' table exists in UserMerge hooks
..

Check 'wikilove_log' table exists in UserMerge hooks

Bug: T104740
Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
(cherry picked from commit 6fbcb7616ab5724e50ac517a5d02aeb6716da2ea)
---
M WikiLove.hooks.php
1 file changed, 8 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikiLove 
refs/changes/24/222724/1

diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index cc47c2a..36a298f 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -221,8 +221,14 @@
 * @return bool
 */
public static function onUserMergeAccountFields( array &$updateFields ) 
{
-   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
-   $updateFields[] = array( 'wikilove_log', 'wll_receiver' );
+   global $wgWikiLoveLogging;
+   $dbr = wfGetDB( DB_SLAVE );
+   // FIXME HACK: The extension never actually required the 
'wikilove_log' table
+   // and would suppress db errors if it didn't exist
+   if ( $wgWikiLoveLogging && $dbr->tableExists( 'wikilove_log' ) 
) {
+   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
+   $updateFields[] = array( 'wikilove_log', 'wll_receiver' 
);
+   }
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222724
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove 'wikilove_image_log' from UserMerge hooks, it no long... - change (mediawiki...WikiLove)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove 'wikilove_image_log' from UserMerge hooks, it no longer 
exists
..


Remove 'wikilove_image_log' from UserMerge hooks, it no longer exists

Follows up e8b4d84a1c5c1

Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
(cherry picked from commit 30596ae4a1f887f483e0dc7bcaa222f9caf6bb26)
---
M WikiLove.hooks.php
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index 7aad78b..cc47c2a 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -223,7 +223,6 @@
public static function onUserMergeAccountFields( array &$updateFields ) 
{
$updateFields[] = array( 'wikilove_log', 'wll_sender' );
$updateFields[] = array( 'wikilove_log', 'wll_receiver' );
-   $updateFields[] = array( 'wikilove_image_log', 'wlil_user_id' );
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222723
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove 'wikilove_image_log' from UserMerge hooks, it no long... - change (mediawiki...WikiLove)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222723

Change subject: Remove 'wikilove_image_log' from UserMerge hooks, it no longer 
exists
..

Remove 'wikilove_image_log' from UserMerge hooks, it no longer exists

Follows up e8b4d84a1c5c1

Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
(cherry picked from commit 30596ae4a1f887f483e0dc7bcaa222f9caf6bb26)
---
M WikiLove.hooks.php
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikiLove 
refs/changes/23/222723/1

diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index 7aad78b..cc47c2a 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -223,7 +223,6 @@
public static function onUserMergeAccountFields( array &$updateFields ) 
{
$updateFields[] = array( 'wikilove_log', 'wll_sender' );
$updateFields[] = array( 'wikilove_log', 'wll_receiver' );
-   $updateFields[] = array( 'wikilove_image_log', 'wlil_user_id' );
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222723
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: wmf/1.26wmf12
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check 'wikilove_log' table exists in UserMerge hooks - change (mediawiki...WikiLove)

2015-07-03 Thread Reedy (Code Review)
Reedy has submitted this change and it was merged.

Change subject: Check 'wikilove_log' table exists in UserMerge hooks
..


Check 'wikilove_log' table exists in UserMerge hooks

Bug: T104740
Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
---
M WikiLove.hooks.php
1 file changed, 8 insertions(+), 2 deletions(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index cc47c2a..36a298f 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -221,8 +221,14 @@
 * @return bool
 */
public static function onUserMergeAccountFields( array &$updateFields ) 
{
-   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
-   $updateFields[] = array( 'wikilove_log', 'wll_receiver' );
+   global $wgWikiLoveLogging;
+   $dbr = wfGetDB( DB_SLAVE );
+   // FIXME HACK: The extension never actually required the 
'wikilove_log' table
+   // and would suppress db errors if it didn't exist
+   if ( $wgWikiLoveLogging && $dbr->tableExists( 'wikilove_log' ) 
) {
+   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
+   $updateFields[] = array( 'wikilove_log', 'wll_receiver' 
);
+   }
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222720
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: BryanDavis 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove 'wikilove_image_log' from UserMerge hooks, it no long... - change (mediawiki...WikiLove)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove 'wikilove_image_log' from UserMerge hooks, it no longer 
exists
..


Remove 'wikilove_image_log' from UserMerge hooks, it no longer exists

Follows up e8b4d84a1c5c1

Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
---
M WikiLove.hooks.php
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Reedy: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index 7aad78b..cc47c2a 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -223,7 +223,6 @@
public static function onUserMergeAccountFields( array &$updateFields ) 
{
$updateFields[] = array( 'wikilove_log', 'wll_sender' );
$updateFields[] = array( 'wikilove_log', 'wll_receiver' );
-   $updateFields[] = array( 'wikilove_image_log', 'wlil_user_id' );
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222719
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Alex Monk 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: Reedy 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] [WIP] Database improvements. - change (mediawiki...WikibaseQualityConstraints)

2015-07-03 Thread Soeren.oldag (Code Review)
Soeren.oldag has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222722

Change subject: [WIP] Database improvements.
..

[WIP] Database improvements.

Change-Id: I32dacbde7aef28bf012ca90218d9fb3a7cd703a0
---
M includes/ConstraintRepository.php
M maintenance/UpdateTable.php
M sql/create_wbqc_constraints.sql
3 files changed, 8 insertions(+), 11 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikibaseQualityConstraints
 refs/changes/22/222722/1

diff --git a/includes/ConstraintRepository.php 
b/includes/ConstraintRepository.php
index 000de2c..df66a75 100644
--- a/includes/ConstraintRepository.php
+++ b/includes/ConstraintRepository.php
@@ -51,9 +51,6 @@
);
 
$db = wfGetDB( DB_MASTER );
-   $db->commit( __METHOD__, "flush" );
-   wfWaitForSlaves();
-
return $db->insert( CONSTRAINT_TABLE, $accumulator );
}
 
diff --git a/maintenance/UpdateTable.php b/maintenance/UpdateTable.php
index 8078776..246e1e0 100644
--- a/maintenance/UpdateTable.php
+++ b/maintenance/UpdateTable.php
@@ -51,6 +51,10 @@
$data = fgetcsv( $csvFile );
if ( $data === false || ++$i % $this->mBatchSize === 0 
) {
$constraintRepo->insertBatch( $accumulator );
+
+   wfGetDB( DB_MASTER )->commit( __METHOD__, 
"flush" );
+   wfWaitForSlaves();
+
if ( !$this->isQuiet() ) {
$this->output( "\r\033[K" );
$this->output( "$i rows inserted" );
diff --git a/sql/create_wbqc_constraints.sql b/sql/create_wbqc_constraints.sql
index 7b371c1..22c4640 100755
--- a/sql/create_wbqc_constraints.sql
+++ b/sql/create_wbqc_constraints.sql
@@ -2,11 +2,7 @@
   constraint_guidVARCHAR(255)  PRIMARY KEY,
   pidINT(11)   NOT NULL,
   constraint_type_qid  VARCHAR(255)NOT NULL,
-  constraint_parametersTEXT  DEFAULT 
NULL
-) /*$wgDBTableOptions*/;
-
-CREATE INDEX /*i*/wbqc_constraints_pid_index
-ON /*_*/wbqc_constraints (pid);
-
-CREATE INDEX /*i*/wbqc_constraints_constraint_type_qid_index
-ON /*_*/wbqc_constraints (constraint_type_qid);
\ No newline at end of file
+  constraint_parametersTEXT  DEFAULT 
NULL,
+  PRIMARY KEY ( constraint_guid ),
+  INDEX /*i*/pid ( pid )
+) /*$wgDBTableOptions*/;
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/222722
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I32dacbde7aef28bf012ca90218d9fb3a7cd703a0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikibaseQualityConstraints
Gerrit-Branch: v1
Gerrit-Owner: Soeren.oldag 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Force 'Transfer-Encoding: Chunked' header on 404 responses - change (operations/mediawiki-config)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Force 'Transfer-Encoding: Chunked' header on 404 responses
..


Force 'Transfer-Encoding: Chunked' header on 404 responses

In HHVM, if we do not set this header explicitly, Varnish barfs on the
response.

Change-Id: Iae241141606756823661286b0b65c87feb44d55f
---
M w/404.php
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Ori.livneh: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/w/404.php b/w/404.php
index 5922274..b5087ed 100644
--- a/w/404.php
+++ b/w/404.php
@@ -1,4 +1,5 @@
 https://gerrit.wikimedia.org/r/222721
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iae241141606756823661286b0b65c87feb44d55f
Gerrit-PatchSet: 2
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 
Gerrit-Reviewer: Ori.livneh 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Force 'Transfer-Encoding: Chunked' header on 404 responses - change (operations/mediawiki-config)

2015-07-03 Thread Ori.livneh (Code Review)
Ori.livneh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222721

Change subject: Force 'Transfer-Encoding: Chunked' header on 404 responses
..

Force 'Transfer-Encoding: Chunked' header on 404 responses

In HHVM, if we do not set this header explicitly, Varnish barfs on the
response.

Change-Id: Iae241141606756823661286b0b65c87feb44d55f
---
M w/404.php
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/21/222721/1

diff --git a/w/404.php b/w/404.php
index 5922274..b5087ed 100644
--- a/w/404.php
+++ b/w/404.php
@@ -1,4 +1,5 @@
 https://gerrit.wikimedia.org/r/222721
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iae241141606756823661286b0b65c87feb44d55f
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check 'wikilove_log' table exists in UserMerge hooks - change (mediawiki...WikiLove)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222720

Change subject: Check 'wikilove_log' table exists in UserMerge hooks
..

Check 'wikilove_log' table exists in UserMerge hooks

Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
---
M WikiLove.hooks.php
1 file changed, 8 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikiLove 
refs/changes/20/222720/1

diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index cc47c2a..36a298f 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -221,8 +221,14 @@
 * @return bool
 */
public static function onUserMergeAccountFields( array &$updateFields ) 
{
-   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
-   $updateFields[] = array( 'wikilove_log', 'wll_receiver' );
+   global $wgWikiLoveLogging;
+   $dbr = wfGetDB( DB_SLAVE );
+   // FIXME HACK: The extension never actually required the 
'wikilove_log' table
+   // and would suppress db errors if it didn't exist
+   if ( $wgWikiLoveLogging && $dbr->tableExists( 'wikilove_log' ) 
) {
+   $updateFields[] = array( 'wikilove_log', 'wll_sender' );
+   $updateFields[] = array( 'wikilove_log', 'wll_receiver' 
);
+   }
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222720
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I37216c85850a82aee5e1c7e60331398333a5af1d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove 'wikilove_image_log' from UserMerge hooks, it no long... - change (mediawiki...WikiLove)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222719

Change subject: Remove 'wikilove_image_log' from UserMerge hooks, it no longer 
exists
..

Remove 'wikilove_image_log' from UserMerge hooks, it no longer exists

Follows up e8b4d84a1c5c1

Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
---
M WikiLove.hooks.php
1 file changed, 0 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikiLove 
refs/changes/19/222719/1

diff --git a/WikiLove.hooks.php b/WikiLove.hooks.php
index 7aad78b..cc47c2a 100644
--- a/WikiLove.hooks.php
+++ b/WikiLove.hooks.php
@@ -223,7 +223,6 @@
public static function onUserMergeAccountFields( array &$updateFields ) 
{
$updateFields[] = array( 'wikilove_log', 'wll_sender' );
$updateFields[] = array( 'wikilove_log', 'wll_receiver' );
-   $updateFields[] = array( 'wikilove_image_log', 'wlil_user_id' );
 
return true;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222719
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id8e7f8cf64e9cfc95747a38133fede7ad68c89eb
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikiLove
Gerrit-Branch: master
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Check that tables exist before trying to update them in User... - change (mediawiki...Translate)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222718

Change subject: Check that tables exist before trying to update them in 
UserMerge hooks
..

Check that tables exist before trying to update them in UserMerge hooks

Bug: T104739
Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
---
M TranslateHooks.php
1 file changed, 22 insertions(+), 12 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Translate 
refs/changes/18/222718/1

diff --git a/TranslateHooks.php b/TranslateHooks.php
index 6816808..8356af5 100644
--- a/TranslateHooks.php
+++ b/TranslateHooks.php
@@ -534,6 +534,12 @@
return true;
}
 
+   /**
+* Any user of this list should make sure that the tables
+* actually exist, since they may be optional
+*
+* @var array
+*/
private static $userMergeTables = array(
'translate_stash' => 'ts_user',
'translate_reviews' => 'trr_user',
@@ -552,13 +558,15 @@
// Update the non-duplicate rows, we'll just delete
// the duplicate ones later
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->update(
-   $table,
-   array( $field => $newUser->getId() ),
-   array( $field => $oldUser->getId() ),
-   __METHOD__,
-   array( 'IGNORE' )
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->update(
+   $table,
+   array( $field => $newUser->getId() ),
+   array( $field => $oldUser->getId() ),
+   __METHOD__,
+   array( 'IGNORE' )
+   );
+   }
}
 
return true;
@@ -575,11 +583,13 @@
 
// Delete any remaining rows that didn't get merged
foreach ( self::$userMergeTables as $table => $field ) {
-   $dbw->delete(
-   $table,
-   array( $field => $oldUser->getId() ),
-   __METHOD__
-   );
+   if ( $dbw->tableExists( $table ) ) {
+   $dbw->delete(
+   $table,
+   array( $field => $oldUser->getId() ),
+   __METHOD__
+   );
+   }
}
 
return true;

-- 
To view, visit https://gerrit.wikimedia.org/r/222718
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4d530c5233d79c1c5592b574314174c2bbb44abc
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Enable the AstroPay audit module - change (wikimedia...civicrm-buildkit)

2015-07-03 Thread Awight (Code Review)
Awight has submitted this change and it was merged.

Change subject: Enable the AstroPay audit module
..


Enable the AstroPay audit module

FIXME: This config file should be contained in the crm repo, so test
provisioning can be changed with code.

Bug: T104718
Change-Id: I80ddc57fe601724ef7adb73a075416fa09420cda
---
M app/config/wmff/install.sh
1 file changed, 1 insertion(+), 0 deletions(-)

Approvals:
  Cdentinger: Looks good to me, approved
  Awight: Verified



diff --git a/app/config/wmff/install.sh b/app/config/wmff/install.sh
index ef44bfd..0ddb340 100644
--- a/app/config/wmff/install.sh
+++ b/app/config/wmff/install.sh
@@ -40,6 +40,7 @@
   civicrm \
   toolbar \
   garland \
+  astropay_audit \
   contribution_audit \
   contribution_tracking \
   environment_indicator \

-- 
To view, visit https://gerrit.wikimedia.org/r/222716
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I80ddc57fe601724ef7adb73a075416fa09420cda
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/civicrm-buildkit
Gerrit-Branch: master
Gerrit-Owner: Awight 
Gerrit-Reviewer: AndyRussG 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Cdentinger 
Gerrit-Reviewer: Ejegg 
Gerrit-Reviewer: Katie Horn 
Gerrit-Reviewer: Ssmith 
Gerrit-Reviewer: XenoRyet 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] comments and refund test for square - change (wikimedia...crm)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: comments and refund test for square
..


comments and refund test for square

Change-Id: Ida1a616ad1f7903c9d199019bc73caddd4959115
---
M sites/all/modules/offline2civicrm/SquareFile.php
M sites/all/modules/offline2civicrm/tests/SquareFileTest.php
2 files changed, 46 insertions(+), 1 deletion(-)

Approvals:
  Awight: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/sites/all/modules/offline2civicrm/SquareFile.php 
b/sites/all/modules/offline2civicrm/SquareFile.php
index 73126a5..9c5b9de 100644
--- a/sites/all/modules/offline2civicrm/SquareFile.php
+++ b/sites/all/modules/offline2civicrm/SquareFile.php
@@ -43,6 +43,8 @@
 }
 
 protected function parseRow ( $data ) {
+// completed and refunded are the only rows that mean anything.
+// the others as of now are pending, canceled, and deposited.
 if (! in_array($data['Status'], array('Completed', 'Refunded'))) {
 throw new IgnoredRowException;
 }
@@ -85,7 +87,10 @@
 
 protected function handleDuplicate( $duplicate ) {
 if ( $this->refundLastTransaction ) {
-// square updates the existing row with the "Refunded" status and 
resends
+// override the default behavior which is skip all duplicates.
+// square sends refund rows with the same transaction ID as
+// the parent contribution.  so in this case we still want to
+// ignore the sent row but also insert a wmf approved refund.
 wmf_civicrm_mark_refund(
 $duplicate[0]['id'],
 'refund',
diff --git a/sites/all/modules/offline2civicrm/tests/SquareFileTest.php 
b/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
index 8f0279b..3d7e257 100644
--- a/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
+++ b/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
@@ -46,4 +46,44 @@
 $this->stripSourceData( $output );
 $this->assertEquals( $expected_normal, $output );
 }
+
+function testParseRow_Refund() {
+$data = array(
+'Currency' => 'USD',
+'Email Address' => 'm...@gmail.com',
+'Gross Amount' => '$35.00',
+'Name' => 'Max Normal',
+'Net Amount' => '$0',
+'Payment ID' => 'abc123',
+'Phone Number' => '33',
+'Status' => 'Refunded',
+'Timestamp' => 1426129877,
+'Zip Code' => '94103',
+);
+$expected_normal = array(
+'contact_source' => 'check',
+'contact_type' => 'Individual',
+'contribution_type' => 'cash',
+'country' => 'US',
+'currency' => 'USD',
+'date' => 1426129877,
+'email' => 'm...@gmail.com',
+'first_name' => 'Max',
+'full_name' => 'Max Normal',
+'gateway' => 'square',
+'gateway_status_raw' => 'Refunded',
+'gateway_txn_id' => 'abc123',
+'gross' => '35.00',
+'last_name' => 'Normal',
+'net' => '35.00',
+'phone' => '33',
+'postal_code' => '94103',
+);
+
+$importer = new SquareFileProbe( "no URI" );
+$output = $importer->_parseRow( $data );
+
+$this->stripSourceData( $output );
+$this->assertEquals( $expected_normal, $output );
+}
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/222717
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ida1a616ad1f7903c9d199019bc73caddd4959115
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Cdentinger 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: Ejegg 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] comments and refund test for square - change (wikimedia...crm)

2015-07-03 Thread Cdentinger (Code Review)
Cdentinger has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222717

Change subject: comments and refund test for square
..

comments and refund test for square

Change-Id: Ida1a616ad1f7903c9d199019bc73caddd4959115
---
M sites/all/modules/offline2civicrm/SquareFile.php
M sites/all/modules/offline2civicrm/tests/SquareFileTest.php
2 files changed, 46 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/17/222717/1

diff --git a/sites/all/modules/offline2civicrm/SquareFile.php 
b/sites/all/modules/offline2civicrm/SquareFile.php
index 73126a5..9c5b9de 100644
--- a/sites/all/modules/offline2civicrm/SquareFile.php
+++ b/sites/all/modules/offline2civicrm/SquareFile.php
@@ -43,6 +43,8 @@
 }
 
 protected function parseRow ( $data ) {
+// completed and refunded are the only rows that mean anything.
+// the others as of now are pending, canceled, and deposited.
 if (! in_array($data['Status'], array('Completed', 'Refunded'))) {
 throw new IgnoredRowException;
 }
@@ -85,7 +87,10 @@
 
 protected function handleDuplicate( $duplicate ) {
 if ( $this->refundLastTransaction ) {
-// square updates the existing row with the "Refunded" status and 
resends
+// override the default behavior which is skip all duplicates.
+// square sends refund rows with the same transaction ID as
+// the parent contribution.  so in this case we still want to
+// ignore the sent row but also insert a wmf approved refund.
 wmf_civicrm_mark_refund(
 $duplicate[0]['id'],
 'refund',
diff --git a/sites/all/modules/offline2civicrm/tests/SquareFileTest.php 
b/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
index 8f0279b..3d7e257 100644
--- a/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
+++ b/sites/all/modules/offline2civicrm/tests/SquareFileTest.php
@@ -46,4 +46,44 @@
 $this->stripSourceData( $output );
 $this->assertEquals( $expected_normal, $output );
 }
+
+function testParseRow_Refund() {
+$data = array(
+'Currency' => 'USD',
+'Email Address' => 'm...@gmail.com',
+'Gross Amount' => '$35.00',
+'Name' => 'Max Normal',
+'Net Amount' => '$0',
+'Payment ID' => 'abc123',
+'Phone Number' => '33',
+'Status' => 'Refunded',
+'Timestamp' => 1426129877,
+'Zip Code' => '94103',
+);
+$expected_normal = array(
+'contact_source' => 'check',
+'contact_type' => 'Individual',
+'contribution_type' => 'cash',
+'country' => 'US',
+'currency' => 'USD',
+'date' => 1426129877,
+'email' => 'm...@gmail.com',
+'first_name' => 'Max',
+'full_name' => 'Max Normal',
+'gateway' => 'square',
+'gateway_status_raw' => 'Refunded',
+'gateway_txn_id' => 'abc123',
+'gross' => '35.00',
+'last_name' => 'Normal',
+'net' => '35.00',
+'phone' => '33',
+'postal_code' => '94103',
+);
+
+$importer = new SquareFileProbe( "no URI" );
+$output = $importer->_parseRow( $data );
+
+$this->stripSourceData( $output );
+$this->assertEquals( $expected_normal, $output );
+}
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/222717
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ida1a616ad1f7903c9d199019bc73caddd4959115
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Cdentinger 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] SpecialAllPages: Fix a few subtle "Previous page" link bugs - change (mediawiki/core)

2015-07-03 Thread PleaseStand (Code Review)
PleaseStand has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222715

Change subject: SpecialAllPages: Fix a few subtle "Previous page" link bugs
..

SpecialAllPages: Fix a few subtle "Previous page" link bugs

* When finding the start of the previous page, exclude redirects if
  "Hide redirects" is checked. Otherwise, if some of the previous 345
  wiki pages were redirects, an equal number of results would be
  repeated when going back.
* Don't select unnecessary rows beyond the start of the previous page.
  At the same time, fix a bug that could cause results close to the
  beginning to be skipped when going back.
* When finding the start of the first page, don't omit ORDER BY for
  MySQL and SQLite.
* Don't suppress the link when the unprefixed title is "0" or similar
  or is numerically equal to the "from" parameter value.

Change-Id: I2cc6958b894afa824a5345871b5a27b01f9fcc73
---
M includes/specials/SpecialAllPages.php
1 file changed, 15 insertions(+), 31 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/15/222715/1

diff --git a/includes/specials/SpecialAllPages.php 
b/includes/specials/SpecialAllPages.php
index 74b1f7b..c8e218c 100644
--- a/includes/specials/SpecialAllPages.php
+++ b/includes/specials/SpecialAllPages.php
@@ -25,6 +25,7 @@
  * Implements Special:Allpages
  *
  * @ingroup SpecialPage
+ * @todo Rewrite using IndexPager
  */
 class SpecialAllPages extends IncludableSpecialPage {
 
@@ -33,7 +34,7 @@
 *
 * @var int $maxPerPage
 */
-   protected $maxPerPage = 345;
+   protected $maxPerPage = 10;
 
/**
 * Determines, which message describes the input field 'nsfrom'.
@@ -191,15 +192,13 @@
list( , $toKey, $to ) = $toList;
 
$dbr = wfGetDB( DB_SLAVE );
-   $conds = array(
-   'page_namespace' => $namespace,
-   'page_title >= ' . $dbr->addQuotes( $fromKey )
-   );
-
+   $filterConds = array( 'page_namespace' => $namespace );
if ( $hideredirects ) {
-   $conds['page_is_redirect'] = 0;
+   $filterConds['page_is_redirect'] = 0;
}
 
+   $conds = $filterConds;
+   $conds[] = 'page_title >= ' . $dbr->addQuotes( $fromKey 
);
if ( $toKey !== "" ) {
$conds[] = 'page_title <= ' . $dbr->addQuotes( 
$toKey );
}
@@ -245,37 +244,22 @@
// First chunk; no previous link.
$prevTitle = null;
} else {
-   # Get the last title from previous chunk
+   # Get the first title from previous chunk
$dbr = wfGetDB( DB_SLAVE );
$res_prev = $dbr->select(
'page',
'page_title',
-   array( 'page_namespace' => $namespace, 
'page_title < ' . $dbr->addQuotes( $from ) ),
+   array_merge( $filterConds, array( 'page_title < 
' . $dbr->addQuotes( $from ) ) ),
__METHOD__,
-   array( 'ORDER BY' => 'page_title DESC',
-   'LIMIT' => $this->maxPerPage, 'OFFSET' 
=> ( $this->maxPerPage - 1 )
-   )
+   array( 'ORDER BY' => 'page_title DESC', 'LIMIT' 
=> $this->maxPerPage )
);
 
-   # Get first title of previous complete chunk
-   if ( $dbr->numrows( $res_prev ) >= $this->maxPerPage ) {
-   $pt = $dbr->fetchObject( $res_prev );
+   if ( $res_prev->numRows() > 0 ) {
+   $res_prev->seek( $res_prev->numRows() - 1 );
+   $pt = $res_prev->fetchObject();
$prevTitle = Title::makeTitle( $namespace, 
$pt->page_title );
} else {
-   # The previous chunk is not complete, need to 
link to the very first title
-   # available in the database
-   $options = array( 'LIMIT' => 1 );
-   if ( !$dbr->implicitOrderby() ) {
-   $options['ORDER BY'] = 'page_title';
-   }
-   $reallyFirstPage_title = $dbr->selectField( 
'page', 'page_title',
-   array( 'page_namespace' => $namespace 
), __METHOD__, $options );
-  

[MediaWiki-commits] [Gerrit] Enable the AstroPay audit module - change (wikimedia...civicrm-buildkit)

2015-07-03 Thread Awight (Code Review)
Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222716

Change subject: Enable the AstroPay audit module
..

Enable the AstroPay audit module

FIXME: This config file should be contained in the crm repo, so test
provisioning can be changed with code.

Bug: T104718
Change-Id: I80ddc57fe601724ef7adb73a075416fa09420cda
---
M app/config/wmff/install.sh
1 file changed, 1 insertion(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/civicrm-buildkit 
refs/changes/16/222716/1

diff --git a/app/config/wmff/install.sh b/app/config/wmff/install.sh
index ef44bfd..0ddb340 100644
--- a/app/config/wmff/install.sh
+++ b/app/config/wmff/install.sh
@@ -40,6 +40,7 @@
   civicrm \
   toolbar \
   garland \
+  astropay_audit \
   contribution_audit \
   contribution_tracking \
   environment_indicator \

-- 
To view, visit https://gerrit.wikimedia.org/r/222716
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I80ddc57fe601724ef7adb73a075416fa09420cda
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/civicrm-buildkit
Gerrit-Branch: master
Gerrit-Owner: Awight 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Push more things into the base class - change (wikimedia...crm)

2015-07-03 Thread Awight (Code Review)
Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222714

Change subject: Push more things into the base class
..

Push more things into the base class

Abstracts how we parse loglines, to support JSON

Bug: T104718
Change-Id: I7fb87d343722c850c2b7131f904af150911e3c20
---
M sites/all/modules/wmf_audit/BaseAuditProcessor.php
M sites/all/modules/wmf_audit/tests/WorldpayAuditTest.php
M sites/all/modules/wmf_audit/worldpay/WorldpayAuditProcessor.php
M sites/all/modules/wmf_civicrm/WmfTransaction.php
4 files changed, 100 insertions(+), 61 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/crm 
refs/changes/14/222714/1

diff --git a/sites/all/modules/wmf_audit/BaseAuditProcessor.php 
b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
index c1ef9f1..a20c479 100644
--- a/sites/all/modules/wmf_audit/BaseAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
@@ -12,15 +12,20 @@
wmf_audit_runtime_options( $options );
 }
 
+/**
+ * Return an object that performs the file parsing.
+ */
+abstract protected function get_audit_parser();
+
 abstract protected function get_log_distilling_grep_string();
 abstract protected function get_log_line_grep_string( $order_id );
-abstract protected function get_log_line_xml_data_nodes();
-abstract protected function get_log_line_xml_outermost_node();
-abstract protected function get_log_line_xml_parent_nodes();
-abstract protected function get_order_id( $transaction );
+abstract protected function parse_log_line( $line );
+// TODO: Move XML stuff into a helper class.
+protected function get_log_line_xml_data_nodes() {}
+protected function get_log_line_xml_outermost_node() {}
+protected function get_log_line_xml_parent_nodes() {}
 abstract protected function get_recon_file_date( $file );
 abstract protected function normalize_and_merge_data( $data, $transaction 
);
-abstract protected function parse_recon_file( $file );
 abstract protected function regex_for_recon();
 
 /**
@@ -195,8 +200,9 @@
  * @return boolean true if it's in there, otherwise false
  */
 protected function main_transaction_exists_in_civi($transaction) {
+  $positive_txn_id = $this->get_parent_order_id( $transaction );
   //go through the transactions and check to see if they're in civi
-  if (wmf_civicrm_get_contributions_from_gateway_id($this->name, 
$transaction['gateway_txn_id']) === false) {
+  if (wmf_civicrm_get_contributions_from_gateway_id($this->name, 
$positive_txn_id) === false) {
return false;
   } else {
return true;
@@ -211,8 +217,9 @@
  * @return boolean true if it's in there, otherwise false
  */
 protected function negative_transaction_exists_in_civi($transaction) {
+  $positive_txn_id = $this->get_parent_order_id( $transaction );
   //go through the transactions and check to see if they're in civi
-  if (wmf_civicrm_get_child_contributions_from_gateway_id($this->name, 
$transaction['gateway_txn_id']) === false) {
+  if (wmf_civicrm_get_child_contributions_from_gateway_id($this->name, 
$positive_txn_id) === false) {
return false;
   } else {
return true;
@@ -560,9 +567,7 @@
'code' => 'MISSING_MANDATORY_DATA',
  );
} else {
- //@TODO: If you ever have a gateway that doesn't communicate 
with xml, this is going to have to be abstracted slightly.
- //Not going to worry about that right now, though.
- $data = $this->get_xml_log_data_by_order_id($order_id, $log);
+ $data = $this->get_log_data_by_order_id($order_id, $log);
}
 
//if we have data at this point, it means we have a match in 
the logs
@@ -945,12 +950,12 @@
  * @return array|boolean The data we sent to the gateway for that order 
id, or
  * false if we can't find it there.
  */
-protected function get_xml_log_data_by_order_id($order_id, $log) {
+protected function get_log_data_by_order_id($order_id, $log) {
   if (!$order_id) {
return false;
   }
 
-  $cmd = 'grep ' . $this->get_log_line_grep_string( $order_id ) . ' ' . 
$log;
+  $cmd = 'grep \'' . $this->get_log_line_grep_string( $order_id ) . '\' ' 
. $log;
   wmf_audit_echo(__FUNCTION__ . ' ' . $cmd, true);
 
   $ret = array();
@@ -970,7 +975,19 @@
$contribution_id = explode(':', $linedata[5]);
$contribution_id = $contribution_id[0];
 
+$raw_data = $this->parse_log_line( $line );
 
+   if (!empty($raw_data)) {
+ $raw_data['contribution_tracking_id'] = $contribution_id;
+ return $raw_data;
+   } else {
+ wmf_audit_log_error("We found a transaction in the logs for 
$order_id, but there's nothing left after we 

[MediaWiki-commits] [Gerrit] WIP: Refactor comment regexp into a constant and reuse every... - change (mediawiki...parsoid)

2015-07-03 Thread Subramanya Sastry (Code Review)
Subramanya Sastry has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222713

Change subject: WIP: Refactor comment regexp into a constant and reuse 
everywhere
..

WIP: Refactor comment regexp into a constant and reuse everywhere

* This indirectly leads to improved documentation.
* Needs sanity check.
* Right now fails tests -- yet to be fixed up.

Change-Id: I92869cf3329ec764248f22f01af212a3d7e47bf9
---
M lib/mediawiki.Util.js
M lib/mediawiki.WikiConfig.js
M lib/wts.SerializerState.js
M lib/wts.TagHandlers.js
M lib/wts.separators.js
5 files changed, 66 insertions(+), 15 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/parsoid 
refs/changes/13/222713/1

diff --git a/lib/mediawiki.Util.js b/lib/mediawiki.Util.js
index fa503b8..c86d356 100644
--- a/lib/mediawiki.Util.js
+++ b/lib/mediawiki.Util.js
@@ -25,6 +25,8 @@
  */
 var Util = {
 
+   COMMENT_REGEXP: //,
+
/**
 * @method
 *
diff --git a/lib/mediawiki.WikiConfig.js b/lib/mediawiki.WikiConfig.js
index 0429ae1..05a5853 100644
--- a/lib/mediawiki.WikiConfig.js
+++ b/lib/mediawiki.WikiConfig.js
@@ -450,7 +450,7 @@
"|",
"__", this.bswRegexp.source, "__",
"|",
-   "",
+   Util.COMMENT_REGEXP.source,
"|",
"\\s",
")*$",
@@ -470,7 +470,7 @@
"|",
"__", this.bswRegexp.source, "__",
"|",
-   "",
+   Util.COMMENT_REGEXP.source,
")*)",
{ flags: "i" }
);
diff --git a/lib/wts.SerializerState.js b/lib/wts.SerializerState.js
index 58fb5cb..60bfa37 100644
--- a/lib/wts.SerializerState.js
+++ b/lib/wts.SerializerState.js
@@ -202,7 +202,7 @@
// Reset separator state
this.sep = {};
// Don't get tripped by newlines in comments!
-   if (sep && /\n/.test(sep.replace(//g, ''))) {
+   if (sep && /\n/.test(sep.replace(new RegExp(Util.COMMENT_REGEXP.source, 
'g'), ''))) {
this.onSOL = true;
}
 
@@ -345,14 +345,24 @@
// If a text node, we have to make sure that the text 
doesn't
// get reparsed as non-text in the wt2html pipeline.
if (pChild && DU.isText(pChild)) {
-   var match = 
res.match(/^((?:|.*?<\/includeonly>)*)([ 
\*#:;{\|!=].*)$/);
+   var solWikitextRE = new RegExp([
+   '^((?:', Util.COMMENT_REGEXP.source,
+   '|',
+   // SSS FIXME: What about onlyinclude 
and noinclude?
+   
/.*?<\/includeonly>/.source,
+   ')*)',
+   /([ \*#:;{\|!=].*)$/.source
+   ].join());
+   var match = res.match(solWikitextRE);
if (match && match[2]) {
if 
(/^([\*#:;]|{\||.*=$)/.test(match[2]) ||
// ! and | chars are harmless 
outside tables
(/^[\|!]/.test(match[2]) && 
this.wikiTableNesting > 0) ||
// indent-pres are suppressed 
inside 
-   (/^ [^\s]/.test(match[2]) && 
!DU.hasAncestorOfName(node, "BLOCKQUOTE"))) {
-   res = 
ConstrainedText.cast((match[1] || "") + "" + match[2][0] + "" 
+ match[2].substring(1), node);
+   (/^ [^\s]/.test(match[2]) && 
!DU.hasAncestorOfName(node, 'BLOCKQUOTE'))) {
+   res = 
ConstrainedText.cast((match[1] || '') +
+   '' + 
match[2][0] + '' +
+   match[2].substring(1), 
node);
}
}
}
@@ -375,7 +385,18 @@
this.sep.lastSourceNode = node;
this.sep.lastSourceSep = this.sep.src;
 
-   if 
(!res.match(/(^|\n)(.*?<\/includeonly>|)*$/))
 {
+   // Update sol flag. Test for
+   // newlines followed by optional includeonly or comments
+   var solRE = new RegExp([
+   /(^|\n)/.source,
+   '(',
+   // SSS FIXME: What about onlyinclude and noinclude?
+   /.*?<\/includeonly>/.source,
+   '|',
+   Util.COMMENT_REGEXP.source,
+   ')*$'
+   ].join());
+   if (!solRE.test(res)) {
this.onSOL 

[MediaWiki-commits] [Gerrit] chmod 644 a few files - change (mediawiki...Echo)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: chmod 644 a few files
..


chmod 644 a few files

Bug: T104721
Change-Id: Iee1ef18d3227807110d4e25f0c48f17907adf8ad
---
M Gemfile
M Hooks.php
M includes/EmailBundler.php
M scripts/generatecss.php
4 files changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Catrope: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Gemfile b/Gemfile
old mode 100755
new mode 100644
diff --git a/Hooks.php b/Hooks.php
old mode 100755
new mode 100644
diff --git a/includes/EmailBundler.php b/includes/EmailBundler.php
old mode 100755
new mode 100644
diff --git a/scripts/generatecss.php b/scripts/generatecss.php
old mode 100755
new mode 100644

-- 
To view, visit https://gerrit.wikimedia.org/r/222629
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iee1ef18d3227807110d4e25f0c48f17907adf8ad
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Echo
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 
Gerrit-Reviewer: Catrope 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 36dac12..e51df12 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 36dac12..e51df12
..


Syncronize VisualEditor: 36dac12..e51df12

Change-Id: Id084fce9d0b2d7ede0ffa5914e04559c1487b413
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index 36dac12..e51df12 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 36dac12958a7a8ed3270fdc1f43a6ca081497f75
+Subproject commit e51df124728b84d25779011f3cb9da96a0b95c50

-- 
To view, visit https://gerrit.wikimedia.org/r/222712
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Id084fce9d0b2d7ede0ffa5914e04559c1487b413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 36dac12..e51df12 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222712

Change subject: Syncronize VisualEditor: 36dac12..e51df12
..

Syncronize VisualEditor: 36dac12..e51df12

Change-Id: Id084fce9d0b2d7ede0ffa5914e04559c1487b413
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/12/222712/1

diff --git a/VisualEditor b/VisualEditor
index 36dac12..e51df12 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 36dac12958a7a8ed3270fdc1f43a6ca081497f75
+Subproject commit e51df124728b84d25779011f3cb9da96a0b95c50

-- 
To view, visit https://gerrit.wikimedia.org/r/222712
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id084fce9d0b2d7ede0ffa5914e04559c1487b413
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove unused dependency - change (mediawiki...VisualEditor)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove unused dependency
..


Remove unused dependency

No longer used now that TitleWidget is upstream.

Change-Id: Ie2a39d1d13a67fd9c1fba5a0040443e7510706af
---
M extension.json
1 file changed, 0 insertions(+), 1 deletion(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extension.json b/extension.json
index 9f92ff7..ad611cf 100644
--- a/extension.json
+++ b/extension.json
@@ -937,7 +937,6 @@
"mediawiki.user",
"mediawiki.util",
"mediawiki.jqueryMsg",
-   "jquery.autoEllipsis",
"jquery.byteLimit",
"mediawiki.skinning.content.parsoid",
"mediawiki.language.specialCharacters",

-- 
To view, visit https://gerrit.wikimedia.org/r/222557
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie2a39d1d13a67fd9c1fba5a0040443e7510706af
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use core dimension widget times separator - change (mediawiki...VisualEditor)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Use core dimension widget times separator
..


Use core dimension widget times separator

For de-duplication, and because trailing whitespace is not allowed.

Bug: T104691
Change-Id: I2e65799daae7e57e6e638b3d6dcf968a6f4582c7
---
M extension.json
M modules/ve-mw/i18n/en.json
M modules/ve-mw/i18n/qqq.json
M modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
4 files changed, 3 insertions(+), 4 deletions(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/extension.json b/extension.json
index a586623..429fe38 100644
--- a/extension.json
+++ b/extension.json
@@ -1094,7 +1094,6 @@
"visualeditor-dialog-media-content-filename",
"visualeditor-dialog-media-content-section",

"visualeditor-dialog-media-content-section-help",
-   "visualeditor-dialog-media-dimensionseparator",
"visualeditor-dialog-media-goback",
"visualeditor-dialog-media-info-artist",
"visualeditor-dialog-media-info-audiofile",
diff --git a/modules/ve-mw/i18n/en.json b/modules/ve-mw/i18n/en.json
index 30ad5ae..0bd5ea3 100644
--- a/modules/ve-mw/i18n/en.json
+++ b/modules/ve-mw/i18n/en.json
@@ -78,7 +78,6 @@
"visualeditor-dialog-media-content-filename": "File name",
"visualeditor-dialog-media-content-section": "Caption",
"visualeditor-dialog-media-content-section-help": "You can use this to 
show a label that shows next to the item for all readers. This is often used to 
explain why the item is relevant to the context in which it is shown. It should 
be succinct and informative.",
-   "visualeditor-dialog-media-dimensionseparator": " × ",
"visualeditor-dialog-media-goback": "Back",
"visualeditor-dialog-media-info-artist": "Uploaded by $1",
"visualeditor-dialog-media-info-audiofile": "Audio file",
diff --git a/modules/ve-mw/i18n/qqq.json b/modules/ve-mw/i18n/qqq.json
index b3a5a51..04fe11b 100644
--- a/modules/ve-mw/i18n/qqq.json
+++ b/modules/ve-mw/i18n/qqq.json
@@ -87,7 +87,6 @@
"visualeditor-dialog-media-content-filename": "Label for the image 
filename.\n{{Identical|Filename}}",
"visualeditor-dialog-media-content-section": "Label for the image 
content sub-section.\n{{Identical|Caption}}",
"visualeditor-dialog-media-content-section-help": "Message displayed as 
contextual help about the caption box to editors in the media editing dialog.",
-   "visualeditor-dialog-media-dimensionseparator": "Label dimensions 
separator in the image size display.{{Optional}}",
"visualeditor-dialog-media-goback": "Label for the button to go back to 
edit settings in the media dialog.\n{{Identical|Go back}}",
"visualeditor-dialog-media-info-artist": "Label for the uploader 
information for the image in the media dialog. $1 - Uploader name.",
"visualeditor-dialog-media-info-audiofile": "Label for denoting an 
audio file for the media info in the media dialog.",
diff --git a/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js 
b/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
index f30bdbc..cd50a11 100644
--- a/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
+++ b/modules/ve-mw/ui/dialogs/ve.ui.MWMediaDialog.js
@@ -493,7 +493,9 @@
.append(
$( '' ).text(
imageinfo.width +
-   ve.msg( 
'visualeditor-dialog-media-dimensionseparator' ) +
+   '\u00a0' +
+   ve.msg( 
'visualeditor-dimensionswidget-times' ) +
+   '\u00a0' +
imageinfo.height +
ve.msg( 
'visualeditor-dimensionswidget-px' )
),

-- 
To view, visit https://gerrit.wikimedia.org/r/222569
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I2e65799daae7e57e6e638b3d6dcf968a6f4582c7
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Esanders 
Gerrit-Reviewer: Jforrester 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 57a86aa..36dac12 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 57a86aa..36dac12
..


Syncronize VisualEditor: 57a86aa..36dac12

Change-Id: I857a603f11ddf70854a473038bbd1e4ef8a43b41
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index 57a86aa..36dac12 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 57a86aa0e2b2903608329c276eb3c6cd3c4c6dc8
+Subproject commit 36dac12958a7a8ed3270fdc1f43a6ca081497f75

-- 
To view, visit https://gerrit.wikimedia.org/r/222711
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I857a603f11ddf70854a473038bbd1e4ef8a43b41
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 57a86aa..36dac12 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222711

Change subject: Syncronize VisualEditor: 57a86aa..36dac12
..

Syncronize VisualEditor: 57a86aa..36dac12

Change-Id: I857a603f11ddf70854a473038bbd1e4ef8a43b41
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/11/222711/1

diff --git a/VisualEditor b/VisualEditor
index 57a86aa..36dac12 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 57a86aa0e2b2903608329c276eb3c6cd3c4c6dc8
+Subproject commit 36dac12958a7a8ed3270fdc1f43a6ca081497f75

-- 
To view, visit https://gerrit.wikimedia.org/r/222711
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I857a603f11ddf70854a473038bbd1e4ef8a43b41
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Add extension.json, empty php entry point - change (mediawiki...MaintenanceShell)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add extension.json, empty php entry point
..


Add extension.json, empty php entry point

Change-Id: I31d31a596f44805f465b6d34b70d6a2f0069a308
---
M MaintenanceShell.php
A extension.json
2 files changed, 62 insertions(+), 51 deletions(-)

Approvals:
  Krinkle: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/MaintenanceShell.php b/MaintenanceShell.php
index 6dd889a..0841966 100644
--- a/MaintenanceShell.php
+++ b/MaintenanceShell.php
@@ -9,54 +9,12 @@
  * @license GNU GPL
  */
 
-$wgExtensionCredits['specialpage'][] = array(
-   'name' => 'MaintenanceShell',
-   'author' => array(
-   '[http://swiftlytilting.com Andrew Fitzgerald]',
-   'Timo Tijhof',
-   ),
-   'url' => 'https://www.mediawiki.org/wiki/Extension:MaintenanceShell',
-   'descriptionmsg' => 'maintenanceshell-desc',
-   'version' => '0.5.0',
-);
-
-
-/* Setup */
-
-$dir = dirname( __FILE__ );
-
-// Register files
-$wgAutoloadClasses['MaintenanceShellHooks'] = $dir . 
'/MaintenanceShell.hooks.php';
-$wgAutoloadClasses['SpecialMaintenanceShell'] = $dir . 
'/includes/SpecialMaintenanceShell.php';
-$wgAutoloadClasses['MaintenanceShellArgumentsParser'] = $dir . 
'/includes/MaintenanceShellArgumentsParser.php';
-$wgMessagesDirs['MaintenanceShell'] = __DIR__ . '/i18n';
-$wgExtensionMessagesFiles['MaintenanceShellAlias'] = $dir . 
'/MaintenanceShell.alias.php';
-
-// Register special pages
-$wgSpecialPages['MaintenanceShell'] = 'SpecialMaintenanceShell';
-
-// Register user rights
-$wgAvailableRights[] = 'maintenanceshell';
-
-// Register hooks
-$wgExtensionFunctions[] = 'MaintenanceShellHooks::onSetup';
-$wgHooks['UnitTestsList'][] = 'MaintenanceShellHooks::onUnitTestsList';
-
-// Register modules
-$wgResourceModules['ext.maintenanceShell'] = array(
-   'scripts' => 'resources/ext.maintenanceShell.js',
-   'styles' => 'resources/ext.maintenanceShell.css',
-   'localBasePath' => $dir,
-   'remoteExtPath' => 'MaintenanceShell',
-   'dependencies' => 'jquery.spinner'
-);
-
-// Not granted to anyone by default.
-// To grant to "developer" group, use:
-// $wgGroupPermissions['developer']['maintenanceshell'] = true;
-// Or create a new user group, use:
-// $wgGroupPermissions['maintainer']['maintenanceshell'] = true;
-
-/* Configuration */
-
-$wgMaintenanceShellPath = false;
+if ( function_exists( 'wfLoadExtension' ) ) {
+   wfLoadExtension( 'MaintenanceShell' );
+   wfWarn(
+   'Deprecated PHP entry point used for MaintenanceShell 
extension. Please use wfLoadExtension instead, ' .
+   'see https://www.mediawiki.org/wiki/Extension_registration for 
more details.'
+   );
+} else {
+   die( 'This version of the MaintenanceShell extension requires MediaWiki 
1.25+' );
+}
diff --git a/extension.json b/extension.json
new file mode 100644
index 000..a968e1b
--- /dev/null
+++ b/extension.json
@@ -0,0 +1,53 @@
+{
+   "name": "MaintenanceShell",
+   "version": "0.5.0",
+   "author": [
+   "[http://swiftlytilting.com Andrew Fitzgerald]",
+   "Timo Tijhof"
+   ],
+   "url": "https://www.mediawiki.org/wiki/Extension:MaintenanceShell";,
+   "descriptionmsg": "maintenanceshell-desc",
+   "type": "specialpage",
+   "AvailableRights": [
+   "maintenanceshell"
+   ],
+   "ExtensionFunctions": [
+   "MaintenanceShellHooks::onSetup"
+   ],
+   "SpecialPages": {
+   "MaintenanceShell": "SpecialMaintenanceShell"
+   },
+   "MessagesDirs": {
+   "MaintenanceShell": [
+   "i18n"
+   ]
+   },
+   "ExtensionMessagesFiles": {
+   "MaintenanceShellAlias": "MaintenanceShell.alias.php"
+   },
+   "AutoloadClasses": {
+   "MaintenanceShellHooks": "MaintenanceShell.hooks.php",
+   "SpecialMaintenanceShell": 
"includes/SpecialMaintenanceShell.php",
+   "MaintenanceShellArgumentsParser": 
"includes/MaintenanceShellArgumentsParser.php"
+   },
+   "ResourceModules": {
+   "ext.maintenanceShell": {
+   "scripts": "resources/ext.maintenanceShell.js",
+   "styles": "resources/ext.maintenanceShell.css",
+   "dependencies": "jquery.spinner"
+   }
+   },
+   "ResourceFileModulePaths": {
+   "localBasePath": "",
+   "remoteExtPath": "MaintenanceShell"
+   },
+   "Hooks": {
+   "UnitTestsList": [
+   "MaintenanceShellHooks::onUnitTestsList"
+   ]
+   },
+   "config": {
+   "MaintenanceShellPath": false
+   },
+   "manifest_version": 1
+}

-- 
To view, visit https://gerrit.wikimedia.org/r/222582
To unsubscribe, 

[MediaWiki-commits] [Gerrit] [WIP] Improve special page UI a little - change (mediawiki...SmiteSpam)

2015-07-03 Thread Polybuildr (Code Review)
Polybuildr has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222710

Change subject: [WIP] Improve special page UI a little
..

[WIP] Improve special page UI a little

Added 'Delete selected' buttons both above and below the table - only
become visible once the table is displayed. Also added "select all" and
"select none".

Change-Id: I4b418c0f7d62ddeba3f3b931d80bd3300a128440
---
M SpecialSmiteSpam.php
M static/js/ext.smitespam.retriever.js
2 files changed, 28 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/SmiteSpam 
refs/changes/10/222710/1

diff --git a/SpecialSmiteSpam.php b/SpecialSmiteSpam.php
index 9793fcc..1433f95 100644
--- a/SpecialSmiteSpam.php
+++ b/SpecialSmiteSpam.php
@@ -54,6 +54,11 @@
)
)
);
+
+   $out->addHTML( '' );
+
+   $out->addHTML( '' );
$out->addHTML( Html::openElement( 'table', array(
'class' => 'wikitable',
'id' => 'smitespam-page-list',
@@ -61,7 +66,7 @@
 
$out->addHTML( Html::closeElement( 'table' ) );
$out->addHTML( '' );
+   . $this->msg( 'smitespam-delete-selected' ) . '" 
style="display:none;">' );
$out->addHTML( Html::closeElement( 'form' ) );
 
$out->addModules( 'ext.SmiteSpam.retriever' );
diff --git a/static/js/ext.smitespam.retriever.js 
b/static/js/ext.smitespam.retriever.js
index 4b1d808..d0d9791 100644
--- a/static/js/ext.smitespam.retriever.js
+++ b/static/js/ext.smitespam.retriever.js
@@ -127,6 +127,28 @@
$( '#displayed-page-number' ).text( 
resultPageToDisplay.getValue() + 1 );
},
displayResults: function () {
+   $( '#smitespam-delete-pages input[type="submit"]' 
).show();
+   var $selectAll = $( '' )
+   .attr( 'href', '#' )
+   .text( 'All' )
+   .on( 'click', function () {
+   $( '#smitespam-page-list 
input[type="checkbox"]' ).each( function () {
+   $( this ).prop( 'checked', true 
).triggerHandler( 'change' );
+   } );
+   } );
+   var $selectNone = $( '' )
+   .attr( 'href', '#' )
+   .text( 'None' )
+   .on( 'click', function () {
+   $( '#smitespam-page-list 
input[type="checkbox"]' ).each( function () {
+   $( this ).prop( 'checked', 
false ).triggerHandler( 'change' );
+   } );
+   } );
+   $( '#smitespam-select-options' ).empty();
+   $( '#smitespam-select-options' ).append( 'Select: ' );
+   $( '#smitespam-select-options' ).append( $selectAll );
+   $( '#smitespam-select-options' ).append( ', ' );
+   $( '#smitespam-select-options' ).append( $selectNone );
$( '#smitespam-page-list' ).empty();
function checkboxChanged() {
var id = $( this ).val();

-- 
To view, visit https://gerrit.wikimedia.org/r/222710
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4b418c0f7d62ddeba3f3b931d80bd3300a128440
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/SmiteSpam
Gerrit-Branch: master
Gerrit-Owner: Polybuildr 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use AuditProcessor instance methods - change (wikimedia...crm)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Use AuditProcessor instance methods
..


Use AuditProcessor instance methods

One breakage fix, one bit of cleanup.

Change-Id: If20e6c48acb2817d9e016979e95ec9570825c4d2
---
M sites/all/modules/wmf_audit/BaseAuditProcessor.php
M sites/all/modules/wmf_audit/wmf_audit.module
2 files changed, 3 insertions(+), 35 deletions(-)

Approvals:
  Awight: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/sites/all/modules/wmf_audit/BaseAuditProcessor.php 
b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
index 06c6ce8..c1ef9f1 100644
--- a/sites/all/modules/wmf_audit/BaseAuditProcessor.php
+++ b/sites/all/modules/wmf_audit/BaseAuditProcessor.php
@@ -206,7 +206,7 @@
 /**
  * Checks to see if the refund or chargeback already exists in civi.
  * NOTE: This does not check to see if the parent is present at all, nor 
should
- * it. Call worldpay_audit_main_transaction_exists_in_civi for that.
+ * it. Call main_transaction_exists_in_civi for that.
  * @param array $transaction Array of donation data
  * @return boolean true if it's in there, otherwise false
  */
@@ -277,7 +277,7 @@
  // which might be resolved below.  Those are archived on the next run,
  // once we can confirm they have hit Civi and are no longer missing.
  if (wmf_audit_count_missing($missing) <= 
$this->get_runtime_options('recon_complete_count')) {
-   wmf_audit_move_completed_recon_file($file, 
$this->get_recon_completed_dir());
+   $this->move_completed_recon_file($file);
  }
 
  //grumble...
@@ -321,7 +321,7 @@
if (array_key_exists('negative', $total_missing) && 
!empty($total_missing['negative'])) {
  foreach ($total_missing['negative'] as $record) {
//check to see if the parent exists. If it does, normalize and send.
-   if (worldpay_audit_main_transaction_exists_in_civi($record)) {
+   if ($this->main_transaction_exists_in_civi($record)) {
  $normal = $this->normalize_negative( $record );
  if (wmf_audit_send_transaction($normal, 'negative')) {
$neg_count += 1;
diff --git a/sites/all/modules/wmf_audit/wmf_audit.module 
b/sites/all/modules/wmf_audit/wmf_audit.module
index d0cbd76..8e186d4 100644
--- a/sites/all/modules/wmf_audit/wmf_audit.module
+++ b/sites/all/modules/wmf_audit/wmf_audit.module
@@ -116,38 +116,6 @@
 }
 
 /**
- * Moves recon files to the completed directory. This should probably only be
- * done at the beginning of a run: If we're running in queue flood mode, we
- * don't know if the data will actually make it all the way in.
- * @param string $file Full path to the file we want to move off
- * @param string $completed_dir Path to the recon completed directory.
- * @return boolean true on success, otherwise false
- */
-function wmf_audit_move_completed_recon_file($file, $completed_dir) {
-  if (!is_dir($completed_dir)) {
-if (!mkdir($completed_dir, 0770)) {
-  $message = "Could not make $completed_dir";
-  wmf_audit_log_error($message, 'FILE_PERMS');
-  return false;
-}
-  }
-
-  $filename = basename($file);
-  $newfile = $completed_dir . '/' . $filename;
-
-  if (!rename($file, $newfile)) {
-$message = "Unable to move $file to $newfile";
-
-wmf_audit_log_error($message, 'FILE_PERMS');
-return false;
-  } else {
-chmod($newfile, 0770);
-  }
-  wmf_audit_echo("Moved $file to $newfile");
-  return true;
-}
-
-/**
  * Wrapper for echo
  * Lets us switch on things we only want to see in verbose mode.
  * Also allows us to impose a char limit per line for the benefit of jenkins

-- 
To view, visit https://gerrit.wikimedia.org/r/222618
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If20e6c48acb2817d9e016979e95ec9570825c4d2
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Ejegg 
Gerrit-Reviewer: Awight 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Small improvements to migration script - change (mediawiki...OAuth)

2015-07-03 Thread Code Review
Gergő Tisza has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222709

Change subject: Small improvements to migration script
..

Small improvements to migration script

* wait for slaves after every batch in migrateCentralWiki.php
* avoid PHP notice due DBConnRef objects not going through
  MWOAuthUtils::getCentralDB
* don't use "migrating grant" text when migrating consumers

Bug: T59336
Change-Id: I9c52534970bb04175b909f41846e83f1aef88d44
---
M maintenance/migrateCentralWiki.php
1 file changed, 10 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/OAuth 
refs/changes/09/222709/1

diff --git a/maintenance/migrateCentralWiki.php 
b/maintenance/migrateCentralWiki.php
index 0a8b447..c11d8f7 100644
--- a/maintenance/migrateCentralWiki.php
+++ b/maintenance/migrateCentralWiki.php
@@ -32,10 +32,10 @@
$this->addOption( 'old', 'Previous central wiki', true, true );
$this->addOption( 'target', 'New central wiki', true, true );
$this->addOption( 'table', 'Table name 
(oauth_registered_consumer or oauth_accepted_consumer)', true, true );
+   $this->setBatchSize( 200 );
}
 
public function execute() {
-
$oldWiki = $this->getOption( 'old' );
$targetWiki = $this->getOption( 'target' );
$table = $this->getOption( 'table' );
@@ -43,15 +43,18 @@
if ( $table === 'oauth_registered_consumer' ) {
$idKey = 'oarc_id';
$cmrClass = 
'MediaWiki\Extensions\OAuth\MWOAuthConsumer';
+   $type = 'consumer';
} elseif ( $table === 'oauth_accepted_consumer' ) {
$idKey = 'oaac_id';
$cmrClass = 
'MediaWiki\Extensions\OAuth\MWOAuthConsumerAcceptance';
+   $type = 'grant';
} else {
$this->error( "Invalid table name. Must be one of 
'oauth_registered_consumer' or 'oauth_accepted_consumer'.\n", 1 );
}
 
$oldDb = wfGetLB( $oldWiki )->getConnectionRef( DB_MASTER, 
array(), $oldWiki );
$targetDb = wfGetLB( $targetWiki )->getConnectionRef( 
DB_MASTER, array(), $targetWiki );
+   $targetDb->daoReadOnly = false;
 
$newMax = $targetDb->selectField(
$table,
@@ -71,8 +74,8 @@
$this->output( "No new rows.\n" );
}
 
-   for ( $currentId = $newMax + 1; $currentId <= $oldMax; 
++$currentId ) {
-   $this->output( "Migrating grant $currentId..." );
+   for ( $currentId = $newMax + 1, $i = 1; $currentId <= $oldMax; 
++$currentId, ++$i ) {
+   $this->output( "Migrating $type $currentId..." );
$cmr = $cmrClass::newFromId( $oldDb, $currentId );
if ( $cmr ) {
$cmr->updateOrigin( 'new' );
@@ -82,6 +85,10 @@
} else {
$this->output( "missing.\n" );
}
+
+   if ( $this->mBatchSize && $i % $this->mBatchSize === 0 
) {
+   wfWaitForSlaves( null, $targetWiki );
+   }
}
 
}

-- 
To view, visit https://gerrit.wikimedia.org/r/222709
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9c52534970bb04175b909f41846e83f1aef88d44
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/OAuth
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] [roundtrip-test] Strip element ids from HTML before normalizing - change (mediawiki...parsoid)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: [roundtrip-test] Strip element ids from HTML before normalizing
..


[roundtrip-test] Strip element ids from HTML before normalizing

* Since DOMUtils HTML normalization no longer strips element ids,
  we are doing them here now to eliminate useless noise in diffs.

Change-Id: I153f22ce3517b6841f456f9a7e257ebc04acc3fc
---
M tests/roundtrip-test.js
1 file changed, 22 insertions(+), 0 deletions(-)

Approvals:
  Arlolra: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/roundtrip-test.js b/tests/roundtrip-test.js
index 8c59ecf..94b3361 100755
--- a/tests/roundtrip-test.js
+++ b/tests/roundtrip-test.js
@@ -350,6 +350,21 @@
].join('\n');
 };
 
+function stripElementIds(node) {
+   while (node) {
+   if (DU.isElt(node)) {
+   var id = node.getAttribute('id');
+   if (/^mw[\w-]{2,}$/.test(id)) {
+   node.removeAttribute('id');
+   }
+   if (node.firstChild) {
+   stripElementIds(node.firstChild);
+   }
+   }
+   node = node.nextSibling;
+   }
+}
+
 var checkIfSignificant = function(env, offsets, data) {
var oldWt = data.oldWt;
var newWt = data.newWt;
@@ -361,6 +376,13 @@
DU.applyDataParsoid(oldBody.ownerDocument, data.oldDp.body);
DU.applyDataParsoid(newBody.ownerDocument, data.newDp.body);
 
+   // Strip 'mw..' ids from the DOMs. This matters for 2 scenarios:
+   // * reduces noise in visual diffs
+   // * all other things being equal after normalization, we don't
+   //   assume DOMs are different simply because ids are different
+   stripElementIds(oldBody.ownerDocument.body);
+   stripElementIds(newBody.ownerDocument.body);
+
var i, offset;
var results = [];
// Use the full tests for fostered content.

-- 
To view, visit https://gerrit.wikimedia.org/r/221986
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I153f22ce3517b6841f456f9a7e257ebc04acc3fc
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/services/parsoid
Gerrit-Branch: master
Gerrit-Owner: Subramanya Sastry 
Gerrit-Reviewer: Arlolra 
Gerrit-Reviewer: Cscott 
Gerrit-Reviewer: Subramanya Sastry 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use existing site attribute - change (pywikibot/core)

2015-07-03 Thread John Vandenberg (Code Review)
John Vandenberg has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222708

Change subject: Use existing site attribute
..

Use existing site attribute

Change-Id: I54410460a314126ad69f1d11beb98815daddae91
---
M scripts/editarticle.py
M scripts/isbn.py
M scripts/reflinks.py
M scripts/revertbot.py
4 files changed, 18 insertions(+), 15 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/08/222708/1

diff --git a/scripts/editarticle.py b/scripts/editarticle.py
index ad0b422..7ba6c5a 100755
--- a/scripts/editarticle.py
+++ b/scripts/editarticle.py
@@ -78,9 +78,8 @@
 
 def setpage(self):
 """Set page and page title."""
-site = pywikibot.Site()
 pageTitle = self.options.page or pywikibot.input("Page to edit:")
-self.page = pywikibot.Page(pywikibot.Link(pageTitle, site))
+self.page = pywikibot.Page(pywikibot.Link(pageTitle, self.site))
 if not self.options.edit_redirect and self.page.isRedirectPage():
 self.page = self.page.getRedirectTarget()
 
@@ -106,7 +105,7 @@
 if new and old != new:
 pywikibot.showDiff(old, new)
 changes = pywikibot.input("What did you change?")
-comment = i18n.twtranslate(pywikibot.Site(), 'editarticle-edit',
+comment = i18n.twtranslate(self.site, 'editarticle-edit',
{'description': changes})
 try:
 self.page.put(new, summary=comment, minorEdit=False,
diff --git a/scripts/isbn.py b/scripts/isbn.py
index b5357d1..117dab4 100755
--- a/scripts/isbn.py
+++ b/scripts/isbn.py
@@ -1479,7 +1479,7 @@
 
 self.generator = generator
 self.isbnR = re.compile(r'(?<=ISBN )(?P[\d\-]+[Xx]?)')
-self.comment = i18n.twtranslate(pywikibot.Site(), 'isbn-formatting')
+self.comment = i18n.twtranslate(self.site, 'isbn-formatting')
 
 def treat(self, page):
 try:
@@ -1540,7 +1540,7 @@
 self.isbn_10_prop_id = self.get_property_by_name('ISBN-10')
 if self.isbn_13_prop_id is None:
 self.isbn_13_prop_id = self.get_property_by_name('ISBN-13')
-self.comment = i18n.twtranslate(pywikibot.Site(), 'isbn-formatting')
+self.comment = i18n.twtranslate(self.site, 'isbn-formatting')
 
 def treat(self, page, item):
 change_messages = []
@@ -1646,9 +1646,9 @@
 if gen:
 preloadingGen = pagegenerators.PreloadingGenerator(gen)
 if use_wikibase:
-bot = IsbnWikibaseBot(preloadingGen, **options)
+bot = IsbnWikibaseBot(preloadingGen, site=site, **options)
 else:
-bot = IsbnBot(preloadingGen, **options)
+bot = IsbnBot(preloadingGen, site=site, **options)
 bot.run()
 else:
 pywikibot.showHelp()
diff --git a/scripts/reflinks.py b/scripts/reflinks.py
index 197c445..fae6441 100755
--- a/scripts/reflinks.py
+++ b/scripts/reflinks.py
@@ -225,10 +225,10 @@
 
 """Container to handle a single bare reference."""
 
-def __init__(self, link, name):
+def __init__(self, link, name, site=None):
 self.refname = name
 self.link = link
-self.site = pywikibot.Site()
+self.site = site or pywikibot.Site()
 self.linkComment = i18n.twtranslate(self.site, 'reflinks-comment')
 self.url = re.sub(u'#.*', '', self.link)
 self.title = None
@@ -302,7 +302,11 @@
 name the first, and remove the content of the others
 """
 
-def __init__(self):
+def __init__(self, site=None):
+"""Constructor."""
+if not site:
+site = pywikibot.Site()
+
 # Match references
 self.REFS = re.compile(
 r'(?i)[^>/]*)>(?P.*?)')
@@ -310,7 +314,7 @@
 r'(?i).*name\s*=\s*(?P"?)\s*(?P.+)\s*(?P=quote).*')
 self.GROUPS = re.compile(
 r'(?i).*group\s*=\s*(?P"?)\s*(?P.+)\s*(?P=quote).*')
-self.autogen = i18n.twtranslate(pywikibot.Site(), 'reflinks-autogen')
+self.autogen = i18n.twtranslate(site, 'reflinks-autogen')
 
 def process(self, text):
 # keys are ref groups
@@ -445,7 +449,7 @@
 bad = globalbadtitles
 self.titleBlackList = re.compile(bad, re.I | re.S | re.X)
 self.norefbot = noreferences.NoReferencesBot(None, verbose=False)
-self.deduplicator = DuplicateReferences()
+self.deduplicator = DuplicateReferences(self.site)
 try:
 self.stopPageRevId = self.stopPage.latest_revision_id
 except pywikibot.NoPage:
@@ -544,7 +548,7 @@
 # TODO: Clean URL blacklist
 continue
 
-ref = RefLink(link, match.group('name'))
+ref = RefLink(link, match.group('name'), site=self.site)
 f = None
 try:
 socket.setdefaulttimeout(20)
d

[MediaWiki-commits] [Gerrit] Make tables.sql idempotent and fix stupid extra , - change (analytics...web)

2015-07-03 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222707

Change subject: Make tables.sql idempotent and fix stupid extra ,
..

Make tables.sql idempotent and fix stupid extra ,

Change-Id: I0db234033d4b1f54428fc3ac338b48cd74270d19
---
M tables.sql
1 file changed, 17 insertions(+), 17 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/quarry/web 
refs/changes/07/222707/1

diff --git a/tables.sql b/tables.sql
index a65bdb1..924d7d1 100644
--- a/tables.sql
+++ b/tables.sql
@@ -1,23 +1,23 @@
 CREATE DATABASE IF NOT EXISTS quarry CHARACTER SET utf8;
 USE quarry;
-CREATE TABLE user(
+CREATE TABLE IF NOT EXISTS user(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 username VARCHAR(255) BINARY NOT NULL UNIQUE,
 wiki_uid INT UNSIGNED NOT NULL UNIQUE
 );
-CREATE UNIQUE INDEX user_username_index ON user(username);
-CREATE UNIQUE INDEX user_wiki_uid ON user(wiki_uid);
+CREATE UNIQUE INDEX IF NOT EXISTS user_username_index ON user( username);
+CREATE UNIQUE INDEX IF NOT EXISTS user_wiki_uid ON user(wiki_uid);
 
-CREATE TABLE user_group(
+CREATE TABLE IF NOT EXISTS user_group(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 user_id INT UNSIGNED NOT NULL,
 group_name VARCHAR(255) BINARY NOT NULL
 );
-CREATE INDEX user_group_user_group_index ON user_group(user_id, group_name);
-CREATE INDEX user_group_user_id_index ON user_group(user_id);
-CREATE INDEX user_group_group_name_index ON user_group(group_name);
+CREATE INDEX IF NOT EXISTS user_group_user_group_index ON user_group(user_id, 
group_name);
+CREATE INDEX IF NOT EXISTS user_group_user_id_index ON user_group(user_id);
+CREATE INDEX IF NOT EXISTS user_group_group_name_index ON 
user_group(group_name);
 
-CREATE TABLE query(
+CREATE TABLE IF NOT EXISTS query(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 user_id INT UNSIGNED NOT NULL,
 title VARCHAR(1024) BINARY,
@@ -27,32 +27,32 @@
 description TEXT BINARY,
 parent_id INT UNSIGNED
 );
-CREATE INDEX query_parent_id_index ON query(parent_id);
+CREATE INDEX IF NOT EXISTS query_parent_id_index ON query(parent_id);
 
-CREATE TABLE query_revision(
+CREATE TABLE IF NOT EXISTS query_revision(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 text TEXT BINARY NOT NULL,
 query_id INT UNSIGNED NOT NULL,
 latest_run_id INT UNSIGNED,
 timestamp TIMESTAMP DEFAULT CURRENT_TIMESTAMP
 );
-CREATE INDEX query_rev_query_id_index ON query_revision(query_id);
+CREATE INDEX IF NOT EXISTS query_rev_query_id_index ON 
query_revision(query_id);
 
-CREATE TABLE query_run(
+CREATE TABLE IF NOT EXISTS query_run(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 query_rev_id INT UNSIGNED NOT NULL,
 status TINYINT UNSIGNED NOT NULL DEFAULT 0,
 timestamp TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
 task_id VARCHAR(36) BINARY,
-extra_info TEXT BINARY,
+extra_info TEXT BINARY
 );
-CREATE INDEX query_run_status_index ON query_run(status);
+CREATE INDEX IF NOT EXISTS query_run_status_index ON query_run(status);
 
-CREATE TABLE star(
+CREATE TABLE IF NOT EXISTS star(
 id INT UNSIGNED NOT NULL PRIMARY KEY AUTO_INCREMENT,
 user_id INT UNSIGNED NOT NULL,
 query_id INT UNSIGNED NOT NULL,
 timestamp TIMESTAMP DEFAULT CURRENT_TIMESTAMP
 );
-CREATE INDEX star_user_id_index ON star(user_id);
-CREATE INDEX star_query_id_index ON star(query_id);
+CREATE INDEX IF NOT EXISTS star_user_id_index ON star(user_id);
+CREATE INDEX IF NOT EXISTS star_query_id_index ON star(query_id);

-- 
To view, visit https://gerrit.wikimedia.org/r/222707
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I0db234033d4b1f54428fc3ac338b48cd74270d19
Gerrit-PatchSet: 1
Gerrit-Project: analytics/quarry/web
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Bump requests version to one that works ok without SSL3 - change (analytics...web)

2015-07-03 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222705

Change subject: Bump requests version to one that works ok without SSL3
..

Bump requests version to one that works ok without SSL3

Change-Id: Ic68390e8e630d7f02ba18abcd84af3d3f05d53d1
---
M requirements.txt
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/quarry/web 
refs/changes/05/222705/1

diff --git a/requirements.txt b/requirements.txt
index b6c205f..089aa5f 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -17,7 +17,7 @@
 oauthlib==0.6.3
 pytz==2014.4
 redis==2.10.1
-requests==2.3.0
+requests==2.7.0
 requests-oauthlib==0.4.1
 six==1.7.3
 translitcodec==0.3

-- 
To view, visit https://gerrit.wikimedia.org/r/222705
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic68390e8e630d7f02ba18abcd84af3d3f05d53d1
Gerrit-PatchSet: 1
Gerrit-Project: analytics/quarry/web
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Make quarry.wsgi listen on all interfaces when run manually - change (analytics...web)

2015-07-03 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222706

Change subject: Make quarry.wsgi listen on all interfaces when run manually
..

Make quarry.wsgi listen on all interfaces when run manually

Change-Id: Ie4f6885e5a5b612dc13453a49599f866d85c1a65
---
M quarry.wsgi
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/analytics/quarry/web 
refs/changes/06/222706/1

diff --git a/quarry.wsgi b/quarry.wsgi
index f87e152..5b1e7aa 100644
--- a/quarry.wsgi
+++ b/quarry.wsgi
@@ -1,4 +1,4 @@
 from quarry.web.app import app as application
 
 if __name__ == '__main__':
-application.run(debug=True)
+application.run(debug=True, host='0.0.0.0')

-- 
To view, visit https://gerrit.wikimedia.org/r/222706
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie4f6885e5a5b612dc13453a49599f866d85c1a65
Gerrit-PatchSet: 1
Gerrit-Project: analytics/quarry/web
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Remove unused global variables in functions - change (mediawiki...MathSearch)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Remove unused global variables in functions
..


Remove unused global variables in functions

Bug: T104386
Change-Id: Iefb46804f255a62b9d9c9a77660b11e36dd32fda
---
M FormulaInfo.php
M SpecialMathDebug.php
M includes/engines/MathEngineRest.php
3 files changed, 3 insertions(+), 4 deletions(-)

Approvals:
  Physikerwelt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/FormulaInfo.php b/FormulaInfo.php
index 2898ebf..2e463a4 100644
--- a/FormulaInfo.php
+++ b/FormulaInfo.php
@@ -64,7 +64,7 @@
 * @throws MWException
 */
public function DisplayInfo( $oldID, $eid ) {
-   global $wgMathDebug, $wgExtensionAssetsPath, $wgMathValidModes;
+   global $wgMathDebug;
$out = $this->getOutput();
$out->addModuleStyles( array( 'ext.mathsearch.styles' ) );
$out->addWikiText( '==General==' );
diff --git a/SpecialMathDebug.php b/SpecialMathDebug.php
index eed2e8c..518a47a 100644
--- a/SpecialMathDebug.php
+++ b/SpecialMathDebug.php
@@ -18,7 +18,7 @@
 
 
function execute( $par ) {
-   global $wgMathDebug, $wgRequest;
+   global $wgRequest;
$offset = $wgRequest->getVal( 'offset', 0 );
$length = $wgRequest->getVal( 'length', 10 );
$page = $wgRequest->getVal( 'page', 'Testpage' );
@@ -118,7 +118,7 @@
}
 
public function testParser( $offset = 0, $length = 10, $page = 
'Testpage' , $purge = true ) {
-   global $wgMathJax, $wgMathUseLaTeXML, $wgTexvc;
+   global $wgMathJax, $wgMathUseLaTeXML;
$out = $this->getOutput();
$out->addModules( array( 'ext.math.mathjax.enabler' ) );
//$out->addModules( array( 'ext.math.mathjax.enabler.mml' ) );
diff --git a/includes/engines/MathEngineRest.php 
b/includes/engines/MathEngineRest.php
index 85cf479..4a2d4c2 100644
--- a/includes/engines/MathEngineRest.php
+++ b/includes/engines/MathEngineRest.php
@@ -100,7 +100,6 @@
 * @return boolean
 */
function postQuery() {
-   global $wgMathDebug;
$numProcess = 3;
$postData = $this->getPostData( $numProcess );
$res = self::doPost($this->backendUrl,$postData);

-- 
To view, visit https://gerrit.wikimedia.org/r/222125
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iefb46804f255a62b9d9c9a77660b11e36dd32fda
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/extensions/MathSearch
Gerrit-Branch: master
Gerrit-Owner: Dyiop 
Gerrit-Reviewer: Hcohl 
Gerrit-Reviewer: Physikerwelt 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] BoilerPlate: Add i18n messages for the HelloWorld special page - change (mediawiki...examples)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: BoilerPlate: Add i18n messages for the HelloWorld special page
..


BoilerPlate: Add i18n messages for the HelloWorld special page

Previously, specials/SpecialHelloWorld.php referred to messages that were
not present in the i18n json files, so all page text and titles would show
up . I added these messages to i18n/en.json and
i18n/qqq.json.

Change-Id: I6c962eb8384cec848029772bf5db0bca1f8e7e99
---
M BoilerPlate/i18n/en.json
M BoilerPlate/i18n/qqq.json
2 files changed, 11 insertions(+), 4 deletions(-)

Approvals:
  Krinkle: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/BoilerPlate/i18n/en.json b/BoilerPlate/i18n/en.json
index a9c79b7..44c5641 100644
--- a/BoilerPlate/i18n/en.json
+++ b/BoilerPlate/i18n/en.json
@@ -3,5 +3,8 @@
"authors": []
},
"boilerplate-desc": "This is an example extension",
-   "boilerplate-i18n-welcome": "Welcome to the localization file of the 
BoilerPlate extension."
-}
\ No newline at end of file
+   "boilerplate-i18n-welcome": "Welcome to the localization file of the 
BoilerPlate extension.",
+   "boilerplate-helloworld": "Hello world!",
+   "boilerplate-helloworld-intro": "Welcome to the \"Hello world\" special 
page of the BoilerPlate extension.",
+   "helloworld": "Hello world"
+}
diff --git a/BoilerPlate/i18n/qqq.json b/BoilerPlate/i18n/qqq.json
index 2c5cd78..5a40c26 100644
--- a/BoilerPlate/i18n/qqq.json
+++ b/BoilerPlate/i18n/qqq.json
@@ -3,9 +3,13 @@
"authors": [
"Shirayuki",
"Umherirrender",
-   "Amire80"
+   "Amire80",
+   "Fhocutt"
]
},
"boilerplate-desc": 
"{{desc|name=Boilerplate|url=https://www.mediawiki.org/wiki/Extension:Boilerplate}}";,
-   "boilerplate-i18n-welcome": "Used to greet the user when reading the 
i18n/??.json file."
+   "boilerplate-i18n-welcome": "Used to greet the user when reading the 
i18n/??.json file.",
+   "boilerplate-helloworld": "Page title of the HelloWorld special page.",
+   "boilerplate-helloworld-intro": "Text displayed on the HelloWorld 
SpecialPage.",
+   "helloworld": "Text of the link to the HelloWorld special page on 
SpecialPages."
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/221823
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6c962eb8384cec848029772bf5db0bca1f8e7e99
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/examples
Gerrit-Branch: master
Gerrit-Owner: Fhocutt 
Gerrit-Reviewer: Fhocutt 
Gerrit-Reviewer: Krinkle 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Build demos as part of `grunt quick-build` - change (oojs/ui)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Build demos as part of `grunt quick-build`
..


Build demos as part of `grunt quick-build`

Adds the `copy:demos` and `copy:fastcomposerdemos` steps to quick-build,
which copies over the minimum set of files necessary to display the
demos.

Bug: T104696
Change-Id: I4346ca9f8dc5ec786f7e99b24ef41faff7997286
---
M Gruntfile.js
1 file changed, 8 insertions(+), 1 deletion(-)

Approvals:
  Esanders: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/Gruntfile.js b/Gruntfile.js
index 812ba9e..5d546bf 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -245,6 +245,13 @@
src: 
'{node_modules/{jquery,oojs}/dist/**/*,composer.json,dist/**/*,php/**/*}',
dest: 'demos/',
expand: true
+   },
+   // Copys the necessary vendor/ files for demos without 
running "composer install"
+   fastcomposerdemos: {
+   // Make sure you update this if PHP 
dependencies are added
+   src: 
'vendor/{autoload.php,composer,mediawiki/at-ease}',
+   dest: 'demos/',
+   expand: true
}
},
colorizeSvg: colorizeSvgFiles,
@@ -408,7 +415,7 @@
'concat:js',
'colorizeSvg', 'less:distVector', 'concat:css',
'copy:imagesCommon', 'copy:imagesApex', 'copy:imagesMediaWiki',
-   'build-i18n'
+   'build-i18n', 'copy:demos', 'copy:fastcomposerdemos'
] );
 
grunt.registerTask( 'lint', [ 'jshint', 'jscs', 'csslint', 'jsonlint', 
'banana' ] );

-- 
To view, visit https://gerrit.wikimedia.org/r/222703
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4346ca9f8dc5ec786f7e99b24ef41faff7997286
Gerrit-PatchSet: 2
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Legoktm 
Gerrit-Reviewer: Bartosz Dziewoński 
Gerrit-Reviewer: Esanders 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Addshore -> WMDE section of whitelist +2 users - change (integration/config)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Addshore -> WMDE section of whitelist +2 users
..


Addshore -> WMDE section of whitelist +2 users

Yes, WMDE again!

Change-Id: I36984d04b5e6c1edd5980f293906c9ca827ae8ea
---
M zuul/layout.yaml
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Hashar: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 6dd986e..bc4c9ef 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -274,6 +274,7 @@
- ^orbit@framezero\.com$ # Christian Williams
 
   # WMDE:
+   - ^addshorewiki@gmail\.com$
- ^aude\.wiki@gmail\.com$
- ^hoo@online\.de$
 
@@ -292,7 +293,6 @@
 
   # Trusted long term users:
- ^adamr_carter@btinternet\.com$ # UltrasonicNXT
-   - ^addshorewiki@gmail\.com$
- ^admin@alphacorp\.tk$ # Hydriz
- ^admin@glados\.cc$ # Unicodesnowman
- ^benapetr@gmail\.com$ # petrb

-- 
To view, visit https://gerrit.wikimedia.org/r/75
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I36984d04b5e6c1edd5980f293906c9ca827ae8ea
Gerrit-PatchSet: 2
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Addshore 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: JanZerebecki 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Deprecate DiscussionThread.code - change (pywikibot/core)

2015-07-03 Thread John Vandenberg (Code Review)
John Vandenberg has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222704

Change subject: Deprecate DiscussionThread.code
..

Deprecate DiscussionThread.code

Use site object with twtranslate

Change-Id: I4c668f6841bdb9d020561b79c633609fd84ceef8
---
M scripts/archivebot.py
1 file changed, 10 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/04/222704/1

diff --git a/scripts/archivebot.py b/scripts/archivebot.py
index 1e82623..332c990 100755
--- a/scripts/archivebot.py
+++ b/scripts/archivebot.py
@@ -265,7 +265,6 @@
 self.title = title
 self.now = now
 self.ts = timestripper
-self.code = self.ts.site.code
 self.content = ""
 self.timestamp = None
 
@@ -273,6 +272,11 @@
 return '%s("%s",%d bytes)' \
% (self.__class__.__name__, self.title,
   len(self.content.encode('utf-8')))
+
+@property
+@deprecated('ts.site')
+def code(self):
+return self.ts.site.code
 
 def feed_line(self, line):
 if not self.content and not line:
@@ -305,7 +309,7 @@
 maxage = str2time(re_t.group(1))
 if self.now - self.timestamp > maxage:
 duration = str2localized_duration(archiver.site, re_t.group(1))
-return i18n.twtranslate(self.code,
+return i18n.twtranslate(self.ts.site,
 'archivebot-older-than',
 {'duration': duration})
 return ''
@@ -340,7 +344,7 @@
 except pywikibot.NoPage:
 self.header = archiver.get_attr('archiveheader',
 i18n.twtranslate(
-self.site.code,
+self.site,
 'archivebot-archiveheader'))
 if self.params:
 self.header = self.header % self.params
@@ -398,7 +402,7 @@
 for t in self.threads:
 newtext += t.to_text()
 if self.full:
-summary += ' ' + i18n.twtranslate(self.site.code,
+summary += ' ' + i18n.twtranslate(self.site,
   'archivebot-archive-full')
 self.text = newtext
 self.save(summary)
@@ -561,7 +565,7 @@
 # Save the archives first (so that bugs don't cause a loss of data)
 for a in sorted(self.archives.keys()):
 self.comment_params['count'] = 
self.archives[a].archived_threads
-comment = i18n.twntranslate(self.site.code,
+comment = i18n.twntranslate(self.site,
 'archivebot-archive-summary',
 self.comment_params)
 self.archives[a].update(comment)
@@ -574,7 +578,7 @@
 = comma.join(a.title(asLink=True)
  for a in self.archives.values())
 self.comment_params['why'] = comma.join(whys)
-comment = i18n.twntranslate(self.site.code,
+comment = i18n.twntranslate(self.site,
 'archivebot-page-summary',
 self.comment_params)
 self.page.update(comment)

-- 
To view, visit https://gerrit.wikimedia.org/r/222704
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4c668f6841bdb9d020561b79c633609fd84ceef8
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: John Vandenberg 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Build demos as part of `grunt quick-build` - change (oojs/ui)

2015-07-03 Thread Legoktm (Code Review)
Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222703

Change subject: Build demos as part of `grunt quick-build`
..

Build demos as part of `grunt quick-build`

Adds the `copy:demos` and `copy:fastcomposerdemos` steps to quick-build,
which copies over the minimum set of files necessary to display the
demos.

Bug: T104696
Change-Id: I4346ca9f8dc5ec786f7e99b24ef41faff7997286
---
M Gruntfile.js
1 file changed, 8 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/oojs/ui refs/changes/03/222703/1

diff --git a/Gruntfile.js b/Gruntfile.js
index 812ba9e..5d546bf 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -245,6 +245,13 @@
src: 
'{node_modules/{jquery,oojs}/dist/**/*,composer.json,dist/**/*,php/**/*}',
dest: 'demos/',
expand: true
+   },
+   // Copys the necessary vendor/ files for demos without 
running "composer install"
+   fastcomposerdemos: {
+   // Make sure you update this if PHP 
dependencies are added
+   src: 
'vendor/{autoload.php,composer,mediawiki/at-ease}',
+   dest: 'demos/',
+   expand: true
}
},
colorizeSvg: colorizeSvgFiles,
@@ -408,7 +415,7 @@
'concat:js',
'colorizeSvg', 'less:distVector', 'concat:css',
'copy:imagesCommon', 'copy:imagesApex', 'copy:imagesMediaWiki',
-   'build-i18n'
+   'build-i18n', 'copy:demos', 'copy:fastcomposerdemos'
] );
 
grunt.registerTask( 'lint', [ 'jshint', 'jscs', 'csslint', 'jsonlint', 
'banana' ] );

-- 
To view, visit https://gerrit.wikimedia.org/r/222703
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I4346ca9f8dc5ec786f7e99b24ef41faff7997286
Gerrit-PatchSet: 1
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Legoktm 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Use .git in .gitreview - change (mediawiki...MathSearch)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Use .git in .gitreview
..


Use .git in .gitreview

Change-Id: I3cb87860af9228d7759b678dc073937ef1d00b6a
---
M .gitreview
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Physikerwelt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/.gitreview b/.gitreview
index 95601d9..b29d8b4 100644
--- a/.gitreview
+++ b/.gitreview
@@ -1,6 +1,6 @@
 [gerrit]
 host=gerrit.wikimedia.org
 port=29418
-project=mediawiki/extensions/MathSearch
+project=mediawiki/extensions/MathSearch.git
 defaultbranch=master
 defaultrebase=0
\ No newline at end of file

-- 
To view, visit https://gerrit.wikimedia.org/r/222624
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3cb87860af9228d7759b678dc073937ef1d00b6a
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/MathSearch
Gerrit-Branch: master
Gerrit-Owner: Paladox 
Gerrit-Reviewer: Hcohl 
Gerrit-Reviewer: Legoktm 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: Physikerwelt 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: Umherirrender 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Changing the sandbox content template on Fa WP - change (pywikibot/core)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Changing the sandbox content template on Fa WP
..


Changing the sandbox content template on Fa WP

Bug: T104716
Change-Id: I24824713adedd3135cc5377141d2443e15dc0fd6
---
M scripts/clean_sandbox.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  John Vandenberg: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/scripts/clean_sandbox.py b/scripts/clean_sandbox.py
index 527da31..b6d9824 100755
--- a/scripts/clean_sandbox.py
+++ b/scripts/clean_sandbox.py
@@ -63,7 +63,7 @@
   u'and editing skills below this line. As this page is for editing '
   u'experiments, this page will automatically be cleaned every 12 '
   u'hours. -->',
-'fa': u'{{subst:User:Amirobot/sandbox}}',
+'fa': u'{{subst:Wikipedia:ربات/sandbox}}',
 'fi': u'{{subst:Hiekka}}',
 'he': u'{{ארגז חול}}\n',
 'id': u'{{Bakpasir}}\n',

-- 
To view, visit https://gerrit.wikimedia.org/r/222696
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I24824713adedd3135cc5377141d2443e15dc0fd6
Gerrit-PatchSet: 2
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Huji 
Gerrit-Reviewer: John Vandenberg 
Gerrit-Reviewer: Ladsgroup 
Gerrit-Reviewer: Merlijn van Deen 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Workaround apparent bug in Edge's history.pushState - change (mediawiki...MultimediaViewer)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Workaround apparent bug in Edge's history.pushState
..


Workaround apparent bug in Edge's history.pushState

When attempting to clear the hash state via history.pushState(),
MS Edge in Windows 10 build 10159 errors out with the helpful
"Unspecified Error".

Catching the exception and trying again with a "#" works around
the error and doesn't look any worse than the non-pushState code
path -- and should have no side effects when the bug is fixed.

Bug: T104381
Change-Id: I6ea4d367af64f85018b06b859ce688053a1caf0f
---
M resources/mmv/mmv.bootstrap.js
1 file changed, 6 insertions(+), 1 deletion(-)

Approvals:
  Gergő Tisza: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/resources/mmv/mmv.bootstrap.js b/resources/mmv/mmv.bootstrap.js
index 53059f7..cac6af5 100644
--- a/resources/mmv/mmv.bootstrap.js
+++ b/resources/mmv/mmv.bootstrap.js
@@ -469,7 +469,12 @@
hash = window.location.href.replace( /#.*$/, '' 
);
}
 
-   this.browserHistory.pushState( null, title, hash );
+   try {
+   window.history.pushState( null, title, hash );
+   } catch ( ex ) {
+   // Workaround for Edge bug -- 
https://phabricator.wikimedia.org/T104381
+   window.history.pushState( null, title, hash + 
'#' );
+   }
} else {
// Since we voluntarily changed the hash, we don't want 
MMVB.hash (which will trigger on hashchange event) to treat it
this.skipNextHashHandling = true;

-- 
To view, visit https://gerrit.wikimedia.org/r/79
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6ea4d367af64f85018b06b859ce688053a1caf0f
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/MultimediaViewer
Gerrit-Branch: master
Gerrit-Owner: Brion VIBBER 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Paladox 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Don't sort pages in Analyzer if accessing from API - change (mediawiki...SmiteSpam)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Don't sort pages in Analyzer if accessing from API
..


Don't sort pages in Analyzer if accessing from API

The pages returned by the API get sorted in the JS and a double sort
messes up the order of paged results in the special page.

Change-Id: Ied06ef4f6aeeba55f5338c88d8f5750ccbe87500
---
M api/SmiteSpamApiQuery.php
M includes/SmiteSpamAnalyzer.php
2 files changed, 11 insertions(+), 8 deletions(-)

Approvals:
  Polybuildr: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/api/SmiteSpamApiQuery.php b/api/SmiteSpamApiQuery.php
index ba654dc..9dac9fb 100644
--- a/api/SmiteSpamApiQuery.php
+++ b/api/SmiteSpamApiQuery.php
@@ -13,7 +13,7 @@
$this->dieUsage( 'Limit parameter must be integer.', 
'badparams' );
}
 
-   $ss = new SmiteSpamAnalyzer();
+   $ss = new SmiteSpamAnalyzer( false );
$spamPages = $ss->run( $offset, $limit );
 
$pages = array();
diff --git a/includes/SmiteSpamAnalyzer.php b/includes/SmiteSpamAnalyzer.php
index adb84d5..908c9ed 100644
--- a/includes/SmiteSpamAnalyzer.php
+++ b/includes/SmiteSpamAnalyzer.php
@@ -9,7 +9,7 @@
 */
protected $config;
 
-   public function __construct() {
+   public function __construct( $sort = true ) {
global $wgSmiteSpamCheckers, $wgSmiteSpamThreshold;
global $wgSmiteSpamIgnorePagesWithNoExternalLinks;
global $wgSmiteSpamIgnoreSmallPages;
@@ -18,6 +18,7 @@
'threshold' => $wgSmiteSpamThreshold,
'ignorePagesWithNoExternalLinks' => 
$wgSmiteSpamIgnorePagesWithNoExternalLinks,
'ignoreSmallPages' => $wgSmiteSpamIgnoreSmallPages,
+   'sort' => $sort,
);
}
/**
@@ -96,12 +97,14 @@
/**
 * @todo check compatibility of inline function
 */
-   usort(
-   $spamPages,
-   function( $pageA, $pageB ) {
-   return $pageA->spamProbability < 
$pageB->spamProbability;
-   }
-   );
+   if ( $this->config['sort'] ) {
+   usort(
+   $spamPages,
+   function( $pageA, $pageB ) {
+   return $pageA->spamProbability < 
$pageB->spamProbability;
+   }
+   );
+   }
return $spamPages;
}
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/222701
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ied06ef4f6aeeba55f5338c88d8f5750ccbe87500
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/SmiteSpam
Gerrit-Branch: master
Gerrit-Owner: Polybuildr 
Gerrit-Reviewer: Polybuildr 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Delete unused i18n strings - change (mediawiki...Math)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Delete unused  i18n strings
..


Delete unused  i18n strings

These i18n strings stopped being used in this repo by 60411b9a, but
were not removed then as an over-sight. Deleting only the en and qqq
messages as normal, and letting the TWN bot delete the others.

Change-Id: I86e1a09f3ddcc2e558a4f04a606cc26ab379d05e
---
M i18n/en.json
M i18n/qqq.json
2 files changed, 0 insertions(+), 8 deletions(-)

Approvals:
  Physikerwelt: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/i18n/en.json b/i18n/en.json
index 6dd7944..e4bac41 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -3,10 +3,6 @@
 "authors": []
 },
 "math-desc": "Render mathematical formulas between 
 ...  tags",
-"math-preference-mwmathinspector-description": "Add experimental support 
to VisualEditor for creating and editing of mathematical formulae for testing, 
ahead of general release. Please remember to always review your changes before 
saving when using experimental features.",
-"math-preference-mwmathinspector-discussion-link": 
"https://www.mediawiki.org/wiki/Special:MyLanguage/Talk:VisualEditor/Beta_Features/Formulae";,
-"math-preference-mwmathinspector-info-link": 
"https://www.mediawiki.org/wiki/Special:MyLanguage/VisualEditor/Beta_Features/Formulae";,
-"math-preference-mwmathinspector-label": "VisualEditor formula editing",
 "math-visualeditor-mwmathinspector-display": "Display",
 "math-visualeditor-mwmathinspector-display-block": "Block",
 "math-visualeditor-mwmathinspector-display-default": "Default",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 14c0cf2..2b2c232 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -14,10 +14,6 @@
]
},
"math-desc": 
"{{desc|name=Math|url=https://www.mediawiki.org/wiki/Extension:Math}}";,
-   "math-preference-mwmathinspector-description": "Used in 
[[Special:Preferences]].\n\nUsed as description for the checkbox to enable 
editing of mathematical formulae in VisualEditor.\n\nThe label for this 
checkbox is {{msg-mw|Math-preference-mwmathinspector-label}}.",
-   "math-preference-mwmathinspector-discussion-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can discuss this Beta 
Feature. Defaults to a page on MediaWiki.org.}}",
-   "math-preference-mwmathinspector-info-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can learn about this 
Beta Feature. Defaults to a page on MediaWiki.org.}}",
-   "math-preference-mwmathinspector-label": "Used in 
[[Special:Preferences]].\n\nUsed as label for checkbox to enable editing of 
mathematical formulae in VisualEditor.\n\nThe description for this checkbox 
is:\n* {{msg-mw|Math-preference-mwmathinspector-description}}",
"math-visualeditor-mwmathinspector-display": "Label for the display 
attribute of the math node\n{{Identical|Display}}",
"math-visualeditor-mwmathinspector-display-block": "Label for the 
'block' value of the display attribute\n{{Identical|Block}}",
"math-visualeditor-mwmathinspector-display-default": "Label for the 
'default' value of the display attribute\n{{Identical|Default}}",

-- 
To view, visit https://gerrit.wikimedia.org/r/222700
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I86e1a09f3ddcc2e558a4f04a606cc26ab379d05e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Math
Gerrit-Branch: master
Gerrit-Owner: Jforrester 
Gerrit-Reviewer: Esanders 
Gerrit-Reviewer: Physikerwelt 
Gerrit-Reviewer: Siebrand 
Gerrit-Reviewer: TheDJ 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Generate edit summary in site lang from used programs - change (pywikibot/core)

2015-07-03 Thread John Vandenberg (Code Review)
John Vandenberg has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222702

Change subject: Generate edit summary in site lang from used programs
..

Generate edit summary in site lang from used programs

piper is a MultipleSitesBot, able to operate with a generator
containing pages from multiple sites.  The edit summary should
be in the site language, and only mention the pipes that
had an effect on the modified page.

Change-Id: Idee2c294f82045a8f8fb825f41f6612efbaae62b
---
M scripts/piper.py
1 file changed, 11 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/02/222702/1

diff --git a/scripts/piper.py b/scripts/piper.py
index a7af13d..edd0f77 100755
--- a/scripts/piper.py
+++ b/scripts/piper.py
@@ -68,7 +68,6 @@
 self.availableOptions.update({
 'always': False,
 'filters': [],
-'comment': None,
 })
 super(PiperBot, self).__init__(generator=generator, **kwargs)
 
@@ -100,12 +99,22 @@
 # Load the page
 text = self.current_page.text
 
+filters_used = []
+
 # Munge!
 for program in self.getOption('filters'):
+old_text = text
 text = self.pipe(program, text)
+if text != old_text:
+filters_used.append(program)
+
+s = ', '.join(filters_used)
+summary = i18n.twtranslate(self.current_page.site,
+   'piper-edit-summary',
+   {'filters': s})
 
 # only save if something was changed
-self.put_current(text, summary=self.getOption('comment'))
+self.put_current(text, summary=summary)
 
 
 def main(*args):
@@ -133,10 +142,6 @@
 genFactory.handleArg(arg)
 
 options['filters'] = filters
-s = ', '.join(options['filters'])
-options['comment'] = i18n.twtranslate(pywikibot.Site().lang,
-  'piper-edit-summary',
-  {'filters': s})
 
 if not gen:
 gen = genFactory.getCombinedGenerator()

-- 
To view, visit https://gerrit.wikimedia.org/r/222702
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Idee2c294f82045a8f8fb825f41f6612efbaae62b
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: John Vandenberg 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Don't sort pages in Analyzer if accessing from API - change (mediawiki...SmiteSpam)

2015-07-03 Thread Polybuildr (Code Review)
Polybuildr has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222701

Change subject: Don't sort pages in Analyzer if accessing from API
..

Don't sort pages in Analyzer if accessing from API

The pages returned by the API get sorted in the JS and a double sort
messes up the order of pages in the special page.

Change-Id: Ied06ef4f6aeeba55f5338c88d8f5750ccbe87500
---
M api/SmiteSpamApiQuery.php
M includes/SmiteSpamAnalyzer.php
2 files changed, 11 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/SmiteSpam 
refs/changes/01/222701/1

diff --git a/api/SmiteSpamApiQuery.php b/api/SmiteSpamApiQuery.php
index ba654dc..9dac9fb 100644
--- a/api/SmiteSpamApiQuery.php
+++ b/api/SmiteSpamApiQuery.php
@@ -13,7 +13,7 @@
$this->dieUsage( 'Limit parameter must be integer.', 
'badparams' );
}
 
-   $ss = new SmiteSpamAnalyzer();
+   $ss = new SmiteSpamAnalyzer( false );
$spamPages = $ss->run( $offset, $limit );
 
$pages = array();
diff --git a/includes/SmiteSpamAnalyzer.php b/includes/SmiteSpamAnalyzer.php
index adb84d5..908c9ed 100644
--- a/includes/SmiteSpamAnalyzer.php
+++ b/includes/SmiteSpamAnalyzer.php
@@ -9,7 +9,7 @@
 */
protected $config;
 
-   public function __construct() {
+   public function __construct( $sort = true ) {
global $wgSmiteSpamCheckers, $wgSmiteSpamThreshold;
global $wgSmiteSpamIgnorePagesWithNoExternalLinks;
global $wgSmiteSpamIgnoreSmallPages;
@@ -18,6 +18,7 @@
'threshold' => $wgSmiteSpamThreshold,
'ignorePagesWithNoExternalLinks' => 
$wgSmiteSpamIgnorePagesWithNoExternalLinks,
'ignoreSmallPages' => $wgSmiteSpamIgnoreSmallPages,
+   'sort' => $sort,
);
}
/**
@@ -96,12 +97,14 @@
/**
 * @todo check compatibility of inline function
 */
-   usort(
-   $spamPages,
-   function( $pageA, $pageB ) {
-   return $pageA->spamProbability < 
$pageB->spamProbability;
-   }
-   );
+   if ( $this->config['sort'] ) {
+   usort(
+   $spamPages,
+   function( $pageA, $pageB ) {
+   return $pageA->spamProbability < 
$pageB->spamProbability;
+   }
+   );
+   }
return $spamPages;
}
 }

-- 
To view, visit https://gerrit.wikimedia.org/r/222701
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ied06ef4f6aeeba55f5338c88d8f5750ccbe87500
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/SmiteSpam
Gerrit-Branch: master
Gerrit-Owner: Polybuildr 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Delete unused i18n strings - change (mediawiki...Math)

2015-07-03 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222700

Change subject: Delete unused  i18n strings
..

Delete unused  i18n strings

These i18n strings stopped being used in this repo by 60411b9a, but
were not removed then as an over-sight. Deleting only the en and qqq
messages as normal, and letting the TWN bot delete the others.

Change-Id: I86e1a09f3ddcc2e558a4f04a606cc26ab379d05e
---
M i18n/en.json
M i18n/qqq.json
2 files changed, 0 insertions(+), 8 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Math 
refs/changes/00/222700/1

diff --git a/i18n/en.json b/i18n/en.json
index 6dd7944..e4bac41 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -3,10 +3,6 @@
 "authors": []
 },
 "math-desc": "Render mathematical formulas between 
 ...  tags",
-"math-preference-mwmathinspector-description": "Add experimental support 
to VisualEditor for creating and editing of mathematical formulae for testing, 
ahead of general release. Please remember to always review your changes before 
saving when using experimental features.",
-"math-preference-mwmathinspector-discussion-link": 
"https://www.mediawiki.org/wiki/Special:MyLanguage/Talk:VisualEditor/Beta_Features/Formulae";,
-"math-preference-mwmathinspector-info-link": 
"https://www.mediawiki.org/wiki/Special:MyLanguage/VisualEditor/Beta_Features/Formulae";,
-"math-preference-mwmathinspector-label": "VisualEditor formula editing",
 "math-visualeditor-mwmathinspector-display": "Display",
 "math-visualeditor-mwmathinspector-display-block": "Block",
 "math-visualeditor-mwmathinspector-display-default": "Default",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 14c0cf2..2b2c232 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -14,10 +14,6 @@
]
},
"math-desc": 
"{{desc|name=Math|url=https://www.mediawiki.org/wiki/Extension:Math}}";,
-   "math-preference-mwmathinspector-description": "Used in 
[[Special:Preferences]].\n\nUsed as description for the checkbox to enable 
editing of mathematical formulae in VisualEditor.\n\nThe label for this 
checkbox is {{msg-mw|Math-preference-mwmathinspector-label}}.",
-   "math-preference-mwmathinspector-discussion-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can discuss this Beta 
Feature. Defaults to a page on MediaWiki.org.}}",
-   "math-preference-mwmathinspector-info-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can learn about this 
Beta Feature. Defaults to a page on MediaWiki.org.}}",
-   "math-preference-mwmathinspector-label": "Used in 
[[Special:Preferences]].\n\nUsed as label for checkbox to enable editing of 
mathematical formulae in VisualEditor.\n\nThe description for this checkbox 
is:\n* {{msg-mw|Math-preference-mwmathinspector-description}}",
"math-visualeditor-mwmathinspector-display": "Label for the display 
attribute of the math node\n{{Identical|Display}}",
"math-visualeditor-mwmathinspector-display-block": "Label for the 
'block' value of the display attribute\n{{Identical|Block}}",
"math-visualeditor-mwmathinspector-display-default": "Label for the 
'default' value of the display attribute\n{{Identical|Default}}",

-- 
To view, visit https://gerrit.wikimedia.org/r/222700
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I86e1a09f3ddcc2e558a4f04a606cc26ab379d05e
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Math
Gerrit-Branch: master
Gerrit-Owner: Jforrester 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Drop some abandonned projects - change (integration/config)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Drop some abandonned projects
..


Drop some abandonned projects

*analytics/asana-stats*
The repo is from 2012, only had a few commits that got pushed directly
bypassing Gerrit.  No point in keeping the related CI configuration.

*analytics/gerrit-stats*
*analytics/reportcard*
Bitrotting. Last commits from 2012.

*analytics/wp-zero
Deprecated. flake8 never passed.

Change-Id: I824f6e365188d4a1f2937ac7acb849738e2edbe9
---
M jjb/analytics.yaml
M zuul/layout.yaml
2 files changed, 0 insertions(+), 71 deletions(-)

Approvals:
  Hashar: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/jjb/analytics.yaml b/jjb/analytics.yaml
index c00d4df..a27d618 100644
--- a/jjb/analytics.yaml
+++ b/jjb/analytics.yaml
@@ -1,18 +1,6 @@
 # Jobs for git repositories under analytics/*
 
 - project:
-name: 'analytics-asana-stats'
-
-jobs:
- - python-jobs
-
-- project:
-name: 'analytics-gerrit-stats'
-
-jobs:
- - python-jobs
-
-- project:
 name: 'analytics-glass'
 
 jobs:
@@ -39,18 +27,3 @@
 name: 'analytics-kraken'
 jobs:
  - 'analytics-kraken'
-
-- project:
-name: 'analytics-reportcard'
-
-jobs:
- - python-jobs
-
-# Currently non-voting, should be converted to generic
-# once passing.
-- project:
-name: 'analytics-wp-zero'
-toxenv:
- - flake8
-jobs:
- - '{name}-tox-{toxenv}'
diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 77af8d0..6dd986e 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -1532,24 +1532,6 @@
 
   # Exceptions for projects not yet passing pep8 or pyflakes
   #
-  - name: analytics-asana-stats-pep8
-voting: false
-  - name: analytics-asana-stats-pyflakes
-voting: false
-  - name: analytics-gerrit-stats-pep8
-voting: false
-  - name: analytics-gerrit-stats-pyflakes
-voting: false
-  - name: analytics-glass-pep8
-voting: false
-  - name: analytics-glass-pyflakes
-voting: false
-  - name: analytics-wp-zero-tox-flake8
-voting: false
-  - name: analytics-reportcard-pep8
-voting: false
-  - name: analytics-reportcard-pyflakes
-voting: false
   - name: mwext-BlameMaps-pep8
 voting: false
   - name: mwext-BlameMaps-pyflakes
@@ -2123,11 +2105,6 @@
   - mediawiki-core-qunit
   - php-composer-validate
 
-  - name: analytics/asana-stats
-template:
-  - name: 'python-lint'
-prefix: 'analytics-asana-stats'
-
   - name: analytics/aggregator
 test:
  - tox-flake8
@@ -2152,16 +2129,6 @@
 gate-and-submit:
  - tox-flake8
 
-  - name: analytics/gerrit-stats
-template:
-  - name: 'python-lint'
-prefix: 'analytics-gerrit-stats'
-
-  - name: analytics/glass
-template:
-  - name: 'python-lint'
-prefix: 'analytics-glass'
-
   - name: analytics/quarry/web
 test:
   - tox-flake8
@@ -2171,11 +2138,6 @@
   - name: analytics/kraken
 test:
   - analytics-kraken
-
-  - name: analytics/reportcard
-template:
-  - name: 'python-lint'
-prefix: 'analytics-reportcard'
 
   - name: analytics/libanon
 test:
@@ -2232,12 +2194,6 @@
  - tox-flake8
 gate-and-submit:
  - tox-flake8
-
-  - name: analytics/wp-zero
-test:
- - analytics-wp-zero-tox-flake8
-gate-and-submit:
- - analytics-wp-zero-tox-flake8
 
   - name: apps/android/commons
 test:

-- 
To view, visit https://gerrit.wikimedia.org/r/222698
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I824f6e365188d4a1f2937ac7acb849738e2edbe9
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 
Gerrit-Reviewer: Hashar 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] WIP Move some shared functions into SmashPig - change (wikimedia...SmashPig)

2015-07-03 Thread Awight (Code Review)
Awight has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222699

Change subject: WIP Move some shared functions into SmashPig
..

WIP Move some shared functions into SmashPig

Change-Id: I78d08152a435a117728fc386c4a6d9951ca74dd8
---
A Core/PaymentMethod.php
A Core/TransactionId.php
2 files changed, 312 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikimedia/fundraising/SmashPig 
refs/changes/99/222699/1

diff --git a/Core/PaymentMethod.php b/Core/PaymentMethod.php
new file mode 100644
index 000..adcf985
--- /dev/null
+++ b/Core/PaymentMethod.php
@@ -0,0 +1,167 @@
+gateway = $gateway;
+   $method->name = PaymentMethod::parseCompoundMethod( 
$method_name, $submethod_name );
+   $method->is_recurring = $is_recurring;
+
+   try {
+   // FIXME: I don't like that we're couple to the gateway 
already.
+   $spec = array();
+   if ( $method_name ) {
+   $spec = $gateway->getPaymentMethodMeta( 
$method_name );
+   }
+   // When we have a more specific method, child metadata 
supercedes
+   // parent metadata
+   if ( $submethod_name ) {
+   $spec = array_replace_recursive(
+   $spec,
+   $gateway->getPaymentSubmethodMeta( 
$submethod_name )
+   );
+   }
+   $method->spec = $spec;
+   } catch ( Exception $ex ) {
+   // Return empty method.
+   $method->name = "none";
+   $method->spec = array();
+   }
+
+   return $method;
+   }
+
+   /**
+* Process an old-style payment method/submethod name into the unique 
form
+*
+* For now, this just eliminates duplicated method-submethods.
+*
+* @param string $bareMethod old-style payment method
+* @param string $subMethod old-style payment submethod
+*
+* @return string unique method id
+*/
+   static public function parseCompoundMethod( $bareMethod, $subMethod ) {
+   $parts = array();
+   if ( $subMethod ) {
+   $parts = explode( '_', $subMethod );
+   }
+   array_unshift( $parts, $bareMethod );
+
+   if ( count( $parts ) > 1 && $parts[0] === $parts[1] ) {
+   array_shift( $parts );
+   }
+
+   return implode( '_', $parts );
+   }
+
+   /**
+* Get the gateway's specification for this payment method
+*
+* @return array method specification data
+*/
+   public function getMethodMeta() {
+   return $this->spec;
+   }
+
+   /**
+* TODO: implement this function
+* @return true if this payment method is complete enough to begin a 
transaction
+*/
+   public function isCompletelySpecified() {
+   if ( $this->name === 'cc' ) return false;
+   return true;
+   }
+
+   /**
+* @return true if the $method descends from a more general $ancestor 
method, or if they are equal.
+*/
+   public function isInstanceOf( $ancestor ) {
+   $method = $this;
+   do {
+   if ( $method->name === $ancestor ) {
+   return true;
+   }
+   } while ( $method = $method->getParent() );
+
+   return false;
+   }
+
+   /**
+* Get the high-level family for this method
+*
+* @return PaymentMethod the most general ancestor of this method
+*/
+   public function getFamily() {
+   $method = $this;
+   while ( $parent = $method->getParent() ) {
+   $method = $parent;
+   }
+   return $method;
+   }
+
+   /**
+* @return PaymentMethod|null parent method or null if there is no 
parent
+*/
+   protected function getParent() {
+   if ( array_key_exists( 'group', $this->spec ) ) {
+   return PaymentMethod::newFromCompoundName( 
$this->gateway, $this->spec['group'], null, $this->is_recurring );
+   }
+   return null;
+   }
+
+   /**
+* @return string normalized utm_source payment method component
+*/
+   public function getUtmSourceName() {
+   $source = $this->getFamily()->name;
+   if ( $this->is_recurring ) {
+   $source = "r" . $source;
+   }
+   return $source;
+   }
+}
diff --git a/Core/T

[MediaWiki-commits] [Gerrit] Drop some abandonned projects - change (integration/config)

2015-07-03 Thread Hashar (Code Review)
Hashar has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222698

Change subject: Drop some abandonned projects
..

Drop some abandonned projects

*analytics/asana-stats*
The repo is from 2012, only had a few commits that got pushed directly
bypassing Gerrit.  No point in keeping the related CI configuration.

*analytics/gerrit-stats*
*analytics/reportcard*
Bitrotting. Last commits from 2012.

*analytics/wp-zero
Deprecated. flake8 never passed.

Change-Id: I824f6e365188d4a1f2937ac7acb849738e2edbe9
---
M jjb/analytics.yaml
M zuul/layout.yaml
2 files changed, 0 insertions(+), 71 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/integration/config 
refs/changes/98/222698/1

diff --git a/jjb/analytics.yaml b/jjb/analytics.yaml
index c00d4df..a27d618 100644
--- a/jjb/analytics.yaml
+++ b/jjb/analytics.yaml
@@ -1,18 +1,6 @@
 # Jobs for git repositories under analytics/*
 
 - project:
-name: 'analytics-asana-stats'
-
-jobs:
- - python-jobs
-
-- project:
-name: 'analytics-gerrit-stats'
-
-jobs:
- - python-jobs
-
-- project:
 name: 'analytics-glass'
 
 jobs:
@@ -39,18 +27,3 @@
 name: 'analytics-kraken'
 jobs:
  - 'analytics-kraken'
-
-- project:
-name: 'analytics-reportcard'
-
-jobs:
- - python-jobs
-
-# Currently non-voting, should be converted to generic
-# once passing.
-- project:
-name: 'analytics-wp-zero'
-toxenv:
- - flake8
-jobs:
- - '{name}-tox-{toxenv}'
diff --git a/zuul/layout.yaml b/zuul/layout.yaml
index 77af8d0..6dd986e 100644
--- a/zuul/layout.yaml
+++ b/zuul/layout.yaml
@@ -1532,24 +1532,6 @@
 
   # Exceptions for projects not yet passing pep8 or pyflakes
   #
-  - name: analytics-asana-stats-pep8
-voting: false
-  - name: analytics-asana-stats-pyflakes
-voting: false
-  - name: analytics-gerrit-stats-pep8
-voting: false
-  - name: analytics-gerrit-stats-pyflakes
-voting: false
-  - name: analytics-glass-pep8
-voting: false
-  - name: analytics-glass-pyflakes
-voting: false
-  - name: analytics-wp-zero-tox-flake8
-voting: false
-  - name: analytics-reportcard-pep8
-voting: false
-  - name: analytics-reportcard-pyflakes
-voting: false
   - name: mwext-BlameMaps-pep8
 voting: false
   - name: mwext-BlameMaps-pyflakes
@@ -2123,11 +2105,6 @@
   - mediawiki-core-qunit
   - php-composer-validate
 
-  - name: analytics/asana-stats
-template:
-  - name: 'python-lint'
-prefix: 'analytics-asana-stats'
-
   - name: analytics/aggregator
 test:
  - tox-flake8
@@ -2152,16 +2129,6 @@
 gate-and-submit:
  - tox-flake8
 
-  - name: analytics/gerrit-stats
-template:
-  - name: 'python-lint'
-prefix: 'analytics-gerrit-stats'
-
-  - name: analytics/glass
-template:
-  - name: 'python-lint'
-prefix: 'analytics-glass'
-
   - name: analytics/quarry/web
 test:
   - tox-flake8
@@ -2171,11 +2138,6 @@
   - name: analytics/kraken
 test:
   - analytics-kraken
-
-  - name: analytics/reportcard
-template:
-  - name: 'python-lint'
-prefix: 'analytics-reportcard'
 
   - name: analytics/libanon
 test:
@@ -2232,12 +2194,6 @@
  - tox-flake8
 gate-and-submit:
  - tox-flake8
-
-  - name: analytics/wp-zero
-test:
- - analytics-wp-zero-tox-flake8
-gate-and-submit:
- - analytics-wp-zero-tox-flake8
 
   - name: apps/android/commons
 test:

-- 
To view, visit https://gerrit.wikimedia.org/r/222698
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I824f6e365188d4a1f2937ac7acb849738e2edbe9
Gerrit-PatchSet: 1
Gerrit-Project: integration/config
Gerrit-Branch: master
Gerrit-Owner: Hashar 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Add maxage, s-maxage and uselang parameters in API call - change (mediawiki...Popups)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Add maxage, s-maxage and uselang parameters in API call
..


Add maxage, s-maxage and uselang parameters in API call

Bug: T97096
Change-Id: I8b4a21b725d25c704eedf3c29ea139a777327a4c
---
M resources/ext.popups.renderer.article.js
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Anomie: Looks good to me, but someone else must approve
  Gergő Tisza: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/resources/ext.popups.renderer.article.js 
b/resources/ext.popups.renderer.article.js
index 15d8be4..f9a5c09 100644
--- a/resources/ext.popups.renderer.article.js
+++ b/resources/ext.popups.renderer.article.js
@@ -60,7 +60,10 @@
piprop: 'thumbnail',
pithumbsize: 300,
rvprop: 'timestamp',
-   titles: title
+   titles: title,
+   smaxage: 300,
+   maxage: 300,
+   uselang: 'content'
} );
 
mw.popups.render.currentRequest.fail( deferred.reject );

-- 
To view, visit https://gerrit.wikimedia.org/r/87
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8b4a21b725d25c704eedf3c29ea139a777327a4c
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/Popups
Gerrit-Branch: master
Gerrit-Owner: Prtksxna 
Gerrit-Reviewer: Anomie 
Gerrit-Reviewer: Gergő Tisza 
Gerrit-Reviewer: Spage 
Gerrit-Reviewer: Ssmith 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Delete the never-used 'MW alien' Beta Feature hook/i18n - change (mediawiki...VisualEditor)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Delete the never-used 'MW alien' Beta Feature hook/i18n
..


Delete the never-used 'MW alien' Beta Feature hook/i18n

The feature is now available for all, so this won't be needed.

Change-Id: I553c9473953651c0963609dd22a895e17c2e2af5
---
M VisualEditor.hooks.php
M modules/ve-mw/i18n/en.json
M modules/ve-mw/i18n/qqq.json
3 files changed, 0 insertions(+), 27 deletions(-)

Approvals:
  Esanders: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/VisualEditor.hooks.php b/VisualEditor.hooks.php
index cfe8a54..2113d8f 100644
--- a/VisualEditor.hooks.php
+++ b/VisualEditor.hooks.php
@@ -325,25 +325,6 @@
'skins' => $veConfig->get( 
'VisualEditorSupportedSkins' ),
)
);
-
-/* Disabling Beta Features option for generic content for now
-   $preferences['visualeditor-enable-mwalienextension'] = array(
-   'version' => '1.0',
-   'label-message' => 
'visualeditor-preference-mwalienextension-label',
-   'desc-message' => 
'visualeditor-preference-mwalienextension-description',
-   'screenshot' => array(
-   'ltr' => 
"$iconpath/betafeatures-icon-VisualEditor-alien-ltr.svg",
-   'rtl' => 
"$iconpath/betafeatures-icon-VisualEditor-alien-rtl.svg",
-   ),
-   'info-message' => 
'visualeditor-preference-mwalienextension-info-link',
-   'discussion-message' => 
'visualeditor-preference-mwalienextension-discussion-link',
-   'requirements' => array(
-   'betafeatures' => array(
-   'visualeditor-enable',
-   ),
-   ),
-   );
-*/
}
 
/**
diff --git a/modules/ve-mw/i18n/en.json b/modules/ve-mw/i18n/en.json
index 30ad5ae..788a443 100644
--- a/modules/ve-mw/i18n/en.json
+++ b/modules/ve-mw/i18n/en.json
@@ -270,10 +270,6 @@
"visualeditor-preference-core-info-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/VisualEditor\/Beta_Features\/General",
"visualeditor-preference-core-label": "VisualEditor",
"visualeditor-preference-enable": "Enable VisualEditor. It will be 
available in the following {{PLURAL:$2|namespace|namespaces}}: $1",
-   "visualeditor-preference-mwalienextension-description": "Add 
experimental basic support to VisualEditor for editing extension tags (like 
galleries or source code blocks), ahead of individual tools being available. 
Please remember to always review your changes before saving when using 
experimental features.",
-   "visualeditor-preference-mwalienextension-discussion-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/Talk:VisualEditor\/Beta_Features\/Generic",
-   "visualeditor-preference-mwalienextension-info-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/VisualEditor\/Beta_Features\/Generic",
-   "visualeditor-preference-mwalienextension-label": "VisualEditor 
extension tag editing",
"visualeditor-recreate": "The page has been deleted since you started 
editing. Press \"$1\" to recreate it.",
"visualeditor-reference-input-placeholder": "Search within current 
citations",
"visualeditor-referenceslist-isempty": "There are no references with 
the group \"$1\" on this page to include in this list.",
diff --git a/modules/ve-mw/i18n/qqq.json b/modules/ve-mw/i18n/qqq.json
index b3a5a51..0f469a2 100644
--- a/modules/ve-mw/i18n/qqq.json
+++ b/modules/ve-mw/i18n/qqq.json
@@ -279,10 +279,6 @@
"visualeditor-preference-core-info-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can learn about this 
Beta Feature. Defaults to a page on MediaWiki.org.}}",
"visualeditor-preference-core-label": "Used in 
[[Special:Preferences]].\n\nUsed as label for checkbox to enable 
VisualEditor.\n\nThe description for this checkbox is:\n* 
{{msg-mw|Visualeditor-preference-core-description}}\n{{Identical|VisualEditor}}",
"visualeditor-preference-enable": "Label for the user preference to 
enable VisualEditor while it is in alpha (opt-in) mode.\nLinks are in 
{{msg-mw|Visualeditor-mainnamespacepagelink}} and 
{{msg-mw|visualeditor-usernamespacepagelink}}.\n\nParameters:\n* $1 - Comma 
separated list of namespace names.\n* $2 - Number of namespaces in which it 
will be used.\n\nSee also:\n* 
{{msg-mw|Visualeditor-preference-core-description}}",
-   "visualeditor-preference-mwalienextension-description": "Used in 
[[Special:Preferences]].\n\nUsed as description for the checkbox to enable 
editing of extension tags in VisualEditor.\n\nThe label for this checkbox is 
{{msg-mw|Visualeditor-preference-mwalienex

[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 422d824..57a86aa - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222697

Change subject: Syncronize VisualEditor: 422d824..57a86aa
..

Syncronize VisualEditor: 422d824..57a86aa

Change-Id: I65bbf14a2f50b11e7e0c3e864a7fe0ff6f5d9070
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/97/222697/1

diff --git a/VisualEditor b/VisualEditor
index 422d824..57a86aa 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 422d82448d0e173367438e5537c93edd6c4f0a8c
+Subproject commit 57a86aa0e2b2903608329c276eb3c6cd3c4c6dc8

-- 
To view, visit https://gerrit.wikimedia.org/r/222697
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I65bbf14a2f50b11e7e0c3e864a7fe0ff6f5d9070
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 422d824..57a86aa - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 422d824..57a86aa
..


Syncronize VisualEditor: 422d824..57a86aa

Change-Id: I65bbf14a2f50b11e7e0c3e864a7fe0ff6f5d9070
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index 422d824..57a86aa 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 422d82448d0e173367438e5537c93edd6c4f0a8c
+Subproject commit 57a86aa0e2b2903608329c276eb3c6cd3c4c6dc8

-- 
To view, visit https://gerrit.wikimedia.org/r/222697
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I65bbf14a2f50b11e7e0c3e864a7fe0ff6f5d9070
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Changing the page used by pywikipedia to reset the sandbox o... - change (pywikibot/core)

2015-07-03 Thread Huji (Code Review)
Huji has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222696

Change subject: Changing the page used by pywikipedia to reset the sandbox on 
Fa WP.
..

Changing the page used by pywikipedia to reset the sandbox on Fa WP.

Bug: T104716

Change-Id: I24824713adedd3135cc5377141d2443e15dc0fd6
---
M scripts/clean_sandbox.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core 
refs/changes/96/222696/1

diff --git a/scripts/clean_sandbox.py b/scripts/clean_sandbox.py
index 527da31..b6d9824 100755
--- a/scripts/clean_sandbox.py
+++ b/scripts/clean_sandbox.py
@@ -63,7 +63,7 @@
   u'and editing skills below this line. As this page is for editing '
   u'experiments, this page will automatically be cleaned every 12 '
   u'hours. -->',
-'fa': u'{{subst:User:Amirobot/sandbox}}',
+'fa': u'{{subst:Wikipedia:ربات/sandbox}}',
 'fi': u'{{subst:Hiekka}}',
 'he': u'{{ארגז חול}}\n',
 'id': u'{{Bakpasir}}\n',

-- 
To view, visit https://gerrit.wikimedia.org/r/222696
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I24824713adedd3135cc5377141d2443e15dc0fd6
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Huji 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] QA: All public collection steps should use a brand new colle... - change (mediawiki...Gather)

2015-07-03 Thread Jdlrobson (Code Review)
Jdlrobson has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222695

Change subject: QA: All public collection steps should use a brand new 
collection
..

QA: All public collection steps should use a brand new collection

Create collection specifically for the test

Change-Id: I5cde09e269d23713192cfad7e0a01c65c261b3b9
---
M tests/browser/features/step_definitions/common_steps.rb
A tests/browser/features/support/pages/gather_user_collection_page.rb
2 files changed, 9 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Gather 
refs/changes/95/222695/1

diff --git a/tests/browser/features/step_definitions/common_steps.rb 
b/tests/browser/features/step_definitions/common_steps.rb
index 2c16e96..9df92ba 100644
--- a/tests/browser/features/step_definitions/common_steps.rb
+++ b/tests/browser/features/step_definitions/common_steps.rb
@@ -9,8 +9,9 @@
 end
 
 Given(/^I view one of my public collections$/) do
-  visit(GatherPage)
-  on(GatherPage).my_first_public_collection_element.click
+  # create a collection with a random name
+  response = make_collection((0...50).map { ('a'..'z').to_a[rand(26)] }.join)
+  visit(GatherUserCollectionPage, using_params: { :id => response.data["id"] } 
)
 end
 
 Given(/^I am logged into the mobile website$/) do
diff --git 
a/tests/browser/features/support/pages/gather_user_collection_page.rb 
b/tests/browser/features/support/pages/gather_user_collection_page.rb
new file mode 100644
index 000..58a92ea
--- /dev/null
+++ b/tests/browser/features/support/pages/gather_user_collection_page.rb
@@ -0,0 +1,6 @@
+class GatherUserCollectionPage < GatherPage
+  include PageObject
+
+  page_url 'Special:Gather/id/<%= params[:id] %>'
+end
+

-- 
To view, visit https://gerrit.wikimedia.org/r/222695
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5cde09e269d23713192cfad7e0a01c65c261b3b9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Gather
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Delete the never-used 'MW alien' Beta Feature hook/i18n - change (mediawiki...VisualEditor)

2015-07-03 Thread Jforrester (Code Review)
Jforrester has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222694

Change subject: Delete the never-used 'MW alien' Beta Feature hook/i18n
..

Delete the never-used 'MW alien' Beta Feature hook/i18n

The feature is now available for all, so this won't be needed.

Change-Id: I553c9473953651c0963609dd22a895e17c2e2af5
---
M VisualEditor.hooks.php
M modules/ve-mw/i18n/en.json
M modules/ve-mw/i18n/qqq.json
3 files changed, 0 insertions(+), 27 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VisualEditor 
refs/changes/94/222694/1

diff --git a/VisualEditor.hooks.php b/VisualEditor.hooks.php
index cfe8a54..2113d8f 100644
--- a/VisualEditor.hooks.php
+++ b/VisualEditor.hooks.php
@@ -325,25 +325,6 @@
'skins' => $veConfig->get( 
'VisualEditorSupportedSkins' ),
)
);
-
-/* Disabling Beta Features option for generic content for now
-   $preferences['visualeditor-enable-mwalienextension'] = array(
-   'version' => '1.0',
-   'label-message' => 
'visualeditor-preference-mwalienextension-label',
-   'desc-message' => 
'visualeditor-preference-mwalienextension-description',
-   'screenshot' => array(
-   'ltr' => 
"$iconpath/betafeatures-icon-VisualEditor-alien-ltr.svg",
-   'rtl' => 
"$iconpath/betafeatures-icon-VisualEditor-alien-rtl.svg",
-   ),
-   'info-message' => 
'visualeditor-preference-mwalienextension-info-link',
-   'discussion-message' => 
'visualeditor-preference-mwalienextension-discussion-link',
-   'requirements' => array(
-   'betafeatures' => array(
-   'visualeditor-enable',
-   ),
-   ),
-   );
-*/
}
 
/**
diff --git a/modules/ve-mw/i18n/en.json b/modules/ve-mw/i18n/en.json
index 30ad5ae..788a443 100644
--- a/modules/ve-mw/i18n/en.json
+++ b/modules/ve-mw/i18n/en.json
@@ -270,10 +270,6 @@
"visualeditor-preference-core-info-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/VisualEditor\/Beta_Features\/General",
"visualeditor-preference-core-label": "VisualEditor",
"visualeditor-preference-enable": "Enable VisualEditor. It will be 
available in the following {{PLURAL:$2|namespace|namespaces}}: $1",
-   "visualeditor-preference-mwalienextension-description": "Add 
experimental basic support to VisualEditor for editing extension tags (like 
galleries or source code blocks), ahead of individual tools being available. 
Please remember to always review your changes before saving when using 
experimental features.",
-   "visualeditor-preference-mwalienextension-discussion-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/Talk:VisualEditor\/Beta_Features\/Generic",
-   "visualeditor-preference-mwalienextension-info-link": 
"\/\/mediawiki.org\/wiki\/Special:MyLanguage\/VisualEditor\/Beta_Features\/Generic",
-   "visualeditor-preference-mwalienextension-label": "VisualEditor 
extension tag editing",
"visualeditor-recreate": "The page has been deleted since you started 
editing. Press \"$1\" to recreate it.",
"visualeditor-reference-input-placeholder": "Search within current 
citations",
"visualeditor-referenceslist-isempty": "There are no references with 
the group \"$1\" on this page to include in this list.",
diff --git a/modules/ve-mw/i18n/qqq.json b/modules/ve-mw/i18n/qqq.json
index b3a5a51..0f469a2 100644
--- a/modules/ve-mw/i18n/qqq.json
+++ b/modules/ve-mw/i18n/qqq.json
@@ -279,10 +279,6 @@
"visualeditor-preference-core-info-link": "{{optional|Used on 
[[Special:Preferences]] as a link to a page where users can learn about this 
Beta Feature. Defaults to a page on MediaWiki.org.}}",
"visualeditor-preference-core-label": "Used in 
[[Special:Preferences]].\n\nUsed as label for checkbox to enable 
VisualEditor.\n\nThe description for this checkbox is:\n* 
{{msg-mw|Visualeditor-preference-core-description}}\n{{Identical|VisualEditor}}",
"visualeditor-preference-enable": "Label for the user preference to 
enable VisualEditor while it is in alpha (opt-in) mode.\nLinks are in 
{{msg-mw|Visualeditor-mainnamespacepagelink}} and 
{{msg-mw|visualeditor-usernamespacepagelink}}.\n\nParameters:\n* $1 - Comma 
separated list of namespace names.\n* $2 - Number of namespaces in which it 
will be used.\n\nSee also:\n* 
{{msg-mw|Visualeditor-preference-core-description}}",
-   "visualeditor-preference-mwalienextension-description": "Used in 
[[Special:Preferences]].\n\nUsed as description for the checkbox to enable 
editing of extension tags in VisualEditor.\n\nThe label for

[MediaWiki-commits] [Gerrit] WikidataPageBanner fixes for skin Minerva - change (mediawiki...WikidataPageBanner)

2015-07-03 Thread Sumit (Code Review)
Sumit has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222693

Change subject: WikidataPageBanner fixes for skin Minerva
..

WikidataPageBanner fixes for skin Minerva

Introduced the following css changes for skin Minerva:
* precontent  made to hide
* extra margin-top given to topbanner to prevent overlapping with edit buttons.
* .banner-image class renamed to .wpb-banner-image class because
 MobileFrontend's banner module also uses the same class.
* Reduce banner name font to 1em when screen below 768px

Bug: T98034
Change-Id: Iaab674cc216110fa2b59348e0a3add7e2c001654
---
M resources/Resources.php
M resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less
A resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.mobile.less
M resources/ext.WikidataPageBanner.toc/ext.WikidataPageBanner.toc.less
M templates/banner.mustache
5 files changed, 29 insertions(+), 2 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikidataPageBanner 
refs/changes/93/222693/1

diff --git a/resources/Resources.php b/resources/Resources.php
index 1fecc55..cdf02ef 100644
--- a/resources/Resources.php
+++ b/resources/Resources.php
@@ -28,6 +28,9 @@
'styles' => array(
'ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less',
),
+   'skinStyles' => array(
+   'minerva' => 
'ext.WikidataPageBanner.styles/ext.WikidataPageBanner.mobile.less'
+   ),
'localBasePath' => __DIR__,
'remoteExtPath' => 'WikidataPageBanner/resources',
'targets' => array( 'desktop', 'mobile' ),
diff --git 
a/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less 
b/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less
index 3b6fd8e..4abd59a 100644
--- a/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less
+++ b/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.less
@@ -10,6 +10,7 @@
position: relative;
max-width: 1800px;
height: auto;
+   margin: 1em 0;
 }
 
 .topbanner .name {
@@ -30,7 +31,7 @@
display: none;
 }
 
-.topbanner .banner-image{
+.topbanner .wpb-banner-image{
width: 100%;
height: auto;
 }
@@ -49,3 +50,9 @@
float: left;
}
 }
+
+@media screen and ( max-width: 768px ) {
+   .topbanner .name {
+   font-size: 1em;
+   }
+}
diff --git 
a/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.mobile.less 
b/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.mobile.less
new file mode 100644
index 000..52673dc
--- /dev/null
+++ b/resources/ext.WikidataPageBanner.styles/ext.WikidataPageBanner.mobile.less
@@ -0,0 +1,12 @@
+/**
+ * Stylesheet for page-wide Banner in WikidataPageBanner extension.
+ */
+@import "mediawiki.mixins";
+.topbanner{
+   // since h1 is hidden so give extra margin to prevent overlapping with 
edit buttons
+   margin: 3em 0 1em 0;
+}
+
+.pre-content h1 {
+   display: none;
+}
diff --git 
a/resources/ext.WikidataPageBanner.toc/ext.WikidataPageBanner.toc.less 
b/resources/ext.WikidataPageBanner.toc/ext.WikidataPageBanner.toc.less
index 1924c14..59f11bf 100644
--- a/resources/ext.WikidataPageBanner.toc/ext.WikidataPageBanner.toc.less
+++ b/resources/ext.WikidataPageBanner.toc/ext.WikidataPageBanner.toc.less
@@ -105,4 +105,9 @@
#toctitle {
display: none;
}
+
+   // hide toc if toc module added and screen is large
+   .toc-mobile, .toc {
+   display: none;
+   }
 }
diff --git a/templates/banner.mustache b/templates/banner.mustache
index 47e2d32..a6e6ed7 100644
--- a/templates/banner.mustache
+++ b/templates/banner.mustache
@@ -2,7 +2,7 @@


{{title}}
-   
+   

{{#icons}}
{{{icon}}}

-- 
To view, visit https://gerrit.wikimedia.org/r/222693
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaab674cc216110fa2b59348e0a3add7e2c001654
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikidataPageBanner
Gerrit-Branch: master
Gerrit-Owner: Sumit 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] static-bugzilla: update Apache config for 2.4 - change (operations/puppet)

2015-07-03 Thread Dzahn (Code Review)
Dzahn has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222692

Change subject: static-bugzilla: update Apache config for 2.4
..

static-bugzilla: update Apache config for 2.4

Change-Id: I91b8d3d9e604fabcecb092b7352c3330f466a722
---
M modules/bugzilla_static/templates/apache/static-bugzilla.wikimedia.org.erb
1 file changed, 1 insertion(+), 3 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/92/222692/1

diff --git 
a/modules/bugzilla_static/templates/apache/static-bugzilla.wikimedia.org.erb 
b/modules/bugzilla_static/templates/apache/static-bugzilla.wikimedia.org.erb
index 62a7c73..15e55a1 100644
--- a/modules/bugzilla_static/templates/apache/static-bugzilla.wikimedia.org.erb
+++ b/modules/bugzilla_static/templates/apache/static-bugzilla.wikimedia.org.erb
@@ -29,9 +29,7 @@
 
 Options Indexes FollowSymLinks MultiViews
 AllowOverride None
-Order allow,deny
-Deny from env=nobots
-allow from all
+Require all granted
 
 
 ErrorLog /var/log/apache2/error.log

-- 
To view, visit https://gerrit.wikimedia.org/r/222692
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I91b8d3d9e604fabcecb092b7352c3330f466a722
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Dzahn 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] add HTTPS variants for wmfblog in feed whitelists - change (operations/mediawiki-config)

2015-07-03 Thread Jeremyb (Code Review)
Jeremyb has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222691

Change subject: add HTTPS variants for wmfblog in  feed whitelists
..

add HTTPS variants for wmfblog in  feed whitelists

Bug: T104727
Change-Id: I38082f7720bce5ba6647018eb54d40f9a5e537d1
---
M wmf-config/InitialiseSettings.php
1 file changed, 4 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/91/222691/1

diff --git a/wmf-config/InitialiseSettings.php 
b/wmf-config/InitialiseSettings.php
index da50cfe..9dabaac 100644
--- a/wmf-config/InitialiseSettings.php
+++ b/wmf-config/InitialiseSettings.php
@@ -12794,9 +12794,13 @@
'http://blog.wikimedia.org/feed/',
'http://blog.wikimedia.org/c/our-wikis/wikimediacommons/feed/',

'http://blog.wikimedia.org/c/communications/picture-of-the-day/feed/',
+   'https://blog.wikimedia.org/feed/',
+   'https://blog.wikimedia.org/c/our-wikis/wikimediacommons/feed/',
+   
'https://blog.wikimedia.org/c/communications/picture-of-the-day/feed/',
),
'mediawikiwiki' => array(
'http://blog.wikimedia.org/feed/',
+   'https://blog.wikimedia.org/feed/',

'https://git.wikimedia.org/feed/mediawiki/extensions/Translate.git',

'https://mingle.corp.wikimedia.org/projects/analytics/feeds/8z8k6vUfniLmWc2qGe6GMQsxBujvKRKuybLd8mdTbMFHwGfLH3oxK*MU0E8zM6go.atom',

'https://bugzilla.wikimedia.org/buglist.cgi?bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=PATCH_TO_REVIEW'

-- 
To view, visit https://gerrit.wikimedia.org/r/222691
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I38082f7720bce5ba6647018eb54d40f9a5e537d1
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Jeremyb 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] labstore: Minor code cleanup of the exports daemon - change (operations/puppet)

2015-07-03 Thread Yuvipanda (Code Review)
Yuvipanda has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222690

Change subject: labstore: Minor code cleanup of the exports daemon
..

labstore: Minor code cleanup of the exports daemon

Change-Id: I5f39013beaceee39d2a05fdc1ed43ac92e5ad79e
---
M modules/labstore/files/nfs-project-exports-daemon
1 file changed, 21 insertions(+), 12 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/90/222690/1

diff --git a/modules/labstore/files/nfs-project-exports-daemon 
b/modules/labstore/files/nfs-project-exports-daemon
index 47901df..998e8ca 100755
--- a/modules/labstore/files/nfs-project-exports-daemon
+++ b/modules/labstore/files/nfs-project-exports-daemon
@@ -122,23 +122,21 @@
 logging.info('Fetched config for project %s, with %s instances',
  name, len(project.instance_ips))
 
-return projects
-
-
-def manage_exports(exports_d_base, projects_config_path):
-"""
-Collects projets that need exports, and then do the exports
-"""
-projects = get_projects_with_nfs(projects_config_path)
-logging.info("Found %s projects requiring private mounts", len(projects))
-
 # Validate that there are no duplicate gids
-gids = [project.gid for project in projects]
+gids = [p.gid for p in projects]
 if len(set(gids)) != len(gids):
 # OMG DUPLICATES
 logging.error('Duplicate GIDs found in project config, aborting')
 sys.exit(1)
 
+logging.info("Found %s projects requiring private mounts", len(projects))
+return projects
+
+
+def sync_exports_files(projects, exports_d_base):
+"""
+Generate exports files for syncfs
+"""
 for project in projects:
 logging.debug('Writing exports file for %s', project.name)
 path = os.path.join(exports_d_base, '%s.exports' % project.name)
@@ -147,6 +145,9 @@
 logging.info('Wrote exports file for %s', project.name)
 
 logging.debug('Attempting to exportfs')
+
+
+def exportfs():
 try:
 subprocess.check_call([
 '/usr/bin/sudo',
@@ -173,6 +174,11 @@
 help='Turn on debug logging',
 action='store_true'
 )
+argparser.add_argument(
+'--dry-run',
+help='Do a dry run, do not call exportfs',
+action='store_true'
+)
 
 args = argparser.parse_args()
 
@@ -188,5 +194,8 @@
 logging.info('Daemon starting')
 
 while True:
-manage_exports(args.exports_d_path, args.projects_config_path)
+projects = get_projects_with_nfs(args.projects_config_path)
+sync_exports_files(projects, args.exports_d_path)
+if not args._dry_run:
+exportfs()
 time.sleep(60)

-- 
To view, visit https://gerrit.wikimedia.org/r/222690
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5f39013beaceee39d2a05fdc1ed43ac92e5ad79e
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Yuvipanda 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 9e730bf..422d824 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has submitted this change and it was merged.

Change subject: Syncronize VisualEditor: 9e730bf..422d824
..


Syncronize VisualEditor: 9e730bf..422d824

Change-Id: I9e8a014a419eba0c04dcd019253ec2e8f05766f0
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)

Approvals:
  Jenkins-mwext-sync: Verified; Looks good to me, approved



diff --git a/VisualEditor b/VisualEditor
index 9e730bf..422d824 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 9e730bf5288913c43d0218ea3160d612166f2eb9
+Subproject commit 422d82448d0e173367438e5537c93edd6c4f0a8c

-- 
To view, visit https://gerrit.wikimedia.org/r/222689
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I9e8a014a419eba0c04dcd019253ec2e8f05766f0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 
Gerrit-Reviewer: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Syncronize VisualEditor: 9e730bf..422d824 - change (mediawiki/extensions)

2015-07-03 Thread Jenkins-mwext-sync (Code Review)
Jenkins-mwext-sync has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222689

Change subject: Syncronize VisualEditor: 9e730bf..422d824
..

Syncronize VisualEditor: 9e730bf..422d824

Change-Id: I9e8a014a419eba0c04dcd019253ec2e8f05766f0
---
M VisualEditor
1 file changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions 
refs/changes/89/222689/1

diff --git a/VisualEditor b/VisualEditor
index 9e730bf..422d824 16
--- a/VisualEditor
+++ b/VisualEditor
-Subproject commit 9e730bf5288913c43d0218ea3160d612166f2eb9
+Subproject commit 422d82448d0e173367438e5537c93edd6c4f0a8c

-- 
To view, visit https://gerrit.wikimedia.org/r/222689
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9e8a014a419eba0c04dcd019253ec2e8f05766f0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions
Gerrit-Branch: master
Gerrit-Owner: Jenkins-mwext-sync 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Cleanup in doTableStuff - change (mediawiki/core)

2015-07-03 Thread Arlolra (Code Review)
Arlolra has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222683

Change subject: Cleanup in doTableStuff
..

Cleanup in doTableStuff

Change-Id: I75c0a943b24f96a30c6ee1efc3f0b11388f892b7
---
M includes/parser/Parser.php
1 file changed, 7 insertions(+), 6 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core 
refs/changes/83/222683/1

diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php
index 1603fc6..a745f4b 100644
--- a/includes/parser/Parser.php
+++ b/includes/parser/Parser.php
@@ -1023,6 +1023,7 @@
}
 
$first_character = $line[0];
+   $first_two = substr( $line, 0, 2 );
$matches = array();
 
if ( preg_match( '/^(:*)\{\|(.*)$/', $line, $matches ) 
) {
@@ -1042,7 +1043,7 @@
# Don't do any of the following
$out .= $outLine . "\n";
continue;
-   } elseif ( substr( $line, 0, 2 ) === '|}' ) {
+   } elseif ( $first_two === '|}' ) {
# We are ending a table
$line = '' . substr( $line, 2 );
$last_tag = array_pop( $last_tag_history );
@@ -1060,7 +1061,7 @@
}
array_pop( $tr_attributes );
$outLine = $line . str_repeat( '', 
$indent_level );
-   } elseif ( substr( $line, 0, 2 ) === '|-' ) {
+   } elseif ( $first_two === '|-' ) {
# Now we have a table row
$line = preg_replace( '#^\|-+#', '', $line );
 
@@ -1089,15 +1090,15 @@
array_push( $last_tag_history, '' );
} elseif ( $first_character === '|'
|| $first_character === '!'
-   || substr( $line, 0, 2 ) === '|+'
+   || $first_two === '|+'
) {
# This might be cell elements, td, th or 
captions
-   if ( substr( $line, 0, 2 ) === '|+' ) {
+   if ( $first_two === '|+' ) {
$first_character = '+';
+   $line = substr( $line, 2 );
+   } else {
$line = substr( $line, 1 );
}
-
-   $line = substr( $line, 1 );
 
if ( $first_character === '!' ) {
$line = str_replace( '!!', '||', $line 
);

-- 
To view, visit https://gerrit.wikimedia.org/r/222683
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I75c0a943b24f96a30c6ee1efc3f0b11388f892b7
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Arlolra 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] mediawiki apache config: don't load mod_deflate on HHVMs - change (operations/puppet)

2015-07-03 Thread Ori.livneh (Code Review)
Ori.livneh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222673

Change subject: mediawiki apache config: don't load mod_deflate on HHVMs
..

mediawiki apache config: don't load mod_deflate on HHVMs

The combination of mod_deflate and mod_fastcgi cause Apache to send responses
with a Content-Length header that does not agree with the actual response size.
This is suspected to be the cause of errors on the HHVM scaler.
See .

Change-Id: I16c378ddccdc7e6e51b1c69c1cde9269843b909d
---
M modules/mediawiki/files/apache/sites/main.conf
1 file changed, 3 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/puppet 
refs/changes/73/222673/1

diff --git a/modules/mediawiki/files/apache/sites/main.conf 
b/modules/mediawiki/files/apache/sites/main.conf
index b6d12fb..bed09f3 100644
--- a/modules/mediawiki/files/apache/sites/main.conf
+++ b/modules/mediawiki/files/apache/sites/main.conf
@@ -816,7 +816,9 @@
 Alias /zh-tw /srv/mediawiki/docroot/wikivoyage.org/w/index.php
 
 
-LoadModule deflate_module /usr/lib/apache2/modules/mod_deflate.so
+
+LoadModule deflate_module /usr/lib/apache2/modules/mod_deflate.so
+
 
 
 AddOutputFilterByType DEFLATE text/css text/javascript 
application/x-javascript

-- 
To view, visit https://gerrit.wikimedia.org/r/222673
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I16c378ddccdc7e6e51b1c69c1cde9269843b909d
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ori.livneh 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] chmod 644 a few files - change (mediawiki...Echo)

2015-07-03 Thread Alex Monk (Code Review)
Alex Monk has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/222629

Change subject: chmod 644 a few files
..

chmod 644 a few files

Bug: T104721
Change-Id: Iee1ef18d3227807110d4e25f0c48f17907adf8ad
---
M Gemfile
M Hooks.php
M includes/EmailBundler.php
M scripts/generatecss.php
4 files changed, 0 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Echo 
refs/changes/29/222629/1

diff --git a/Gemfile b/Gemfile
old mode 100755
new mode 100644
diff --git a/Hooks.php b/Hooks.php
old mode 100755
new mode 100644
diff --git a/includes/EmailBundler.php b/includes/EmailBundler.php
old mode 100755
new mode 100644
diff --git a/scripts/generatecss.php b/scripts/generatecss.php
old mode 100755
new mode 100644

-- 
To view, visit https://gerrit.wikimedia.org/r/222629
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iee1ef18d3227807110d4e25f0c48f17907adf8ad
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Echo
Gerrit-Branch: master
Gerrit-Owner: Alex Monk 

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


[MediaWiki-commits] [Gerrit] Reload collection when exiting overlay after making changes. - change (mediawiki...Gather)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Reload collection when exiting overlay after making changes.
..


Reload collection when exiting overlay after making changes.

* Reload collection if collection settings were changed and overlay
** Was exited by clicking the back or cancel button.
* If collection name changes, reload with correct url.

Bug: T104025
Change-Id: I991dc45335e0c5b97b335af795628147799b76b5
---
M resources/ext.gather.collection.editor/CollectionEditOverlay.js
1 file changed, 28 insertions(+), 6 deletions(-)

Approvals:
  Jdlrobson: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/resources/ext.gather.collection.editor/CollectionEditOverlay.js 
b/resources/ext.gather.collection.editor/CollectionEditOverlay.js
index 37427be..490386b 100644
--- a/resources/ext.gather.collection.editor/CollectionEditOverlay.js
+++ b/resources/ext.gather.collection.editor/CollectionEditOverlay.js
@@ -94,7 +94,8 @@
'input .search-header input': 'onRunSearch',
'click .search-header .back': 'onExitSearch',
'click .save-description': 'onSaveDescriptionClick',
-   'click .back': 'onBackClick',
+   'click .back': 'onSettingsBackClick',
+   'click .cancel': 'onCancelClick',
'click .save': 'onFirstPaneSaveClick',
'click .collection-privacy': 'onToggleCollectionPrivacy'
} ),
@@ -106,8 +107,13 @@
} ),
/** @inheritdoc */
initialize: function ( options ) {
+   // Initial properties;
+   this.id = null;
+   this.originalTitle = '';
+
if ( options && options.collection ) {
this.id = options.collection.id;
+   this.originalTitle = options.collection.title;
} else {
options.collection = {
// New collection is public by default
@@ -121,13 +127,11 @@
},
/** @inheritdoc */
postRender: function () {
-   var id = this.id;
Overlay.prototype.postRender.apply( this, arguments );
 
-   if ( id ) {
+   if ( this.id ) {
this._populateCollectionMembers();
} else {
-   this.id = null;
this._switchToSettingsPane();
}
},
@@ -300,9 +304,18 @@
deleteOverlay.show();
},
/**
+* Event handler when the cancel (back) button is clicked on 
the edit pane.
+*/
+   onCancelClick: function () {
+   Overlay.prototype.onExit.apply( this, arguments );
+   if ( this._stateChanged ) {
+   this._reloadCollection();
+   }
+   },
+   /**
 * Event handler when the back button is clicked on the 
title/edit description pane.
 */
-   onBackClick: function () {
+   onSettingsBackClick: function () {
if ( this.id ) {
// reset the values to their original values.
this.$( 'input.title' ).val( 
this.options.collection.title );
@@ -320,9 +333,18 @@
_reloadCollection: function () {
var self = this;
window.setTimeout( function () {
+   var collection;
router.navigate( '/' );
if ( self.options.reloadOnSave ) {
-   window.location.reload();
+   collection = self.options.collection;
+   // Reload collection with updated title 
in url
+   if ( self.originalTitle !== 
collection.title ) {
+   window.location.href = 
mw.util.getUrl(
+   [ 'Special:Gather', 
'id', collection.id, collection.title ].join( '/' )
+   );
+   } else {
+   window.location.reload();
+   }
}
}, 100 );
},

-- 
To view, visit https://gerrit.wikimedia.org/r/221772
To un

[MediaWiki-commits] [Gerrit] Recursively create the graphviz images directory - change (mediawiki...GraphViz)

2015-07-03 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Recursively create the graphviz images directory
..


Recursively create the graphviz images directory

This ensures that a missing parent directory is gracefully handled.

Change-Id: Iea9e6c70d5050fcfa23166c6d49c8c153beaacae
---
M GraphViz_body.php
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Welterkj: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/GraphViz_body.php b/GraphViz_body.php
index ba61ec1..69d82d0 100644
--- a/GraphViz_body.php
+++ b/GraphViz_body.php
@@ -1750,7 +1750,7 @@
// create the output directory if it does not exist
if ( !is_dir( $uploadSubdir ) ) {
$mode = fileperms ( $wgUploadDirectory );
-   if ( !mkdir( $uploadSubdir, $mode ) ) {
+   if ( !mkdir( $uploadSubdir, $mode, true ) ) {
wfDebug( __METHOD__ . ": mkdir($uploadSubdir, 
$mode) failed\n" );
return false;
}

-- 
To view, visit https://gerrit.wikimedia.org/r/207402
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iea9e6c70d5050fcfa23166c6d49c8c153beaacae
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/GraphViz
Gerrit-Branch: master
Gerrit-Owner: Rcdeboer 
Gerrit-Reviewer: Welterkj 
Gerrit-Reviewer: jenkins-bot <>

___
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits


  1   2   3   >