Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

create-react-app: No matching version found for @babel/types@^7.22.18

I try to run this create-react-app command, according to the AWS amplify tutorial

npx create-react-app react-amplified

Eventually I get this error:

npm ERR! notarget No matching version found for @babel/types@^7.22.18.

Note I am running this as an admin on my personal laptop — I don’t think I use a proxy, I don’t think I have a "company registry".

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

I checked these questions:

I tried to clean my cache:

npm cache clean --force

And I tried to update my registry:

npm config set registry=https://registry.npmjs.org/

But still I get the error.

Is this a case where the babel version 7.22.18, legitimately doesn’t exist, according to the npmjs registry?

I am running this command at 9/14/2023 10:15AM MST (GMT-6) (aka 2023-09-14 4:15 UTC)…

Indeed I cannot see that npmjs has a 7.22.18 version, when I visit https://www.npmjs.com/package/@babel/types?activeTab=versions
the only thing I see is the 7.22.17 version:

screenshot of https://www.npmjs.com/package/@babel/types?activeTab=versions showing only 7.22.17 version, no mention of 7.22.18

I also don’t see the 7.22.18 package available on the yarn registry:
screenshot of https://yarnpkg.com/package?q=babel%2Ftypes&name=%40babel%2Ftypes showing only 7.22.17 version, no mention of 7.22.18

It seems like the specific version @babel/types@^7.22.18; note the caret ^ means…

^1.2.3 "Compatible with version" will update you to all future minor/patch versions, without incrementing the major version. ^1.2.3 will use releases from 1.2.3 to <2.0.0.

… so this means create-react-app is searching for babel version @babel/types@^7.22.18 through <8.0.0, right?

Note, just a few minutes before I ran the above command with a failure, I ran the above command successfully. The command created a directory and installed all the necessary packages, but I had a typo in my directory name, so I deleted it and tried again. I restored the deleted file to see that it used @babel/core@7.22.17, which has a dependency on "@babel/types": "^7.22.17", (see screenshot below). Therefore I hope @Cosimo is correct and it’s just a matter of waiting for the registry index to update…

when the npx create-react-app runs successfully, it uses @babel/core@7.22.17

UPDATE This is fixed now

Thanks to @Bomel for crosslinking …

>Solution :

Same here, but… it seems 7.22.18 was published just a few minutes ago: https://www.npmjs.com/package/@babel/core/v/7.22.18

Perhaps it was a case of dependent packages being updated first.

As of 2023-09-14 16:32 UTC, @babel/types it’s still at 7.22.17, but hopefully it will be updated soon

EDIT: and 7.22.19 is there now, 16:36 UTC.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading