Properly rephrase

This commit is contained in:
Alexander Hess 2026-12-04 16:12:58 +01:00
commit c5be06fb57
Signed by: alexander
GPG key ID: B46EDB4DFC26805D

View file

@ -10,8 +10,9 @@ from velofy.db import meta
class AddressPixelAssociation(meta.Base): class AddressPixelAssociation(meta.Base):
"""Association pattern between `Address` and `Pixel`. """Association pattern between `Address` and `Pixel`.
This approach is needed here mainly because it implicitly A plain many-to-many relationship would only set `.address_id` and `.pixel_id`.
updates the `city_id` and `grid_id` columns. This class also copies `.city_id` from the `Address` and `.grid_id` from
the `Pixel`, which the composite foreign keys need for their checks.
See: See:
https://docs.sqlalchemy.org/en/stable/orm/basic_relationships.html#association-object https://docs.sqlalchemy.org/en/stable/orm/basic_relationships.html#association-object