npm outdated/update on a project that uses a linked package fails

I’m running into a situation where running npm outdated/npm update on a project that uses a linked package fails:

$ npm outdated
npm ERR! code ETARGET
npm ERR! notarget No matching version found for my-library@^2.0.0.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/myuser/.npm/_logs/2021-09-26T06_18_14_326Z-debug.log

This is the output from linking:

$ npm link my-library
/home/myuser/path/to/project/node_modules/my-library -> /home/myuser/path/to/node/node-v14.15.1-linux-x64/lib/node_modules/my-library -> /home/myuser/path/to/library/my-library

I cleared npm’s cache (forced it). Deleted my package-lock.json and node_modules. Linked first, then npm install for other dependencies.

Nothing worked to resolve this issue.

$ npm -v
$ node -v