[BUG] Read tool rejects .dat files

Resolved 💬 2 comments Opened May 8, 2026 by seedship Closed May 8, 2026

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?

The Read tool incorrectly classifies .dat text files as binary, forcing use of sed for viewing and editing. Workaround is symlink to .txt or use sed -n.

What Should Happen?

Claude should be able to read .dat text files

Error Messages/Logs

Steps to Reproduce

  1. Create a file data.dat
Here is some data
  1. Ask claude "What is in data.dat"
  2. Tell claude can you change insert the line: "Here is some more data"
  3. Claude will attempt to make the changes using sed, making it hard to see the changes it wants to make

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

.1.98 (Claude Code)

Platform

AWS Bedrock

Operating System

Ubuntu/Debian Linux

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗

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