Commit Graph

25 Commits

Author SHA1 Message Date
513fd32cc8 Fix property_fields not being inherited. Fix for #774. (#891)
* Fix property_fields not being inherited. Fix for #774.

* Fix coverage

* Fix coverage by removing set attribute update - during inheriting the current property fields are not set yet.
2022-10-21 16:18:37 +02:00
b6e057c303 CheckColumns Constraint (#730)
* feat: add check columns class

* feat: write document of check columns part

* test: write a test for check columns constraints

* fix: debuging test exception raise mysql

* fix: set pragma no cover to ignore cov

* fix: ignore pytest raise in python 3.x not 10

* feat: set constraint name for check columns

* refactor: support index and check overwrites

* fix: debuging check constraint arguments

* fix: debug coverage all code tests

* fix: pass the map of type constraint to counter

* refactor: edit check name replace sapce underline

* refactor: write new function copy constraints

* test: write test for invalid constraint type

* fix: debug text cluase replaced names

* fix: set pragma no cover for result returned

* refactor: no coverage for main if statement

* perf: change get constraint copy func code

* fix: fix bug in mypy typing check
2022-07-14 10:05:30 +02:00
11bf6d30c4 Fix #320 add __cache__ property into PydanticMixin (#625)
* add __cache__ property into PydanticMixin

* add new test for exclude fields on relations

* fix the return type from __cache__  property

* run pre-commit lints/checks

Co-authored-by: collerek <collerek@gmail.com>
2022-05-07 13:45:42 +02:00
851fe0c14f fix for validators inheritance 2021-10-15 10:39:41 +02:00
10e2d01a91 update docs, bump version, update releases 2021-10-12 18:52:40 +02:00
9559c0f7f6 inherit choices validators and class validators for fields in generated pydantic models 2021-10-11 16:22:50 +02:00
f6458be157 fix coverage 2021-10-11 12:22:47 +02:00
6d2712c0f8 resolve merge conflicts 2021-10-09 16:30:35 +02:00
1b1da6c3b1 add workaround test for validation of fields in generated pydantic 2021-10-08 15:31:33 +02:00
b2541bed1e Added poetry integration.
Description:
* Fixed github actions;
* Removed requirements.txt;
* Fixed CONTRIBUTING.md;
* Fixed black and flake8.

Signed-off-by: Pavel <win10@list.ru>
2021-10-08 16:56:59 +04:00
cd87303b5c add multi column non unique columns 2021-09-06 16:47:37 +02:00
46500eba39 fix for #327 and #328 2021-09-01 11:50:04 +02:00
3528d6effa add docs, provide check if Config is a class, ignore dynamic bases for mypy 2021-07-25 12:11:50 +02:00
5dcbe8f0e5 Change comparisons to use 'is' 2021-07-24 11:48:11 -07:00
29761999e7 Allow custom model config 2021-07-24 11:43:48 -07:00
b423c1c56d fixes for #270 and #274 2021-07-21 14:39:23 +02:00
7b1d1ad328 test for missing nested models in generated pydantic models 2021-07-21 13:55:48 +02:00
107404c3e8 fix inherited pk and add field accessor access to relations 2021-06-25 13:32:31 +02:00
0254abcd6c fix chars 2021-06-02 10:37:27 +02:00
f52797fb06 more tests for excluding parent fields, finished docs 2021-06-02 10:16:47 +02:00
3b9c8b323b add exclude_parent_fields param and first test 2021-06-01 18:51:06 +02:00
b643c884ac add fastapi tests for get_pydantic 2021-05-24 18:04:41 +02:00
981d10d4db add tests for self-reference ormar -> pydantic 2021-05-24 10:29:27 +02:00
b611c891cd fix default check 2021-05-23 16:50:51 +02:00
f93ab413de add get_pydantic and basic tests 2021-05-23 16:44:24 +02:00