WIP: build: add a mise game build task #860
No reviewers
Labels
No labels
area/accessibility
area/audio
area/input
area/install
area/menu
area/renderer
area/saves
area/upscaling
beanstalk: approved @ 1697603
beanstalk: approved @ 2c5a62e
beanstalk: approved @ 4fd82b7
beanstalk: approved @ 64d6d09
beanstalk: approved @ 6f91fae
beanstalk: approved @ 70a78f9
beanstalk: approved @ 8015c9a
beanstalk: approved @ 8d361dc
beanstalk: approved @ 9d8356e
beanstalk: approved @ abf2227
beanstalk: approved @ d82f202
beanstalk: approved @ e5f1e40
beanstalk: approved @ ee8ab5f
ci: approved
good first issue
gpu/amd
gpu/igpu
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
needs measurements
platform/linux
platform/macos
platform/steam-deck
platform/windows
preview
priority
critical
priority
high
priority
low
regression
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
testing wanted
ci: approved
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/Longshot!860
Loading…
Reference in a new issue
No description provided.
Delete branch "Marcuss2/Longshot:builder/mise-build-task"
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?
Type: build · Risk: low · Tested on: Linux, mise 2026.11.8, game-free checks and a full local build; no GPU run · Needs: Windows and a Vulkan 1.3 GPU for
run-winWhy
Mise now centralizes Longshot's task runner, but building a game still requires knowing the Python script and its
prerequisites.
mise run buildshould provide that entry point alongsidemise run testandmise run lint, acceptingthe same dump and output arguments as the builder. No open issue covers this follow-up to the mise migration #417.
What changed
Add a mise
buildtask that installs the pinned builder prerequisites and forwards its complete argument list directlyto
nx2/make_game.py. Make it discoverable to contributors and agents, with an argv regression test rather than only aconfiguration string check.
mise.toml:setup,build,build-dev,build-fastandpacksinstallrequirements.txtthrough a hiddenbuild-depshelper.build-devcompiles the existing standalone tree (4 jobs);build-fastselects the documenteddevelopment-only
-O1mode (8 jobs);packsforwards todev_packs.py; and Windows-onlyrun-windelegates toscripts/run-vk.ps1. Every argument passthrough uses"$@", preserving spaces, brackets and trailing backslashes.tests/test_mise_build.py: parses the declaration and executes a fake builder through mise with synthetic arguments;no dump or real build is needed for this test.
CONTRIBUTING.md:mise tasks,mise run buildandmise execexamples, including the automatic requirementsinstallation and a dump-version check.
AGENTS.md:mise tasksleads the disk discovery section; agents prefer listed tasks, and the testing advice matchesthe new CircleCI workflow.
Measurements
N/A — task discovery and argument forwarding only; no game code or performance behavior changes. Before: main @
b7a014b8had no build task; After: this PR @50bf5e74runs the full requested Linux build from a fresh mise Python setup and exposes the standalone development commands.Flags and settings
None — no game flags or settings changed. The only new task setting is
depends = ["build-deps"]andhide = trueon the dependency helper.
Testing
Tested: on Linux:
mise run build --nup <escaped .nup with spaces and brackets> --out build --language en-US:full build completed with exit code 0 on
5ebabeb5, and again on the final rebasedc4b6a640head. Shell escapingis preserved by
"$@".python -I -B tests/test_mise_build.py: 3 tests passed, including actual argv recording through a fake builder with aspaced path and a trailing-Windows-backslash output path, the new tasks' declarations, and the standalone/packs help
entry points without starting a build.
mise run setup: installed the git hooks with all Python requirements already satisfied, exit 0.7ffd87ba, before the final task-only rebase: a fresh local dump preparation (nx2/dump.py --setthennx2/lift.py --standalone --write) followed bymise run build-dev: 489 files compiled in 744 seconds with zero failures;work/sa/build/longshot(440 MB) andlongshot_vk.so(14 MB) linked successfully.mise run build-fast -- --dry-run: exit 0, reporting a dry host-buildplan without compiling. These are invocation checks, not performance measurements.
mise run test -- mise_build: 1 passed through the strict task runner.mise taskslistings were checked forbuild,build-dev,build-fast,packs,run-winandsetup.mise run lint: pre-commit and actionlint passed.mise taskslistsbuildand keeps the internal dependency hidden.mise run testat theb7a014b8checkpoint: 518 passed, 61 failed, 16 skipped. Base at that checkpoint: 517 passed, 61 failed, 16 skipped;the additional passing test is
tests/test_mise_build.py. The strict failures are outside this change's four files,including
test_lift_cleanup_error.py,test_make_game_cache.py,test_crash_dialog.py,test_cpm_discovery.py,test_env_on.py,test_pipeline_tour.py,test_vk_pgo.pyand 48 strict header/tool checks also present on base.mise run deps: passed after retry once the sequential package-index job finished; the earlier parallel pip setupattempt failed and was not used as a test result.
Not tested: Windows task execution, the
run-winlauncher, a real Windows build, or an in-game GPU run. No game code changed.build-devandbuild-fastrequire the existing standalone lift documented in CONTRIBUTING.md; they do not synthesize it.Must be tested:
mise tasksandpython -I -B tests/test_mise_build.py, expecting all commands in the list and 3 tests passed; runmise run run-win -Seconds 2 -Name mise-smoke, expecting a short windowed run and an automatic clean quit, with logs and shots kept underwork/runs/mise-smoke/.Risks
Low: a thin change to an existing task runner plus docs.
build-depscontacts Python package indexes and installs thepinned requirements before building; subsequent runs use already installed packages. No game data is sent and no
compiler, linker, optimization or output-folder behavior changes.
Compatibility
MkwVkHost/MkwVkRendererABI: unchanged,MKWVK_API_VERSIONnot bumped.nx2/make_game.py; direct use remains possible outside mise.lint,test,depsandvalidatetasks and all CircleCI jobs are unchanged; no workflow files are added.setupalso installs the build requirements, while the new build/pack/run commands are explicit invocations, never automatic changes.Checklist
Everyone
type(scope): description) of the status line's type.main. The final head50bf5e74is based on999102a6,origin/mainat the last fetch; lint and the focused task suite were rerun at this head. Full builds ran on the same wrappers before that final task-only rebase.python -I -B tests/run_all.pypasses (any failure that also fails onmainis named).mise run testhas the same strict total as base plus this new passing test; representative and strict-tool failures are named above.third_party/untouched (a new folder with aPROVENANCE.mdinstead). No third-party files change on this PR.When it applies
tests/that reads changed source updated in this PR, not weakened. The new test asserts the task declaration and the real argv mise supplies.5ebabeb520c4b6a640e4Rebased onto current main @
1310ecc6asc4b6a640and force-pushed with lease. mise lint and the focused mise_build check pass again; the exact escaped-path full Linux build also passed on this head. The description keeps the earlier strict base comparison as a separate checkpoint.Added the requested setup and development commands in
7ffd87ba: setup now installs build requirements; build-dev compiles the current standalone tree; build-fast wraps the documented development-only -O1 route; packs forwards to dev_packs.py; and Windows-only run-win uses the existing guarded PowerShell launcher. Tests now cover these declarations and help entry points. Real verification: setup passed, all 3 task tests passed, lint passed, a fresh standalone lift and build-dev compiled and linked successfully, and build-fast dry-run passed.7ffd87ba7b50bf5e740dRebased both task commits onto latest main @
999102a6; new head50bf5e74. Focused mise tests and lint pass again at this head. The detailed description distinguishes the earlier full build verification (same wrapper code) from the final rebase checks.50bf5e740d38ad084a57Rebased onto
main@bbe6fdf: no conflicts. No tests were run here; the test boxes stay yours.Could someone test it on Windows? Then I can remove the
WIPtag.Windows test of PR #860 at
38ad084a572ab15f11f580273e787953e2bef843(basebbe6fdf): mixed; the wrappers work with environment workarounds, but the requested run does not close cleanly.Windows 11 Home, i5-13420H, 32 GB RAM, RTX 4050 Laptop 6 GB (driver 621.14). Tools: mise 2026.11.8 windows-x64, its pinned Python 3.12.15, Git Bash. Used a separate tooling environment and test user directory.
Task checks
mise taskslists the new commands.test_standalone_and_packs_helpfails for build-dev, build-fast and packs before their commands run:aqua:pre-commit/[email protected]reportsunsupported env: windows/amd64 (supported: ["darwin", "linux"]). That tool declaration already exists in the base; this is not a new declaration in #860.MISE_DISABLE_TOOLS=aqua:pre-commit/pre-commit, all 3 focused tests pass. The pinned build requirements install into mise's isolated Python, and the development/packs help entry points work.run-wincheckRestricted:scripts/run-vk.ps1 cannot be loaded because running scripts is disabled.PSExecutionPolicyPreference=RemoteSignedin the child process environment. The machine policy stayedRestrictedafterward.mise run run-win -Seconds 2 -Name mise-smoke-860 -Romfs <existing-romfs> -Priority BelowNormalthen returned exit 0: peak working set 1059 MB,stopped after 2 s. It launched an isolated copy of the existing Nightly 189 executable, not a newly rebuilt game at this PR head. The log reached NVIDIA Vulkan device enumeration; no screenshots were produced in that short run.Stop-Process -Forcetimeout path: task exit 0 is not a graceful-shutdown pass. This observation is not evidence of an out-of-memory crash.Suggested follow-ups: document/provide Windows-compatible tooling prerequisites and the script-execution prerequisite, and handle expected timeout termination so it does not produce a misleading crash dialog (prefer a graceful stop where possible).
All 14 normal save files were hash-verified unchanged. Not tested: a full Windows rebuild at this PR head, the full game-free suite, gameplay/FPS, or a successful graceful shutdown. No game files, saves or raw traces are attached.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.