我的鬼鬼
Results
1
comments of
我的鬼鬼
``` File "/env/storageadmin/lib/python3.9/site-packages/aerich/migrate.py", line 211, in diff_models table = change[0][1].get("through") AttributeError: 'str' object has no attribute 'get' ``` 我在把一张包含ManytoMany字段的表的更改后(改了表名,related_name和through) ,迁移时发生了同样的问题,我的解决办法是把迁移分成两次,第一次直接把模型删除, 第二次把更改后的模型添加,就ok了