Feature Request: Auto-report critical crashes to GitHub Issues

Resolved 💬 2 comments Opened Jan 25, 2026 by emregurhan Closed Feb 27, 2026

Feature Request

Summary

When Claude Code encounters critical/session-breaking errors (such as API-level crashes, invalid request errors, or unrecoverable state issues), it should offer the user an option to automatically create a GitHub issue with relevant diagnostic information.

Problem

Currently, when Claude Code crashes or encounters a critical error:

  1. The user sees a raw error message in the terminal
  2. The user must manually go to GitHub, create an issue, and copy-paste the error
  3. Important context (environment info, request IDs, error stack traces) is often lost or forgotten
  4. Many users may not report bugs at all due to the friction involved

Proposed Solution

After a critical error, Claude Code should prompt the user:

⚠️ A critical error occurred.
Would you like to report this issue to GitHub? (y/n)

If the user accepts, Claude Code should automatically:

  1. Collect non-sensitive diagnostic information:
  • Claude Code CLI version
  • VS Code version (if applicable)
  • Model name and ID
  • Node.js version
  • OS and architecture
  • Error message and request ID
  • Error type/category
  1. Exclude all sensitive information:
  • No conversation content
  • No file paths or project names
  • No API keys or tokens
  • No personal information
  1. Create a GitHub issue on anthropics/claude-code with a structured bug report
  1. Show the user the issue URL for tracking

Privacy Considerations

  • The user must explicitly opt-in each time (no automatic reporting)
  • A preview of the report should be shown before submission
  • Only technical metadata should be included, never conversation content
  • Users should be able to edit the report before submission
  • A global setting to disable the prompt entirely should be available

Example Auto-Generated Report

## Auto-Generated Crash Report

**Error:** invalid_request_error — thinking block ordering
**Request ID:** req_xxxxx
**Claude Code:** 2.1.19
**Model:** claude-opus-4-5-20251101
**OS:** macOS 26.3 (arm64)
**Node.js:** v24.7.0

### Steps Before Crash
- Session was active with extended thinking enabled
- Error occurred at message index 29

Benefits

  • Higher bug report rate → faster issue discovery
  • Consistent, structured reports → easier triage for the team
  • Lower friction for users → better user experience
  • Automatic environment info → fewer back-and-forth questions on issues

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗