一. 前言
事情是这样子的, 在玩all in boom时, 发现作为Wi-Fi信号发射的无线路由太过于碍事和占地方, 准备通过无线网卡, 以win10上自带的移动热点来发射Wi-Fi信号, 这样就完全实现all in boom.
由于对于Wi-Fi没什么高要求, 只需要设备具备2.4G/5G双频即可, 由于主机机箱完全封死, 不准备拆开安装PCIE 无线网卡, 所以在淘宝上随便买了一个不知名品牌(反正全是长得一个模子)的usb无线网卡(集成蓝牙5.3).
事情是这样子的, 在玩all in boom时, 发现作为Wi-Fi信号发射的无线路由太过于碍事和占地方, 准备通过无线网卡, 以win10上自带的移动热点来发射Wi-Fi信号, 这样就完全实现all in boom.
由于对于Wi-Fi没什么高要求, 只需要设备具备2.4G/5G双频即可, 由于主机机箱完全封死, 不准备拆开安装PCIE 无线网卡, 所以在淘宝上随便买了一个不知名品牌(反正全是长得一个模子)的usb无线网卡(集成蓝牙5.3).

对于各类网络配置介绍的文章或视频, 可以简单分为两类
以下, 以Hyper-V的网络设置为中心, 简略对其中涉及的主要内容进行相对详尽的梳理.
# Windows预置的时间同步服务器, time.windows.com, 就属于可访问, 但速度慢不稳地
ntp.ntsc.ac.cn # 中国国家授时中心
由于大清特殊的国情和外部的某些原因, 不少境外站点的访问很多时候都是问题. 不是无法访问就是速度如蜗牛, 亦或者135墙, 246放, 间歇性的可访问.
尽管有梯子存在, 但是在下载大文件, 代理的设置方面都存在各种问题, 镜像资源站的存在就很重要了.
以下为一些镜像站和js的静态资源站以及基本的配置.

Loguru is a library which aims to bring enjoyable logging in Python.
Did you ever feel lazy about configuring a logger and used
print()instead?... I did, yet logging is fundamental to every application and eases the process of debugging. Using Loguru you have no excuse not to use logging from the start, this is as simple asfrom loguru import logger.Also, this library is intended to make Python logging less painful by adding a bunch of useful functionalities that solve caveats of the standard loggers. Using logs in your application should be an automatism, Loguru tries to make it both pleasant and powerful.
pip install loguru
Delgan/loguru: Python logging made (stupidly) simple
loguru.logger - loguru documentation
简而言之, loguru是个开箱即用近乎傻瓜化的强大日志管理工具, 相比于原生的logging - Logging facility for Python - Python 3.13.7 documentation, loguru不需要复杂的封装, 也不需要复杂的配置, 拿来就可以用.
但需要注意, 在某些场景下的使用, 如: 多进程.
事情是这样子的, 在整理python loguru日志管理工具的使用记录. 专门开了个章节用于阐述在多进程下的使用, 随即扩张了下内容, 谈到了fastapi 在uvicorn下多进程(workers )的使用, 在查询资料时, 在GitHub上看到某项目上的一个离谱PR, 然后就有了文本(不吐不快).
事情是这样的, 为了测试fastapi的并发请求处理, 写了简单的前端脚本测试
{
console.time('total');
const urls = Array(4).fill('http://127.0.0.1:8000/test'),
tasks = urls.map(url => fetch(url).then(r => r.json()).then(data => data));
await Promise.allSettled(tasks);
console.timeEnd('total');
}
http://127.0.0.1:8000/test, 在服务器端, 设置每个请求需要等待1秒.