claude-code - 💡(How to fix) Fix /export command reports success but writes empty content [1 comments, 2 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#49077Fetched 2026-04-17 08:51:33
View on GitHub
Comments
1
Participants
2
Timeline
6
Reactions
0
Author
Timeline (top)
labeled ×4closed ×1commented ×1

The /export command reports success but doesn't actually write any content — both clipboard and file exports are empty.

Root Cause

The /export command reports success but doesn't actually write any content — both clipboard and file exports are empty.

RAW_BUFFERClick to expand / collapse

Description

The /export command reports success but doesn't actually write any content — both clipboard and file exports are empty.

Steps to reproduce

  1. Have an active conversation with some history
  2. Run /export (clipboard mode) — reports "Conversation copied to clipboard", but pbpaste returns empty
  3. Run /export somefile (file mode) — reports "Conversation exported to: .../somefile.txt", but the file is 0 bytes

Expected behavior

Clipboard / file should contain the conversation transcript.

Actual behavior

  • /export → "Conversation copied to clipboard" but clipboard is empty (verified with pbpaste | wc -c → 0)
  • /export somefile → creates the file but it's 0 bytes (verified with wc -l and ls -la)

Environment

  • macOS (Darwin 25.2.0)
  • Claude Code CLI
  • Model: claude-opus-4-6

extent analysis

TL;DR

The /export command's failure to write content to the clipboard or file may be due to an issue with the conversation history or the export mechanism itself, requiring further investigation into the command's implementation or the environment.

Guidance

  • Verify that the conversation history is not empty and contains the expected content before running the /export command.
  • Check the Claude Code CLI documentation for any specific requirements or limitations for the /export command, especially regarding the model version (claude-opus-4-6) and macOS environment.
  • Test the /export command with a different model or environment to isolate if the issue is specific to the current setup.
  • Consider debugging the /export command's output or logs to understand why it reports success despite not writing any content.

Example

No code snippet can be provided without more context on the /export command's implementation.

Notes

The issue might be specific to the Claude Code CLI, the claude-opus-4-6 model, or the macOS environment, and without more information on the command's implementation or logs, it's challenging to provide a definitive fix.

Recommendation

Apply workaround: Test the /export command with different inputs, models, or environments to gather more information about the cause of the issue, as there's not enough information to suggest a specific upgrade or fix.

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…

FAQ

Expected behavior

Clipboard / file should contain the conversation transcript.

Still need to ship something?

×6

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

Back to top recommendations

TRENDING