-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
♻ Refactor items and services endpoints to return count and data, and add CI tests #599
Conversation
statement = select(User).offset(skip).limit(limit) | ||
users = session.exec(statement).all() | ||
return users | ||
|
||
return UsersOut(data=users, count=count) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Front end needs to know how many items are in database to be able to create a pagination
Great, thanks! I updated it a bit, mainly to match the previous GitLab CI config, mainly to avoid race conditions between migrations running and the tests starting before the app/DB is ready. This is ready! 🚀 |
… add CI tests (fastapi#599) Co-authored-by: Esteban Maya Cadavid <emaya@trueblue.com> Co-authored-by: Sebastián Ramírez <tiangolo@gmail.com>
Refactor items and services endpoints and added support to run pytest within docker-compose and actions