上一页 1 2 3 4 5 6 ··· 19 下一页
摘要: flask_limit nginx的配置 location / { include uwsgi_params; proxy_pass http://127.0.0.1:5000/; uwsgi_param UWSGI_CHDIR /home/flask/Aflask_api; proxy_set_h 阅读全文
posted @ 2020-08-03 17:26 得淼 阅读(480) 评论(0) 推荐(0)
摘要: 控制台执行如下语句 VACUUM; 阅读全文
posted @ 2020-08-03 16:02 得淼 阅读(156) 评论(0) 推荐(0)
摘要: from sqlalchemy import Column from sqlalchemy.orm import sessionmaker from sqlalchemy.ext.declarative import declarative_base def make_model(fanyi_en_ 阅读全文
posted @ 2020-08-03 10:29 得淼 阅读(294) 评论(0) 推荐(0)
摘要: def rreplace(string,str,new_str,max=1): string=string[::-1] str=str[::-1] new_str=new_str[::-1] return string.replace(str,new_str,max)[::-1] 阅读全文
posted @ 2020-07-31 11:37 得淼 阅读(241) 评论(0) 推荐(0)
摘要: from pypinyin import pinyin, Style def is_number(s): try: float(s) return True except ValueError: pass try: import unicodedata unicodedata.numeric(s) 阅读全文
posted @ 2020-07-30 14:50 得淼 阅读(407) 评论(0) 推荐(0)
摘要: 电脑安装证书-》 手机安装证书(导入证书到文件里,点击,描述文件安装输入密码) 关于手机-》证书信任设置-》完全信任 阅读全文
posted @ 2020-07-23 18:29 得淼 阅读(110) 评论(0) 推荐(0)
摘要: [uwsgi] http=127.0.0.1:5000 #项目路径 chdir=/home/flask/Aflask_api #启动qpp callable = app #启动文件名 wsgi-file =app.py #进程数 processes = 2 #线程数 threads = 8 buff 阅读全文
posted @ 2020-07-19 16:59 得淼 阅读(800) 评论(0) 推荐(0)
摘要: 数据库当前只有一个root用户,需要创建一个只读帐户给其他使用,因使用者是使用数据库管理工具在其他主机访问,所以还要开户远程访问权限,操作步骤如下。 使用现有的root用户登录到Mysql。 mysql -uroot -p 2. 创建用户,并授权SELECT查询权限,授权远程访问权限,注意,命令中u 阅读全文
posted @ 2020-07-19 12:06 得淼 阅读(911) 评论(0) 推荐(1)
摘要: js2py的用法 content = js2py.EvalJs() #实例化解析js对象 content.execute(js_code) #js转python代码 tk=content.TL(word2) #调用js中的TL函数,word2为TL的参数 阅读全文
posted @ 2020-07-07 16:44 得淼 阅读(1066) 评论(0) 推荐(0)
摘要: 关于Flask的jsonify返回的数据是utf-8编码的问题 Flask的两种运行方式是 1. app.py 作为被执行文件(即左上角的configuration) 那么__main__下的配置是不生效的,要写到上面 app = Flask(__name__) app.config['JSON_A 阅读全文
posted @ 2020-05-29 10:03 得淼 阅读(1617) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 ··· 19 下一页