1 使用create_all()生成带问号的数据库文件 2 在models.py 中创建模型类后,会把表模型注册到sqlalchemy里,所以在create_all之前必须把模型的声明导入进来 导入前: 导入后: