# sanic-init **Repository Path**: MemoryFast/sanic-init ## Basic Information - **Project Name**: sanic-init - **Description**: No description available - **Primary Language**: Python - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2021-09-28 - **Last Updated**: 2021-09-28 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 安装 pip3 install pipreqs # 使用步骤 1.在项目根目录下执行命令 pipreqs . # 报错就执行下面这条 pipreqs . --encoding=utf8 --force 2.可以看到生成了requirements.txt文件 3.执行下面代码就会把项目用到的所有组件装上 pip3 install -r requirements.txt D:\code\sanic\venv\Scripts\pipreqs . --encoding=utf8 --force db = MySQLDatabase('db',host='127.0.0.1',port='3306',user='root',password='123456') 以上为连接mysql数据库的代码 db:数据库名 host:ip地址,连接远程数据库服务器时需要修改 port:数据库的端口号 user:数据库的用户名 password:数据库的数据库密码 peewee.ImproperlyConfigured: MySQL driver not installed! pip install pymysql