WIP: feat(home): build a pull request's version to help test it #59
No reviewers
Labels
No labels
area/build
area/install
area/saves
area/tooling
area/ui
area/updates
ci: approved
good first issue
gpu/amd
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
platform/linux
platform/steam-deck
platform/windows
priority
critical
priority
high
priority
low
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/LongshotLauncher!59
Loading…
Reference in a new issue
No description provided.
Delete branch "gab9281/LongshotLauncher:feat/pr-builds"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why
To try a Longshot pull request today, a tester has to check it out and build it from source, so most of the hardware we need never runs a change before it is merged. This adds Build another version > A pull request to the launcher: a tester names a pull request by its number or link, and the launcher builds it on their PC, beside their other versions.
It builds the way the Test Farm's agents do (Beanstalk): the pull request's source over
tools.lock's tools. The earlier version of this PR waited for CI to publish signedpr-pre-releases. That CI was Longshot#353, now closed, and Longshot#283 keeps CircleCI artifacts only, so that design is gone, along with the pull request key it needed.Requirements and source
What changed
App/Views/ChannelPickerView.axaml,ChannelPickerViewModel): a Pull request choice beside the channels.332,#332) or its link as copied from the browser, and Find (or Enter). There is no list to browse.Core/PullRequests.cs: one pull request from the public API (an error page counts as none), drafts as Longshot's CI reads them, the platform labels, andNumberOf.Core/PullRequestSource.cs(new):archive/<full hash>.tar.gz: about 20 MB, capped at 128 MB, plain files only, nothing outside its folder.Toolchains.InstallPullRequest(new): makestoolchains/pr-<number>-<commit>from both. For what each part keeps, see docs/releases.md, "Pull request builds".tools.lockdiffers from the nightly's for this system.ToolsSource: apr-tag goes throughPullRequestSource. The wizard's later steps are unchanged.VersionsandUpdatePolicy:prtrack, thepr-<number>-<8 hex>names, and "PR #222 · 1a2b3c4d" as the shown name.HomeView.axaml,HomeViewModel,LauncherService):prand has a Read button.docs/releases.md, "Pull request builds": the flow, the trust, and why it's built on the tester's PC.tests/launcher_core/PullRequestChecks.cscovers:Problem;InstallPullRequest, checking that:tools.lockis refused and leaves nothing.tests/test_launcher_core.py: theprentries in the track vectors.Testing
Tested (Linux, .NET SDK 10.0.114, at HEAD):
dotnet build LongshotLauncher.slnx --configuration Release -p:RestoreLockedMode=true, as CI runs it: 0 warnings, 0 errors.python -I tests/test_launcher_core.py --strict --longshot <Longshot main>: 1345 checks pass.python -I tests/test_release.py: OK.scripts/translations.py: no faults.Toolchains.InstallPullRequeston real files: the installednightly-189-aa95d35ftools and the real archive of Longshot#206's head (962c5aad, 18 MB).Not tested:
Needs other testers: one pull request built from the picker on Linux and on Windows, then played.
Risk and rollback
@Beanstalk, a signed ticket for that commit, and a sandbox.🤖 Generated with Claude Code
https://claude.ai/code/session_015KgSKp43znbyyPyDajp3Cm
- ChannelPickerView.axaml declared xmlns:c twice (Avalonia AVLN1001: not valid XAML). - PullRequests.Match: letters in order are looked for within one word of the title or the author, from its first letter ("rendr" is "render"); across the whole title "hud" matched "their ... amateurwizrd", which the core's check caught. Co-Authored-By: Claude Opus 5.5 <[email protected]>b4025c1: the first compile found two faults, both fixed. ChannelPickerView.axaml declaredxmlns:ctwice, which is not valid XAML. The core's check caught the search's letters-in-order match running across the whole title and author, sohudmatched an unrelated pull request; it now matches within one word, from its first letter. Locally the Release build has 0 warnings, and test_launcher_core.py --strict and test_release.py pass. This repository's CI skips the compile on pull requests.f81cd5f,4ae4e76, from trying the picker: the search and the list sit in a box of their own; a draft (Forgejo's mark, or a WIP: or [WIP] title) is never listed, and Testing wanted stays on by default, showing every other open pull request when it is off; the choice now reads "Help the team get a better-quality port by testing features before they are merged"; and the dialog is at most 560 px tall, so Cancel and Build no longer go past the window's bottom (the choices scroll). Release build 0 warnings; test_launcher_core.py --strict and test_release.py pass.1abc2dbfixes a/code-review highof the whole pull request (10 findings). The update check now checks the launcher's own update first and asks about installed pull requests all at once; an error page about one is skipped rather than failing the check; a pull request whose builds were deleted is offered no update; and a pull request's newest build is its head's. The picker never builds a pull request the search or filter hides, picks nothing without a pull request key, says so when the builds can't be read, and works out its rows once per change. PullRequests also retries a transient failure, and release.py's download(to=) leaves no partial file. Release build: 0 warnings. test_launcher_core.py --strict and test_release.py pass, and CI passed on1abc2db(the title only: this repository's CI skips compiling on pull requests).Still incomplete, and kept in draft. The description now opens with what is missing: Longshot PR 353 and the pull request key, an end-to-end install, Windows, real screenshots, the translations, and separate saves.
Real screenshots of the picker at
1abc2db(Linux, KDE) replace the mock in the description: the new choice, Testing wanted on (the default), off (every pull request that isn't a draft), and a search. Still a draft: see the incomplete list at the top.- A pull request labelled for the other system only is not listed: platform/windows on Linux, platform/linux or platform/steam-deck on Windows (PullRequest.For); one with neither label, or both, is. A search that finds only those says so ("Only pull requests for Windows match: #12."). - The order: those the fewest people other than their author have commented on or reviewed first, then the oldest (PullRequests.Order), from Longshot's pull-requests.json (PullRequests.CountsAsync: its pull request 353's counts); without that file, the oldest first. A pull request's Created is read from the list. - docs/releases.md: the same as Longshot's copy. Co-Authored-By: Claude Opus 5.5 <[email protected]>f5a070e: a pull request labelled for the other system only is no longer listed (platform/windows on Linux; platform/linux or platform/steam-deck on Windows), and a search that finds only those says so. The order now puts first the pull requests the fewest people other than their author have looked at, then the oldest, from Longshot's pull-requests.json (PR 353's counts); without that file, oldest first. Release build 0 warnings; the core checks, with new ones for the platform rule, the counts file and the order, pass; CI passed. Still a draft.I'm removing the testing wanted thing, so let's just make it accept number or URL
f5a070e17dca8ea443ccDone in
ca8ea44, rebased on maine5c3675: the picker takes a number or a URL now.332,#332or the pull request's link as copied from the browser (https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/332, its files tab, a comment's link). Another repository's or another server's link is refused. Find (or Enter) reads that one pull request and its newest build.tests/test_launcher_core.pypasses (1341 checks) and the app builds with 0 warnings. The new box hasn't been run in the window yet, so the old screenshots are out of the description until new ones are taken.One question for #353: the launcher no longer reads
pull-requests.json(who has looked at each pull request). Should that count come out of Longshot#353 too?Longshot#353 is closed: Longshot#283 (CircleCI) builds pull requests now, and main's builder workflows run on
releaserunners only (#728). The description now says this PR still has to move its download, and its trust check, to #283's run artifacts. It stays a draft until then.7b0780b7a738f32b9f8aView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.