Skip to content

Warm the CLI-init app closure in warm-feed - #16458

Merged
Vladimir Morozov (vmoroz) merged 1 commit into
microsoft:mainfrom
vmoroz:PR/handle-cli-apps-in-warm-feed
Sep 26, 2026
Merged

Vladimir Morozov (vmoroz) merged 1 commit into
microsoft:mainfrom
vmoroz:PR/handle-cli-apps-in-warm-feed

Conversation

@vmoroz

@vmoroz Vladimir Morozov (vmoroz) commented Sep 26, 2026 •

Copy link
Copy Markdown
Member

Description

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • Automation (CI/pipeline changes)

Why

The CLI-init tests scaffold a fresh project and install it anonymously from the
isolated ms/react-native-public feed, which only serves a version once an
authenticated identity has pulled it. warm-feed already reproduces the library-init
closure but not the app-init closure, so new app-template dependencies were never
warmed — anonymous PR builds then failed to restore them (e.g. the CLI checks on
#16449 and #16447 could not
download react-native-safe-area-context@5.10.0, which had to be warmed by hand).

Separately, the scheduled warm-feed run itself went red: the existing library scaffold
resolves a nightly React Native through the short-lived
@react-native-community/template@nightly tag, and once that tag rotated away the
scaffold failed with ETARGET.

What

Warm the CLI-init app closure. A new create-react-native-app warm-feed module
reproduces creaternwapp.cmd's scaffold for each release branch and warms the generated
app's dependency graph (e.g. react-native-safe-area-context), which feed enumeration
can't discover on its own. It's enabled across main and the stable branches, so the
scheduled run keeps that closure warm and isolated PR builds restore it anonymously. It
mirrors the app script's template selection, including the fixed stable template used
when React Native is a nightly.

Fix nightly library scaffolding. The existing create-react-native-library module
scaffolded a nightly React Native via the short-lived
@react-native-community/template@nightly tag, which rotates away and then fails
(ETARGET), turning the scheduled run red. It now scaffolds from the matching stable
base version (0.87.0-nightly-… → 0.87.0) and rewrites the generated closure back to
the nightly, mirroring the same workaround already in creaternwlib.cmd.

Testing

Exercised through the scheduled warm-feed pipeline — the run is green. Unit tests cover
the new module's config/version/template selection and the nightly scaffold-version
helper.

Changelog

Should this change be included in the release notes: no

Internal feed-warming tooling now covers the CLI-init app closure and no longer breaks on
nightly templates; no user-facing change.

Microsoft Reviewers: Open in CodeFlow

@vmoroz
Vladimir Morozov (vmoroz) requested a review from a team as a code owner September 26, 2026 00:18
Copilot AI balanced review requested due to automatic review settings September 26, 2026 00:18

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The implementation matches the CLI-init scripts and includes focused coverage for the new behavior.

Review effort: Balanced
Findings: None

What changed in this PR

Extends warm-feed coverage to CLI-created apps and prevents nightly library scaffolding failures.

Changes:

  • Adds and registers app dependency-closure warming across supported branches.
  • Uses stable base versions when scaffolding nightly libraries.
  • Adds unit tests and documentation.
File Description
warm-feed.config.json Enables app closure warming.
createReactNativeLibrary.test.ts Tests nightly scaffold versions.
createReactNativeApp.test.ts Tests app configuration and dependencies.
specialModules/​index.ts Registers the app module.
createReactNativeLibrary.ts Uses stable bases for nightly scaffolds.
createReactNativeApp.ts Implements app closure collection.
README.md Documents app warming behavior.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@vmoroz
Vladimir Morozov (vmoroz) merged commit dac75b6 into microsoft:main Sep 26, 2026
32 checks passed
@vmoroz
Vladimir Morozov (vmoroz) deleted the PR/handle-cli-apps-in-warm-feed branch September 26, 2026 23:12
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.

3 participants