摘要: 替换源 ``` # 显示所有通道 conda config --show channels # 删除所有通道 conda config --remove-key channels # 清华镜像使用帮助 https://mirror.tuna.tsinghua.edu.cn/help/anaconda 阅读全文
posted @ 2022-04-29 16:33 太晓 阅读(87) 评论(0) 推荐(0) 编辑
摘要: # 修改默认源 pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple # 临时修改源 pip install django -i https://pypi.tuna.tsinghua.edu.cn/simpl 阅读全文
posted @ 2020-12-09 21:15 太晓 阅读(238) 评论(0) 推荐(0) 编辑
摘要: ``` import csv def parseCSVFileStr(data): """ 将csv转换为 [{},{},{},{},{},{},] 形式的列表 """ titleFlag = 0 ldata = [] ltitle = [] data = data.replace('"', '') 阅读全文
posted @ 2023-06-03 14:03 太晓 阅读(7) 评论(0) 推荐(0) 编辑
摘要: 常用 ``` # float 整数位为秒 time.time() # struct_time time.localtime() # string time.ctime() # string time.asctime() ``` 转换 ``` # struct_time time.localtime( 阅读全文
posted @ 2023-06-03 11:35 太晓 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 初始化webdriver ``` opts = webdriver.chrome.options.Options() # 无头模式 opts.add_argument("--headless") opts.add_argument("--disable-gpu") # 驱动地址 driver_pat 阅读全文
posted @ 2023-05-20 13:43 太晓 阅读(5) 评论(0) 推荐(0) 编辑
摘要: env ``` 华为云 HECS Ubuntu 22.04 server 64bit ``` ``` # 安装 sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plu 阅读全文
posted @ 2023-04-05 13:53 太晓 阅读(7) 评论(0) 推荐(0) 编辑
摘要: wx.showToast wx.showToast({ title: '失败',//提示文字 duration:2000,//显示时长 mask:true,//是否显示透明蒙层,防止触摸穿透,默认:false icon:'success', //图标,支持"success"、"loading" su 阅读全文
posted @ 2023-03-23 09:53 太晓 阅读(127) 评论(0) 推荐(0) 编辑
摘要: # 安装 sudo apt-get install tinyproxy # 修改配置 vim /etc/tinyproxy/tinyproxy.conf # 所有的ip都可访问, 注释所有Allow #Allow 127.0.0.1 # 重启 sudo service tinyproxy resta 阅读全文
posted @ 2023-03-22 11:08 太晓 阅读(66) 评论(0) 推荐(0) 编辑
摘要: SVG源 ``` ``` 转为 BASE64 ``` PHN2ZyBzdHlsZT0id2lkdGg6IDFlbTtoZWlnaHQ6IDFlbTt2ZXJ0aWNhbC1hbGlnbjogbWlkZGxlO2ZpbGw6IGN1cnJlbnRDb2xvcjtvdmVyZmxvdzogaGlkZGV 阅读全文
posted @ 2023-03-09 14:11 太晓 阅读(1001) 评论(0) 推荐(0) 编辑
摘要: ''' 1.序列化相关 serializer ModelSerializer ''' from rest_framework import serializers class SerializerClass(serializers.ModelSerializer): class Meta: mode 阅读全文
posted @ 2023-02-23 15:05 太晓 阅读(8) 评论(0) 推荐(0) 编辑
摘要: 环境 华为云 HECS Ubuntu 22.04 server 64bit 常用命令 # 添加用户 sudo useradd -m aaa -g admin sudo passwd aaa # 修改用户解释器 sudo vi /etc/passwd 最后一条添加或修改为 aaa:x:1000:100 阅读全文
posted @ 2023-01-13 21:22 太晓 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 运行时无法将程序传送到远程端问题排查 Tools -> Options -> Devices 配置好IP地址后, 点击 Test 按钮提示: Device test finished successfully. 则远程通信成功 打开.pro文件 添加 # 远程部署的路径 target.path=/h 阅读全文
posted @ 2022-09-09 11:06 太晓 阅读(70) 评论(0) 推荐(0) 编辑