Autogenerate Colander schemas based on SQLAlchemy models.
Colander schemas can be used with libraries like Deform and helps remove the
need for duplication of schema definitions.
Latest documentation is at: Read The Docs.
pip install ColanderAlchemy
ColanderAlchemy is distributed under the MIT license.
Fork the development version on GitHub.
The branch ‘0.1’ contains the old version of ColanderAlchemy: 0.1x The branch ‘master’ contains the new version of ColanderAlchemy: 0.3x
- maintain the order of SQLAlchemy object attributes in the Colander schema [tisdall]
- use Colander defaults wherever explicit settings are not given [tisdall]
- added tests for confirming documentation examples [tisdall]
- added fix and test for issue 35 (thrown exception on encountering synonym() ) [tisdall]
- made changes to accommodate SQLAlchemy >= 0.9a [tisdall]
- allows “children” override (https://github.com/Pylons/colander/issues/44) [tisdall]
- no longer call callable SQLAlchemy defaults to fill in colander default values (https://github.com/Pylons/colander/issues/43) [tisdall]
- fixed some minor issues with colander default and missing values to ensure transitive relationships (such as dictify/objectify) [tisdall]
- require colander 1.0b1 or greater to support
- Add objectify function on SQLAlchemySchemaNode – use this to recreate SQLAlchemy object instances from the configured mappers. This new method is the opposite of dictify. [davidjb]
- Colander’s DateTime now defaults to using a naive datetime when no timezone is provided, similar to SQLAlchemy. [tisdall]
- fixed defaults for SchemaNode.default and SchemaNode.missing [tisdall]
- No changes.
- Ensure relationship mapped schemas have a name. This ensures correct usage with Deform.
- Ensure missing schema node information correctly maps to SQLAlchemy structures.
- Map missing information for “required” relationships based upon the join condition. This can be further customised by given relationships setting missing=colander.required within their respective configurations.
- Read Colander node init settings for a mapped class using the __colanderalchemy__ attribute. This allows for full customisation of the resulting colander.Mapping SchemaNode.
- Allow non-SQLAlchemy schema nodes within SQLAlchemySchemaNode. Previously, the dictify method would throw an AttributeError.
- Fix setup.py for python 3k
- Ensure relationships are mapped recursively and adhere to ColanderAlchemy settings for mappings.
- Remove dictify method in SQLAlchemyMapping.
- Fix minor bugs.
- Fix bug in MappingRegistry.__init__: pkeys is a list of property keys instead of column name
- Add support to specify schema node ordering.
- Fix bug related to ‘ca_include=False’.
- Change tests to cover that bug.
- Fix issue related to mapped class inheritance.
- Fix minor bugs.
- Added support to use ColanderAlchemy declaratively.
- Added SQLAlchemyMapping.dictify method.
- Updated tests with checks needed to test SQLAlchemyMapping.dictify.
- Mentioned supported Python versions in trove classifiers.
- Updated tests to run with current
- Made compatible with Python 3.2.
- Initial public release.