> For the complete documentation index, see [llms.txt](https://help.aikido.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.aikido.dev/docs/docs-ja/autofix-to/faq/lockfile-only-updates.md).

# lockfileのみの更新

AutoFix は、依存関係を更新するために必要な最小限の変更のみを行います。これは、以下のパッケージマネージャーで適用可能な場合、ロックファイルのみの更新を行うことを意味します:

* NPM
* Yarn
* PNPM
* Bun
* Poetry
* UV

**以下の例では NPM を使用していますが、同じロジックは上記で言及した他のパッケージマネージャーにも適用されます。**

～への更新 `package.json` は、ほとんどのシナリオでは必要ですが、推移的依存関係については、親の依存関係が修正版を含むバージョン範囲でその推移的依存関係を含んでいる場合は必要ありません。

例えば、あなたのプロジェクトには axios 1.15.0 が含まれています:

{% code title="package.json" %}

```json
{
	"dependencies": {
		"axios": "1.15.0"
	}
}
```

{% endcode %}

Axios 自体は次に依存しています: `follow-redirects` :

{% code title="package.json（axios）" %}

```json
{
    "dependencies": {
    "follow-redirects": "^1.15.11",
    "form-data": "^4.0.5",
    "proxy-from-env": "^2.1.0"
  }
}
```

{% endcode %}

依存関係をインストールした時点での最新バージョンが `follow-redirects` だった場合、 `1.15.11` 、ロックファイルは `follow-redirects` バージョン `1.15.11` 、このバージョンには **CVE-2026-40895**.

この CVE はバージョン `1.16.0` の `follow-redirects`で修正されています。follow-redirects は **含まれていません** package.json には含まれていませんが、axios はバージョン `1.16.0` をバージョンセレクターで定義されたとおりに許可しています `^1.15.11`。つまり、クリーンな npm install を実行したときと同じように、package.json を変更せずに lockfile で問題を修正できます。

この場合、AutoFix は lockfile のみを更新し、package.json には変更を加えません。

## 新規インストールで元に戻りますか?

いいえ。axios がバージョン範囲を `^1.15.11` と指定しているため、npm/yarn/pnpm/bun は自動的に最新のマイナーバージョンを選択し、それは `1.16.0` 本稿執筆時点では

同じ動作は Poetry と UV にも適用されます。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.aikido.dev/docs/docs-ja/autofix-to/faq/lockfile-only-updates.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
