Make every create-error legible; walk the provider matrix (#44) - #58
Merged
Conversation
Make every create-error legible; walk the provider matrix (#44) Umbrella close-out for creation reliability. #42 (installer args-or-jar) and #43 (empty-download guard + first error messages) covered the two concrete bugs and the download hardening; this finishes the "no bare error code in the UI" and "walk the matrix" bullets. - shared/versions.ts: new pure createErrorKey(raw) -> i18n key | null, the single source of truth for code->message. Covers every code the creation path throws (audited across core/versions.ts, core/createServer.ts, core/net.ts): no-build / no-download / no-server-jar-for-version / unknown-version / no-*-build, empty-download, Checksum mismatch, HTTP <status>, installer exited, installer-args-not- found, folder-exists, no-provider-for-*. Unknown strings pass through. - CreateView: friendlyCreateError now just wraps createErrorKey, so both the toast and the progress label go through one table. - en/tr: errChecksum / errNetwork / errInstaller / errUnsupportedType added; errNetwork reworded to cover both "offline" and "file removed" (a 404). - WIZARD smoke: (a) deterministic legibility unit — all 14 audited codes map, an unknown string still passes through; (b) provider matrix walk — resolve a bogus version for each creatable provider; hard-fail only on a MALFORMED descriptor, log throw-vs-defer + whether the code maps. Matrix walk result (this run): every provider is legible for bad input — vanilla->unknown-version, forge/neoforge->no-*-build, paper/folia/purpur/velocity/mohist->HTTP 404 (all mapped), fabric defers to a well-formed URL that fails legibly at download. No illegible or malformed outcomes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> @
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.
Closes #44. Umbrella close-out for the provider-reliability pass (with #42 and #43).
Context
#42 (installer args-file or runnable jar) and #43 (empty-download guard + first friendly messages) fixed the two concrete failures and hardened the download layer. This PR finishes the umbrella's remaining bullets: no bare error code in the UI, and walk the matrix.
Changes
shared/versions.ts— new purecreateErrorKey(raw): string | null, the single source of truth for code → i18n key. It covers every error the creation path can throw, audited acrosscore/versions.ts,core/createServer.tsandcore/net.ts:no-build/no-download/no-server-jar-for-version/unknown-version/no-*-build,empty-download,Checksum mismatch,HTTP <status>,installer exited,installer-args-not-found,folder-exists,no-provider-for-*. Unknown strings pass through unchanged.CreateView—friendlyCreateErrornow just wrapscreateErrorKey, so both the error toast and the progress label render through one table.en/tr— addederrChecksum/errNetwork/errInstaller/errUnsupportedType; rewordederrNetworkto cover both "server offline" and "file removed" (a 404).MSMS_SMOKE_WIZARD— (a) a deterministic legibility unit: all 14 audited codes map, an unknown string still passes through; (b) a provider matrix walk: resolve a bogus version for each creatable provider, hard-fail only on a malformed descriptor, and log throw-vs-defer plus whether the thrown code maps.Matrix walk result (this run)
Every provider is legible for bad input:
unknown-version(mapped)no-*-build(mapped)HTTP 404(mapped → network/unavailable)No illegible or malformed outcomes. The walk stays inspection (network-dependent); the committed gate is the pure legibility unit + the malformed-descriptor guard.
Verify
typecheck,build— pass.MSMS_SMOKE_WIZARDPASS (legibility unit + matrix walk).🤖 Generated with Claude Code