The deployment prep scripts checkoutMediaWiki, deleteMediaWiki and updateWikiversions run the updateBitsBranchPointers script to maintain symlinks in the bits server's docroot. This script manages the contents of the static-current and static-stable directories.
In theory static-current should point to the static assets for the most recently deployed MW version and static-stable should point to the second oldest branch. Currently the script determines these versions not by reading wikiversions.{json,cdb} but by finding all the php-* directories in /usr/local/apache/common-local.
The checkoutMediaWiki is used to provision newly created branches on the deploy staging server (tin). One would assume that when this operation is complete the symlinks in static-current should point to the newly created branch as upon the next cluster sync (scap) that new branch will be the most current version of MW deployed. It turns out however that since this operation is performed in the staging directory (/a/common) rather than the deploy directory (/usr/local/apache/common-local) updateBitsBranchPointers will select the branch that was provisioned in the last branch deploy cycle rather than the in progress deploy cycle.
At the moment I can't link to a commit in operations/mediawiki-config.git showing this mistake in action as separate bug that was recently fixed [0] in updateBitsBranchPointers has prevented the symlinks for static-{current,stable} from being updated at all since the 1.23wmf10 branch was deployed.
[0]: https://gerrit.wikimedia.org/r/117618
Version: wmf-deployment
Severity: normal