Closed sr-verde closed 5 months ago
I'll work on the docs - the simple answer is - this is ONLY necessary if you use the provided fsqla models. If you declare your own models then your model code has the equivalent code. set_db_info is just needed to glue together the fsqla models.
As per your examples - none of those use the fsqla models.
Yes, in the meantime, I also came to this assumption. Yes, in the meantime, I also came to this assumption. I'm currently trying to integrate the "new" dataclasses support into my models and am looking for the cause of some problems. That's why I came across these lines in the docs.
The Basic SQLAlchemy Application quickstart tells us to use
fsqla.FsModels.set_db_info(db)
. But I cannot find any documentation about the purpose of this function. On other places in the docs [1], [2], [3], [4] I cannot find this function be used. The docstring tells usThis needs to be called after the DB object has been created
.My question: Is this function call really needed? Until now, my code works well without it. And: Should it be added to the other quickstart examples as well?