-
Notifications
You must be signed in to change notification settings - Fork 24.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade glob@7
to glob@10
to resolve deprecation warnings
#48875
base: main
Are you sure you want to change the base?
Conversation
Looks like just Flow errors. Will import and resolve. |
@huntie has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Will see if I have time to test this today (need to secure a Windows device from around the office). |
Hey @huntie! I just got back from my Lunar new year tour. If there is any way I can help test the Glob changes on Windows, lmk. I literally have 2 desktops ready to go for that. |
Summary: This is a long overdue follow-up from facebook/react-native#46724, and upgrades the deprecated `glob@7` to `glob@10`. When creating any React Native project today, you are greeted by a wall of deprecation warnings when installing with `npm` -- with the most frequent offender being `[email protected]`. This hurts UX and diminishes developers' trust, even before starting their project. <img width="1005" alt="image" src="https://github.com/user-attachments/assets/a5661470-98df-4f3f-8be2-7b0baa9711b6" /> Unfortunately, no [flow types are available for `glob@9+`](https://github.com/flow-typed/flow-typed/tree/main/definitions/npm). I've tried creating a flow definition, but it turns out that the `glob@10` types use `path-scurry@^1.11.1`, `minimatch@^9.0.4`, and `minipass@^7.1.2` -- all without flow type definitions. Writing the flow definitions for glob@9+ is non-trivial work, I'd be happy to help but I can't fix that on my own. > [!IMPORTANT] > `glob@11` has already been released, but it's only supporting Node 20+. I believe React Native still supports Node 18 until the EOL in April 2025, that's why I used `glob@10`. ## Changelog: [GENERAL] [CHANGED] - Upgrade from deprecated `glob@7` to supported `glob@10` <!-- Help reviewers and the release process by writing your own changelog entry. Pick one each for the category and type tags: [GENERAL] [CHANGED] - Upgrade from deprecated `glob@7` to supported `glob@10` For more details, see: https://reactnative.dev/contributing/changelogs-in-pull-requests X-link: facebook/react-native#48875 Reviewed By: robhogan, cortinico Differential Revision: D69594539 Pulled By: huntie
Summary:
This is a long overdue follow-up from #46724, and upgrades the deprecated
glob@7
toglob@10
.When creating any React Native project today, you are greeted by a wall of deprecation warnings when installing with
npm
-- with the most frequent offender being[email protected]
. This hurts UX and diminishes developers' trust, even before starting their project.Unfortunately, no flow types are available for
glob@9+
. I've tried creating a flow definition, but it turns out that theglob@10
types usepath-scurry@^1.11.1
,minimatch@^9.0.4
, andminipass@^7.1.2
-- all without flow type definitions. Writing the flow definitions for glob@9+ is non-trivial work, I'd be happy to help but I can't fix that on my own.Important
glob@11
has already been released, but it's only supporting Node 20+. I believe React Native still supports Node 18 until the EOL in April 2025, that's why I usedglob@10
.Changelog:
[GENERAL] [CHANGED] - Upgrade from deprecated
glob@7
to supportedglob@10
Test Plan:
npm create expo@latest ./test-install-warnings
cd ./test-install-warnings
rm -rf node_modules
npm install
npm list [email protected]
Most of the offending packages come from React Native packages, with some from
jest
/jest-expo
.