Skip to content

Reset buffer cursor#1078

Open
amrit-kaur45 wants to merge 1 commit into
imDarshanGK:mainfrom
amrit-kaur45:1076
Open

Reset buffer cursor#1078
amrit-kaur45 wants to merge 1 commit into
imDarshanGK:mainfrom
amrit-kaur45:1076

Conversation

@amrit-kaur45

Copy link
Copy Markdown

Reset buffer cursor before reading ZIP file to avoid EOF issues.

Description

Added buffer.seek(0) after the chunked upload loop, before zipfile.ZipFile(buffer)

Related Issue

Fixes #1076

Type of change

  • Bug fix

Checklist

  • I have read CONTRIBUTING.md
  • My branch is up to date with main
  • I have run pytest -v and all tests pass
  • I have not introduced duplicate issues or features
  • My PR title follows the format: feat/fix/docs/test: short description
  • I have added tests for new features (Level 2 and 3 issues)
  • No hardcoded secrets or API keys in my code
  • This PR is linked to a GSSoC 2026 issue

Reset buffer cursor before reading ZIP file to avoid EOF issues.
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.

[Bug] POST /analyze/zip/ always returns 400 "Invalid ZIP file" for valid uploads

1 participant