• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

jallum / iodata / 0bb10535e8bcd0717704bccf3f6a80a74380bd20-PR-2
100%
main: 100%

Build:
Build:
LAST BUILD BRANCH: fix/file-read-contract
DEFAULT BRANCH: main
Ran 31 Aug 2026 05:53PM UTC
Jobs 1
Files 7
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

31 Aug 2026 05:53PM UTC coverage: 100.0%. Remained the same
0bb10535e8bcd0717704bccf3f6a80a74380bd20-PR-2

Pull #2

github

jallum
Enforce exact-count file reads, normalize text-mode reads, validate split/2

Review fixes for the file implementations:

- to_binary/3 accepted any {:ok, data} from pread, so a range overlapping
  EOF returned a short read tagged ok — silent truncation. It now requires
  exactly `count` bytes and returns {:error, :insufficient_data} otherwise;
  reads entirely past EOF return :insufficient_data instead of :eof, matching
  the other implementations.
- Files opened without :binary made pread return charlists, breaking the
  to_binary contract and starts_with?. Reads are normalized with
  IO.iodata_to_binary/1, the identity for binary-mode files.
- split/2 on a file returned {:ok, slices} for any offset. It now checks the
  offset against the file size (one read_file_info) and returns
  {:error, :insufficient_data} / raises from split!/2. slice/2,3 stays lazy
  by design; its laziness is documented in IOData.File.

Claude-Session: https://claude.ai/code/session_01GqkKDgEdSuWfZRL2KnYqAs
Pull Request #2: Enforce exact-count file reads, normalize text-mode reads, validate split/2

13 of 13 new or added lines in 1 file covered. (100.0%)

252 of 252 relevant lines covered (100.0%)

115.05 hits per line

Jobs
ID Job ID Ran Files Coverage
1 0bb10535e8bcd0717704bccf3f6a80a74380bd20-PR-2.1 31 Aug 2026 05:53PM UTC 7
100.0
GitHub Action Run
Source Files on build 0bb10535e8bcd0717704bccf3f6a80a74380bd20-PR-2
  • Tree
  • List 7
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Pull Request #2
  • PR Base - main (#FB3136CC...)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc