I propose not to update pywikibot directly from master branch but from last published tag. The reason is that master is under perpetual development and may contain bugs from recently committed patches whereas tags are more like a stable release and are deployed after the recent tests are sucessfull. Tags are published currently every month. Refer the HISTORY.rst or this release history: https://pypi.org/project/pywikibot/#history
Description
Status | Subtype | Assigned | Task | ||
---|---|---|---|---|---|
Resolved | Xqt | T217908 Don't update pywikibot directly from master but from last published tag | |||
Resolved | Dvorapa | T217236 Fix not working links to recent changes and remove outdated content from webservice | |||
Open | None | T219059 Fix installation steps all over the docs to point to the stable tag by default |
Event Timeline
We're currently cloning from core and pulling on every user start. To change that we'd need to change this line in the singleuser Dockerfile https://github.com/yuvipanda/paws/blob/087d0ecf3c13f22319f20329ee30b4d4b87b4aa8/images/singleuser/Dockerfile#L124
@Xqt Any thoughts on what tag to consistently clone?
We're currently going for https://gerrit.wikimedia.org/r/pywikibot/core.git.
It seems cloning from master is the recommend install method at https://www.mediawiki.org/wiki/Manual:Pywikibot/Installation
No, it recommends to download the code from http://tools.wmflabs.org/pywikibot/ where it is packaged both from current master and also from 1 week old master commit. @Xqt I would cancel the webpage and redirect it to pip downloads page. What do you think?
That's correct. Alternatively ... for active bot operators and developers I would just reword it to experienced bot operators and developers as in English these two words have slightly different meaning. But that's not recommended for regular users
Please document a standard, repeatable and cheap way to install and update pywikibot on PAWS.
I would personally fetch the current remote master and then checkout last tag (Can be found using git tag | tail -1) every time new tag is created, because pip package contains only library parts, not the full package, so it it not good for PAWS.
And that's what is suggested in the task's description actually!
For PAWS (and we should use this way also in user docs):
$ git clone --recursive --branch $(git tag | tail -1) https://gerrit.wikimedia.org/r/pywikibot/core.git
Oh I see. Then:
a)
$ git clone --recursive --branch $(curl pip latest version somehow?) https://gerrit.wikimedia.org/r/pywikibot/core.git
b) (we should find a shortcut for users)
$ git clone --recursive https://gerrit.wikimedia.org/r/pywikibot/core.git $ cd core $ git checkout $(git tag | tail -1)
I propose another way:
Currently a new version tag like 3.0.20190301 is created every month if 5 tests passed on travis and appveyor is green. The library part is uploaded to pypi then. I would create a new tag stable (which indicates a stable release whereas master is under perpetual development) which always is the same commit as the last published release tag. This ensures that teh repository can always be cloned with
git clone --branch stable "https://gerrit.wikimedia.org/r/pywikibot/core"
and updated with
git pull "origin" stable
I need to investigate it. I'll create a task for it, I think it is likely a requirement not being pinned and a new version clashing with another package.
Mentioned in SAL (#wikimedia-cloud) [2019-05-18T11:13:41Z] <chicocvenancio> PAWS update helm chart to point to new singleuser image (T217908)