Address review feedback: Address review feedback: Scaffold FastAPI backend project structure #17

Merged
reviewer-bot merged 27 commits from agent/684f458e47fc into main 2026-08-18 00:16:07 +00:00
Collaborator

Addresses the remaining critical issue from PR #15's review: list_worlds's ownership check was bypassed entirely when a caller passed an explicit ?visibility=PRIVATE/FRIENDS_ONLY filter, letting any authenticated user enumerate other users' private worlds. Also cleans up assets.py's current_user: CurrentUser = Depends() to the plain form used everywhere else. users.py and assets.py's other fixes from the prior round are unchanged and already correct.

Supersedes #15.

Addresses the remaining critical issue from PR #15's review: list_worlds's ownership check was bypassed entirely when a caller passed an explicit ?visibility=PRIVATE/FRIENDS_ONLY filter, letting any authenticated user enumerate other users' private worlds. Also cleans up assets.py's current_user: CurrentUser = Depends() to the plain form used everywhere else. users.py and assets.py's other fixes from the prior round are unchanged and already correct. Supersedes #15.
coder-bot added 27 commits 2026-08-18 00:15:07 +00:00
Scaffolding only — FastAPI app, SQLAlchemy models, Alembic migrations,
and docker-compose from the original task description are still not
implemented. Committing what exists so it isn't lost; task ec0074121ca3
reset to pending to finish the rest.
config.py's DATABASE_URL uses postgresql+asyncpg but requirements.txt
only listed the sync psycopg2-binary driver, causing ModuleNotFoundError
on app startup.
Requesting an explicit ?visibility=PRIVATE (or FRIENDS_ONLY) skipped the
ownership check entirely — any authenticated user could list every other
user's private worlds just by passing the filter. Only the no-filter
default path enforced ownership. Now the ownership check applies whenever
a non-PUBLIC visibility is requested, explicit or not.

Also fixed current_user: CurrentUser = Depends() in assets.py (redundant
empty Depends() on an already-Annotated dependency, inconsistent with
every other endpoint) to plain current_user: CurrentUser per the review
feedback, and reordered params since that made it a non-default arg
following a defaulted one (SyntaxError otherwise).

Verified: py_compile clean, full app imports and loads in a clean venv.
reviewer-bot merged commit 10b372f379 into main 2026-08-18 00:16:07 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: daddy/modbison#17