github agronholm/sqlacodegen 4.0.0

6 hours ago
  • BACKWARD INCOMPATIBLE API changes (for those who customize code generation by subclassing the existing generators):
    • Added new optional keyword argument, explicit_foreign_keys to DeclarativeGenerator, to force foreign keys to be rendered as ClassName.attribute_name string references
    • Removed the render_relationship_args() method from the SQLModel generator
    • Added two new methods for customizing relationship rendering in DeclarativeGenerator:
      • render_relationship_annotation(): returns the appropriate type annotation (without the Mapped wrapper) for the relationship
      • render_relationship_arguments(): returns a dictionary of keyword arguments to sqlalchemy.orm.relationship()

Don't miss a new sqlacodegen release

NewReleases is sending notifications on new releases.