Skip to content
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

CRUD database operations and SQLmodel modifications #65

Open
jurmy24 opened this issue Dec 10, 2024 · 1 comment
Open

CRUD database operations and SQLmodel modifications #65

jurmy24 opened this issue Dec 10, 2024 · 1 comment
Assignees

Comments

@jurmy24
Copy link
Member

jurmy24 commented Dec 10, 2024

The way we have structured the database operations and the database setup in code right now is not great practice. We need to make some changes to database.py, engine.py and main.py so that the FastAPI project is using a more industry-accepted structure for the SQLmodel integration.

For instance, we're using async for sqlmodel by using the sqlalchemy Async features and we have a contextmanager to handle sessions.

@jurmy24 jurmy24 added this to the Release v0.1.0 milestone Dec 10, 2024
@jurmy24
Copy link
Member Author

jurmy24 commented Jan 6, 2025

Hey @TimothyBesada happy new year!

I made some updates in the most recent merge to development for #41 but also made it easier to reinitialize the database so that its integrated directly with alembic.

Just FYI if you wanna rebase. Also i did reset the migrations too but if you're happy with your migration scripts then you can keep your changes. It's mainly just about ensuring we have a good process for dealing with enum types. If you want you can put down the rules about editing enums for it to work with the migrations in docs/en/MIGRATIONS.md if you want.

@jurmy24 jurmy24 removed this from the Release v0.1.0 milestone Jan 30, 2025
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

No branches or pull requests

2 participants