Read tool: suggest alternatives when rejecting binary files
Status Closed — not planned
Maintainer reply None cached
Activity 2 comments · opened Apr 20, 2026 · closed May 26, 2026
Problem
When the Read tool encounters a binary file (e.g., .xlsx, .docx), it returns:
This tool cannot read binary files. The file appears to be a binary .xlsx file.
The message is accurate but unhelpful — the user needs to know what to do instead.
Suggested Fix
Append guidance based on file type:
.xlsx→ "Use a Python script with openpyxl or pandas to read Excel files".docx→ "Use a Python script with python-docx to read Word files".pptx→ "Use the pptx skill or python-pptx to read PowerPoint files".pdf→ "The Read tool supports PDF files — try reading it directly" (if applicable)- Other binary → "Use a Python script or appropriate CLI tool to process this file"
Impact
Minor UX improvement. Users hit this when they forget the tool's limitations and have to figure out the alternative path themselves. One extra sentence in the error saves a round-trip.
Environment
- Claude Code CLI on Windows 11
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗