Skip to content

Gate CI on typecheck, lint, tests and a release bundle - #787

Merged
oristanovic merged 7 commits into
mainfrom
ci/gate-typecheck-lint-test
Oct 28, 2026
Merged

oristanovic merged 7 commits into
mainfrom
ci/gate-typecheck-lint-test

Conversation

@oristanovic

Copy link
Copy Markdown
Contributor

What do these changes do?

Run typecheck, lint, tests and a release-mode bundle on every pull request, in
their own job, and update the native job's toolchain.

Why are these changes necessary?

CI ran npm ci and two Debug native builds. A Debug build loads its JavaScript
from Metro at runtime, so the JS was never compiled or bundled, and typecheck,
lint and tests were never invoked at all. Broken JavaScript could not fail a
build — which is how the example's missing imports went unnoticed.

How did you verify these changes?

From a real install in a clean worktree: typecheck reports no errors, lint
exits 0, and the bundle writes. npm test fails here because the suite is
#785.

Anything else a reviewer should know?

Two things had to be fixed before the gates could go green, and both are worth
a look on their own.

example/src/AirshipConfig.ts holds credentials and is gitignored, so the
example could never typecheck or bundle in CI. The committed
AirshipConfig.ts.example is copied into place.

The example imported @react-navigation/native, @react-navigation/stack and
@react-native-clipboard/clipboard with nothing declaring them in either
package.json and zero entries in the lockfile. They resolved only from stale
node_modules in a long-lived checkout, so a fresh clone could not typecheck,
bundle or run the example. They are declared now, together with the two native
peers @react-navigation/stack needs.

The example's typecheck backlog is cleared here too. One of those was a defect
rather than a type complaint: addCustomEvent was passed
properties: undefined, and CustomEvent requires that field.

Stacked on #786, which the lint step depends on, and merged in already to keep
the example edits from conflicting. Merge #785 first so npm test exists.

Making the four checks required on main is a branch protection setting, not
part of this change.

🤖 Generated with Claude Code

Ognjen Ristanovic and others added 2 commits October 22, 2026 16:13
CI ran npm ci and two Debug native builds. Debug loads JS from Metro at
runtime, so the JavaScript was never compiled or bundled, and typecheck, lint
and tests were never invoked. Broken JS could not fail a build.

The checks now run in their own job on ubuntu, with the native builds left on
macOS. Bundling in release mode is what catches a missing import.

Two things had to be fixed for the gates to go green:

AirshipConfig.ts holds credentials and is gitignored, so the example could
never typecheck or bundle in CI. The committed AirshipConfig.ts.example is
copied into place.

The example imported @react-navigation/native, @react-navigation/stack and
@react-native-clipboard/clipboard with nothing declaring them anywhere, and
zero entries in the lockfile; they resolved only from stale node_modules in a
working checkout. They are declared now, with the two native peers
@react-navigation/stack needs. Verified from a real install: typecheck reports
no errors and the bundle writes.

The example's own typecheck backlog is fixed here too. One was a defect:
addCustomEvent was passed properties: undefined, and CustomEvent requires it.

setup-java moves to v4 and Ruby off 3.0.1, which is past end of life.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
…gate-typecheck-lint-test

# Conflicts:
#	example/src/screens/HomeScreen.tsx
#	example/src/screens/MessageDetailsScreen.tsx
#	package-lock.json
@oristanovic
oristanovic requested a review from a team as a code owner October 22, 2026 14:15
Declaring @react-native-clipboard/clipboard autolinks it into the iOS build
for the first time, and the pod fails to link: it calls UTTypeConformsTo,
UTTypeCopyPreferredTagWithClass, kUTTagClassMIMEType and kUTTypeImage, while
its podspec declares only React-Core, so nothing carries those symbols.

Fixed in the Podfile rather than by pinning an older release; 1.16.3 is the
latest and still ships the same podspec.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Base automatically changed from fix/lint-clean-install to main October 28, 2026 16:49
@oristanovic
oristanovic merged commit 4b722fa into main Oct 28, 2026
2 checks passed
@oristanovic
oristanovic deleted the ci/gate-typecheck-lint-test branch October 28, 2026 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants