Skip to content

Conversation

@Zverik
Copy link

@Zverik Zverik commented May 22, 2025

Fixes #634 for most cases. Ideally we could have used os.path.getsize(), but I decided not to introduce any more complexity, just circumvent the reading.

@Zverik
Copy link
Author

Zverik commented May 22, 2025

I actually have no idea what happens when f.seekable() is False. The original code just threw an exception, this code renders the file into an unreadable state.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

FileSize validator reads the entire file into memory

1 participant