fix(i18n): localize error-component, fix bug report URL, replace console.trace in fn.ts#859
Open
MrRealORG wants to merge 1 commit into
Open
Conversation
…ole.trace in fn.ts
- error-component.tsx: fix issue URL from anomalyco/opencode to XiaomiMiMo/MiMo-Code
- error-component.tsx: fix title prefix from 'opentui: fatal:' to 'MiMo Code: fatal:'
- error-component.tsx: rename version param from 'opencode-version' to 'mimo-code-version'
- error-component.tsx: i18n all 6 hardcoded English strings (report_issue, copy_url, copied, fatal, reset, exit)
- Add 6 new tui.error.* keys to all 7 language files (en, zh, zht, ja, es, fr, ru)
- util/fn.ts: replace console.trace + console.error with structured Log.create({service: 'fn'}).error()
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.
Summary
Localizes the TUI error/fatal screen component and fixes the broken bug report URL that still pointed to the original
anomalyco/opencoderepository. Also replaces rawconsole.trace/console.errorin the schema validation utility with structured logging.Changes (9 files)
packages/opencode/src/cli/cmd/tui/component/error-component.tsx:anomalyco/opencode/issues/new→XiaomiMiMo/MiMo-Code/issues/newopentui: fatal:→MiMo Code: fatal:opencode-version→mimo-code-versionuseLanguageimport and replaced all 6 hardcoded English strings witht()callspackages/opencode/src/cli/cmd/tui/i18n/(7 files):tui.error.*keys to each of:en.ts,zh.ts,zht.ts,ja.ts,es.ts,fr.ts,ru.tstui.error.report_issue,tui.error.copy_url,tui.error.copied,tui.error.fatal,tui.error.reset,tui.error.exitpackages/opencode/src/util/fn.ts:console.trace("schema validation failure stack trace:")+console.error("schema validation issues:", ...)withLog.create({ service: "fn" }).error("schema validation failure", { input, error })Closes #679 (partial — error screen branding)