Repository navigation
Update feed: a hotfix's envelope is also served under its release label - #352
Merged
Merged
Conversation
A game switching to the version a server runs asks the feed for that version's envelope by its release label, and a hotfix x.y.z.w goes out as x.y.z-hotfix.w: the feed served hotfix envelopes only under x.y.z.w, so a player could not switch to a server on 1.2.0.1 or 1.2.0.2 (404). update_feed writes a hotfix's envelope, and the one it replaces, under both folders and checks both are served.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
A player on 1.2.1 could not join a server on 1.2.0.1: the game offers SWITCH TO 1.2.0.1, and the launcher asks the update feed for that version's envelope by its release label (
/v1/updates/stable/versions/1.2.0-hotfix.1/manifest), the name a hotfix x.y.z.w goes out as. The feed kept hotfix envelopes only underversions/1.2.0.1/and its route accepted only digits and dots, so the request was a 404 for every hotfix (1.2.0.1, 1.2.0.2, 1.1.3.1, ...).update_feed.py: a hotfix's envelope, and the one a release replaces, are written under both folders, its version and its release label (envelope_folders), and both are checked to be served.test_update_feed.py(in CI with the other release tool tests).Already done on the update host, so the launchers players have work now: the existing hotfix envelopes copied to their label folders, and the route widened to
([0-9]+(\.[0-9]+)*(-hotfix\.[0-9]+)?)(nginx config backed up first).https://updates.kcdsynced.com/v1/updates/stable/versions/1.2.0-hotfix.1/manifestnow answers 200 with the signed 1.2.0-hotfix.1 envelope.How it was tested
python -m unittest discover -s Dev/tools/release -p test_update_feed.py: 5 passed (folders of a version and a hotfix, the upload's moves for a new hotfix and a replaced one, verify reads both folders).kcds-launcher --version 1.2.0.1 --fetch-into <folder>, printed "KCDS 1.2.0.1 verified and installed" (before the host change it got a 404).Checklist
python Dev/tools/format_source.py --checkpasses.