[pr-docs][startup] Add docs/testing-prs.md: build and test a pull request without having built Darner before #203
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
hle
input
INTEL
lighting
linux-proton
memory
MULDER
needs-info
needs-logs
needs-rebase
NVIDIA
performance
post-merge
pr-diagnostics
pr-docs
pre-merge
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
relevance
high
relevance
low
relevance
medium
relevance
very-high
rendering
report
roadmap-proposal
saves
series-s
shaders
startup
status
blocked-by-rework
status
needs-test-report
status
needs-triage
status
ready-for-review
status
stale
status
superseded
status
wip
tools
ui
upstream
wontfix
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
TrustNo1/Darner!203
Loading…
Reference in a new issue
No description provided.
Delete branch "Jesper-A/Darner:up-docs-testing-prs"
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?
Related: #167 asks whether dev builds should have one way in; the page names today's
scripts\play-nvidia.ps1and will follow if that changes.What it changes
CONTRIBUTING.mdsays testing someone else's pull request is the most useful thing to do, but gives no steps.Adds
docs/testing-prs.md, a copy-and-paste guide, and one sentence inCONTRIBUTING.mdthat links to it. It covers:wingetinstalls of Git, Rustup and the Visual Studio 2022 Build Tools with the C++ workload (Microsoft.VisualStudio.Workload.VCTools, with--includeRecommended, and--wait --passivebecause--overridereplaces winget's own installer arguments);git fetch origin refs/pull/<N>/head, thengit checkout <the verified 40-character commit>;Get-NVIDIA-DLSS.cmd, thenscripts\play-nvidia.ps1 -Exe ... -More '<SWITCH>';-Dlss off);Why a pinned commit and a build, not a downloaded exe: testers build a commit that someone checked first, named by its full hash. A pull request can be changed after it was checked, and a downloaded exe from an unchecked pull request could be malicious. If the pull request moved,
git checkoutfails with "reference is not a tree" and the page tells the tester to wait. This came out of a Fluxer discussion on 2026-12-04 with xrobau and TrustNo1. The Fluxer bot will post a thread per pull request that fills in N, the commit and the switch, and links to this page.How it was tested
up-docs-testing-prs, based ontrustno1/mainf3840d73d).cargo clippy --workspace --all-targets --locked -- -D warnings, the same with--all-features,cargo test --workspace --locked) none applies to a docs-only diff and none was run.cargo xtask policy: not run. The facts the page states were checked againsttrustno1/mainby readingscripts/play-nvidia.ps1,rust-toolchain.tomlandGet-NVIDIA-DLSS.cmd.play-nvidia.ps1line with-Morewas not run end to end from a fresh clone of the final page.play-nvidia.ps1: without the NVIDIA files it printslauncher.sdk.nvidia_missingand plays on, and-Dlss offskips the check.scripts/build-darner.ps1andplay.ps1), the page follows the new names.Spec dependence
Likely general: the page is about Windows tools and git. The play line was read for an NVIDIA card; AMD and Intel are untested. Nothing here depends on the author's hardware (RTX 2070 SUPER, ReBAR off).
Checklist
main.docs/asset-policy.md. No game data, names or screenshots.Checked for overlap
README.mdonly, no install orrefs/pullsteps), #152 (docs/ab-testing.md). Related issue: #167 (question about launcher names).This change was made with AI assistance (Claude Code).
I tested the section 2 copy-and-paste block at
4d6960aaa178with Windows PowerShell 5.1 and Git 2.53.0.windows.1, using a local two-commit repository and a print marker in place of the downloader. With a valid pin, the marker ran on the intended commit. With an unknown pin,git checkoutexited 128, but the marker still ran on the default commit. A failed clone into an existing directory also continued to the next line.Please put the sequence in a single
& { … }block that checks$LASTEXITCODEafter each Git command, usesSet-Location -ErrorAction Stop, and verifies thatgit rev-parse --verify HEADsucceeds and equals the full pin before the downloader runs. In the same fixture this preserved the successful case and stopped all three failure cases (unknown pin, existing non-repository directory, existing clone). No SDK or game was run.Thanks for testing this, and for the fixture. You were right: the line-by-line paste carried on after a failed clone or checkout.
Fixed in
2a01b3b78. Section 2 is now one& { }block that:$LASTEXITCODEafter clone, fetch and checkout;cd ... -ErrorAction Stop;(git rev-parse HEAD)with the pinned commit beforeGet-NVIDIA-DLSS.cmdruns;One difference from your suggestion: I used
git rev-parse HEADwithout--verify. After a checkout a detached HEAD always resolves, so the comparison checks the same thing.I ran it in a local fixture repository with a pull ref, with the downloader replaced by an echo. Windows PowerShell 5.1:
PowerShell 7: the valid and unknown-pin cases behave the same. No SDK or game was run.
The same commit also adds
--norestartto the Build Tools line, so the installer doesn't ask for a restart during setup.This comment was written with AI assistance (Claude Code).
WIP: [pr-docs][startup] Add docs/testing-prs.md: build and test a pull request without having built Darner beforeto [pr-docs][startup] Add docs/testing-prs.md: build and test a pull request without having built Darner beforeReview of
2a01b3b7(read only):The new step 2 block is right. It checks
$LASTEXITCODEafter clone, fetch and checkout, comparesHEADwith the pinned commit, andreturnstops the block.cdinside& { }still moves the window's location, so step 3 runs in the clone as intended.One blocker is still open: the last line says the player's own Darner folder and settings are not changed. They are.
scripts\play-nvidia.ps1usesDARNER_HOME, which defaults to%LOCALAPPDATA%\darner, the same folder as the released darner.exe (settings, logs, shader and pipeline caches). A PR build with another translator starts a new pipeline library there and replaces the player's (main34b0ba77), so their next normal start compiles everything again. Please add, before the play line in step 3:and say that the first start there compiles shaders (stutter, or run a preload). Then the last line is true.
Small:
-Builddefaults tofast, which isn't fully optimised. For fps comparisons, use-Build releaseon both runs or say both used the same build.Ready to merge once the
DARNER_HOMEline is in.Thanks. Fixed in
cdb6920bf:$env:DARNER_HOME = "$PWD\test-home"on the line before the play line, so the settings, logs and caches go to atest-homefolder in the clone. It says the first start there compiles shaders (stutter, or let the preload run), and that the variable has to be set again in a new window.test-home\logs\, and the last line says the player's own folder is unchanged withDARNER_HOMEset.fastbuild is not fully optimised: use-Build releaseon both runs, or say both used the same build.Not run: no build or game start with the new line; only the text changed.
This comment was written with AI assistance (Claude Code).
Review of
cdb6920b(read only): the blocker is fixed. With$env:DARNER_HOME = "$PWD\test-home"in step 3,play-nvidia.ps1keeps the settings, logs and caches in the clone, so the closing line is now true. The fresh-cache stutter note, the-Build releasenote and the new log path are all right. Nothing is left open: ready to merge.