Skip to content
Discussion options

You must be logged in to vote

the full stack trace is quite important to give context but we would assume your delete_app_by_user_id function is where the trace originates, since that's where there is an explicit call to session.begin(). if the session delivered by the Session = Depends(get_database_session) construct (this is a fastapi thing that we dont have information on) was already being used in a different method , then it would already be ongoing in a transaction and you can't call begin() on a session in that state.

well looking at your code if I had to guess I would say that since you have a single session used for everything, you are first calling into client.post("/api/v1/app-users", json=data) which is go…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@zzzeek
Comment options

@michaelxswe
Comment options

@zzzeek
Comment options

Answer selected by michaelxswe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants