You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I used the GitHub search to find a similar issue and didn't find it.
I searched the FastAPI documentation, with the integrated search.
I already searched in Google "How to interact with FastAPI app" and didn't find any information.
Description
I have a few SQLAlchemy models in my fastAPI app, and let's say I want to experiment, for instance, I want to develop a filter, and I need to tinker with the code to try a few things. How can I do that without having to create Schemas and endpoints for a model I just want to play with?
Additional context
The FastAPI docs give a method for debugging, would it be one way to handle it? Pause the program then write custom commands. Essentially, I am asking if there is the equivalent of an interactive shell, similar to what Django, Flask, or Laravel (tinker) offer. If not, what is the recommended workflow to tinker with models?
The text was updated successfully, but these errors were encountered:
Thanks @Kilo59 I tried that, but I get this error: sqlalchemy.exc.UnboundExecutionError: Could not locate a bind configured on mapper mapped class User->user, SQL expression or this Session
What I would do is using VS Code, start an "Interactive Session", that's actually Jupyter underneath, that I think is more powerful than any other Python interactive shell, and then I would run commands there interactively, or actually, select sections of code in the editor and execute them in the interactive session (with Shift+Enter).
First check
Description
I have a few SQLAlchemy models in my fastAPI app, and let's say I want to experiment, for instance, I want to develop a filter, and I need to tinker with the code to try a few things. How can I do that without having to create Schemas and endpoints for a model I just want to play with?
Additional context
The FastAPI docs give a method for debugging, would it be one way to handle it? Pause the program then write custom commands. Essentially, I am asking if there is the equivalent of an interactive shell, similar to what Django, Flask, or Laravel (tinker) offer. If not, what is the recommended workflow to tinker with models?
The text was updated successfully, but these errors were encountered: