* fix: aerich migrate raises `tortoise.exceptions.FieldError` when `index.INDEX_TYPE` is not empty
* feat: add `IF NOT EXISTS` to postgres create index template
* chore: explicit declare type hints of function parameters
* feat: support `--fake` for aerich upgrade
* Add `--fake` to downgrade
* tests: check --fake result for aerich upgrade and downgrade
* Update readme
* Fix unittest failed because of `db_field_types` changed
* refactor: improve type hints and document
* fix: migration with duplicate renaming of columns in some cases
* Update var name
* fix downgrade sql error
* fix test error
* docs: update changelog
* Add unittest
* Move not change line to origin position
* Update sort key to make it more frieldly interactive from multi fields rename
* refactor: remove puzzle vars
* docs: fix PR links in changelog
* fix sort key lambda error
* Add `__eq__` method for `Index`instances
* tests: add Index test case
* refactor: compare index instances before set hash and eq func to class
* fix: sort fields when generating index hash
* docs: update changlog
* fix style issue
* refactor: use CustomIndex instead of postgres special HashIndex
* Check tortoise version before patch Index
* Add comment
* Add comment for why > work
---------
Co-authored-by: dbf <somnium@riseup.net>
* fix: migrate drop the wrong m2m field when model have multi m2m fields
* Make style and update changelog
* refactor: return new lists instead of change argument values in function
* refactor: use custom diff function instead of reorder lists
* docs: fix typo
* Fix hardcoded and rename custom diff function
* Update function doc
* Fix KeyError when deleting a field with unqiue=True
* refactor: rename `old_data_unique` to `is_unique_field`
* Add testcases for remove unique field
---------
Co-authored-by: gongchangku <gongchangku@anban.tech>
Co-authored-by: Waket Zheng <waketzheng@gmail.com>