Skip to content

Feat/zip multi file analysis#197

Open
gitsofyash wants to merge 5 commits into
imDarshanGK:mainfrom
gitsofyash:feat/zip-multi-file-analysis
Open

Feat/zip multi file analysis#197
gitsofyash wants to merge 5 commits into
imDarshanGK:mainfrom
gitsofyash:feat/zip-multi-file-analysis

Conversation

@gitsofyash
Copy link
Copy Markdown

Summary

Adds multi-file ZIP analysis support.

This PR adds a new POST /analyze/zip/ backend endpoint that accepts a .zip upload, safely reads supported source files, analyzes up to 20 files with a 5MB total source-size limit, and returns a combined project report.

The response includes per-file analysis results, skipped-file information, and an overall project health score.

Frontend support is also added so users can upload .zip files, send them to the new endpoint, view the overall project score, and expand/collapse per-file analysis results.

Type of Change

  • Bug fix
  • New feature
  • Documentation update
  • Refactor

Testing

  • I ran backend tests (pytest -q)
  • I tested frontend behavior manually

Backend Test Command

python -m pytest backend/tests/test_endpoints.py -q

Result:

40 passed

Manual Frontend Testing

  1. Started the FastAPI backend locally with uvicorn
  2. Opened the frontend
  3. Set API URL to http://localhost:8000
  4. Uploaded a ZIP project containing C++ source files
  5. Verified the frontend shows the overall project health score
  6. Verified per-file results render in collapsible sections
  7. Verified generated folders like .git, build, Release, and x64 are ignored instead of flooding skipped-file output
  8. Verified C++ files are detected as C++

Checklist

  • Code is readable and beginner-friendly
  • No fake or placeholder behavior introduced
  • Documentation updated if needed

@imDarshanGK
Copy link
Copy Markdown
Owner

@gitsofyash Please link the related issue number in the PR description (e.g., Fixes #issue_number), resolve the conflicts, and include screenshots or implementation proof so the changes can be verified easily.

@gitsofyash gitsofyash requested a review from imDarshanGK as a code owner May 21, 2026 11:01
@gitsofyash
Copy link
Copy Markdown
Author

Fixes #131

Implementation proof:

  • Added POST /analyze/zip/
  • ZIP upload supports up to 20 source files and 5MB total source size
  • Frontend supports .zip upload and collapsible per-file results
  • Generated folders like .git, build, Release, and x64 are ignored
  • Backend tests pass: 47 passed

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.

2 participants