Skip to content

fix: reject non-positive size in Path.chunks#247

Closed
santhreal wants to merge 1 commit into
jaraco:mainfrom
santhreal:fix/reject-nonpositive-chunk-size
Closed

fix: reject non-positive size in Path.chunks#247
santhreal wants to merge 1 commit into
jaraco:mainfrom
santhreal:fix/reject-nonpositive-chunk-size

Conversation

@santhreal

@santhreal santhreal commented Jul 18, 2026

Copy link
Copy Markdown

Path.chunks hits data-loss when size=0-empty-yield. This PR fixes the regression with a focused test covering the case.

size 0 made read(0) return empty and stop immediately, silently
dropping the whole file. Negative sizes read the entire file at once.
@santhreal santhreal closed this Jul 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant