Skip to content
Proposals/Set CLAUDE_CODE_TOOL_MEMORY_LIMIT for Bash tool
proposalteamP5Worth a lookClaude Code

Set CLAUDE_CODE_TOOL_MEMORY_LIMIT for Bash tool cgroups on Linux

Opt into Linux memory cgroups for Claude Code Bash tool commands so runaway builds cannot stall the session, and wire related v2.1.233 controls (identity forwarding, WebFetch cache TTL, GitLab MR worktrees) into daily agent workflows.

Why this loop

v2.1.233 adds opt-in memory cgroup support via CLAUDE_CODE_TOOL_MEMORY_LIMIT so a runaway Bash build cannot stall the session. Teams running long agent sessions on Linux should set this in their environment. The same release adds forward_user_identity on Anthropic apps-gateway upstreams for per-user spend attribution behind a proxy, CLAUDE_CODE_WEBFETCH_CACHE_TTL_MS to tune WebFetch URL cache TTL (default 15 minutes), and GitLab merge request URL support on --worktree (MRs show as !N in claude agents). Adopting these together hardens session stability, cost attribution, and MR-centric worktree flows without waiting for further releases.

Proposed actions

  1. export CLAUDE_CODE_TOOL_MEMORY_LIMIT=4G # or your cap in bytes/suffix; add to shell profile or agent runner env so Bash tool commands run under a memory cgroup on Linux
  2. In apps gateway Anthropic upstream config, set forward_user_identity: true so the signed-in user identity is sent as headers and the proxy can attribute spend per user
  3. export CLAUDE_CODE_WEBFETCH_CACHE_TTL_MS=900000 # keep 15m default, or lower (e.g. 300000) for fresher fetches; set in the environment that launches claude
  4. claude --worktree https://gitlab.example.com/group/project/-/merge_requests/123 # open a worktree from a GitLab MR URL; confirm it appears as !123 in `claude agents`
  5. claude plugin validate # re-run after upgrade so bare .claude/skills SKILL.md frontmatter parse failures are reported

Agent prompt

Paste into your agent or query via MCP (`get_agent_prompt`) — free, no extra AI cost

Paste into Claude Code / CLAUDE.md task

# DevAgentRadar → Claude Code

You are helping me adopt a real coding-assistant change. Work only from the facts below. Do not invent features.

## Context
Assistant: Claude Code
Proposal: Set CLAUDE_CODE_TOOL_MEMORY_LIMIT for Bash tool cgroups on Linux
Summary: Opt into Linux memory cgroups for Claude Code Bash tool commands so runaway builds cannot stall the session, and wire related v2.1.233 controls (identity forwarding, WebFetch cache TTL, GitLab MR worktrees) into daily agent workflows.
Primary source: https://github.com/anthropics/claude-code/releases/tag/v2.1.233

## Why it matters
v2.1.233 adds opt-in memory cgroup support via CLAUDE_CODE_TOOL_MEMORY_LIMIT so a runaway Bash build cannot stall the session. Teams running long agent sessions on Linux should set this in their environment. The same release adds forward_user_identity on Anthropic apps-gateway upstreams for per-user spend attribution behind a proxy, CLAUDE_CODE_WEBFETCH_CACHE_TTL_MS to tune WebFetch URL cache TTL (default 15 minutes), and GitLab merge request URL support on --worktree (MRs show as !N in claude agents). Adopting these together hardens session stability, cost attribution, and MR-centric worktree flows without waiting for further releases.

## Suggested actions
1. export CLAUDE_CODE_TOOL_MEMORY_LIMIT=4G  # or your cap in bytes/suffix; add to shell profile or agent runner env so Bash tool commands run under a memory cgroup on Linux
2. In apps gateway Anthropic upstream config, set forward_user_identity: true so the signed-in user identity is sent as headers and the proxy can attribute spend per user
3. export CLAUDE_CODE_WEBFETCH_CACHE_TTL_MS=900000  # keep 15m default, or lower (e.g. 300000) for fresher fetches; set in the environment that launches claude
4. claude --worktree https://gitlab.example.com/group/project/-/merge_requests/123  # open a worktree from a GitLab MR URL; confirm it appears as !123 in `claude agents`
5. claude plugin validate  # re-run after upgrade so bare .claude/skills SKILL.md frontmatter parse failures are reported

## Config surfaces this release may change
- permission rules **(high confidence)** — check your repo before applying
- settings files — check your repo before applying
- MCP servers — check your repo before applying
- skills — check your repo before applying


## Your job
1. Restate the change in one sentence.
2. Propose a minimal plan for my repo (or a throwaway pilot).
3. Implement only what I approve; prefer small diffs and tests.
4. Call out risks (permissions, breaking APIs, cost).

Start by confirming you understood the proposal.
agentmcpmodelsecuritybreakingRelease source ↗

Your loop

This browser · no sign-in · not shared as “you”

Your decision stays on this device. A public tally appears after a few votes.

Originating release signal

Claude Codev2.1.233Aug 14, 2026

v2.1.233

Added GitLab merge request URL support to the `--worktree` flag and the `claude agents` view (where MRs display as `!N`) · Added an opt-in `forward_user_identity` apps gateway setting on Anthropic upstreams that sends the signed-in user's identity as headers, so a proxy behind the gateway can attribute spend per user · Added opt-in memory cgroup support for Bash tool commands on Linux (`CLAUDE_CODE_TOOL_MEMORY_LIMIT`) so a runaway build can't stall the session · +17 more changes

Verified excerpt — the source's own words
## What's changed

- Added GitLab merge request URL support to the `--worktree` flag and the `claude agents` view (where MRs display as `!N`)
- Added an opt-in `forward_user_identity` apps gateway setting on Anthropic upstreams that sends the signed-in user's identity as headers, so a proxy behind the gateway can attribute spend per user
- Added opt-in memory cgroup support for Bash tool commands on Linux (`CLAUDE_CODE_TOOL_MEMORY_LIMIT`) so a runaway build can't stall the session
- Added `CLAUDE_CODE_WEBFETCH_CACHE_TTL_MS` environment variable to configure the WebFetch session URL cache TTL (default unchanged: 15 minutes)
- Fixed cloud sessions occasionally being marked as lost when the environment shut down while Claude was waiting on a permission prompt
- Fixed MCP v2 connections endlessly reopening the subscriptions/listen stream against servers that terminate long-held streams on a fixed timeout (e.g. serverless hosts)
- Fixed Notification hooks not firing for permission prompts when running under Claude Desktop or VS Code
- Fixed idle sessions on Linux sometimes keeping one CPU core at 100% when sandboxing is enabled

Excerpt ends here — this release continues at the source ↗.

Primary source ↗