diff --git a/CHANGELOG.md b/CHANGELOG.md index 8098ba5..e627ea5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,44 @@ All notable changes to ModbusSim are documented in this file. --- +## [0.17.2] - 2026-08-14 + +补丁版本:恢复 ModbusMaster 正常启动,并交付完整的从站点位工作流、SOCKS5 代理、静默后台更新和自动发布链路。无破坏性变更,现有 v1 工程文件继续兼容。 + +Patch release: restores ModbusMaster startup and delivers complete slave point workflows, SOCKS5 proxying, silent background updates, and automated releases. There are no breaking changes; existing v1 project files remain compatible. + +### Highlights / 亮点 + +- 🚑 **ModbusMaster 恢复启动** — 修复 Aptabase 初始化时缺少 Tokio runtime 导致所有安装包打开即退出的问题。/ **ModbusMaster starts normally again** — fixes the missing Tokio runtime during Aptabase initialization that caused packaged Master apps to exit immediately. +- 🎛️ **完整点位工作流** — 从站支持独立周期的点位变异、数据源、宽值地址冲突校验、站号/名称编辑以及工程保存恢复。/ **Complete point workflows** — slave points gain independent mutation schedules, data sources, wide-value overlap validation, editable unit metadata, and project save/restore. +- 🌐 **SOCKS5 代理** — Master 的 TCP、TCP+TLS、RTU-over-TCP 支持 IPv4/IPv6、代理侧域名解析和可选用户名/密码认证。/ **SOCKS5 proxying** — Master TCP, TCP+TLS, and RTU-over-TCP support IPv4/IPv6, proxy-side DNS, and optional username/password authentication. +- 🔄 **静默更新与自动发布** — 更新包先在后台下载并验签,准备完成后再提示立即安装、跳过该版本或下次启动安装;发布矩阵覆盖两款应用的 10 个平台构建任务。/ **Silent updates and automated releases** — updates download and verify before prompting to install now, skip the version, or install on next launch; the release matrix covers 10 platform builds across both apps. + +### Added 新增 + +- **从站点位变异与数据源** — 每个点位可配置固定值、随机、正弦、斜坡与 CSV 数据源;单一 100 ms 后端 tick 按各点位周期独立调度,配置随工程持久化。/ **Slave point mutation and data sources** — each point can use fixed, random, sine, ramp, or CSV data; one 100 ms backend tick honors independent point schedules and persists configuration with the project. +- **SOCKS5 CONNECT** — 新增三类 Master 网络传输的代理连接与工程保存恢复;密码不会出现在 Rust Debug 输出中,界面明确提示 RFC 1929 凭据与工程文件的安全边界。/ **SOCKS5 CONNECT** — adds proxy connections and project persistence to three Master transports; passwords are redacted from Rust debug output, and the UI explains the RFC 1929 and project-file security boundary. + +### Changed 改进 + +- **应用内更新流程** — Slave 与 Master 共用“后台下载并验签 → 再提示”的状态机,替代等待用户确认后才开始下载的流程。/ **In-app updater flow** — Slave and Master now share a download-and-verify-before-prompt state machine instead of waiting for confirmation before downloading. +- **工程恢复完整性** — Master 扫描组、寄存器定义和值,以及 Slave 变异和点位数据源均可完整保存并恢复运行时状态。/ **Project restoration completeness** — Master scan groups, register definitions and values, plus Slave mutations and point data sources now save and restore their runtime state. +- **自动发布链路** — 夜间任务准备补丁版本,发布 PR 合并且 Test 通过后自动打 tag,再构建 macOS Apple Silicon/Intel、Linux x64、Windows x64/ARM64 产物和独立更新清单。/ **Automated release pipeline** — nightly automation prepares patch releases; a merged release PR that passes Test is tagged and built for macOS Apple Silicon/Intel, Linux x64, and Windows x64/ARM64 with separate updater manifests. + +### Fixed 修复 + +- **Master 启动闪退** — 在构建 Tauri 与 Aptabase 插件前创建并进入多线程 Tokio runtime,消除 `there is no reactor running` panic。/ **Master startup crash** — creates and enters a multi-threaded Tokio runtime before Tauri and Aptabase initialization, eliminating the `there is no reactor running` panic. +- **协议与扫描健壮性** — 加强非法 Modbus PDU、未定义地址、重连和扫描取消处理,避免错误响应、残留任务或扫描状态卡住。/ **Protocol and scanner hardening** — strengthens invalid Modbus PDU, undefined-address, reconnect, and scan-cancellation handling to prevent incorrect responses, orphaned tasks, and stuck scans. +- **寄存器与工程一致性** — 后端拒绝重复或重叠的宽值寄存器范围,寄存器编辑改为原子操作,并修复从站工程保存/加载和旧 32 位寄存器块迁移。/ **Register and project consistency** — rejects duplicate or overlapping wide-register ranges, makes register edits atomic, and fixes slave project save/load plus legacy 32-bit register-block migration. + +### Security 安全 + +- 将 Vite/PostCSS 间接依赖 `nanoid` 从 3.3.17 升级到 3.3.18,修复零长度自定义生成器可能无限循环的高危拒绝服务问题(GHSA-2v37-7h3g-55p8)。/ Upgraded the Vite/PostCSS transitive dependency `nanoid` from 3.3.17 to 3.3.18, fixing the high-severity denial-of-service issue where a zero-sized custom generator could loop indefinitely (GHSA-2v37-7h3g-55p8). + +### Internal 内部 + +- 发布前门禁通过 290 个 Rust 测试、16 个共享前端测试与 20 个发布脚本测试,并覆盖 Rust 格式化、Clippy、两端生产构建、npm audit、Release 元数据与产物校验。/ Release gates passed 290 Rust tests, 16 shared frontend tests, and 20 release-script tests, plus Rust formatting, Clippy, both production builds, npm audit, release metadata, and artifact validation. + ## [0.17.1] - 2026-06-12 维护版本:发布流水线修复 + OpenSpec 规格归档。**无应用代码改动**,安装包与 v0.17.0 功能一致。 diff --git a/crates/modbusmaster-app/Cargo.toml b/crates/modbusmaster-app/Cargo.toml index 71d3a2b..580aee3 100644 --- a/crates/modbusmaster-app/Cargo.toml +++ b/crates/modbusmaster-app/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "modbusmaster-app" -version = "0.17.1" +version = "0.17.2" description = "ModbusMaster - Cross-platform Modbus TCP Master" edition = "2021" rust-version = "1.77.2" diff --git a/crates/modbusmaster-app/src/lib.rs b/crates/modbusmaster-app/src/lib.rs index 0ce4a6a..d98c26e 100644 --- a/crates/modbusmaster-app/src/lib.rs +++ b/crates/modbusmaster-app/src/lib.rs @@ -7,6 +7,11 @@ use state::AppState; #[cfg_attr(mobile, tauri::mobile_entry_point)] pub fn run() { + // tauri-plugin-aptabase starts a background task with tokio::spawn during + // plugin initialization, so enter a Tokio runtime before building Tauri. + let rt = tokio::runtime::Runtime::new().expect("failed to create Tokio runtime"); + let _guard = rt.enter(); + tauri::Builder::default() .plugin(tauri_plugin_updater::Builder::new().build()) .plugin(tauri_plugin_process::init()) diff --git a/crates/modbusmaster-app/tauri.conf.json b/crates/modbusmaster-app/tauri.conf.json index a0e5fdb..980d23a 100644 --- a/crates/modbusmaster-app/tauri.conf.json +++ b/crates/modbusmaster-app/tauri.conf.json @@ -1,7 +1,7 @@ { "$schema": "https://schema.tauri.app/config/2", "productName": "ModbusMaster", - "version": "0.17.1", + "version": "0.17.2", "identifier": "com.modbusmaster.dev", "build": { "devUrl": "http://localhost:5174", diff --git a/crates/modbussim-app/Cargo.toml b/crates/modbussim-app/Cargo.toml index 684932d..100e491 100644 --- a/crates/modbussim-app/Cargo.toml +++ b/crates/modbussim-app/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "modbussim-app" -version = "0.17.1" +version = "0.17.2" description = "ModbusSim - Cross-platform Modbus Simulator" edition = "2021" rust-version = "1.77.2" diff --git a/crates/modbussim-app/tauri.conf.json b/crates/modbussim-app/tauri.conf.json index aacc7a8..7371554 100644 --- a/crates/modbussim-app/tauri.conf.json +++ b/crates/modbussim-app/tauri.conf.json @@ -1,7 +1,7 @@ { "$schema": "https://schema.tauri.app/config/2", "productName": "ModbusSlave", - "version": "0.17.1", + "version": "0.17.2", "identifier": "com.modbusslave.dev", "build": { "devUrl": "http://localhost:5175", diff --git a/package-lock.json b/package-lock.json index 02301d9..c1bce4c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2093,9 +2093,9 @@ } }, "node_modules/nanoid": { - "version": "3.3.17", - "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.17.tgz", - "integrity": "sha512-xQLf0A3HOMlgHq0n247/LRuAOYmB7dXJ/DvAxGvsSBij45XtBSmQycu+F8ODbHwns/XyFZagyL1+J0Offw1E0g==", + "version": "3.3.18", + "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.18.tgz", + "integrity": "sha512-DTg4MJbGMWkfi6VZFdNt2/caMbQy4Ou+Op/hJQvGEWcnVfoA1QA+xzRKAzw9jD6+GVOOeYr/mIcuDSdug6F6+w==", "funding": [ { "type": "github",