isaacs / node-lru-cache

A fast cache that automatically deletes the least recently used items
http://isaacs.github.io/node-lru-cache/
ISC License
5.35k stars 353 forks source link

Version 10.3.1 drops support for Node 14 and 16 #340

Closed Lms24 closed 4 months ago

Lms24 commented 4 months ago

Commit https://github.com/isaacs/node-lru-cache/commit/1aa58f9183e017e0dddf5a9236f3843c01627fb5 introduced a min Node version bump to Node 18, meaning support for 14 and 16 was dropped in a minor release. This just completely broke our CI (along with the same change in glob as reported in https://github.com/isaacs/node-glob/issues/596).

For the moment we can work around this with a dependency resolution override but I'd ask to only drop Node version support in a major version. I'm sure we're not the only ones affected by this.

ErikKhasanov commented 4 months ago

I confirm, my build broke on the node version 16.x

ErikKhasanov commented 4 months ago
I added dependency fixing for my package.json, but this is a temporary solution
"resolutions": {
    "lru-cache": "10.3.0",
    "glob": "10.4.2",
    "jackspeak": "3.4.0"
},
erikkristiaan commented 4 months ago

Same here, this also broke our build. Not sure why a breaking change was introduced with a patch.

icefire1987 commented 4 months ago
I added dependency fixing for my package.json, but this is a temporary solution
"resolutions": {
    "lru-cache": "10.3.0",
    "glob": "10.4.2",
    "jackspeak": "3.4.0"
},

You saved me, thanks!

Lms24 commented 4 months ago

In our case, the following override fixed things for us. We couldn't globally set versions for lru-cache and glob since some of our deps depended on multiple older major versions. In case anyone else is stuck in a similar situation, I recommend going through your lock file and identifying which packages need the specific major versions and only pin for those:

"resolutions": {
    "@sentry/remix/glob": "<10.4.3",
    "jackspeak": "<3.4.1",
    "**/path-scurry/lru-cache": "10.2.0"
},
isaacs commented 4 months ago

https://nodejs.org/en/blog/announcements/nodejs16-eol/

It's been EOL for 10 months. Pin your deps and only upgrade carefully if you are using EOL platform versions.