fix(mobile): make app.config.ts resolve the languages import - #5473
Merged
Conversation
The Expo config loader transpiles app.config.ts and hands the result to
Node, which resolves require('./x.ts') but not the extensionless
require('./x'). Every other app.config.ts import points at a hand-written
.js sibling; the languages import added by #5444 has none, so
`expo config` failed with "Cannot find module './src/i18n/languages'".
That broke the nightly kilo-app release preflight (eas-cli spawns
`expo config --json`) and every local mobile prebuild. Import the module
with its .ts extension and allow the extension in the app's tsconfig.
Moving the list into a .js sibling was the alternative; it widens
SUPPORTED_LANGUAGES to string[] and breaks the SupportedLanguage union
that ten call sites depend on.
Read the config in kilo-app CI too. The release preflight was the only
job that evaluated app.config.ts, and it runs nightly, so a broken
import reached main twice.
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Executive SummaryReviewed the Expo config languages import fix, mobile tsconfig change, and CI config-read guard with high confidence; no correctness or security issues. Files Reviewed (3 files)
Reviewed by grok-4.6 · Input: 59.2K · Output: 8.6K · Cached: 366K Review guidance: REVIEW.md from base branch |
iscekic
enabled auto-merge (squash)
August 25, 2026 09:33
RSO
approved these changes
Aug 25, 2026
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
mainagain.Symptom
expo configfailed onmain:That failure blocked two things:
kilo-app Releasepreflight, which fails at "Verify EAS production environment" becauseeas-clispawnsexpo config --json(run 32816122305).Cause
The Expo config loader transpiles
app.config.tsand hands the result to Node. Node 24 resolvesrequire('./x.ts')but not the extensionlessrequire('./x'), and the transpiler keeps the specifier as written.Every other
app.config.tsimport already points at a hand-written.jssibling —env-keys.js,sentry-dsn.js,url-contract.js,universal-link-paths.js. Thelanguagesimport added by #5444 is the only one without one.Fix
Import the module with its extension, and allow the extension in the app's tsconfig.
The alternative was a
languages.jssibling holding the tag list. It widensSUPPORTED_LANGUAGESfrom a readonly tuple tostring[], which erases theSupportedLanguageunion thatcatalogs.ts,resolve-language.ts,language-rows.ts,rtl.ts,apply-language.ts,use-language-preference.ts, and two tests depend on.Files
apps/mobile/app.config.ts— import./src/i18n/languages.tswith its extension.apps/mobile/tsconfig.json—allowImportingTsExtensions, with the reason inline.Guard
assert:configalready evaluates the config, but it runs only in the nightly release workflow and needs the EAS production environment. No pull-request job read the config, so a broken import reachedmaintwice (#5444, and the earlier break #5454 repaired). Thetypecheckjob inkilo-app CInow reads the config. Missing environment variables only warn underGITHUB_ACTIONS, so the step needs no secret.Files
.github/workflows/kilo-app-ci.yml— read the Expo config in thetypecheckjob.Tests: none changed.
Generated: none.
Verification
Run from
apps/mobileon this branch:npx expo config --type publicpnpm typecheckpnpm testpnpm format:checkThe guard was proven against the defect: with the two source changes stashed,
pnpm --filter kilo-app exec expo config --type publicexits 1; with them applied it exits 0.Visual Changes
Visual Changes: N/A — build configuration only.
Human Steps
kilo-app Releaseto confirm the preflight passes, or wait for the next scheduled run.Reviewer Notes
apps/mobile. Metro never bundlesapp.config.ts, and no bundled source uses a.tsimport specifier.