[BUG] Native installation / binary return API errors

Status Open
Maintainer reply None cached
Activity 12 comments · opened Sep 16, 2025

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

While using the native binary, using ( specific? ) internal tools will result in an API Error.

Using the NPM installation method doesn't show doesn't result in those problems

What Should Happen?

Claude Code should be able to run without API errors, when using tools

Error Messages/Logs

⏺ Update(cmd/automations/patch-auto/pr_processor_test.go)
  ⎿  File must be read first
[DEBUG] Hooks: getAsyncHookResponseAttachments called
[DEBUG] Hooks: checkForNewResponses called
[DEBUG] Hooks: Found 0 total hooks in registry
[DEBUG] Hooks: checkForNewResponses returning 0 responses


  ⎿  API Error: undefined is not an object (evaluating 'Z.map')
[DEBUG] Executing hooks for Stop
[DEBUG] Getting matching hook commands for Stop with query: undefined
[DEBUG] Found 1 hook matchers in settings
[DEBUG] Matched 2 unique hooks for query "no match query" (2 before deduplication)
[DEBUG] Found 2 hook commands to execute
[DEBUG] Executing hook command: make fix with timeout 300000ms
[DEBUG] Executing hook command: make test-coverage with timeout 300000ms
[DEBUG] Hook command completed with status 0: make

Steps to Reproduce

  1. Install via homebrew native installation method.
  2. Run tasks
  3. Randomly API error messages appear and stop running

Claude Model

Other

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

1.0.115

Platform

AWS Bedrock

Operating System

macOS

Terminal/Shell

iTerm2

Additional Information

We are running inside of a teleport proxy tsh aws exec inject the AWS environment variables such as HTTPS_PROXY, AWS_ACCESS_KEY_ID, AWS_CA_BUNDLE and others.
Further we manually inject NODE_EXTRA_CA_CERTS

What I have tried:

  • Setting NO_PROXY to localhost and localhost,127.0.0.1
  • Setting CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC=1

View original on GitHub ↗

12 Comments

github-actions[bot] · 11 months ago

Found 2 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/3606
  2. https://github.com/anthropics/claude-code/issues/6335

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

sorokod · 11 months ago

Same error with 1.0.128 installed via npm install -g @anthropic-ai/claude-code

Diagnostics
 └ Currently running: native (1.0.128)
 └ Path: /Users/XXXX/.local/bin/claude
 └ Invoked: /Users/XXXX/.local/share/claude/versions/1.0.128
 └ Config install method: native
 └ Auto-updates enabled: default (true)
 └ Search: OK (bundled)
secustor · 10 months ago

Still happening in 2.0.29 though in this version it is no longer Z.map but rather R.map, so I would assume something changed in this version that the minifying is using a different variable name.

Debug log:

[DEBUG] Slash commands included in SlashCommand tool:
[DEBUG] Stream started - received first chunk
[ERROR] Error streaming, falling back to non-streaming mode: request ended without sending any chunks
[ERROR] Error in non-streaming fallback: undefined is not an object (evaluating 'R.map')
[DEBUG] Getting matching hook commands for Stop with query: undefined
[DEBUG] Found 2 hook matchers in settings
kadirtugarantibbva · 10 months ago

I'm not able to run native build using NODE_EXTRA_CA_CERTS with HTTPS_PROXY.
npm installation works fine.

github-actions[bot] · 8 months ago

This issue has been inactive for 30 days. If the issue is still occurring, please comment to let us know. Otherwise, this issue will be automatically closed in 30 days for housekeeping purposes.

secustor · 8 months ago

Still happening with 2.0.64 with the following error message:

Error: undefined is not an object (evaluating 'T.input_tokens')
alexx-ftw · 8 months ago

Still happening in 2.0.76

secustor · 7 months ago

Now with the NPM installation method deprecated, this will potentially be fully blocking usage in enterprise environments

https://github.com/anthropics/claude-code/blob/main/CHANGELOG.md#2115

shanthu9999 · 7 months ago

Any update or workarounds identified on this issue? I am also facing issue when using native client with teleport proxy.

secustor · 7 months ago

ClaudeCode 2.1.23 has a reference to a related problem, but it is still failing.

- Fixed mTLS and proxy connectivity for users behind corporate proxies or using client certificates
Error: undefined is not an object (evaluating 'T.input_tokens')
shanthu9999 · 7 months ago

Yes, I have tried it with 2.1.23 and still failing for me as well.

yulonglin · 6 months ago

Experiencing something slightly different: ⎿  Error: undefined is not an object (evaluating 'T.includes')