Skip to content

[0.83.x] Backport paired watcher matching fixes and remove micromatch - #2028

Draft
gogulapatipavani212 wants to merge 1 commit into
react:0.83.xfrom
gogulapatipavani212:codex/backport-no-micromatch-0.83
Draft

gogulapatipavani212 wants to merge 1 commit into
react:0.83.xfrom
gogulapatipavani212:codex/backport-no-micromatch-0.83

Conversation

@gogulapatipavani212

Copy link
Copy Markdown

Summary

Backport the paired watcher fixes from #2000 (a77924694dd4e36c0a3e595956e322033a6c2c57) and #2024 (3865c007c592c4ab7357f95fa6ae9e6ac735a7d1) to 0.83.x. Related: #2027.

metro-file-map no longer needs micromatch to select extensions, exact basenames, and health-check prefixes. The extension matcher checks the suffix after every dot, preserving .env, .env.local, and multipart extensions such as d.ts.

The adaptation preserves this branch's NativeWatcher event handling, Flow syntax, and walker dependency. Generated TypeScript declarations are synchronized. The existing integration test now checks creation, modification, and deletion of dotfiles, multipart extensions, hidden files, and package.json in addition to ordinary JavaScript files.

This is a draft for review of the backport and release policy. It removes the metro-file-map dependency path; independent uses of micromatch elsewhere in the monorepo remain. No dependency audit policy is changed.

Changelog: [Fix] Remove metro-file-map's micromatch dependency while preserving dotfile and multipart-extension watcher events.

Test plan

Validated on macOS with Node 22.22.3 and Yarn 1.22.22:

  • yarn install --frozen-lockfile
  • yarn test: Flow, ESLint/Prettier, build, and all 140 test suites passed; 2,555 tests passed, 19 platform/tool-dependent tests skipped, 513 snapshots passed. This includes the real NativeWatcher and FallbackWatcher integration cases. Watchman is unavailable locally; its mocked unit tests passed.
  • yarn typecheck-ts: passed.
  • yarn test-smoke: passed.
  • git diff --check: passed.

CLA status has not been verified; no new agreement has been accepted as part of preparing this draft.

…83.x

Backports a779246 and 3865c00 while retaining 0.83.x watcher event behavior and regenerating TypeScript declarations.

Co-authored-by: Rob Hogan <2590098+robhogan@users.noreply.github.com>
@meta-cla

meta-cla Bot commented Oct 5, 2026

Copy link
Copy Markdown

Hi @gogulapatipavani212!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

This branch has not been deployed

No deployments
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.

1 participant