claude-code - 💡(How to fix) Fix [Bug] Context window display mismatch: status bar denominator differs from /context output [2 comments, 3 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#53712Fetched 2026-04-28 06:49:03
View on GitHub
Comments
2
Participants
3
Timeline
7
Reactions
1
Author
Timeline (top)
labeled ×4commented ×2cross-referenced ×1

Error Message

[{"error":"Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'"},"request_id":"req_011CaTWt4sanYFboVgeAfFxw"}\n at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:25.494Z"},{"error":"Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'"},"request_id":"req_011CaTWt8xu79PS1paSNADc6"}\n at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:26.007Z"}]

Code Example

[{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'\"},\"request_id\":\"req_011CaTWt4sanYFboVgeAfFxw\"}\n    at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n    at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:25.494Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'\"},\"request_id\":\"req_011CaTWt8xu79PS1paSNADc6\"}\n    at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n    at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:26.007Z"}]
RAW_BUFFERClick to expand / collapse

Bug Description Model: claude-opus-4-7[1m], Claude Code 2.1.120 ▎ /context shows 59.9k/400k (15%), status bar shows 6% ▎ Two issues: (a) status bar denominator doesn't match /context, (b) window cap is 400K despite [1m] label

Environment Info

  • Platform: win32
  • Terminal: vscode
  • Version: 2.1.120
  • Feedback ID: 8a35099f-fcfa-4c8b-adeb-c6705bd9bf8c

Errors

[{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'\"},\"request_id\":\"req_011CaTWt4sanYFboVgeAfFxw\"}\n    at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n    at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:25.494Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"tools.304.custom.input_schema.properties: Property keys should match pattern '^[a-zA-Z0-9_.-]{1,64}$'\"},\"request_id\":\"req_011CaTWt8xu79PS1paSNADc6\"}\n    at generate (B:/~BUN/root/src/entrypoints/cli.js:11:56508)\n    at makeRequest (B:/~BUN/root/src/entrypoints/cli.js:50:4943)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-27T02:50:26.007Z"}]

extent analysis

TL;DR

The issue may be resolved by adjusting the input schema properties to match the required pattern '^[a-zA-Z0-9_.-]{1,64}$' to fix the invalid request error.

Guidance

  • Review the input schema properties in the code to identify any keys that do not match the pattern '^[a-zA-Z0-9_.-]{1,64}$'.
  • Check the cli.js file at lines 11 and 50 to understand how the generate and makeRequest functions are handling the input schema properties.
  • Verify that the property keys in the input schema are not exceeding the 64 character limit.
  • Consider updating the input schema to use valid property keys that conform to the required pattern.

Example

No code snippet is provided as the issue does not contain sufficient information to create a specific example.

Notes

The issue seems to be related to an invalid request error caused by property keys in the input schema not matching the required pattern. However, without more information about the input schema and the code, it is difficult to provide a more specific solution.

Recommendation

Apply workaround: Adjust the input schema properties to match the required pattern to fix the invalid request error, as this is the most likely cause of the issue.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING