Skip to content

更新版本到0.5.5.rc1 - #31

Merged
UF4OVER merged 9 commits into
F4CP_releasefrom
F4CP_debug
Jun 7, 2026
Merged

UF4OVER merged 9 commits into
F4CP_releasefrom
F4CP_debug

Conversation

@UF4OVER

@UF4OVER UF4OVER commented Jun 7, 2026

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings June 7, 2026 10:14
@UF4OVER
UF4OVER merged commit 083d49e into F4CP_release Jun 7, 2026
1 of 2 checks passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

该 PR 将项目版本更新到 0.5.5.rc1,同步升级运行环境到 Python 3.11,并新增「版本」页面用于展示软件提交历史与管理远程固件历史/详情/下载;同时对日志体系、固件管理与电源协议常量进行了重构,以提升可维护性与一致性。

Changes:

  • 版本与环境升级:更新 pyproject.toml / Resources/Config/config.json / README.md,并将入口标注升级到 Python 3.11
  • 新增 VersionPage:集成软件提交历史(本地 git log + GitHub commits API)与远程固件历史/详情/下载
  • 基础设施调整:引入 get_logger() 子 logger 模式、固件历史/详情缓存、抽离电源协议常量到 app/core/const.py,并更新 Windows 构建工作流为 x86

Reviewed changes

Copilot reviewed 33 out of 35 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
start.py 更新 Python 版本标注并切换到新的 logger 获取方式
script/sim_power_device.py 将脚本输出从 print 迁移到 logging,并统一日志格式
Resources/Theme/qss/light/VersionPage.qss 新增 VersionPage 浅色主题样式
Resources/Theme/qss/dark/VersionPage.qss 新增 VersionPage 深色主题样式
Resources/Config/config.json 版本号与默认主题/高 DPI 等配置更新
README.md 更新页面说明与环境要求(Python >= 3.11)
pyproject.toml 更新项目版本与依赖约束(含 capstone 约束)
docs/AGENTS.md 更新项目结构与开发命令说明,补充 Version 子系统描述
config/config.py 调整目录解析与日志初始化;新增 get_logger()
config/init.py 导出 get_logger 以供各模块使用
app/window/navigation.py 将 VersionPage 加入导航与页面创建流程
app/window/main_window.py 调整 DynamicIsland 初始化与启动流程
app/widgets/pages/page_version.py 新增版本与固件管理页面实现
app/widgets/pages/page_power.py PowerPage 日志迁移到 logger;移除页面自写日志文件逻辑等
app/widgets/pages/page_home.py 轻微格式调整(空行)
app/widgets/pages/page_device.py DevicePage 与 BluetoothSession 日志切换到 get_logger()
app/widgets/pages/page_daplink.py DaplinkPage 日志切换到 get_logger() 并简化日志前缀
app/widgets/pages/init.py 导出新增的 page_version
app/widgets/components/splashscreen/splashscreen.py 清理未使用的标题栏相关代码/导入
app/widgets/chart/realtime_chart_widget.py RealtimeChartWidget 日志切换到 get_logger()
app/session/session_serial.py SerialSession 日志切换到 get_logger() 并简化部分日志内容
app/session/session_power.py 电源协议常量/类型迁移到 app.core.const;增强部分错误日志
app/session/session_daplink.py DAPLink 会话日志切换到 get_logger();调整下载地址解析参数传递
app/session/session_bluetooth.py 蓝牙会话日志切换到 get_logger()
app/protocol/payLoad.py 轻微格式调整(空行)
app/manager/manager_update.py 更新检查请求统一走 build_request();切换到 get_logger()
app/manager/manager_stylesheet.py 在 StyleSheet 枚举中注册 VERSION_PAGE
app/manager/manager_font.py 字体管理切换到 get_logger() 并调整导入
app/manager/manager_firmware.py 增加固件历史/详情线程与缓存管理;下载支持指定 release
app/core/update_request.py 新增网络请求构建辅助函数 build_request()
app/core/const.py 新增电源协议常量与部分 DAPLink 常量集中定义
app/controllers/controller_power_page.py 注释 mockButton 的控制器绑定(与页面改动保持一致)
.gitignore 忽略 Resources/Cache/ 缓存目录
.github/workflows/buildEXE.yml Windows 构建改为 x86 Python,并更新产物命名与 UPX 版本

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

self._appendLog(self._diagnoseDebugSnapshot(snapshot))

def _diagnoseDebugSnapshot(self, snapshot: DebugSnapshot) -> str:
@ staticmethod
file_path = str(Path(payload.file_path or "").resolve())
file_ext = Path(file_path).suffix.lower().lstrip(".")
base_address = self._resolve_download_address(payload.base_address, f".{file_ext}", target_info)
base_address = self._resolve_download_address(payload.base_address, file_ext, target_info)
Comment thread app/window/main_window.py
Comment on lines 46 to +47
def showDynamicIsland(self, title: str, content: str = "", level: str = "info", duration: int = 3200):
if hasattr(self, "dynamicIsland"):
self.dynamicIsland.notify(title, content, level, duration)
self.dynamicIsland.notify(title, content, level, duration)
Comment on lines 432 to +433
except Exception:
pass
logger.error(f"Failed to detach serial session on {self._session.cfg.port}")
Comment thread config/config.py
Comment on lines 34 to 38
def _detect_base_dir() -> Path:
"""Return the project root, respecting frozen (cx_Freeze) layouts."""
"""Return the project root, respecting frozen (cx_Freeze) layouts返回项目根,但要遵守冻结(cx_Freeze)布局."""
if getattr(sys, "frozen", False):
return Path(sys.executable).resolve().parent
return Path(__file__).resolve().parent.parent
Comment thread config/config.py
Comment on lines 14 to +18
import logging
import os
import shutil
import sys
from datetime import datetime
import time
Comment on lines +22 to +23
from qfluentwidgets import FluentIcon as FIF
from qfluentwidgets import qconfig, QConfig, ConfigItem, OptionsConfigItem, OptionsValidator, BoolValidator
Comment on lines 298 to 300
except Exception as exc:
logger.error(f"{self.__class__.__name__}: {e}")
logger.error(f"{e}")
pass
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants