Name | AnyBlok JSON |
Version |
2.2.0
JSON |
| download |
home_page | |
Summary | Anyblok is a dynamic injection blok framework |
upload_time | 2024-02-17 22:47:43 |
maintainer | |
docs_url | None |
author | |
requires_python | >=3.7 |
license | MPL2 |
keywords |
django
notifications
delayed sending
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
.. This file is a part of the AnyBlok project
..
.. Copyright (C) 2014 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2019 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
.. Copyright (C) 2019 Hugo QUEZADA <gohu@hq.netlib.re>
..
.. This Source Code Form is subject to the terms of the Mozilla Public License,
.. v. 2.0. If a copy of the MPL was not distributed with this file,You can
.. obtain one at http://mozilla.org/MPL/2.0/.
.. image:: https://img.shields.io/pypi/pyversions/anyblok.svg?longCache=True
:alt: Python versions
.. image:: https://img.shields.io/pypi/v/AnyBlok.svg
:target: https://pypi.python.org/pypi/AnyBlok/
:alt: Version status
.. image:: https://travis-ci.org/AnyBlok/AnyBlok.svg?branch=master
:target: https://travis-ci.org/AnyBlok/AnyBlok
:alt: Build status
.. image:: https://coveralls.io/repos/github/AnyBlok/AnyBlok/badge.svg?branch=master
:target: https://coveralls.io/github/AnyBlok/AnyBlok?branch=master
:alt: Coverage
.. image:: https://readthedocs.org/projects/anyblok/badge/?version=latest
:alt: Documentation Status
:scale: 100%
:target: https://doc.anyblok.org/en/latest/?badge=latest
.. image:: https://badges.gitter.im/AnyBlok/community.svg
:alt: gitter
:target: https://gitter.im/AnyBlok/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge
.. image:: https://img.shields.io/static/v1?label=Compatible%20with&message=PostgreSQL%20|%20MySQL%20|%20Microsoft%20SQL%20Server&color=informational
:alt: Dialects compatibility
AnyBlok
=======
AnyBlok is a Python framework allowing to create highly dynamic and modular
applications on top of SQLAlchemy.
AnyBlok is released under the terms of the `Mozilla Public License`.
AnyBlok is hosted on `github <https://github.com>`_ - the main project
page is at https://github.com/anyblok/anyblok or
http://code.anyblok.org. source code is tracked here
using `git <https://git-scm.com>`_.
Releases and project status are available on Pypi at
https://pypi.python.org/pypi/anyblok.
The most recent published version of the documentation should be at
https://doc.anyblok.org.
There is a tutorial to teach you how to develop applications with AnyBlok at
https://anyblok.gitbooks.io/anyblok-book/content/en/
Project Status
--------------
AnyBlok is expected to be stable.
Some early partners are using it on production and are involved in
the project development.
We are aiming to make a stable release as soon as possible.
Users should take care to report bugs and missing features on an as-needed
basis.
It should be expected that the development version may be required
for proper implementation of recently repaired issues in between releases;
the latest master is always available at https://github.com/AnyBlok/AnyBlok/archive/master.zip.
Installation
------------
Install released versions of AnyBlok from the Python package index with
`pip <http://pypi.python.org/pypi/pip>`_ or a similar tool::
pip install anyblok
Installation via source distribution is via the ``setup.py`` script::
python setup.py install
Installation will add the ``anyblok`` commands to the environment.
Running Tests
-------------
To run framework tests with ``pytest``::
pip install pytest
ANYBLOK_DATABASE_DRIVER=postgresql ANYBLOK_DATABASE_NAME=test_anyblok py.test anyblok/tests
To run tests of all installed bloks with demo data::
anyblok_createdb --db-name test_anyblok --db-driver-name postgresql --install-all-bloks --with-demo
ANYBLOK_DATABASE_DRIVER=postgresql ANYBLOK_DATABASE_NAME=test_anyblok py.test anyblok/bloks
AnyBlok is tested continuously using `Travis CI
<https://travis-ci.org/AnyBlok/AnyBlok>`_
Contributing (hackers needed!)
------------------------------
AnyBlok is ready for production usage even though it can be
improved and enriched.
Feel free to fork, talk with core dev, and spread the word !
Author
------
Jean-Sébastien Suzanne
Contributors
------------
* Jean-Sébastien Suzanne
* Georges Racinet
* Pierre Verkest
* Franck Bret
* Denis Viviès
* Alexis Tourneux
* Hugo Quezada
* Simon André
* Florent Jouatte
* Christophe Combelles
* Sébastien Chazallet
* François GUÉRIN
Bugs
----
Bugs and features enhancements to AnyBlok should be reported on the `Issue
tracker <http://issue.anyblok.org>`_.
.. This file is a part of the AnyBlok project
..
.. Copyright (C) 2014 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2015 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2016 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2017 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2018 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2019 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>
.. Copyright (C) 2019 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
.. Copyright (C) 2020 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
.. Copyright (C) 2021 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
.. Copyright (C) 2022 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
.. Copyright (C) 2023 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>
..
.. This Source Code Form is subject to the terms of the Mozilla Public License,
.. v. 2.0. If a copy of the MPL was not distributed with this file,You can
.. obtain one at http://mozilla.org/MPL/2.0/.
CHANGELOG
=========
2.2.0 (2024-02-18)
------------------
* Removed tables **system_model**, **system_field**, **system_column**,
**system_relationship**, this action can break the compatibility.
You must use the **ModelSelection** or **ModelFieldSelection**
column to give the same behaviour
* Added new column type **ModelReference**. This column is used to replace
the Many2One when the target could be coming from any Model validate by
the model_validator choosen. If you have only one targeted Model use the
relationship ManyToOne
* Reverted the deletion of the core.Session
* With python > 3.11, removed dependencies of pkg_ressource for entrypoints
and use importlib.
* Added the capability to add mixin to build the Registry Class.
2.1.0 (2023-07-26)
------------------
* Implement psycopg3 capability
* Improved TimeStamp field
* Fixed #227 str and repr of the query call str query.sql_statement
* Refactored main methods to get the description of the models and fields
without used the existing table
* Added new column type **ModelSelection** this role is to replace a column
with a foreigh key to the deprecated model **Model.System.Model**
* Added new column type **ModelFieldSelection** this role is to replace a
column with a foreigh key to the deprecated model **Model.System.Field**,
**Model.System.Column** or **Model.System.Relationship**
2.0.0 (2023-03-11)
------------------
* Upgrade version of sqlalchemy to **2.0.0**
* Upgrade version of sqlalchemy utils to **0.40.0**
* Upgrade version of sqlalchemy views to **0.3.2**
* The previsous deprecated configuration are placed as removed
theses configurations will be removed from the code in the next version
* Added Sequence with *no gap* to provide functional sequence without gaps.
* Fixed sphinx plugins
1.4.0 (2023-02-17)
------------------
* Freeze version of SQLAlchemy < 2.0
* Freeze version of SQLAlchemy_Util < 0.40.0
* Forbid primary key on Float and Decimal
* Replace setup packagin by pyproject.toml
1.3.2 (2022-02-19)
------------------
* Fixed Graphviz dependencies #207
* Fixed Mapper on column with **primary_key=False** #208
1.3.1 (2021-08-25)
------------------
* Fixed sphinx pluggin
1.3.0 (2021-07-12)
------------------
* Added deprecated name argument on the configuration to
add a deprecated message on theses. The goal is to informe
the user of AnyBlok that a sys args will be removed
* Added removed name argument on the configuration to forbid
the sys arg
* Added plugins to migrate DateTime to DateTime with MariaDB and MySQL
* Added cache_ok attribute on Column Type
* Fixed issue #195, the issue was due of a changement of the api of
the hybrid properties, Thanks @petrus-v for your help
* Fixed issue #196, A setter on the deprecated attribut **registry**
do a setter on the attribute **anyblok**
1.2.0 (2021-04-14)
------------------
* Adapted to **SQLAlchemy >= 1.4**
* Fixed Many2One with pycountry as primary key
* Fixed Many2One with **primary_key=True**, when primary key is True,
this nullable is forced to False
* Refactored hybrid_property to use the decorator mecanisme
* Adapted SQLA.URL manipulation, which was became immutable
* Used the inspect method, not the deprecated Inspector
* Refactored View, need the latest version of sqlalchemy-views
* Removed old sqlalchemy interfaces for MySQL, replaced it by entry points
* Added engine.event entry point to define action on engine
* Added engine.event.**dialect name** entry point to define action on the
engine for the dialect
* Added session.event.**dialect name** entry point to define action on the
session for the dialect
* Added entries in configuration to ignore migration for Schema or Model
* Fixed the configuration of the documentation build on readthedoc
1.1.0 (2021-03-22)
------------------
* Fixed version of **SQLAlchemy < 1.4.0**, The next version of AnyBlok
will be adapted to **SQLAlchemy >= 1.4.0 < 2.0.0**, and will prepare to
**SQLAlchemy >= 2.0**, See issue #168
* **SQLAlchemy 1.4.0** add a new attribut in the model **registry**,
this attribute conflicts with the registry of AnyBlok. A new attribute
**anyblok** is created on the model to call the registry of AnyBlok.
A modification of the attribute **registry** is done to use both attributes
with the same name. A deprecation warning is added on the attibute **registry**
of AnyBlok
1.0.0 (2020-12-03)
------------------
* Added Sequence with *no gap* to provide functional sequence without gaps.
* OrderList class_collection can be defined on x2Many
* Added plugins system for migration of column type
* Bug Fix on registry loading sequence. The **apply_model_schema_on_table**
method called at registry initialisation has been splitted to make sqlalchemy
ORM events registration independent from migration.
* Added undefined blok behaviour. It is an important behaviour needed and
written in the roadmap where the goal is to defined blok which need another
inexisting blok. this blok is installabled only if the blok exist. A package
can defined a group of bloks that depend of another packages. They bloks
are installabled if the another package is installed
* It is now possible to place a "Model" in another schema on the SGDB
::
@registry(...)
class MyModelInOtherSchema:
__db_schema__ = 'my_schema'
* Now the Email, Selection, Country, Json, Decimal, Interval, LargeBinary
columns can be crypted
* Removed compatibility with **Python 3.4** and **python 3.5**, because
these versions are deprecated
* Added *TimeStamp* column
* Added *Enum* column
* Added **ignore_migration** to protect the existing table or column again
auto migration when then schema and this definition are diferents
* Added capability with mssql+pyodbc
* Fixed View: allow to add Many2One to a View
* Added flag_modified method on SQLModel #72
* Add in extra dependencies drivers used in unit tests for dialects tested
with cPython
* postgres: psycopg2-binary
* mysql: mysqlclient
* mariadb: mysqlclient
* mssql: pymssql
* pyodbc
* System.Parameter.get do not raise if a default value is provided
* Add ``--with-demo`` parameter while creating a database (anyblok_createdb) in
order to load demo data while installing bloks on that database.
* Fixed issue #45: System.Sequence: inconsistency in 'number' field
* Fixed issue #134: is now possible to validate if the type at each part of foreign key
are the same
0.22.5 (2019-06-24)
-------------------
* Reverted console script **anyblok_nose**: to keep compatibility
* Fixed minimum version of **SQLalchemy >= 1.3** in package dependencies
* Removed some deprecation warning
0.22.2 (2019-06-23)
-------------------
* Fixed configfile with pytest with blok tests
0.22.1 (2019-06-22)
-------------------
* Fixed configfile with pytest
0.22.0 (2019-06-21)
-------------------
* Replaced the **nose test** by **pytest**. All the test was converted.
* Moved and renamed ``anyblok.tests.testcase.py`` to ``anyblok.testing.py``.
The file ``anyblok.tests.testcase.py`` import only the TestCase class to
continue to maintain the compatibility with older tests. PR
`#67 <https://github.com/AnyBlok/AnyBlok/pull/67>`_
* the console script ``anyblok_nose`` raise an exception. Because this runner
can't execute pytest tests. The goal is to use the nose plugin.
* Removed the behviour ``test-bloks-at-install``
* Added compatibility with `MySQL <https://www.mysql.com/>`_ and
`MariaDB <https://mariadb.org/>`_. PR `#85 <https://github.com/AnyBlok/AnyBlok/pull/85>`_
.. warning::
this version can break unittest if the console script **anyblok_nose** is used
0.21.3 (2019-03-19)
-------------------
* Fixed issue #83, the name of constraint create by anyblok is truncated to check if the name is the same as the reflected name
0.21.2 (2019-03-18)
-------------------
* Fixed truncated constraint, the sqltext is different in function of the DB type
0.21.1 (2019-03-18)
-------------------
* Fixed pypi upload
0.21.0 (2019-03-15)
-------------------
* Fixed alias. The ``Model.aliased`` method now binds the registry to the alias. The goal is
to use **hybrid_method** with alias in AnyBlok.
* Fixed Column.Country, The latest version of pycountry does not raise a lookup exception
When the countries does not exist. Now AnyBlok takes this change into consideration to raise the exception
and keep the main behaviour
* Fixed alias. Now the ``Model.aliased`` method links the registry instance into the aliased model.
The goal is to use `hybrid_method <https://docs.sqlalchemy.org/en/latest/orm/extensions/hybrid.html#sqlalchemy.ext.hybrid.hybrid_method>`_
decorator with alias in AnyBlok.
* Fixed #60: Now DateTime plugins verify also the DateTime columns of the dependencies of the Model
* Removed **Python 3.3** compatibility
* Improved the NoResultFound Exception for query.one and query.dictone. Now the registry name of the model
is added to the exception's message
* Fixed compatitibility with **SQLAlchemy > 1.3**
0.20.0 (2018-09-10)
-------------------
* Refactor the plugins MODEL and VIEW to become factory, rename type attribute by factory
attribute.
.. warning::
This new version does not break the compatibility, but
deprecates older ways of registering SQL View Models.
The version 1.0.0 of AnyBlok will remove these deprecated ways entirely.
The new way to register SQL View Model is as follows::
from anyblok.model.factory import ViewFactory
@register(Model, factory=ViewFactory)
class MyModel:
...
whereas before version 0.19.2, it would have been::
@register(Model, is_sql_view=True)
class MyModel:
...
and in version 0.19.3, it was::
from anyblok.model.common import VIEW
@register(Model, type=VIEW)
class MyModel:
...
* issue #53: added primary join for mapping relationship of SQL views
to themselves
* issue #54: on Blok methods
``pre_migration()``, ``post_migration()`` and ``update()`` the
``latest_version`` parameter is now instance
of ``pkg_resources`` ``Version`` class, or ``None``
* new tests base class: SharedDataTestCase, allowing to share costly
fixtures among tests of the same class
* scripts: removed useless and too magic ``need_blok``
* fixed Travis configuration for python 3.7
* plugins sytem optimization: removed stub implementations for all
possible methods in base class (gives a substantial speedup in
Travis tests).
* issue #55: Now, the **auto migration engine** of the Blok is entirely executed between
``pre_migration()`` and ``post_migration()``.
0.19.3 (2018-09-03)
-------------------
* FIX #52, bad naming convention for type of model
0.19.2 (2018-09-01)
-------------------
* Fix phone number with an empty string value
* Fix migration with added more than one new required columns with default values
* Fix Sql View can define Many2One relationship
* Fix SQL View, The __mapper__ is put in the Model
* FIX SQL View, For Sql view the mapping of the field must be find with anyblok prefix column
* The build of the Model class come from plugin model, The objectif is to implement other than
Model or View
0.19.1 (2018-06-07)
-------------------
* Remove useless method, because this was move on distribution **anyblok_io**
* In Many2Many the generated join table add fieldname to get two M2M with the same models
* Fix ``load_namespace_first_step``, the bug merged properties between Mixin
0.19.0 (2018-05-29)
-------------------
* Remove All mixins, put them in another distribution **anyblok_mixins**
* remove bloks **anyblok-io**, **anyblok-io-csv**, **anyblok-io-xml**, they
are put in another distribution **anyblok_io**
* improve unit test + coverage
0.18.0 (2018-05-22)
-------------------
* Refactor of the nose's plugin by Georges Racinet
* Add mixin **ConditionalForbidUpdate**, **ConditionalForbidDelete**,
**ConditionalReadOnly**, **BooleanForbidUpdate**, **BooleanForbidDelete**,
**BooleanReadOnly**, **StateReadOnly**
0.17.4 (2018-05-16)
-------------------
* [FIX] autodoc
0.17.3 (2018-05-16)
-------------------
* [FIX] fix remove field
* [FIX] ``io`` formater model with external id. The error forbidden the
none / empty value.
* [FIX] option ``install_or_update_bloks``, if one blok is marked as
**toupdate**, then this blok will be not marked as **toinstall**
* [FIX] ``Blok.import_file`` have not raise if does not found
**error_found** in the result of the import
* [FIX] ``Model.get_primary_keys`` with polymorphism (single table)
* Remove ``column.uText``, ``column.uString``, ``column.SmallInteger``
* [ADD] ``column.PhoneNumber``
* [ADD] ``column.Email``
* [ADD] ``column.Country``
0.17.2 (2018-02-27)
-------------------
* [FIX] hasattr on field.Function
* [IMP] Improve rich **Many2Many** to allow to have got a rich **Many2Many**
with the same model on the both side, Add also a new attribute
**join_model** to compute the real join table from the table name defined
on the Model, In the case of join_model with column based on Many2One.
Add an option to force recompute secondaryjoin and primaryjoin in the
case where the model join have more than one foreign key to one of the
both model. the m2m_local_columns and m2m_remote_columns become required
attribute
* [ADD] New field.JsonRelated. The goal is to manipulate a json entry as a
column
0.17.1 (2018-02-24)
-------------------
* [FIX] repr when no value for relationship
0.17.0 (2018-02-23)
-------------------
* [FIX] **SQLAlchemy_Utils** changed the import path of **EncryptedType** in
version **0.33.0**
* [REF] Add default_time on configuration and **DateTime** column.
Before this change a naive datetime get the timezone of server host, now
it possible to add the attibute **default_timezone** on each column or
**default_timezone** on configuration for all the column.
For each **DateTime** column the default timezone use is define by the order:
1) default_timezone on column (if defined)
2) default_timezone in configuration (if defined)
3) timezone of the server
.. warning::
This options are only use for naive datetime, to save them with a timezone.
In the case of a datetime with timezone, this datetime keep their own datetime.
* [REF] add a function in config to get the name of the database from Configuration
**db_name** or **db_url**. The script **anyblok_createdb** and the plugin
use this function.
* [IMP] Add option **--anyblok-db-url** in plugin nose options. the options can have
default value from environment variable **ANYBLOK_DATABASE_URL**
* [IMP] add primary_key attibute on Many2One and One2One.
Only when the column is created by the relationship Many2One or One2One.
The column created get the attribute primary_key gave to relationship and
apply it.
* [IMP] add repr default method on all SqlModel and ViewSqlModel
* [FIX] Encrypt columns, the custom type from anyblok did not implement
the ``process_result_value`` need for decrypt value
* [REF] Simplify Configuration, old and unused code are removed
0.16.2 (2018-02-12)
-------------------
* [FIX] Add column with an unique constraint.
Alembic declare now two changes: **add column** and **add unique constraint**
. Then the migration operation **add column** must not create the constraint
* [IMP] add index constraint operation.
Alembic declare now **add unique constraint**, the migration operation
create the constraint on an existing and an unexisting columns
* [IMP] add index attibute on Many2One and One2One.
Only when the column is created by the relationship Many2One or One2One.
The column created get the attribute index gave to relationship and
apply it.
* [FIX] raise an ConfigurationException on wrong path
if an inexisting configuration file is given the the exception is raised
* [REF] update **anyblok.start**
The configuration is now loaded when configuration_group is none
* [ADD] **isolation_level** configuration
The isolation level can be passed by **anyblok.start** or by the Configuration
The default value is **READ_COMMITTED**, In the case or console script and
Configuration add isolation level, the isolation used is always the isolation
came from **anyblok.start**
* [REF] The nose plugins take the **tests** directories in any location in the blok
not only at the root of the blok
* [REF] The options **test-blok-at-install** take the **tests** directory in any
location in the blok not only at the root of the blok
* [REF] The anyblok_nose console script to take the **tests** directories in any
location in the blok not only at the root of the blok
0.16.1 (2018-01-29)
-------------------
* [FIX] Many2Many on the same Model
* [FIX] Many2One with multi primary key
* [FIX] add specific exception when the number of column in join table
for many2many is not the same that primary key
0.16.0 (2018-01-25)
-------------------
* [REF] Json field, use the Json field from SQLAlchemy, because it
is implemented by the db
* [FIX] check constraint on selection to get a name without number
of entry
0.15.0 (2018-01-17)
-------------------
* [REF] column Selection add check constraint to forbid other
value than the wanted
0.14.0 (2018-01-15)
-------------------
* [REF] change log level, the instalation become less verbose
* [REF] change namimg convention, dont check in function of
table and column name to know if it is an AnyBlok constraint
* [FIX] check if a drop check constraint is not a add check constraint
truncated
* [ADD] raise an exception if the primary changed, this action is too
complexe to know how transform the relationship and keep the real
value
0.13.0 (2018-01-09)
-------------------
* [FIX] check constraint must not be create at the same time that the column,
because the column of the constraint could have not exist yet
* [REF] change namimg convention
* [FIX] detect and apply drop check constraint in the migration
* [FIX] detect and apply add check constraint in the migration
0.12.2 (2018-01-04)
-------------------
* [FIX] name of the created class, before the fix anyblok use the tablename.
In the case of polymorphism on single table, sqlalchemy found two two or more
mappers for a single mapper name. Now the class name is the registry name
without dot.
This change have consequence only if the primary join is forced.
In the case::
Test = registry.Test
Test.id
you need to change::
primaryjoin = 'test.id == ...'
by::
primaryjoin = 'ModelTest.id == ...'
* [FIX] name of the fakecolumn when a Many2One is added whitout
existing column names. This action allow to create two Many2One
to the same remote Model.
.. warning::
This change have a big consequence on existing table, because a new column
is added and the origin column is mark as unknown. You have to rename the column
by SQL migration or add the column in Model or force the name in Many2One.
* [FIX] In the One2Many when two foreign keys found to the same primary key
the primary join of the relation ship is now a ``or_`` not a ``and_``
* [FIX] One2Many detect also the Many2One to get the FakeColumn to do primary join
0.12.1 (2017-12-23)
-------------------
* [FIX] not invalidate cache on an uninstalled model
0.12.0 (2017-12-23)
-------------------
* [FIX] Declare Field Function in Polymophic subclass
* [FIX] Declare Field Function in Polymophic
* [ADD] auto register of sqlalchemy ORM event
* [ADD] Mixin to do readonly
* [REMOVE] cron functionality, it will be add in another package **anyblok_dramatiq**
* [FIX] Field.DateTime documentation, add ``is auto updated``
* [REF] add entry point ``anyblok.session.event`` and additional_setting
``anyblok.session.event`` to add some events on the session
* [FIX] clean foreign_key in some column type, now the foreign_key is made by Column class
* [FIX] remove for System.Field and System.Model the removed fields
0.11.1 (2017-11-28)
-------------------
* [ADD] in DBTestCase add init_registry_with_bloks, this method is similar at
init_registry, it install the bloks after add the new model
* [FIX] create precommit_hooks in the EnvironnementManager if it does not exist
* [FIX] create postcommit_hooks in the EnvironnementManager if it does not exist
0.11.0 (2017-11-20)
-------------------
* [ADD] log debug for commit / rollback
* [REF] precommit_hook, can also be on no SQL Model
* [ADD] postcommit_hook
* [FIX] UUID inheritance
0.10.1 (2017-11-14)
-------------------
* [FIX] change log
0.10.0 (2017-11-14)
-------------------
* [ADD] ``anyblok_configuration.post_load`` to initialize some services in
function of configuration
* [REF] Update configuration groups to add ``dramatiq-broker`` by default.
This configuration groups is filled by **anyblok_dramatiq** package
* [FIX] when the applications configuration has not ``configuration_groups``
then the configuration use the ``configuration_groups`` of the default
application
* [ADD] Add configuration group ``preload`` definition, but not used
* [ADD] Entry point ``anyblok.model.plugin`` to add behaviour on the model
* [REF] **hybrid_method** become an ``anyblok.model.plugin``
* [REF] adapter of mapper_args and table_args become an ``anyblok.model.plugin``
* [REF] **event** become an ``anyblok.model.plugin``
* [REF] **sqlachemy event** become an ``anyblok.model.plugin``
* [REF] **cache** and **classmethod_cache** become an ``anyblok.model.plugin``
* [IMP] **Configuration.add_configuration_group** need to add a new group for
a console script
* [IMP] add new ``anyblok.model.plugin`` to update datetime columns when the
auto_update is True
0.9.10 (2017-09-23)
-------------------
* [FIX] type ``Paramater`` => ``Parameter``
* [IMP] add the the author in autodoc
* [IMP] in the script blok the exclude and include model can use ``.*`` to take
children in the namespace
* [FIX] anyblok_doc with UML, don 't make agregation when the model doesn't
exist
0.9.9 (2017-09-19)
------------------
* [FIX]: add logo in the MANIFEST.in
0.9.8 (2017-09-19)
------------------
* [IMP] fields_description add remote_name
* [Update] doc, add foreign_key_option and unique for Many2One
* [IMP] add ``expire_all`` and ``expunge`` registry methods, expire all the
instance in the session
* [IMP] add ``expunge`` method on the instance
* FIX]: expire attribute must use also all the fields which come from
polymorphic model
* [FIX] if ondelete=cascade in foreign keu options, then the many2one force
the delete directely in the session
* [FIX] delete method can be also be que session.query, mapping.remove can
use this session.query.delete to remove in case of recursivity
* [IMP] IO.Mapping save the blok name when use the Blok.import_file method
* [IMP] IO blok overload ``Model.delete`` and ``Query.delete`` to delete mapping
with instances of the Models
* [FIX] create new session make must commit and remove all old session instances
* [IMP] add ``Mapping.clean`` method to clean unlinked mapping
* [IMP] add ``Mapping.remove_for_blokname`` method to remove mapping and obj
* [IMP] add new field in ``Model.System.Blok`` ``author`` and ``logo``
0.9.7 (2017-07-03)
------------------
* [FIX] field_description get also the polymorphique fields from inherit model
0.9.6 (2017-07-03)
------------------
* [FIX] in One2Many and Many2Many field, the attribute model can be used on
record node. Used for Polymorphisme
0.9.5 (2016-12-05)
------------------
* [ADD] Python 3.6 support
* Flake8
0.9.4 (2016-10-27)
------------------
* [FIX] Nose test pluggins load the configuration need for unit test
* [ADD] getFieldType on SQLBase, this method return the type of the column
0.9.3 (2016-10-12)
------------------
* [FIX] SQLAlchemy 1.1.* add autoincrement='auto', or AnyBlok wait Boolean.
If the field is an Integer and a primary_key with autoincrement='auto'
then the value is True else False
* [FIX] SQLAlchemy 1.1.*, primary_key attribute don't define autoincrement.
The column Integer with a primary_key=True whithout autoincrement
declaration use autoincrement=True
* [FIX] SQLAlchemy 1.1.*, backref property check if the collection_class has
__emulates__ attributes. InstrumentedList haven't to have this attribute
* [FIX] SQLAlchemy 1.1.*, Session State changed, update the update method
of the registry to install / update / uninstall bloks
* [FIX] SQLAlchemy 1.1.*, Hybrid property don't propagate the relationship
info attribute. The propagate is forced for Many2One and One2One. The only
both relationships to be wrapped by hybrid_property
* [FIX] SQLAlchemy 1.1.*, Hybrid property wrap the fget result in the case of
the fget is called on the class (not the instance). Adapt the unit test,
don't check if the result id of column are the same, check if the expression
give by this results are the same.
* [FIX] SQLAlchemy 1.1.*, listen can not be used with a hybrid_property.
In the case of a listen, the mapper returned is not the hybrid_property
but the real wrapped field
0.9.2 (2016-10-12)
------------------
* [FIX] setup.py: error with pip
0.9.1 (2016-10-3)
-----------------
* [FIX] migration testcase
* [FIX] graphviz FORMATS
* [FIX] travis configuration
0.9.0 (2016-07-11)
------------------
* [REF] add Configuration.has method
* [FIX] test migration, force to load registry with unittest=True
* [FIX] test event
* [FIX] test blok
* [FIX] mapper with None parameter
* [FIX] add set_defaults in parser to update configuration dict
* [FIX] one2many remote columns
* [FIX] load anyblok.init in the unit test
* [IMP] Add plugins by configuration for:
* Registry
* Migration
* get_url
* [IMP] add LogCapture
* [IMP] TestCase.Configuration, use to update Configuration only in
a context manager
* [IMP] add Registry.db_exists class method, check with the configuration
and the db_name if the connection is possible
0.8.5 (2016-06-20)
------------------
* [FIX] utf-8 encoding
* [REF] move bitbucket (mergurial) to github (git)
0.8.4 (2016-06-14)
------------------
* [FIX] io/xml/importer one2many field
* [FIX] install blok, who are not in the blok list yet. But the blok is loaded
0.8.3 (2016-04-18)
------------------
* [FIX] cache and classmethod_cache on SQL model
* [ADD] is_installed classmethod cache
0.8.2 (2016-04-06)
------------------
* [REF] IO.Mapping methods delete and multi_delete can remove entry
* [FIX] datetime with timezone use timezone.localize, better than
datetime.replace(tzinfo=...)
* [ADD] update sphinx extension
0.8.1 (2016-03-15)
------------------
* [FIX] `#21 <https://bitbucket.org/jssuzanne/anyblok/issues/21/update-setter-for-decimal>`_
Improve Decimal column setter
* [FIX] `#22 <https://bitbucket.org/jssuzanne/anyblok/issues/22/string-ustring-text-utext-columns-save>`_
String, uString, Text and uText write '' in database for False value
* [FIX] Change the external_id save in a two way
* [FIX] `#23 <https://bitbucket.org/jssuzanne/anyblok/issues/23/selection-field-when-nullable-true-doesnt>`_
Column.Selection with None value, don't return 'None' value by the getter
0.8.0 (2016-02-05)
------------------
.. warning::
Break the compatibility with the previous version of anyblok
* update method on the model
replace ::
obj.update({field1: val1, ...})
by::
obj.update(field1=val1, ...)
* [REF] session expire is now on the attribute, the update method is refactored
too.
* [FIX] blok: update version if the version change
* [REF] add required blok, this bloks is installed and updated by the scripts
anyblok_updatedb and anyblok_createdb
* [ADD] Add Color Column
* [REF] column can be encrypted
* [REF] DataTime column is not a naive datatime value
* [ADD] Add Password Column
* [ADD] Add UUID Column
* [ADD] Add URL Column
0.7.2 (2016-01-14)
------------------
* [FIX] delete flush after remove of the session
* [FIX] nose plugins
* [FIX] does'nt destroy automaticly constraints (not created by anyblok),
indexes (not created by anyblok), columns, tables by automigration, add
options to force the delete of its.
* [REF] standardize the constraint and index names
* [FIX] Multi declaration of the same foreign key in the case of M2O and O2O
* [REF] SqlBase.update, become hight level meth
0.7.1 (2016-01-08)
------------------
* [FIX] didn't cast the config data from the config file
* [IMP] copy init entry point from anyblok_pyramid
0.7.0 (2016-01-07)
------------------
.. warning::
Python 3.2 is not supported
* [REF] Add options to give database url, No break compatibility
* [REF] the argument of ArgumentParser can be add in the configuration
- Improve the help of the application
- Improve the type of the configuration, Work also with config file.
- Adapt current configuration
* [REF] start to use sqlalchemy-utils, replace the database management
* [IMP] `#18 <https://bitbucket.org/jssuzanne/anyblok/issues/18/forbidden-the-declaration-of-sqlachemy>`_
Forbidden the declaration of SQLAchemy column or relationship
* [REF] `#15 <https://bitbucket.org/jssuzanne/anyblok/issues/15/speed-up-the-unittest>`_
Refactor unittest case to not create/drop database for each test
* [FIX] `#19 <https://bitbucket.org/jssuzanne/anyblok/issues/19/migration-contrainte>`_
During migration if an unique constraint must be apply without unique
value, then the constraint will be ignore and log a warning. No break the
instalation of the blok
* [FIX] `#20 <https://bitbucket.org/jssuzanne/anyblok/issues/20/update-meth-must-refresh-the-instance-when>`_
Update meth: expire the instance cause of relationship
* [IMP] refresh and expire meth on model
* [REF] delete obj, flush the session and delete the instance of obj of the
session, before expire all the session, the goal is to reload the
relation ship.
* [REF] `#13 <https://bitbucket.org/jssuzanne/anyblok/issues/13/refactor-inheritance-tree>`_
Remove association model, replace it by call at the Blok definition
* [IMP] `#14 <https://bitbucket.org/jssuzanne/anyblok/issues/14/add-conflicting-link-between-bloks>`_
Add conflicting link between blok, two blok who are in conflict can be installed
if the other is installed
0.6.0 (2016-01-07)
------------------
* [REF] unittest isolation
* [IMP] possibility to apply an extension for sqlalchemy
* [ADD] pool configuration
0.5.2 (2015-09-28)
------------------
* [IMP] extension for Sphinx and autodoc
* [ADD] API doc in doc
* [ADD] add foreign key option in relation ship
* [CRITICAL FIX] the EnvironnementManager didn't return the good scoped method
for SQLAlchemy
* [CRITICAL FIX] the precommit_hook was not isolated by session
* [REF] add a named argument ``must_be_loaded_by_unittest``, by dafault False,
in ``Configuration.add`` to indicate if the function must be call during the
initialisation of the unittest, generally for the configuration initialized
by Environ variable
0.5.1 (2015-08-29)
------------------
* [IMP] unload declaration type callback
0.5.0 (2015-08-28)
------------------
.. warning::
Break the compatibility with the previous version of anyblok
* cache, classmethod_cache, hybrid_method and listen
replace::
from anyblok import Declarations
cache = Declarations.cache
classmethod_cache = Declarations.classmethod_cache
hybrid_method = Declarations.hybrid_method
addListener = Declarations.addListener
by::
from anyblok.declarations import (cache, classmethod_cache,
hybrid_method, listen)
.. note::
The listener can declare SQLAlchemy event
* declaration of the foreign key
replace::
@register(Model):
class MyClass:
myfield = Integer(foreign_key=(Model.System.Blok, 'name'))
myotherfield = Integer(foreign_key=('Model.System.Blok', 'name'))
by::
@register(Model):
class MyClass:
myfield = Integer(foreign_key=Model.System.Blok.use('name'))
myotherfield = Integer(foreign_key="Model.System.Blok=>name")
* [IMP] add ``pop`` behaviour on **Model.System.Parameter**
* [REF] Load configuration befoare load bloks, to use Configuration during
the declaration
* [FIX] all must return InstrumentedList, also when the result is empty
* [FIX] to_dict must not cast column
* [REF] add third entry in foreign key declaration to add options
* [IMP] ModelAttribute used to declarate the need of specific attribute and
get the attribute or the foreign key from this attribute
* [IMP] ModelAttributeAdapter, get a ModelAttribute from ModelAttribute or str
* [IMP] ModelRepr, Speudo representation of a Model
* [IMP] ModelAdapter, get a ModelRepr from ModelRepr or str
* [IMP] ModelMapper and ModelAttributeMapper
* [REF] Event, the declaration of an event can be an anyblok or a sqlalchemy event
* [REF] the foreign key must be declared with ModelAttribute
* [REF] Use Adapter for Model and attribute in relation ship
* [REF] hybrid_method, cache and classmethod_cache are now only impotable decorator function
* [IMP] in column the default can be a classmethod name
* [REF] replace all the field (prefix, suffic, ...) by a formater field.
It is a python formater string
* [IMP] Sequence column
* [IMP] add the default system or user configuration file
0.4.1 (2015-07-22)
------------------
.. warning::
Field Function change, fexp is required if you need filter
* [FIX] Field.Function, fexp is now a class method
* [REF] reduce flake8 complexity
* [REF] refactor field function
* [FIX] inherit relation ship from another model, thank Simon ANDRÉ for the
bug report
* [REF] table/mapper args definition
* [REF] Refactor Field, Column, RelationShip use now polymophic inherit
* [FIX] Foreign key constraint, allow to add and drop constraint on more than
one foreign key
* [ADD] update-all-bloks option
* [ADD] pre / post migration
* [REF] UML Diagram is now with autodoc script
* [REF] SQL Diagram is now with autodoc script
* [REF] Add **extend** key word in configuration file to extend an existing
configuration
0.4.0 (2015-06-21)
------------------
.. warning::
Break the compatibility with the previous version of anyblok
* [REF] Add the possibility to add a logging file by argparse
* [ADD] No auto migration option
* [ADD] Plugin for nose to run unit test of the installed bloks
* [REF] The relation ship can be reference more than one foreign key
* [IMP] Add define_table/mapper_args methods to fill __table/mapper\_args\_\_
class attribute need to configure SQLAlachemy models
* [REF] Limit the commit in the registry only when the SQLA Session factory
is recreated
* [REF] Commit and re-create the SQLA Session Factory, at installation, only
if the number of Session inheritance of the number of Query inheritance
change, else keep the same session
* [REF] Exception is not a Declarations type
* [FIX] Reload fonctionnality in python 3.2
* [REF] Remove the Declarations typs Field, Column, RelationShip, they are
replaced by python import
* [REF] rename **ArgsParseManager** by **Configuration**
* [REF] rename **reload_module_if_blok_is_reloaded** by
**reload_module_if_blok_is_reloading** method on blok
* [REF] rename **import_cfg_file** by **import_file** method on blok
* [REF] Consistency the argsparse configuration
* [REF] refactor part_to_load, the entry points loaded is bloks
* [IMP] Allow to define another column name in the table versus model
* [FIX] add importer for import configuration file
* [FIX] x2M importer without field just, external id
0.3.5 (2015-05-10)
------------------
* [IMP] When a new column is add, if the column have a default value, then
this value will be added in all the entries where the value is null for this
column
* [REF] import_cfg_file remove the importer when import has done
0.3.4 (2015-05-10)
------------------
* [ADD] logger.info on migration script to indicate what is changed
* [IMP] Add sequence facility in the declaration of Column
* [ADD] ADD XML Importer
0.3.3 (2015-05-04)
------------------
* [FIX] createdb script
0.3.2 (2015-05-04)
------------------
* [IMP] doc
* [REF] Use logging.config.configFile
0.3.1 (2015-05-04)
------------------
* [IMP] Update setup to add documentation files and blok's README
0.3.0 (2015-05-03)
------------------
* [IMP] Update Doc
* [FIX] Remove nullable column, the nullable constraint is removed not the column
* [ADD] Formater, convert value 2 str or str 2 value, with or without mapping
* [ADD] CSV Importer
* [REF] CSV Exporter to use Formater
0.2.12 (2015-04-29)
-------------------
* [IMP] CSV Exporter
* [IMP] Exporter Model give external ID behaviour
* [ADD] Sequence model (Model.System.Sequence)
* [ADD] fields_description cached_classmethod with invalidation
* [ADD] Parameter Model (Model.System.Parameter)
* [FIX] environnement variable for test unitaire
0.2.11 (2015-04-26)
-------------------
* [FIX] UNIT test createdb with prefix
0.2.10 (2015-04-26)
-------------------
* [IMP] add enviroment variable for database information
* [ADD] argsparse option install all bloks
* [FIX] Python 3.2 need that bloks directory are python modules, add empty __init__ file
0.2.9 (2015-04-18)
------------------
* [FIX] Add all rst at the main path of all the bloks
0.2.8 (2015-04-16)
------------------
* [IMP] unittest on SQLBase
* [IMP] add delete method on SQLBase to delete une entry from an instance of the model
* [REF] rename get_primary_keys to get_mapping_primary_keys, cause of get_primary_keys
already exist in SQLBase
0.2.7 (2015-04-15)
------------------
* [IMP] Add IPython support for interpreter
* [REF] Update and Standardize the method to field the models (Field, Column, RelationShip)
now all the type of the column go on the ftype and comme from the name of the class
0.2.6 (2015-04-11)
------------------
* [FIX] use the backref name to get the label of the remote relation ship
* [FIX] add type information of the simple field
0.2.5 (2015-03-23)
------------------
* [FIX] In the parent / children relationship, where the pk is on a mixin or
from inherit
* [FIX] How to Environment
* [FIX] Many2Many declared in Mixin
* [IMP] Many2One can now declared than the local column must be unique (
only if the local column is not declared in the model)
0.2.3 (2015-03-23)
------------------
.. warning::
This version can be not compatible with the version **0.2.2**. Because
in the foregn key model is a string you must replace the tablename by
the registry name
* [FIX] Allow to add a relationship on the same model, the main use is to add
parent / children relation ship on a model, They are any difference with
the declaration of ta relation ship on another model
* [REF] standardize foreign_key and relation ship, if the str which replace
the Model Declarations is now the registry name
0.2.2 (2015-03-15)
------------------
* [REF] Unittest
* TestCase and DBTestCase are only used for framework
* BlokTestCase is used:
- by ``run_exit`` function to test all the installed bloks
- at the installation of a blok if wanted
0.2.0 (2015-02-13)
------------------
.. warning::
This version is not compatible with the version **0.1.3**
* [REF] Import and reload are more explicite
* [ADD] IO:
* Mapping: Link between Model instance and (Model, str key)
* [ADD] Env in registry_base to access at EnvironmentManager without to import
it at each time
* [IMP] doc add how to on the environment
0.1.3 (2015-02-03)
------------------
* [FIX] setup long description, good for pypi but not for easy_install
0.1.2 (2015-02-02)
------------------
* [REFACTOR] Allow to declare Core components
* [ADD] Howto declare Core / Type
* [FIX] Model can only inherit simple python class, Mixin or Model
* [FIX] Mixin inherit chained
* [FIX] Flake8
0.1.1 (2015-01-23)
------------------
* [FIX] version, documentation, setup
0.1.0 (2015-01-23)
------------------
Main version of AnyBlok. You can with this version
* Create your own application
* Connect to a database
* Define bloks
* Install, Update, Uninstall the blok
* Define field types
* Define Column types
* Define Relationship types
* Define Core
* Define Mixin
* Define Model (SQL or not)
* Define SQL view
* Define more than one Model on a specific table
* Write unittest for your blok
Raw data
{
"_id": null,
"home_page": "",
"name": "AnyBlok",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.7",
"maintainer_email": "",
"keywords": "django,notifications,delayed sending",
"author": "",
"author_email": "Jean-S\u00e9bastien Suzanne <jssuzanne@anybox.fr>",
"download_url": "https://files.pythonhosted.org/packages/42/07/ff1958b89886a11f3cf05518ca735018935152ad377d63fd306e6ba62790/AnyBlok-2.2.0.tar.gz",
"platform": null,
"description": ".. This file is a part of the AnyBlok project\n..\n.. Copyright (C) 2014 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2019 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n.. Copyright (C) 2019 Hugo QUEZADA <gohu@hq.netlib.re>\n..\n.. This Source Code Form is subject to the terms of the Mozilla Public License,\n.. v. 2.0. If a copy of the MPL was not distributed with this file,You can\n.. obtain one at http://mozilla.org/MPL/2.0/.\n\n.. image:: https://img.shields.io/pypi/pyversions/anyblok.svg?longCache=True\n :alt: Python versions\n\n.. image:: https://img.shields.io/pypi/v/AnyBlok.svg\n :target: https://pypi.python.org/pypi/AnyBlok/\n :alt: Version status\n\n.. image:: https://travis-ci.org/AnyBlok/AnyBlok.svg?branch=master\n :target: https://travis-ci.org/AnyBlok/AnyBlok\n :alt: Build status\n\n.. image:: https://coveralls.io/repos/github/AnyBlok/AnyBlok/badge.svg?branch=master\n :target: https://coveralls.io/github/AnyBlok/AnyBlok?branch=master\n :alt: Coverage\n\n.. image:: https://readthedocs.org/projects/anyblok/badge/?version=latest\n :alt: Documentation Status\n :scale: 100%\n :target: https://doc.anyblok.org/en/latest/?badge=latest\n\n.. image:: https://badges.gitter.im/AnyBlok/community.svg\n :alt: gitter\n :target: https://gitter.im/AnyBlok/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge\n\n.. image:: https://img.shields.io/static/v1?label=Compatible%20with&message=PostgreSQL%20|%20MySQL%20|%20Microsoft%20SQL%20Server&color=informational\n :alt: Dialects compatibility\n\nAnyBlok\n=======\n\nAnyBlok is a Python framework allowing to create highly dynamic and modular\napplications on top of SQLAlchemy.\n\nAnyBlok is released under the terms of the `Mozilla Public License`.\n\nAnyBlok is hosted on `github <https://github.com>`_ - the main project\npage is at https://github.com/anyblok/anyblok or\nhttp://code.anyblok.org. source code is tracked here\nusing `git <https://git-scm.com>`_.\n\nReleases and project status are available on Pypi at\nhttps://pypi.python.org/pypi/anyblok.\n\nThe most recent published version of the documentation should be at\nhttps://doc.anyblok.org.\n\nThere is a tutorial to teach you how to develop applications with AnyBlok at\nhttps://anyblok.gitbooks.io/anyblok-book/content/en/\n\nProject Status\n--------------\n\nAnyBlok is expected to be stable.\nSome early partners are using it on production and are involved in\nthe project development.\nWe are aiming to make a stable release as soon as possible.\n\nUsers should take care to report bugs and missing features on an as-needed\nbasis.\n\nIt should be expected that the development version may be required\nfor proper implementation of recently repaired issues in between releases;\nthe latest master is always available at https://github.com/AnyBlok/AnyBlok/archive/master.zip.\n\nInstallation\n------------\n\nInstall released versions of AnyBlok from the Python package index with\n`pip <http://pypi.python.org/pypi/pip>`_ or a similar tool::\n\n pip install anyblok\n\nInstallation via source distribution is via the ``setup.py`` script::\n\n python setup.py install\n\nInstallation will add the ``anyblok`` commands to the environment.\n\nRunning Tests\n-------------\n\nTo run framework tests with ``pytest``::\n\n pip install pytest\n ANYBLOK_DATABASE_DRIVER=postgresql ANYBLOK_DATABASE_NAME=test_anyblok py.test anyblok/tests\n\nTo run tests of all installed bloks with demo data::\n\n anyblok_createdb --db-name test_anyblok --db-driver-name postgresql --install-all-bloks --with-demo\n ANYBLOK_DATABASE_DRIVER=postgresql ANYBLOK_DATABASE_NAME=test_anyblok py.test anyblok/bloks\n\nAnyBlok is tested continuously using `Travis CI\n<https://travis-ci.org/AnyBlok/AnyBlok>`_\n\nContributing (hackers needed!)\n------------------------------\n\nAnyBlok is ready for production usage even though it can be\nimproved and enriched.\nFeel free to fork, talk with core dev, and spread the word !\n\nAuthor\n------\n\nJean-S\u00e9bastien Suzanne\n\nContributors\n------------\n\n* Jean-S\u00e9bastien Suzanne\n* Georges Racinet\n* Pierre Verkest\n* Franck Bret\n* Denis Vivi\u00e8s\n* Alexis Tourneux\n* Hugo Quezada\n* Simon Andr\u00e9\n* Florent Jouatte\n* Christophe Combelles\n* S\u00e9bastien Chazallet\n* Fran\u00e7ois GU\u00c9RIN\n\nBugs\n----\n\nBugs and features enhancements to AnyBlok should be reported on the `Issue\ntracker <http://issue.anyblok.org>`_.\n\n.. This file is a part of the AnyBlok project\n..\n.. Copyright (C) 2014 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2015 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2016 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2017 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2018 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2019 Jean-Sebastien SUZANNE <jssuzanne@anybox.fr>\n.. Copyright (C) 2019 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n.. Copyright (C) 2020 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n.. Copyright (C) 2021 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n.. Copyright (C) 2022 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n.. Copyright (C) 2023 Jean-Sebastien SUZANNE <js.suzanne@gmail.com>\n..\n.. This Source Code Form is subject to the terms of the Mozilla Public License,\n.. v. 2.0. If a copy of the MPL was not distributed with this file,You can\n.. obtain one at http://mozilla.org/MPL/2.0/.\n\nCHANGELOG\n=========\n\n2.2.0 (2024-02-18)\n------------------\n\n* Removed tables **system_model**, **system_field**, **system_column**,\n **system_relationship**, this action can break the compatibility.\n You must use the **ModelSelection** or **ModelFieldSelection**\n column to give the same behaviour\n* Added new column type **ModelReference**. This column is used to replace\n the Many2One when the target could be coming from any Model validate by\n the model_validator choosen. If you have only one targeted Model use the\n relationship ManyToOne\n* Reverted the deletion of the core.Session\n* With python > 3.11, removed dependencies of pkg_ressource for entrypoints\n and use importlib.\n* Added the capability to add mixin to build the Registry Class.\n\n2.1.0 (2023-07-26)\n------------------\n\n* Implement psycopg3 capability\n* Improved TimeStamp field\n* Fixed #227 str and repr of the query call str query.sql_statement\n* Refactored main methods to get the description of the models and fields\n without used the existing table\n* Added new column type **ModelSelection** this role is to replace a column\n with a foreigh key to the deprecated model **Model.System.Model**\n* Added new column type **ModelFieldSelection** this role is to replace a\n column with a foreigh key to the deprecated model **Model.System.Field**,\n **Model.System.Column** or **Model.System.Relationship**\n\n2.0.0 (2023-03-11)\n------------------\n\n* Upgrade version of sqlalchemy to **2.0.0**\n* Upgrade version of sqlalchemy utils to **0.40.0**\n* Upgrade version of sqlalchemy views to **0.3.2**\n* The previsous deprecated configuration are placed as removed\n theses configurations will be removed from the code in the next version\n* Added Sequence with *no gap* to provide functional sequence without gaps.\n* Fixed sphinx plugins\n\n1.4.0 (2023-02-17)\n------------------\n\n* Freeze version of SQLAlchemy < 2.0\n* Freeze version of SQLAlchemy_Util < 0.40.0\n* Forbid primary key on Float and Decimal\n* Replace setup packagin by pyproject.toml\n\n1.3.2 (2022-02-19)\n------------------\n\n* Fixed Graphviz dependencies #207\n* Fixed Mapper on column with **primary_key=False** #208\n\n1.3.1 (2021-08-25)\n------------------\n\n* Fixed sphinx pluggin\n\n1.3.0 (2021-07-12)\n------------------\n\n* Added deprecated name argument on the configuration to\n add a deprecated message on theses. The goal is to informe\n the user of AnyBlok that a sys args will be removed\n* Added removed name argument on the configuration to forbid\n the sys arg\n* Added plugins to migrate DateTime to DateTime with MariaDB and MySQL\n* Added cache_ok attribute on Column Type\n* Fixed issue #195, the issue was due of a changement of the api of\n the hybrid properties, Thanks @petrus-v for your help\n* Fixed issue #196, A setter on the deprecated attribut **registry**\n do a setter on the attribute **anyblok**\n\n1.2.0 (2021-04-14)\n------------------\n\n* Adapted to **SQLAlchemy >= 1.4**\n* Fixed Many2One with pycountry as primary key\n* Fixed Many2One with **primary_key=True**, when primary key is True,\n this nullable is forced to False\n* Refactored hybrid_property to use the decorator mecanisme\n* Adapted SQLA.URL manipulation, which was became immutable\n* Used the inspect method, not the deprecated Inspector\n* Refactored View, need the latest version of sqlalchemy-views\n* Removed old sqlalchemy interfaces for MySQL, replaced it by entry points\n* Added engine.event entry point to define action on engine\n* Added engine.event.**dialect name** entry point to define action on the\n engine for the dialect\n* Added session.event.**dialect name** entry point to define action on the\n session for the dialect\n* Added entries in configuration to ignore migration for Schema or Model\n* Fixed the configuration of the documentation build on readthedoc\n\n1.1.0 (2021-03-22)\n------------------\n\n* Fixed version of **SQLAlchemy < 1.4.0**, The next version of AnyBlok\n will be adapted to **SQLAlchemy >= 1.4.0 < 2.0.0**, and will prepare to\n **SQLAlchemy >= 2.0**, See issue #168\n* **SQLAlchemy 1.4.0** add a new attribut in the model **registry**,\n this attribute conflicts with the registry of AnyBlok. A new attribute\n **anyblok** is created on the model to call the registry of AnyBlok.\n A modification of the attribute **registry** is done to use both attributes\n with the same name. A deprecation warning is added on the attibute **registry**\n of AnyBlok\n\n1.0.0 (2020-12-03)\n------------------\n\n* Added Sequence with *no gap* to provide functional sequence without gaps.\n* OrderList class_collection can be defined on x2Many\n* Added plugins system for migration of column type\n* Bug Fix on registry loading sequence. The **apply_model_schema_on_table**\n method called at registry initialisation has been splitted to make sqlalchemy\n ORM events registration independent from migration.\n* Added undefined blok behaviour. It is an important behaviour needed and\n written in the roadmap where the goal is to defined blok which need another\n inexisting blok. this blok is installabled only if the blok exist. A package\n can defined a group of bloks that depend of another packages. They bloks\n are installabled if the another package is installed\n* It is now possible to place a \"Model\" in another schema on the SGDB\n ::\n\n @registry(...)\n class MyModelInOtherSchema:\n __db_schema__ = 'my_schema'\n\n* Now the Email, Selection, Country, Json, Decimal, Interval, LargeBinary\n columns can be crypted\n* Removed compatibility with **Python 3.4** and **python 3.5**, because\n these versions are deprecated\n* Added *TimeStamp* column\n* Added *Enum* column\n* Added **ignore_migration** to protect the existing table or column again\n auto migration when then schema and this definition are diferents\n* Added capability with mssql+pyodbc\n* Fixed View: allow to add Many2One to a View\n* Added flag_modified method on SQLModel #72\n* Add in extra dependencies drivers used in unit tests for dialects tested\n with cPython\n\n * postgres: psycopg2-binary\n * mysql: mysqlclient\n * mariadb: mysqlclient\n * mssql: pymssql\n * pyodbc\n\n* System.Parameter.get do not raise if a default value is provided\n* Add ``--with-demo`` parameter while creating a database (anyblok_createdb) in\n order to load demo data while installing bloks on that database.\n* Fixed issue #45: System.Sequence: inconsistency in 'number' field\n* Fixed issue #134: is now possible to validate if the type at each part of foreign key\n are the same\n\n0.22.5 (2019-06-24)\n-------------------\n\n* Reverted console script **anyblok_nose**: to keep compatibility\n* Fixed minimum version of **SQLalchemy >= 1.3** in package dependencies\n* Removed some deprecation warning\n\n0.22.2 (2019-06-23)\n-------------------\n\n* Fixed configfile with pytest with blok tests\n\n0.22.1 (2019-06-22)\n-------------------\n\n* Fixed configfile with pytest\n\n0.22.0 (2019-06-21)\n-------------------\n\n* Replaced the **nose test** by **pytest**. All the test was converted.\n* Moved and renamed ``anyblok.tests.testcase.py`` to ``anyblok.testing.py``.\n The file ``anyblok.tests.testcase.py`` import only the TestCase class to\n continue to maintain the compatibility with older tests. PR\n `#67 <https://github.com/AnyBlok/AnyBlok/pull/67>`_\n* the console script ``anyblok_nose`` raise an exception. Because this runner\n can't execute pytest tests. The goal is to use the nose plugin.\n* Removed the behviour ``test-bloks-at-install``\n* Added compatibility with `MySQL <https://www.mysql.com/>`_ and\n `MariaDB <https://mariadb.org/>`_. PR `#85 <https://github.com/AnyBlok/AnyBlok/pull/85>`_\n\n.. warning::\n\n this version can break unittest if the console script **anyblok_nose** is used\n\n0.21.3 (2019-03-19)\n-------------------\n\n* Fixed issue #83, the name of constraint create by anyblok is truncated to check if the name is the same as the reflected name\n\n0.21.2 (2019-03-18)\n-------------------\n\n* Fixed truncated constraint, the sqltext is different in function of the DB type\n\n0.21.1 (2019-03-18)\n-------------------\n\n* Fixed pypi upload\n\n0.21.0 (2019-03-15)\n-------------------\n\n* Fixed alias. The ``Model.aliased`` method now binds the registry to the alias. The goal is\n to use **hybrid_method** with alias in AnyBlok.\n* Fixed Column.Country, The latest version of pycountry does not raise a lookup exception\n When the countries does not exist. Now AnyBlok takes this change into consideration to raise the exception\n and keep the main behaviour\n* Fixed alias. Now the ``Model.aliased`` method links the registry instance into the aliased model.\n The goal is to use `hybrid_method <https://docs.sqlalchemy.org/en/latest/orm/extensions/hybrid.html#sqlalchemy.ext.hybrid.hybrid_method>`_\n decorator with alias in AnyBlok.\n* Fixed #60: Now DateTime plugins verify also the DateTime columns of the dependencies of the Model\n* Removed **Python 3.3** compatibility\n* Improved the NoResultFound Exception for query.one and query.dictone. Now the registry name of the model\n is added to the exception's message\n* Fixed compatitibility with **SQLAlchemy > 1.3**\n\n0.20.0 (2018-09-10)\n-------------------\n\n* Refactor the plugins MODEL and VIEW to become factory, rename type attribute by factory\n attribute.\n\n .. warning::\n\n This new version does not break the compatibility, but\n deprecates older ways of registering SQL View Models.\n\n The version 1.0.0 of AnyBlok will remove these deprecated ways entirely.\n\n The new way to register SQL View Model is as follows::\n\n from anyblok.model.factory import ViewFactory\n\n @register(Model, factory=ViewFactory)\n class MyModel:\n ...\n\n whereas before version 0.19.2, it would have been::\n\n @register(Model, is_sql_view=True)\n class MyModel:\n ...\n\n and in version 0.19.3, it was::\n\n from anyblok.model.common import VIEW\n\n @register(Model, type=VIEW)\n class MyModel:\n ...\n\n* issue #53: added primary join for mapping relationship of SQL views\n to themselves\n* issue #54: on Blok methods\n ``pre_migration()``, ``post_migration()`` and ``update()`` the\n ``latest_version`` parameter is now instance\n of ``pkg_resources`` ``Version`` class, or ``None``\n* new tests base class: SharedDataTestCase, allowing to share costly\n fixtures among tests of the same class\n* scripts: removed useless and too magic ``need_blok``\n* fixed Travis configuration for python 3.7\n* plugins sytem optimization: removed stub implementations for all\n possible methods in base class (gives a substantial speedup in\n Travis tests).\n* issue #55: Now, the **auto migration engine** of the Blok is entirely executed between\n ``pre_migration()`` and ``post_migration()``.\n\n0.19.3 (2018-09-03)\n-------------------\n\n* FIX #52, bad naming convention for type of model\n\n0.19.2 (2018-09-01)\n-------------------\n\n* Fix phone number with an empty string value\n* Fix migration with added more than one new required columns with default values\n* Fix Sql View can define Many2One relationship\n* Fix SQL View, The __mapper__ is put in the Model\n* FIX SQL View, For Sql view the mapping of the field must be find with anyblok prefix column\n* The build of the Model class come from plugin model, The objectif is to implement other than\n Model or View\n\n0.19.1 (2018-06-07)\n-------------------\n\n* Remove useless method, because this was move on distribution **anyblok_io**\n* In Many2Many the generated join table add fieldname to get two M2M with the same models\n* Fix ``load_namespace_first_step``, the bug merged properties between Mixin\n\n0.19.0 (2018-05-29)\n-------------------\n\n* Remove All mixins, put them in another distribution **anyblok_mixins**\n* remove bloks **anyblok-io**, **anyblok-io-csv**, **anyblok-io-xml**, they\n are put in another distribution **anyblok_io**\n* improve unit test + coverage\n\n0.18.0 (2018-05-22)\n-------------------\n\n* Refactor of the nose's plugin by Georges Racinet\n* Add mixin **ConditionalForbidUpdate**, **ConditionalForbidDelete**,\n **ConditionalReadOnly**, **BooleanForbidUpdate**, **BooleanForbidDelete**,\n **BooleanReadOnly**, **StateReadOnly**\n\n0.17.4 (2018-05-16)\n-------------------\n\n* [FIX] autodoc\n\n0.17.3 (2018-05-16)\n-------------------\n\n* [FIX] fix remove field\n* [FIX] ``io`` formater model with external id. The error forbidden the\n none / empty value.\n* [FIX] option ``install_or_update_bloks``, if one blok is marked as\n **toupdate**, then this blok will be not marked as **toinstall**\n* [FIX] ``Blok.import_file`` have not raise if does not found\n **error_found** in the result of the import\n* [FIX] ``Model.get_primary_keys`` with polymorphism (single table)\n* Remove ``column.uText``, ``column.uString``, ``column.SmallInteger``\n* [ADD] ``column.PhoneNumber``\n* [ADD] ``column.Email``\n* [ADD] ``column.Country``\n\n0.17.2 (2018-02-27)\n-------------------\n\n* [FIX] hasattr on field.Function\n* [IMP] Improve rich **Many2Many** to allow to have got a rich **Many2Many**\n with the same model on the both side, Add also a new attribute\n **join_model** to compute the real join table from the table name defined\n on the Model, In the case of join_model with column based on Many2One.\n Add an option to force recompute secondaryjoin and primaryjoin in the\n case where the model join have more than one foreign key to one of the\n both model. the m2m_local_columns and m2m_remote_columns become required\n attribute\n* [ADD] New field.JsonRelated. The goal is to manipulate a json entry as a\n column\n\n0.17.1 (2018-02-24)\n-------------------\n\n* [FIX] repr when no value for relationship\n\n0.17.0 (2018-02-23)\n-------------------\n\n* [FIX] **SQLAlchemy_Utils** changed the import path of **EncryptedType** in\n version **0.33.0**\n* [REF] Add default_time on configuration and **DateTime** column.\n Before this change a naive datetime get the timezone of server host, now\n it possible to add the attibute **default_timezone** on each column or\n **default_timezone** on configuration for all the column.\n For each **DateTime** column the default timezone use is define by the order:\n\n 1) default_timezone on column (if defined)\n 2) default_timezone in configuration (if defined)\n 3) timezone of the server\n\n .. warning::\n\n This options are only use for naive datetime, to save them with a timezone.\n In the case of a datetime with timezone, this datetime keep their own datetime.\n\n* [REF] add a function in config to get the name of the database from Configuration\n **db_name** or **db_url**. The script **anyblok_createdb** and the plugin\n use this function.\n* [IMP] Add option **--anyblok-db-url** in plugin nose options. the options can have\n default value from environment variable **ANYBLOK_DATABASE_URL**\n* [IMP] add primary_key attibute on Many2One and One2One.\n Only when the column is created by the relationship Many2One or One2One.\n The column created get the attribute primary_key gave to relationship and\n apply it.\n* [IMP] add repr default method on all SqlModel and ViewSqlModel\n* [FIX] Encrypt columns, the custom type from anyblok did not implement\n the ``process_result_value`` need for decrypt value\n* [REF] Simplify Configuration, old and unused code are removed\n\n0.16.2 (2018-02-12)\n-------------------\n\n* [FIX] Add column with an unique constraint.\n Alembic declare now two changes: **add column** and **add unique constraint**\n . Then the migration operation **add column** must not create the constraint\n* [IMP] add index constraint operation.\n Alembic declare now **add unique constraint**, the migration operation\n create the constraint on an existing and an unexisting columns\n* [IMP] add index attibute on Many2One and One2One.\n Only when the column is created by the relationship Many2One or One2One.\n The column created get the attribute index gave to relationship and\n apply it.\n* [FIX] raise an ConfigurationException on wrong path\n if an inexisting configuration file is given the the exception is raised\n* [REF] update **anyblok.start**\n The configuration is now loaded when configuration_group is none\n* [ADD] **isolation_level** configuration\n The isolation level can be passed by **anyblok.start** or by the Configuration\n The default value is **READ_COMMITTED**, In the case or console script and\n Configuration add isolation level, the isolation used is always the isolation\n came from **anyblok.start**\n* [REF] The nose plugins take the **tests** directories in any location in the blok\n not only at the root of the blok\n* [REF] The options **test-blok-at-install** take the **tests** directory in any\n location in the blok not only at the root of the blok\n* [REF] The anyblok_nose console script to take the **tests** directories in any\n location in the blok not only at the root of the blok\n\n0.16.1 (2018-01-29)\n-------------------\n\n* [FIX] Many2Many on the same Model\n* [FIX] Many2One with multi primary key\n* [FIX] add specific exception when the number of column in join table\n for many2many is not the same that primary key\n\n0.16.0 (2018-01-25)\n-------------------\n\n* [REF] Json field, use the Json field from SQLAlchemy, because it\n is implemented by the db\n* [FIX] check constraint on selection to get a name without number\n of entry\n\n0.15.0 (2018-01-17)\n-------------------\n\n* [REF] column Selection add check constraint to forbid other\n value than the wanted\n\n0.14.0 (2018-01-15)\n-------------------\n\n* [REF] change log level, the instalation become less verbose\n* [REF] change namimg convention, dont check in function of\n table and column name to know if it is an AnyBlok constraint\n* [FIX] check if a drop check constraint is not a add check constraint\n truncated\n* [ADD] raise an exception if the primary changed, this action is too\n complexe to know how transform the relationship and keep the real\n value\n\n0.13.0 (2018-01-09)\n-------------------\n\n* [FIX] check constraint must not be create at the same time that the column,\n because the column of the constraint could have not exist yet\n* [REF] change namimg convention\n* [FIX] detect and apply drop check constraint in the migration\n* [FIX] detect and apply add check constraint in the migration\n\n0.12.2 (2018-01-04)\n-------------------\n\n* [FIX] name of the created class, before the fix anyblok use the tablename.\n In the case of polymorphism on single table, sqlalchemy found two two or more\n mappers for a single mapper name. Now the class name is the registry name\n without dot.\n This change have consequence only if the primary join is forced.\n In the case::\n\n Test = registry.Test\n Test.id\n\n you need to change::\n\n primaryjoin = 'test.id == ...'\n\n by::\n\n primaryjoin = 'ModelTest.id == ...'\n\n* [FIX] name of the fakecolumn when a Many2One is added whitout\n existing column names. This action allow to create two Many2One\n to the same remote Model.\n\n .. warning::\n\n This change have a big consequence on existing table, because a new column\n is added and the origin column is mark as unknown. You have to rename the column\n by SQL migration or add the column in Model or force the name in Many2One.\n\n* [FIX] In the One2Many when two foreign keys found to the same primary key\n the primary join of the relation ship is now a ``or_`` not a ``and_``\n* [FIX] One2Many detect also the Many2One to get the FakeColumn to do primary join\n\n0.12.1 (2017-12-23)\n-------------------\n\n* [FIX] not invalidate cache on an uninstalled model\n\n0.12.0 (2017-12-23)\n-------------------\n\n* [FIX] Declare Field Function in Polymophic subclass\n* [FIX] Declare Field Function in Polymophic\n* [ADD] auto register of sqlalchemy ORM event\n* [ADD] Mixin to do readonly\n* [REMOVE] cron functionality, it will be add in another package **anyblok_dramatiq**\n* [FIX] Field.DateTime documentation, add ``is auto updated``\n* [REF] add entry point ``anyblok.session.event`` and additional_setting\n ``anyblok.session.event`` to add some events on the session\n* [FIX] clean foreign_key in some column type, now the foreign_key is made by Column class\n* [FIX] remove for System.Field and System.Model the removed fields\n\n0.11.1 (2017-11-28)\n-------------------\n\n* [ADD] in DBTestCase add init_registry_with_bloks, this method is similar at\n init_registry, it install the bloks after add the new model\n* [FIX] create precommit_hooks in the EnvironnementManager if it does not exist\n* [FIX] create postcommit_hooks in the EnvironnementManager if it does not exist\n\n0.11.0 (2017-11-20)\n-------------------\n\n* [ADD] log debug for commit / rollback\n* [REF] precommit_hook, can also be on no SQL Model\n* [ADD] postcommit_hook\n* [FIX] UUID inheritance\n\n0.10.1 (2017-11-14)\n-------------------\n\n* [FIX] change log\n\n0.10.0 (2017-11-14)\n-------------------\n\n* [ADD] ``anyblok_configuration.post_load`` to initialize some services in\n function of configuration\n* [REF] Update configuration groups to add ``dramatiq-broker`` by default.\n This configuration groups is filled by **anyblok_dramatiq** package\n* [FIX] when the applications configuration has not ``configuration_groups``\n then the configuration use the ``configuration_groups`` of the default\n application\n* [ADD] Add configuration group ``preload`` definition, but not used\n* [ADD] Entry point ``anyblok.model.plugin`` to add behaviour on the model\n* [REF] **hybrid_method** become an ``anyblok.model.plugin``\n* [REF] adapter of mapper_args and table_args become an ``anyblok.model.plugin``\n* [REF] **event** become an ``anyblok.model.plugin``\n* [REF] **sqlachemy event** become an ``anyblok.model.plugin``\n* [REF] **cache** and **classmethod_cache** become an ``anyblok.model.plugin``\n* [IMP] **Configuration.add_configuration_group** need to add a new group for\n a console script\n* [IMP] add new ``anyblok.model.plugin`` to update datetime columns when the\n auto_update is True\n\n0.9.10 (2017-09-23)\n-------------------\n\n* [FIX] type ``Paramater`` => ``Parameter``\n* [IMP] add the the author in autodoc\n* [IMP] in the script blok the exclude and include model can use ``.*`` to take\n children in the namespace\n* [FIX] anyblok_doc with UML, don 't make agregation when the model doesn't\n exist\n\n0.9.9 (2017-09-19)\n------------------\n\n* [FIX]: add logo in the MANIFEST.in\n\n0.9.8 (2017-09-19)\n------------------\n\n* [IMP] fields_description add remote_name\n* [Update] doc, add foreign_key_option and unique for Many2One\n* [IMP] add ``expire_all`` and ``expunge`` registry methods, expire all the\n instance in the session\n* [IMP] add ``expunge`` method on the instance\n* FIX]: expire attribute must use also all the fields which come from\n polymorphic model\n* [FIX] if ondelete=cascade in foreign keu options, then the many2one force\n the delete directely in the session\n* [FIX] delete method can be also be que session.query, mapping.remove can\n use this session.query.delete to remove in case of recursivity\n* [IMP] IO.Mapping save the blok name when use the Blok.import_file method\n* [IMP] IO blok overload ``Model.delete`` and ``Query.delete`` to delete mapping\n with instances of the Models\n* [FIX] create new session make must commit and remove all old session instances\n* [IMP] add ``Mapping.clean`` method to clean unlinked mapping\n* [IMP] add ``Mapping.remove_for_blokname`` method to remove mapping and obj\n* [IMP] add new field in ``Model.System.Blok`` ``author`` and ``logo``\n\n0.9.7 (2017-07-03)\n------------------\n\n* [FIX] field_description get also the polymorphique fields from inherit model\n\n0.9.6 (2017-07-03)\n------------------\n\n* [FIX] in One2Many and Many2Many field, the attribute model can be used on\n record node. Used for Polymorphisme\n\n0.9.5 (2016-12-05)\n------------------\n\n* [ADD] Python 3.6 support\n* Flake8\n\n0.9.4 (2016-10-27)\n------------------\n\n* [FIX] Nose test pluggins load the configuration need for unit test\n* [ADD] getFieldType on SQLBase, this method return the type of the column\n\n0.9.3 (2016-10-12)\n------------------\n\n* [FIX] SQLAlchemy 1.1.* add autoincrement='auto', or AnyBlok wait Boolean.\n If the field is an Integer and a primary_key with autoincrement='auto'\n then the value is True else False\n* [FIX] SQLAlchemy 1.1.*, primary_key attribute don't define autoincrement.\n The column Integer with a primary_key=True whithout autoincrement\n declaration use autoincrement=True\n* [FIX] SQLAlchemy 1.1.*, backref property check if the collection_class has\n __emulates__ attributes. InstrumentedList haven't to have this attribute\n* [FIX] SQLAlchemy 1.1.*, Session State changed, update the update method\n of the registry to install / update / uninstall bloks\n* [FIX] SQLAlchemy 1.1.*, Hybrid property don't propagate the relationship\n info attribute. The propagate is forced for Many2One and One2One. The only\n both relationships to be wrapped by hybrid_property\n* [FIX] SQLAlchemy 1.1.*, Hybrid property wrap the fget result in the case of\n the fget is called on the class (not the instance). Adapt the unit test,\n don't check if the result id of column are the same, check if the expression\n give by this results are the same.\n* [FIX] SQLAlchemy 1.1.*, listen can not be used with a hybrid_property.\n In the case of a listen, the mapper returned is not the hybrid_property\n but the real wrapped field\n\n0.9.2 (2016-10-12)\n------------------\n\n* [FIX] setup.py: error with pip\n\n0.9.1 (2016-10-3)\n-----------------\n\n* [FIX] migration testcase\n* [FIX] graphviz FORMATS\n* [FIX] travis configuration\n\n0.9.0 (2016-07-11)\n------------------\n\n* [REF] add Configuration.has method\n* [FIX] test migration, force to load registry with unittest=True\n* [FIX] test event\n* [FIX] test blok\n* [FIX] mapper with None parameter\n* [FIX] add set_defaults in parser to update configuration dict\n* [FIX] one2many remote columns\n* [FIX] load anyblok.init in the unit test\n* [IMP] Add plugins by configuration for:\n\n * Registry\n * Migration\n * get_url\n\n* [IMP] add LogCapture\n* [IMP] TestCase.Configuration, use to update Configuration only in\n a context manager\n* [IMP] add Registry.db_exists class method, check with the configuration\n and the db_name if the connection is possible\n\n0.8.5 (2016-06-20)\n------------------\n\n* [FIX] utf-8 encoding\n* [REF] move bitbucket (mergurial) to github (git)\n\n0.8.4 (2016-06-14)\n------------------\n\n* [FIX] io/xml/importer one2many field\n* [FIX] install blok, who are not in the blok list yet. But the blok is loaded\n\n0.8.3 (2016-04-18)\n------------------\n\n* [FIX] cache and classmethod_cache on SQL model\n* [ADD] is_installed classmethod cache\n\n0.8.2 (2016-04-06)\n------------------\n\n* [REF] IO.Mapping methods delete and multi_delete can remove entry\n* [FIX] datetime with timezone use timezone.localize, better than\n datetime.replace(tzinfo=...)\n* [ADD] update sphinx extension\n\n0.8.1 (2016-03-15)\n------------------\n\n* [FIX] `#21 <https://bitbucket.org/jssuzanne/anyblok/issues/21/update-setter-for-decimal>`_\n Improve Decimal column setter\n* [FIX] `#22 <https://bitbucket.org/jssuzanne/anyblok/issues/22/string-ustring-text-utext-columns-save>`_\n String, uString, Text and uText write '' in database for False value\n* [FIX] Change the external_id save in a two way\n* [FIX] `#23 <https://bitbucket.org/jssuzanne/anyblok/issues/23/selection-field-when-nullable-true-doesnt>`_\n Column.Selection with None value, don't return 'None' value by the getter\n\n0.8.0 (2016-02-05)\n------------------\n\n.. warning::\n\n Break the compatibility with the previous version of anyblok\n\n * update method on the model\n replace ::\n\n obj.update({field1: val1, ...})\n\n by::\n\n obj.update(field1=val1, ...)\n\n* [REF] session expire is now on the attribute, the update method is refactored\n too.\n* [FIX] blok: update version if the version change\n* [REF] add required blok, this bloks is installed and updated by the scripts\n anyblok_updatedb and anyblok_createdb\n* [ADD] Add Color Column\n* [REF] column can be encrypted\n* [REF]\u00a0DataTime column is not a naive datatime value\n* [ADD] Add Password Column\n* [ADD] Add UUID Column\n* [ADD] Add URL Column\n\n0.7.2 (2016-01-14)\n------------------\n\n* [FIX] delete flush after remove of the session\n* [FIX] nose plugins\n* [FIX] does'nt destroy automaticly constraints (not created by anyblok),\n indexes (not created by anyblok), columns, tables by automigration, add\n options to force the delete of its.\n* [REF] standardize the constraint and index names\n* [FIX] Multi declaration of the same foreign key in the case of M2O and O2O\n* [REF] SqlBase.update, become hight level meth\n\n0.7.1 (2016-01-08)\n------------------\n\n* [FIX] didn't cast the config data from the config file\n* [IMP] copy init entry point from anyblok_pyramid\n\n0.7.0 (2016-01-07)\n------------------\n\n.. warning::\n\n Python 3.2 is not supported\n\n* [REF] Add options to give database url, No break compatibility\n* [REF] the argument of ArgumentParser can be add in the configuration\n - Improve the help of the application\n - Improve the type of the configuration, Work also with config file.\n - Adapt current configuration\n* [REF] start to use sqlalchemy-utils, replace the database management\n* [IMP] `#18 <https://bitbucket.org/jssuzanne/anyblok/issues/18/forbidden-the-declaration-of-sqlachemy>`_\n Forbidden the declaration of SQLAchemy column or relationship\n* [REF] `#15 <https://bitbucket.org/jssuzanne/anyblok/issues/15/speed-up-the-unittest>`_\n Refactor unittest case to not create/drop database for each test\n* [FIX] `#19 <https://bitbucket.org/jssuzanne/anyblok/issues/19/migration-contrainte>`_\n During migration if an unique constraint must be apply without unique\n value, then the constraint will be ignore and log a warning. No break the\n instalation of the blok\n* [FIX] `#20 <https://bitbucket.org/jssuzanne/anyblok/issues/20/update-meth-must-refresh-the-instance-when>`_\n Update meth: expire the instance cause of relationship\n* [IMP] refresh and expire meth on model\n* [REF] delete obj, flush the session and delete the instance of obj of the\n session, before expire all the session, the goal is to reload the\n relation ship.\n* [REF] `#13 <https://bitbucket.org/jssuzanne/anyblok/issues/13/refactor-inheritance-tree>`_\n Remove association model, replace it by call at the Blok definition\n* [IMP] `#14 <https://bitbucket.org/jssuzanne/anyblok/issues/14/add-conflicting-link-between-bloks>`_\n Add conflicting link between blok, two blok who are in conflict can be installed\n if the other is installed\n\n0.6.0 (2016-01-07)\n------------------\n\n* [REF] unittest isolation\n* [IMP] possibility to apply an extension for sqlalchemy\n* [ADD] pool configuration\n\n0.5.2 (2015-09-28)\n------------------\n\n* [IMP] extension for Sphinx and autodoc\n* [ADD] API doc in doc\n* [ADD] add foreign key option in relation ship\n* [CRITICAL FIX] the EnvironnementManager didn't return the good scoped method\n for SQLAlchemy\n* [CRITICAL FIX] the precommit_hook was not isolated by session\n* [REF] add a named argument ``must_be_loaded_by_unittest``, by dafault False,\n in ``Configuration.add`` to indicate if the function must be call during the\n initialisation of the unittest, generally for the configuration initialized\n by Environ variable\n\n0.5.1 (2015-08-29)\n------------------\n\n* [IMP] unload declaration type callback\n\n0.5.0 (2015-08-28)\n------------------\n\n.. warning::\n\n Break the compatibility with the previous version of anyblok\n\n * cache, classmethod_cache, hybrid_method and listen\n replace::\n\n from anyblok import Declarations\n cache = Declarations.cache\n classmethod_cache = Declarations.classmethod_cache\n hybrid_method = Declarations.hybrid_method\n addListener = Declarations.addListener\n\n by::\n\n from anyblok.declarations import (cache, classmethod_cache,\n hybrid_method, listen)\n\n .. note::\n\n The listener can declare SQLAlchemy event\n\n * declaration of the foreign key\n replace::\n\n @register(Model):\n class MyClass:\n\n myfield = Integer(foreign_key=(Model.System.Blok, 'name'))\n myotherfield = Integer(foreign_key=('Model.System.Blok', 'name'))\n\n by::\n\n @register(Model):\n class MyClass:\n\n myfield = Integer(foreign_key=Model.System.Blok.use('name'))\n myotherfield = Integer(foreign_key=\"Model.System.Blok=>name\")\n\n* [IMP] add ``pop`` behaviour on **Model.System.Parameter**\n* [REF] Load configuration befoare load bloks, to use Configuration during\n the declaration\n* [FIX] all must return InstrumentedList, also when the result is empty\n* [FIX] to_dict must not cast column\n* [REF] add third entry in foreign key declaration to add options\n* [IMP] ModelAttribute used to declarate the need of specific attribute and\n get the attribute or the foreign key from this attribute\n* [IMP] ModelAttributeAdapter, get a ModelAttribute from ModelAttribute or str\n* [IMP] ModelRepr, Speudo representation of a Model\n* [IMP] ModelAdapter, get a ModelRepr from ModelRepr or str\n* [IMP] ModelMapper and ModelAttributeMapper\n* [REF] Event, the declaration of an event can be an anyblok or a sqlalchemy event\n* [REF] the foreign key must be declared with ModelAttribute\n* [REF] Use Adapter for Model and attribute in relation ship\n* [REF] hybrid_method, cache and classmethod_cache are now only impotable decorator function\n* [IMP] in column the default can be a classmethod name\n* [REF] replace all the field (prefix, suffic, ...) by a formater field.\n It is a python formater string\n* [IMP] Sequence column\n* [IMP] add the default system or user configuration file\n\n0.4.1 (2015-07-22)\n------------------\n\n.. warning::\n\n Field Function change, fexp is required if you need filter\n\n* [FIX] Field.Function, fexp is now a class method\n* [REF] reduce flake8 complexity\n* [REF] refactor field function\n* [FIX] inherit relation ship from another model, thank Simon ANDR\u00c9 for the\n bug report\n* [REF] table/mapper args definition\n* [REF] Refactor Field, Column, RelationShip use now polymophic inherit\n* [FIX] Foreign key constraint, allow to add and drop constraint on more than\n one foreign key\n* [ADD] update-all-bloks option\n* [ADD] pre / post migration\n* [REF] UML Diagram is now with autodoc script\n* [REF] SQL Diagram is now with autodoc script\n* [REF] Add **extend** key word in configuration file to extend an existing\n configuration\n\n0.4.0 (2015-06-21)\n------------------\n\n.. warning::\n\n Break the compatibility with the previous version of anyblok\n\n* [REF] Add the possibility to add a logging file by argparse\n* [ADD] No auto migration option\n* [ADD] Plugin for nose to run unit test of the installed bloks\n* [REF] The relation ship can be reference more than one foreign key\n* [IMP] Add define_table/mapper_args methods to fill __table/mapper\\_args\\_\\_\n class attribute need to configure SQLAlachemy models\n* [REF] Limit the commit in the registry only when the SQLA Session factory\n is recreated\n* [REF] Commit and re-create the SQLA Session Factory, at installation, only\n if the number of Session inheritance of the number of Query inheritance\n change, else keep the same session\n* [REF] Exception is not a Declarations type\n* [FIX] Reload fonctionnality in python 3.2\n* [REF] Remove the Declarations typs Field, Column, RelationShip, they are\n replaced by python import\n* [REF] rename **ArgsParseManager** by **Configuration**\n* [REF] rename **reload_module_if_blok_is_reloaded** by\n **reload_module_if_blok_is_reloading** method on blok\n* [REF] rename **import_cfg_file** by **import_file** method on blok\n* [REF] Consistency the argsparse configuration\n* [REF] refactor part_to_load, the entry points loaded is bloks\n* [IMP] Allow to define another column name in the table versus model\n* [FIX] add importer for import configuration file\n* [FIX]\u00a0x2M importer without field just, external id\n\n0.3.5 (2015-05-10)\n------------------\n\n* [IMP] When a new column is add, if the column have a default value, then\n this value will be added in all the entries where the value is null for this\n column\n* [REF] import_cfg_file remove the importer when import has done\n\n0.3.4 (2015-05-10)\n------------------\n\n* [ADD] logger.info on migration script to indicate what is changed\n* [IMP] Add sequence facility in the declaration of Column\n* [ADD] ADD XML Importer\n\n0.3.3 (2015-05-04)\n------------------\n\n* [FIX] createdb script\n\n0.3.2 (2015-05-04)\n------------------\n\n* [IMP] doc\n* [REF] Use logging.config.configFile\n\n0.3.1 (2015-05-04)\n------------------\n\n* [IMP] Update setup to add documentation files and blok's README\n\n0.3.0 (2015-05-03)\n------------------\n\n* [IMP] Update Doc\n* [FIX] Remove nullable column, the nullable constraint is removed not the column\n* [ADD] Formater, convert value 2 str or str 2 value, with or without mapping\n* [ADD] CSV Importer\n* [REF] CSV Exporter to use Formater\n\n0.2.12 (2015-04-29)\n-------------------\n\n* [IMP] CSV Exporter\n* [IMP] Exporter Model give external ID behaviour\n* [ADD] Sequence model (Model.System.Sequence)\n* [ADD] fields_description cached_classmethod with invalidation\n* [ADD] Parameter Model (Model.System.Parameter)\n* [FIX] environnement variable for test unitaire\n\n0.2.11 (2015-04-26)\n-------------------\n\n* [FIX] UNIT test createdb with prefix\n\n0.2.10 (2015-04-26)\n-------------------\n\n* [IMP] add enviroment variable for database information\n* [ADD] argsparse option install all bloks\n* [FIX] Python 3.2 need that bloks directory are python modules, add empty __init__ file\n\n0.2.9 (2015-04-18)\n------------------\n\n* [FIX] Add all rst at the main path of all the bloks\n\n0.2.8 (2015-04-16)\n------------------\n\n* [IMP] unittest on SQLBase\n* [IMP] add delete method on SQLBase to delete une entry from an instance of the model\n* [REF] rename get_primary_keys to get_mapping_primary_keys, cause of get_primary_keys\n already exist in SQLBase\n\n0.2.7 (2015-04-15)\n------------------\n\n* [IMP] Add IPython support for interpreter\n* [REF] Update and Standardize the method to field the models (Field, Column, RelationShip)\n now all the type of the column go on the ftype and comme from the name of the class\n\n0.2.6 (2015-04-11)\n------------------\n\n* [FIX] use the backref name to get the label of the remote relation ship\n* [FIX] add type information of the simple field\n\n0.2.5 (2015-03-23)\n------------------\n\n* [FIX] In the parent / children relationship, where the pk is on a mixin or\n from inherit\n* [FIX] How to Environment\n* [FIX] Many2Many declared in Mixin\n* [IMP] Many2One can now declared than the local column must be unique (\n only if the local column is not declared in the model)\n\n0.2.3 (2015-03-23)\n------------------\n\n.. warning::\n\n This version can be not compatible with the version **0.2.2**. Because\n in the foregn key model is a string you must replace the tablename by\n the registry name\n\n* [FIX] Allow to add a relationship on the same model, the main use is to add\n parent / children relation ship on a model, They are any difference with\n the declaration of ta relation ship on another model\n* [REF] standardize foreign_key and relation ship, if the str which replace\n the Model Declarations is now the registry name\n\n0.2.2 (2015-03-15)\n------------------\n\n* [REF] Unittest\n * TestCase and DBTestCase are only used for framework\n * BlokTestCase is used:\n - by ``run_exit`` function to test all the installed bloks\n - at the installation of a blok if wanted\n\n0.2.0 (2015-02-13)\n------------------\n\n.. warning::\n\n This version is not compatible with the version **0.1.3**\n\n* [REF] Import and reload are more explicite\n* [ADD] IO:\n * Mapping: Link between Model instance and (Model, str key)\n\n* [ADD] Env in registry_base to access at EnvironmentManager without to import\n it at each time\n* [IMP] doc add how to on the environment\n\n0.1.3 (2015-02-03)\n------------------\n\n* [FIX] setup long description, good for pypi but not for easy_install\n\n0.1.2 (2015-02-02)\n------------------\n\n* [REFACTOR] Allow to declare Core components\n* [ADD] Howto declare Core / Type\n* [FIX] Model can only inherit simple python class, Mixin or Model\n* [FIX] Mixin inherit chained\n* [FIX] Flake8\n\n0.1.1 (2015-01-23)\n------------------\n\n* [FIX] version, documentation, setup\n\n0.1.0 (2015-01-23)\n------------------\n\nMain version of AnyBlok. You can with this version\n\n* Create your own application\n* Connect to a database\n* Define bloks\n* Install, Update, Uninstall the blok\n* Define field types\n* Define Column types\n* Define Relationship types\n* Define Core\n* Define Mixin\n* Define Model (SQL or not)\n* Define SQL view\n* Define more than one Model on a specific table\n* Write unittest for your blok\n",
"bugtrack_url": null,
"license": "MPL2",
"summary": "Anyblok is a dynamic injection blok framework",
"version": "2.2.0",
"project_urls": {
"Homepage": "https://doc.anyblok.org/en/1.4.0/"
},
"split_keywords": [
"django",
"notifications",
"delayed sending"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "cb86826aa4f259b6d3396379e05990cc47b565bf9fb459682aec05a80e9b4ee9",
"md5": "cec43a8fde875cb4c31f7102ee23aebd",
"sha256": "963eaf55778674c9986db4e1054ed55d5699a43a942cd7d1b9558d63f8da178f"
},
"downloads": -1,
"filename": "AnyBlok-2.2.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "cec43a8fde875cb4c31f7102ee23aebd",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7",
"size": 296162,
"upload_time": "2024-02-17T22:47:40",
"upload_time_iso_8601": "2024-02-17T22:47:40.173238Z",
"url": "https://files.pythonhosted.org/packages/cb/86/826aa4f259b6d3396379e05990cc47b565bf9fb459682aec05a80e9b4ee9/AnyBlok-2.2.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4207ff1958b89886a11f3cf05518ca735018935152ad377d63fd306e6ba62790",
"md5": "3c1d727e004e94937e2d3781fc339c5d",
"sha256": "dbf6b98f124ed535038c646183935c5500ed0013a1e7c88f2ef2c119ba1a57b7"
},
"downloads": -1,
"filename": "AnyBlok-2.2.0.tar.gz",
"has_sig": false,
"md5_digest": "3c1d727e004e94937e2d3781fc339c5d",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7",
"size": 275897,
"upload_time": "2024-02-17T22:47:43",
"upload_time_iso_8601": "2024-02-17T22:47:43.507441Z",
"url": "https://files.pythonhosted.org/packages/42/07/ff1958b89886a11f3cf05518ca735018935152ad377d63fd306e6ba62790/AnyBlok-2.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-02-17 22:47:43",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "anyblok"
}