Last modified: 2014-08-05 10:04:24 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T64509, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 62509 - investigate updating test2 Jenkins builds weekly to pull by branch
investigate updating test2 Jenkins builds weekly to pull by branch
Status: RESOLVED FIXED
Product: Wikimedia
Classification: Unclassified
Quality Assurance (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Antoine "hashar" Musso (WMF)
:
: 64611 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-03-10 20:38 UTC by Chris McMahon
Modified: 2014-08-05 10:04 UTC (History)
4 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Chris McMahon 2014-03-10 20:38:40 UTC
I learned today from Rob Lanphier that it has recently become possible to do this reliably in every extension repo as well as mw core: 

$ git checkout wmf/1.23wmf17


For example: 

/VisualEditor$ git checkout wmf/1.23wmf17
Branch wmf/1.23wmf17 set up to track remote branch wmf/1.23wmf17 from origin.
Switched to a new branch 'wmf/1.23wmf17'

The current branch of each wiki is tracked in https://git.wikimedia.org/blob/operations%2Fmediawiki-config/HEAD/wikiversions.json

The current branch of core (which should be consistent across all extensions also) is available on https://test2.wikipedia.org/wiki/Special:Version (and theoretically in the API somewhere)

It would be good if we could change our Jenkins builds with test2 as a target to pull the current wmf branch instead of master. 

In the short term, we could update the build config manually every Thursday. 

In the slightly longer term it should be possible to read Special:Version or the wikiversions.json file in order to determine at run time the proper version of the tests appropriate for test2 (and any other target environment not beta labs, e.g. enwiki or commons)
Comment 1 Antoine "hashar" Musso (WMF) 2014-04-29 16:29:09 UTC
*** Bug 64611 has been marked as a duplicate of this bug. ***
Comment 2 Antoine "hashar" Musso (WMF) 2014-04-29 16:29:37 UTC
From bug 64611:

When browsertests hit the production wikis, we should fetch the extension wmf branch that match the targeted website.  The mapping of wiki vs wmf branch can be found via the dblist files in operations/mediawiki-config.git

Instead of using the Jenkins git plugin, we will have to use a script to find out which branch to check.
Comment 3 Antoine "hashar" Musso (WMF) 2014-05-06 16:33:41 UTC
I am pretty sure I have a good idea about fixing this :-]
Comment 4 Gerrit Notification Bot 2014-05-06 19:32:01 UTC
Change 131768 had a related patch set uploaded by Hashar:
Api: expose git branch in siteinfo

https://gerrit.wikimedia.org/r/131768
Comment 5 Gerrit Notification Bot 2014-05-06 20:27:33 UTC
Change 131861 had a related patch set uploaded by Hashar:
mw-api-siteinfo: fetch siteinfo from MW API

https://gerrit.wikimedia.org/r/131861
Comment 6 Antoine "hashar" Musso (WMF) 2014-05-06 20:29:41 UTC
The mw-api-siteinfo.py script will let us do something like:

 $ mw-api-siteinfo.py http://test2.wikipedia.org/ git_branch
 1.24wmf2
 $

We can then checkout that branch in the extensions to run the matching set of browser tests.
Comment 7 Gerrit Notification Bot 2014-05-07 00:30:13 UTC
Change 131768 merged by jenkins-bot:
API: Expose git branch in siteinfo

https://gerrit.wikimedia.org/r/131768
Comment 8 Gerrit Notification Bot 2014-05-07 07:40:52 UTC
Change 131935 had a related patch set uploaded by Hashar:
API: Expose git branch in siteinfo

https://gerrit.wikimedia.org/r/131935
Comment 9 Gerrit Notification Bot 2014-05-07 07:41:11 UTC
Change 131936 had a related patch set uploaded by Hashar:
API: Expose git branch in siteinfo

https://gerrit.wikimedia.org/r/131936
Comment 10 Antoine "hashar" Musso (WMF) 2014-05-07 19:54:09 UTC
I will try to get it included in the currently deployed wmf installations, else the patch will land under the next two weeks.

The tiny python script will let us easily get the branch of a target wiki. Knowing it, we can then git checkout that branch before starting the browsertests.

I might be able to handle that during this week hackaton, no promise though.
Comment 11 Gerrit Notification Bot 2014-05-09 17:41:20 UTC
Change 131935 abandoned by Reedy:
API: Expose git branch in siteinfo

Reason:
1.24wmf2 is not used now

https://gerrit.wikimedia.org/r/131935
Comment 12 Gerrit Notification Bot 2014-05-12 12:37:43 UTC
Change 131936 abandoned by Hashar:
API: Expose git branch in siteinfo

Reason:
No urgency to have this deployed in 1.24wmf3 since commit is in the branch wmf/1.24wmf4 which is going to be deployed on the remaining production wikis on May 15th ( https://wikitech.wikimedia.org/wiki/Deployment ).

https://gerrit.wikimedia.org/r/131936
Comment 13 Gerrit Notification Bot 2014-05-19 20:12:20 UTC
Change 131861 merged by jenkins-bot:
mw-api-siteinfo: fetch siteinfo from MW API

https://gerrit.wikimedia.org/r/131861
Comment 14 Antoine "hashar" Musso (WMF) 2014-05-19 20:14:24 UTC
The lame mw-api-siteinfo.py is now deployed.  We can use to query the target MediaWiki installation to grab the branch and attempt to check it out before running the browser tests.

Should do git checkout -f  iirc.
Comment 15 Gerrit Notification Bot 2014-05-19 20:38:36 UTC
Change 134236 had a related patch set uploaded by Hashar:
Get mw branch from target URL and check it out

https://gerrit.wikimedia.org/r/134236
Comment 16 Gerrit Notification Bot 2014-05-20 16:05:41 UTC
Change 134376 had a related patch set uploaded by Hashar:
mw-sort-wmf-branches: sort wmf branchs numerically

https://gerrit.wikimedia.org/r/134376
Comment 17 Gerrit Notification Bot 2014-05-20 16:19:32 UTC
Change 134376 merged by jenkins-bot:
mw-sort-wmf-branches: sort wmf branchs numerically

https://gerrit.wikimedia.org/r/134376
Comment 18 Gerrit Notification Bot 2014-05-20 20:17:20 UTC
Change 134236 merged by jenkins-bot:
Get mw branch from target URL and check it out

https://gerrit.wikimedia.org/r/134236
Comment 19 Gerrit Notification Bot 2014-05-20 20:27:46 UTC
Change 134483 had a related patch set uploaded by Hashar:
Fallback to master branch when test repo miss branch

https://gerrit.wikimedia.org/r/134483
Comment 20 Gerrit Notification Bot 2014-05-20 20:29:05 UTC
Change 134483 merged by jenkins-bot:
Fallback to master branch when test repo miss branch

https://gerrit.wikimedia.org/r/134483
Comment 21 Antoine "hashar" Musso (WMF) 2014-05-20 20:30:09 UTC
I tested it on a few change and it seems to be working fine.

The qa/browsertests.git is missing wmf branches, so I have added a fallback to the 'master' branch.

Lets see what happens tomorrow :)
Comment 22 Antoine "hashar" Musso (WMF) 2014-05-21 09:31:07 UTC
Gilles from the Multimedia team reported an issue with the browser tests running some outdated version of the code.   Turns out the repo was not reset to origin/master but to local master branch.

Fixed up with https://gerrit.wikimedia.org/r/#/c/134576/
Comment 23 Antoine "hashar" Musso (WMF) 2014-08-05 10:04:24 UTC
I think this was implemented entirely back in May 2014.  The fix was to have MediaWiki API the branch it runs then have the browser test checkout the matching branch, fall backing to master if the branch is not found.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links