]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
- MapperProperty gets its .key attribute assigned early, in _compile_property.
authorMike Bayer <mike_mp@zzzcomputing.com>
Wed, 16 Jul 2008 21:56:23 +0000 (21:56 +0000)
committerMike Bayer <mike_mp@zzzcomputing.com>
Wed, 16 Jul 2008 21:56:23 +0000 (21:56 +0000)
commit5af88c5df1f26d60becc8c60f7d99b3278e7c220
treedbb25a51d179b854d2086830f8974097e8f4ce80
parent0d9985588bf1575ed77eb1eddbbb5f185a73b5b3
- MapperProperty gets its .key attribute assigned early, in _compile_property.
MapperProperty compilation is detected using a "_compiled" flag.
- A mapper which inherits from another, when inheriting
the columns of its inherited mapper, will use any
reassigned property names specified in that inheriting
mapper.  Previously, if "Base" had reassigned "base_id"
to the name "id", "SubBase(Base)" would still get
an attribute called "base_id".   This could be worked
around by explicitly stating the column in each
submapper as well but this is fairly unworkable
and also impossible when using declarative [ticket:1111].
CHANGES
lib/sqlalchemy/orm/interfaces.py
lib/sqlalchemy/orm/mapper.py
test/orm/inheritance/basic.py