Recently, a new table has been added to the flash project, but an error is reported when executing flash DB migrate, as shown in the following figure:
Google around the Internet and finally know the problem:
although the migration directory in the project has been deleted, the version information has been saved in the database. Yes, this is the table – alembic_ version
So all you have to do is delete the version record of this table:
After deletion, execute flash DB migrate again, no error is reported, and the table is generated normally ~
Read More:
- Flask Database Migration Error: ERROR [flask_migrate] Error: Can‘t locate revision identified by ‘a1c25fe0fc0e‘
- Python: Django exception when executing migrate operation: django.db.utils.OperationalError: (1051, “Unknown table’xxx’”)
- can‘t multiply sequence by non-int of type ‘numpy.float64‘
- Flash cli encountered a keyerror “migrate” [How to Solve]
- [Solved] flash initializate database error: Keyerror: ‘migrate’
- [Solved] D455 Depth Camera Error: keyerror: ‘frame_ device_ t‘
- [Solved] SyntaxError: (unicode error) ‘unicodeescape‘ codec can‘t decode bytes in position 10-11: malformed
- AttributeError: can‘t set attribute [How to Solve]
- [Solved] git review Error: UnicodeDecodeError: ‘gbk‘ codec can‘t decode
- [Solved] transformers Install Error: error can‘t find rust compiler
- [Solved] Can‘t pickle local object ‘_createenviron.<locals>.encodekey‘
- [Solved] YOLO v5 Error: AttributeError: Can‘t get attribute SPPF on module models
- How to Solve Pytorch DataLoader Loading Error: UnicodeDecodeError: ‘utf-8‘ codec can‘t decode byte 0xe5 in position 1023
- [Solved] SyntaxError: (unicode error) ‘unicodeescape‘ codec can‘t decode bytes in position 6-7: malformed
- You can run the Ansible Playbook in Python by hand
- SyntaxError: (unicode error) ‘unicodeescape‘ codec can‘t decode bytes in position 2-3: truncated \UX
- SyntaxError: (unicode error) ‘unicodeescape‘ codec can‘t decode bytes in position 2-3: truncated \UX
- [Solved] Grid Search Error (GridSearchCV): ‘ascii‘ codec can‘t encode characters in position 18-20: ordinal not in r
- [Solved] UnicodeDecodeError: ‘utf-8‘ codec can‘t decode byte 0xbf in position 7: invalid start byte
- Python Error: SyntaxError: (unicode error) ‘unicodeescape‘ codec can‘t decode bytes in position 2-3: