Refuse a game folder whose path leaves no room for the game's files.

Windows and the build tools stop at 260 characters for a file's whole path, and a built game needs up to 128 below
its folder. A deeper folder made the build stop in the middle with a file "not found"; Begin Installation and the
install job now refuse it first and name both lengths.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-12 22:24:26 -05:00
parent 0a85e33e0f
commit 8c32aedabb
5 changed files with 71 additions and 1 deletions

View File

@@ -9,7 +9,7 @@ import threading
import time
import traceback
from . import build, feed, gamefiles, locks, net, toolchain, updater, versions, winsys
from . import build, feed, gamefiles, locks, net, paths, toolchain, updater, versions, winsys
RECHECK = 3600 # seconds between update checks while the launcher stays open, hidden during play included
@@ -456,6 +456,9 @@ class InstallJob(Job):
return build.install_args(self.ctx.layout, self.dump, self.game_dir)
def run(self):
too_long = paths.long_path_problem(self.game_dir) # the window asks first (begin_install); the command line here
if too_long:
raise build.BuildError(too_long)
self.ensure_tools('tools')
self.make_game(self.args(),
{s: s for s in ('check', 'exefs', 'romfs', 'lift', 'compile', 'shaders', 'prompts', 'scan')})