Skip to content

A lockfile can't be read

warning: Axle couldn't read pnpm-lock.yaml at main, so every package counts as affected: Axle doesn't read lockfile version 5.4
hint: Resolve any merge conflict in the lockfile and install again, or update Axle if it doesn't read this lockfile's format yet.

The lockfile changed, so Axle reads it before and after the change to see which packages now use different dependencies. It couldn’t read one of the two, so it can’t tell, and treats every package as affected.

The usual reasons are a lockfile format Axle doesn’t read, such as Bun’s older binary bun.lockb or a lockfile from an old version of the package manager, or a lockfile with a merge conflict in it.

If the lockfile has conflict markers, resolve them and install again. If the format is older than Axle reads, upgrade it by installing with a current version of your package manager, and if it’s newer, update Axle; Bun converts bun.lockb to bun.lock with bun install --save-text-lockfile. Axle reads pnpm-lock.yaml versions 6 and 9, package-lock.json versions 2 and 3, yarn.lock from Yarn 1 on, and bun.lock up to version 2.

axle run reads the lockfile too, to learn which dependency versions each package uses. When it can’t, it warns and hashes the whole lockfile into every task instead:

warning: Axle couldn't read pnpm-lock.yaml, so a change to it misses every task: Axle doesn't read lockfile version 5.4
hint: Update Axle, or check that the lockfile isn't damaged.

The run still works, but it can’t tell which tasks a lockfile change matters to. The fixes above apply here too.