diff --git a/XPostArchiver-clean-upload-20260711-225630/.cargo/config.toml b/XPostArchiver-clean-upload-20260711-225630/.cargo/config.toml new file mode 100644 index 0000000000000000000000000000000000000000..37b0006a29ab77e7f6d86a935edac9ec72fc572b --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/.cargo/config.toml @@ -0,0 +1,9 @@ +[source.crates-io] +replace-with = "rsproxy-sparse" + +[source.rsproxy-sparse] +registry = "sparse+https://rsproxy.cn/index/" + +[net] +git-fetch-with-cli = true + diff --git a/XPostArchiver-clean-upload-20260711-225630/.gitignore b/XPostArchiver-clean-upload-20260711-225630/.gitignore new file mode 100644 index 0000000000000000000000000000000000000000..4a30254ee5a7911b3a464eea39c43b34c59cbedc --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/.gitignore @@ -0,0 +1,23 @@ +/target/ +/build/ +/dist/ +/backups/ + +*.db +*.sqlite +*.sqlite3 +*.db-wal +*.db-shm + +*.log +*.tmp +*.part + +.env +.env.* +secrets.* +credentials.* + +.DS_Store +Thumbs.db + diff --git a/XPostArchiver-clean-upload-20260711-225630/CHANGELOG.md b/XPostArchiver-clean-upload-20260711-225630/CHANGELOG.md new file mode 100644 index 0000000000000000000000000000000000000000..4acc8939923cafceb61a2b6489cb8da297ad710a --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/CHANGELOG.md @@ -0,0 +1,56 @@ +# 变更记录 + +## [未发布] + +### 新增 + +- 初始化 Rust + Slint + Cargo 项目。 +- 配置 RsProxy Cargo 镜像。 +- 添加最小 Slint 中文窗口。 +- 添加 Tokio 后台运行时骨架。 +- 添加统一错误类型和脱敏日志骨架。 +- 添加 SQLx 初始迁移草案。 +- 添加数据库新建/打开服务与非敏感设置保存。 +- 添加媒体、导出、日志、备份和临时下载目录选择与保存。 +- 添加数据库和数据目录位于系统盘时的非阻断提醒。 +- 添加数据库完整性检查和手动备份入口。 +- 将主界面整理为数据库、归档内容、准备采集三步配置流程。 +- 添加保存媒体文件/只保存文本选项,并兼容旧配置文件。 +- 添加 X API Bearer Token 的系统密钥库保存、状态显示和清除入口。 +- 添加 X API Bearer Token 联网校验与 mock 测试。 +- 添加公开账号查询入口,并将账号基础信息保存到数据库。 +- 添加采集任务创建入口,并将任务记录写入数据库。 +- 添加一页公开帖子拉取入口,基于任务 ID 调用官方 X API 拉取少量公开帖子。 +- 将公开帖子基础字段保存/更新到 posts 表,并更新采集任务计数。 +- 添加分页游标保存和断点续采骨架,下一页拉取会从 crawl_checkpoints 继续。 +- 添加 X API 媒体元数据解析,并保存 media 与 post_media 关联。 +- 添加媒体文件下载骨架,将待保存媒体下载到归档内容目录并更新下载状态。 +- 添加自动连续采集 3 页骨架,并在每页之间保守等待。 +- 将自动连续采集改为后台线程执行,避免采集期间阻塞主界面。 +- 添加自动连续采集页数上限与每页等待秒数输入;页数上限为 0 时持续采集到末页或手动停止。 +- 添加自动采集停止入口,并在停止后将任务状态写回数据库。 +- 添加最近采集任务列表查询与刷新入口。 +- 为主窗口添加最小尺寸约束,改善自由缩放体验。 +- 创建任务或刷新任务列表后自动填入最新任务 ID。 +- 将 Bearer Token 输入框改为密码遮罩输入。 +- 将采集任务状态在界面中显示为中文,并显示失败原因。 +- X API 拉取失败时写回任务失败状态、错误次数和错误信息。 +- 添加按任务 ID 预览已保存帖子的入口。 +- 添加将任务帖子导出为 Markdown 文本索引的入口。 +- 添加失败媒体重试下载入口。 +- 自动采集运行中阻止重复启动第二个自动采集任务。 +- 添加后期优化路线文档。 +- 添加维护接手文档,方便后续 AI 或开发者阅读维护。 +- 为主界面添加滚动区域,避免功能区超出窗口后无法访问。 +- 添加数据库迁移集成测试。 +- 通过 `cargo fmt --all -- --check`、`cargo check`、`cargo clippy --all-targets --all-features -- -D warnings` 和 `cargo test --all`。 +- 实际运行 `cargo run` 并启动最小 Slint 窗口。 +- 将项目文档从旧技术路线修订为 Rust 技术路线。 + +### 环境 + +- Rust:1.97.0 +- Cargo:1.97.0 +- MSVC Build Tools:Visual Studio Build Tools 2022,17.14.35 +- Windows SDK:10.0.26100.0 + diff --git a/XPostArchiver-clean-upload-20260711-225630/Cargo.lock b/XPostArchiver-clean-upload-20260711-225630/Cargo.lock new file mode 100644 index 0000000000000000000000000000000000000000..02c564998c335a53443f305a78baf282bcecd504 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/Cargo.lock @@ -0,0 +1,7825 @@ +# This file is automatically @generated by Cargo. +# It is not intended for manual editing. +version = 4 + +[[package]] +name = "ab_glyph" +version = "0.2.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "01c0457472c38ea5bd1c3b5ada5e368271cb550be7a4ca4a0b4634e9913f6cc2" +dependencies = [ + "ab_glyph_rasterizer", + "owned_ttf_parser", +] + +[[package]] +name = "ab_glyph_rasterizer" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "366ffbaa4442f4684d91e2cd7c5ea7c4ed8add41959a31447066e279e432b618" + +[[package]] +name = "accesskit" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3b7f7f85a7e5f68090000ed7622545829afd484d210358702ae4cb97dd0c320" +dependencies = [ + "uuid", +] + +[[package]] +name = "accesskit_atspi_common" +version = "0.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e98018dbef3583d751dbb96e07b8728fb99581360e1c3df408af16f4a80b821" +dependencies = [ + "accesskit", + "accesskit_consumer", + "atspi-common", + "phf", + "serde", + "zvariant", +] + +[[package]] +name = "accesskit_consumer" +version = "0.37.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f950720ce064757a1b629caad3a408e8d2c63bb01f29b8a3ff8daa331053ffeb" +dependencies = [ + "accesskit", + "hashbrown 0.16.1", +] + +[[package]] +name = "accesskit_ios" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02ecb52198c7cf5f8d3e9ffc03d2ca0a5c7201926befd96721437829da4c5c6a" +dependencies = [ + "accesskit", + "accesskit_consumer", + "hashbrown 0.16.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", + "objc2-ui-kit 0.2.2", +] + +[[package]] +name = "accesskit_macos" +version = "0.26.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "17cb8b66cef272d48161b02a6317cc2bdd5f98bb0a5e79c68f704a5862aa396b" +dependencies = [ + "accesskit", + "accesskit_consumer", + "hashbrown 0.16.1", + "objc2 0.5.2", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "accesskit_unix" +version = "0.22.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5376ba4cc23312587634abb5250b1ce8618f01a55915608209aafd01efb4bf8c" +dependencies = [ + "accesskit", + "accesskit_atspi_common", + "async-channel", + "async-executor", + "async-task", + "atspi", + "futures-lite", + "futures-util", + "serde", + "zbus", +] + +[[package]] +name = "accesskit_windows" +version = "0.33.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36e93ac7bf50b964f1cbb75f741629a4e950571baa1ef1274457ab5a80d9bcc2" +dependencies = [ + "accesskit", + "accesskit_consumer", + "hashbrown 0.16.1", + "static_assertions", + "windows", + "windows-core", +] + +[[package]] +name = "accesskit_winit" +version = "0.33.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41fe5862066316f6caaf02cd3aecd54bced25503ac5dbbfd0d03a42bc1246217" +dependencies = [ + "accesskit", + "accesskit_ios", + "accesskit_macos", + "accesskit_unix", + "accesskit_windows", + "raw-window-handle", + "winit", +] + +[[package]] +name = "adler2" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" + +[[package]] +name = "ahash" +version = "0.8.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a15f179cd60c4584b8a8c596927aadc462e27f2ca70c04e0071964a73ba7a75" +dependencies = [ + "cfg-if", + "getrandom 0.3.4", + "once_cell", + "version_check", + "zerocopy", +] + +[[package]] +name = "aho-corasick" +version = "1.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301" +dependencies = [ + "memchr", +] + +[[package]] +name = "aligned" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee4508988c62edf04abd8d92897fca0c2995d907ce1dfeaf369dac3716a40685" +dependencies = [ + "as-slice", +] + +[[package]] +name = "aligned-vec" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc890384c8602f339876ded803c97ad529f3842aba97f6392b3dba0dd171769b" +dependencies = [ + "equator", +] + +[[package]] +name = "allocator-api2" +version = "0.2.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" + +[[package]] +name = "android-activity" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f2a1bb052857d5dd49572219344a7332b31b76405648eabac5bc68978251bcd" +dependencies = [ + "android-properties", + "bitflags 2.13.0", + "cc", + "jni", + "libc", + "log", + "ndk", + "ndk-context", + "ndk-sys", + "num_enum", + "thiserror 2.0.18", +] + +[[package]] +name = "android-properties" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc7eb209b1518d6bb87b283c20095f5228ecda460da70b44f0802523dea6da04" + +[[package]] +name = "android_system_properties" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "819e7219dbd41043ac279b19830f2efc897156490d7fd6ea916720117ee66311" +dependencies = [ + "libc", +] + +[[package]] +name = "annotate-snippets" +version = "0.12.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f211a51805bc641f3ad5b7664c77d2547af685cc33b4cd8d31964027a46f13f1" +dependencies = [ + "anstyle", + "memchr", + "unicode-width", +] + +[[package]] +name = "anstyle" +version = "1.0.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "940b3a0ca603d1eade50a4846a2afffd5ef57a9feac2c0e2ec2e14f9ead76000" + +[[package]] +name = "anyhow" +version = "1.0.103" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a4385e2e34eb35d6b3efe798b9eb88096925d87726c0798709bf56d9ed84af3" + +[[package]] +name = "arbitrary" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3d036a3c4ab069c7b410a2ce876bd74808d2d0888a82667669f8e783a898bf1" +dependencies = [ + "derive_arbitrary", +] + +[[package]] +name = "arg_enum_proc_macro" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ae92a5119aa49cdbcf6b9f893fe4e1d98b04ccbf82ee0584ad948a44a734dea" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "arrayref" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76a2e8124351fda1ef8aaaa3bbd7ebbcb486bbcd4225aca0aa0d84bb2db8fecb" + +[[package]] +name = "arrayvec" +version = "0.7.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3fb67a6e08acf24fdeccbac2cb6ac4305825bd1f117462e0e6f2f193345ad56" + +[[package]] +name = "as-raw-xcb-connection" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "175571dd1d178ced59193a6fc02dde1b972eb0bc56c892cde9beeceac5bf0f6b" + +[[package]] +name = "as-slice" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "516b6b4f0e40d50dcda9365d53964ec74560ad4284da2e7fc97122cd83174516" +dependencies = [ + "stable_deref_trait", +] + +[[package]] +name = "ashpd" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2f3f79755c74fd155000314eb349864caa787c6592eace6c6882dad873d9c39" +dependencies = [ + "async-fs", + "async-net", + "enumflags2", + "futures-channel", + "futures-util", + "rand 0.9.4", + "raw-window-handle", + "serde", + "serde_repr", + "url", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "zbus", +] + +[[package]] +name = "assert-json-diff" +version = "2.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47e4f2b81832e72834d7518d8487a0396a28cc408186a2e8854c0f98011faf12" +dependencies = [ + "serde", + "serde_json", +] + +[[package]] +name = "async-broadcast" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "435a87a52755b8f27fcf321ac4f04b2802e337c8c4872923137471ec39c37532" +dependencies = [ + "event-listener", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-channel" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "924ed96dd52d1b75e9c1a3e6275715fd320f5f9439fb5a4a11fa51f4221158d2" +dependencies = [ + "concurrent-queue", + "event-listener-strategy", + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "async-executor" +version = "1.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c96bf972d85afc50bf5ab8fe2d54d1586b4e0b46c97c50a0c9e71e2f7bcd812a" +dependencies = [ + "async-task", + "concurrent-queue", + "fastrand", + "futures-lite", + "pin-project-lite", + "slab", +] + +[[package]] +name = "async-fs" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8034a681df4aed8b8edbd7fbe472401ecf009251c8b40556b304567052e294c5" +dependencies = [ + "async-lock", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-io" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "456b8a8feb6f42d237746d4b3e9a178494627745c3c56c6ea55d92ba50d026fc" +dependencies = [ + "autocfg", + "cfg-if", + "concurrent-queue", + "futures-io", + "futures-lite", + "parking", + "polling", + "rustix 1.1.4", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-lock" +version = "3.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "290f7f2596bd5b78a9fec8088ccd89180d7f9f55b94b0576823bbbdc72ee8311" +dependencies = [ + "event-listener", + "event-listener-strategy", + "pin-project-lite", +] + +[[package]] +name = "async-net" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b948000fad4873c1c9339d60f2623323a0cfd3816e5181033c6a5cb68b2accf7" +dependencies = [ + "async-io", + "blocking", + "futures-lite", +] + +[[package]] +name = "async-process" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc50921ec0055cdd8a16de48773bfeec5c972598674347252c0399676be7da75" +dependencies = [ + "async-channel", + "async-io", + "async-lock", + "async-signal", + "async-task", + "blocking", + "cfg-if", + "event-listener", + "futures-lite", + "rustix 1.1.4", +] + +[[package]] +name = "async-recursion" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b43422f69d8ff38f95f1b2bb76517c91589a924d1559a0e935d7c8ce0274c11" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "async-signal" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52b5aaafa020cf5053a01f2a60e8ff5dccf550f0f77ec54a4e47285ac2bab485" +dependencies = [ + "async-io", + "async-lock", + "atomic-waker", + "cfg-if", + "futures-core", + "futures-io", + "rustix 1.1.4", + "signal-hook-registry", + "slab", + "windows-sys 0.61.2", +] + +[[package]] +name = "async-task" +version = "4.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b75356056920673b02621b35afd0f7dda9306d03c79a30f5c56c44cf256e3de" + +[[package]] +name = "async-trait" +version = "0.1.89" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9035ad2d096bed7955a320ee7e2230574d28fd3c3a0f186cbea1ff3c7eed5dbb" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "atoi" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f28d99ec8bfea296261ca1af174f24225171fea9664ba9003cbebee704810528" +dependencies = [ + "num-traits", +] + +[[package]] +name = "atomic-waker" +version = "1.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" + +[[package]] +name = "atspi" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c77886257be21c9cd89a4ae7e64860c6f0eefca799bb79127913052bd0eefb3d" +dependencies = [ + "atspi-common", + "atspi-proxies", +] + +[[package]] +name = "atspi-common" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20c5617155740c98003016429ad13fe43ce7a77b007479350a9f8bf95a29f63d" +dependencies = [ + "enumflags2", + "serde", + "static_assertions", + "zbus", + "zbus-lockstep", + "zbus-lockstep-macros", + "zbus_names", + "zvariant", +] + +[[package]] +name = "atspi-proxies" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2230e48787ed3eb4088996eab66a32ca20c0b67bbd4fd6cdfe79f04f1f04c9fc" +dependencies = [ + "atspi-common", + "serde", + "zbus", +] + +[[package]] +name = "auto_enums" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e4487600931c9a89f8db7ffbdf3fbdd45bb7bd85e26861f659a463cd0dff966" +dependencies = [ + "derive_utils", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "autocfg" +version = "1.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2032f911046de80f0a198e0901378627c33f59ea0ac00e363d481118bd70a53" + +[[package]] +name = "av-scenechange" +version = "0.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f321d77c20e19b92c39e7471cf986812cbb46659d2af674adc4331ef3f18394" +dependencies = [ + "aligned", + "anyhow", + "arg_enum_proc_macro", + "arrayvec", + "log", + "num-rational", + "num-traits", + "pastey 0.1.1", + "rayon", + "thiserror 2.0.18", + "v_frame", + "y4m", +] + +[[package]] +name = "av1-grain" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8cfddb07216410377231960af4fcab838eaa12e013417781b78bd95ee22077f8" +dependencies = [ + "anyhow", + "arrayvec", + "log", + "nom 8.0.0", + "num-rational", + "v_frame", +] + +[[package]] +name = "avif-serialize" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7178fe5f7d460b13895ebb9dcb28a3a6216d2df2574a0806cb51b555d297f38" +dependencies = [ + "arrayvec", +] + +[[package]] +name = "base64" +version = "0.22.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" + +[[package]] +name = "base64ct" +version = "1.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2af50177e190e07a26ab74f8b1efbfe2ef87da2116221318cb1c2e82baf7de06" + +[[package]] +name = "bincode" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36eaf5d7b090263e8150820482d5d93cd964a81e4019913c972f4edcc6edb740" +dependencies = [ + "serde", + "unty", +] + +[[package]] +name = "bindgen" +version = "0.72.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "993776b509cfb49c750f11b8f07a46fa23e0a1386ffc01fb1e7d343efc387895" +dependencies = [ + "bitflags 2.13.0", + "cexpr", + "clang-sys", + "itertools 0.13.0", + "log", + "prettyplease", + "proc-macro2", + "quote", + "regex", + "rustc-hash 2.1.3", + "shlex 1.3.0", + "syn", +] + +[[package]] +name = "bit_field" +version = "0.10.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e4b40c7323adcfc0a41c4b88143ed58346ff65a288fc144329c5c45e05d70c6" + +[[package]] +name = "bitflags" +version = "1.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" + +[[package]] +name = "bitflags" +version = "2.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4388bee8683e3d04af747c73422af53102d2bd24d9eadb6cbc100baef4b43f8" +dependencies = [ + "serde_core", +] + +[[package]] +name = "bitstream-io" +version = "4.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7eff00be299a18769011411c9def0d827e8f2d7bf0c3dbf53633147a8867fd1f" +dependencies = [ + "no_std_io2", +] + +[[package]] +name = "block-buffer" +version = "0.10.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" +dependencies = [ + "generic-array", +] + +[[package]] +name = "block2" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c132eebf10f5cad5289222520a4a058514204aed6d791f1cf4fe8088b82d15f" +dependencies = [ + "objc2 0.5.2", +] + +[[package]] +name = "block2" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdeb9d870516001442e364c5220d3574d2da8dc765554b4a617230d33fa58ef5" +dependencies = [ + "objc2 0.6.4", +] + +[[package]] +name = "blocking" +version = "1.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e83f8d02be6967315521be875afa792a316e28d57b5a2d401897e2a7921b7f21" +dependencies = [ + "async-channel", + "async-task", + "futures-io", + "futures-lite", + "piper", +] + +[[package]] +name = "borsh" +version = "1.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f3f6da4992df95bbcd9af42a6c7dcb994498fc9048230405f3b36ff7cd3f145" +dependencies = [ + "bytes", + "cfg_aliases", +] + +[[package]] +name = "built" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c0e531d93d39c34eef561e929e8a7f86d77a5af08aac4f6d6e39976c51858e9" + +[[package]] +name = "bumpalo" +version = "3.20.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649" + +[[package]] +name = "by_address" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "64fa3c856b712db6612c019f14756e64e4bcea13337a6b33b696333a9eaa2d06" + +[[package]] +name = "bytemuck" +version = "1.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6aedf8ae72766347502cf3cb4f41cf5e9cc37d28bee90f1fdaaae15f9cf9424" +dependencies = [ + "bytemuck_derive", +] + +[[package]] +name = "bytemuck_derive" +version = "1.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f65693059b6b9c588b9f62fed1cedbf0a8b805631457ea162d68f0de186f3de5" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "byteorder" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "byteorder-lite" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495" + +[[package]] +name = "bytes" +version = "1.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04" + +[[package]] +name = "calloop" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b99da2f8558ca23c71f4fd15dc57c906239752dd27ff3c00a1d56b685b7cbfec" +dependencies = [ + "bitflags 2.13.0", + "log", + "polling", + "rustix 0.38.44", + "slab", + "thiserror 1.0.69", +] + +[[package]] +name = "calloop" +version = "0.14.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4dbf9978365bac10f54d1d4b04f7ce4427e51f71d61f2fe15e3fed5166474df7" +dependencies = [ + "bitflags 2.13.0", + "polling", + "rustix 1.1.4", + "slab", + "tracing", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95a66a987056935f7efce4ab5668920b5d0dac4a7c99991a67395f13702ddd20" +dependencies = [ + "calloop 0.13.0", + "rustix 0.38.44", + "wayland-backend", + "wayland-client", +] + +[[package]] +name = "calloop-wayland-source" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "138efcf0940a02ebf0cc8d1eff41a1682a46b431630f4c52450d6265876021fa" +dependencies = [ + "calloop 0.14.4", + "rustix 1.1.4", + "wayland-backend", + "wayland-client", +] + +[[package]] +name = "cc" +version = "1.2.66" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f5d6cac793997bd970000024b2934968efe83b382de4fdcf4fcb46b6ee4ad996" +dependencies = [ + "find-msvc-tools", + "jobserver", + "libc", + "shlex 2.0.1", +] + +[[package]] +name = "cexpr" +version = "0.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6fac387a98bb7c37292057cffc56d62ecb629900026402633ae9160df93a8766" +dependencies = [ + "nom 7.1.3", +] + +[[package]] +name = "cfg-if" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801" + +[[package]] +name = "cfg_aliases" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" + +[[package]] +name = "cgl" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ced0551234e87afee12411d535648dd89d2e7f34c78b753395567aff3d447ff" +dependencies = [ + "libc", +] + +[[package]] +name = "chacha20" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d524456ba66e72eb8b115ff89e01e497f8e6d11d78b70b1aa13c0fbd97540a81" +dependencies = [ + "cfg-if", + "cpufeatures 0.3.0", + "rand_core 0.10.1", +] + +[[package]] +name = "chrono" +version = "0.4.45" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1aa79e62e7697b8e29b513a68abacf485adcd1fe8284a4316c5ae868e6633327" +dependencies = [ + "iana-time-zone", + "js-sys", + "num-traits", + "serde", + "wasm-bindgen", + "windows-link", +] + +[[package]] +name = "clang-sys" +version = "1.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b023947811758c97c59bf9d1c188fd619ad4718dcaa767947df1cadb14f39f4" +dependencies = [ + "glob", + "libc", + "libloading", +] + +[[package]] +name = "clipboard-win" +version = "5.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bde03770d3df201d4fb868f2c9c59e66a3e4e2bd06692a0fe701e7103c7e84d4" +dependencies = [ + "error-code", +] + +[[package]] +name = "clru" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "197fd99cb113a8d5d9b6376f3aa817f32c1078f2343b714fff7d2ca44fdf67d5" +dependencies = [ + "hashbrown 0.16.1", +] + +[[package]] +name = "color_quant" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b" + +[[package]] +name = "combine" +version = "4.6.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba5a308b75df32fe02788e748662718f03fde005016435c444eea572398219fd" +dependencies = [ + "bytes", + "memchr", +] + +[[package]] +name = "concurrent-queue" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ca0197aee26d1ae37445ee532fefce43251d24cc7c166799f4d46817f1d3973" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "const-field-offset" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9713489fbc45a2d113f58d17448c73115d533ed27fd2f2d0e5e5c69663eaf19b" +dependencies = [ + "const-field-offset-macro", + "field-offset", +] + +[[package]] +name = "const-field-offset-macro" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b5dc851b7ea80cc4f69aa28632385ffd3e0f88014d53db3f2e5a781896ca783" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "const-oid" +version = "0.9.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" + +[[package]] +name = "convert_case" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "633458d4ef8c78b72454de2d54fd6ab2e60f9e02be22f3c6104cdc8a4e0fceb9" +dependencies = [ + "unicode-segmentation", +] + +[[package]] +name = "copypasta" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e6811e17f81fe246ef2bc553f76b6ee6ab41a694845df1d37e52a92b7bbd38a" +dependencies = [ + "clipboard-win", + "objc2 0.5.2", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", + "smithay-clipboard", + "x11-clipboard", +] + +[[package]] +name = "core-foundation" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91e195e091a93c46f7102ec7818a2aa394e1e1771c3ab4825963fa03e45afb8f" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2a6cd9ae233e7f62ba4e9353e81a88df7fc8a5987b8d445b4d90c879bd156f6" +dependencies = [ + "core-foundation-sys", + "libc", +] + +[[package]] +name = "core-foundation-sys" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" + +[[package]] +name = "core-graphics" +version = "0.23.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c07782be35f9e1140080c6b96f0d44b739e2278479f64e02fdab4e32dfd8b081" +dependencies = [ + "bitflags 1.3.2", + "core-foundation 0.9.4", + "core-graphics-types", + "foreign-types", + "libc", +] + +[[package]] +name = "core-graphics-types" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45390e6114f68f718cc7a830514a96f903cccd70d02a8f6d9f643ac4ba45afaf" +dependencies = [ + "bitflags 1.3.2", + "core-foundation 0.9.4", + "libc", +] + +[[package]] +name = "core_maths" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77745e017f5edba1a9c1d854f6f3a52dac8a12dd5af5d2f54aecf61e43d80d30" +dependencies = [ + "libm", +] + +[[package]] +name = "countme" +version = "3.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7704b5fdd17b18ae31c4c1da5a2e0305a2bf17b5249300a9ee9ed7b72114c636" + +[[package]] +name = "cpufeatures" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59ed5838eebb26a2bb2e58f6d5b5316989ae9d08bab10e0e6d103e656d1b0280" +dependencies = [ + "libc", +] + +[[package]] +name = "cpufeatures" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b2a41393f66f16b0823bb79094d54ac5fbd34ab292ddafb9a0456ac9f87d201" +dependencies = [ + "libc", +] + +[[package]] +name = "crc" +version = "3.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5eb8a2a1cd12ab0d987a5d5e825195d372001a4094a0376319d5a0ad71c1ba0d" +dependencies = [ + "crc-catalog", +] + +[[package]] +name = "crc-catalog" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "217698eaf96b4a3f0bc4f3662aaa55bdf913cd54d7204591faa790070c6d0853" + +[[package]] +name = "crc32fast" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9481c1c90cbf2ac953f07c8d4a58aa3945c425b7185c9154d67a65e4230da511" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "critical-section" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "790eea4361631c5e7d22598ecd5723ff611904e3344ce8720784c93e3d83d40b" + +[[package]] +name = "crossbeam-channel" +version = "0.5.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d85363c37faeca707aef026efa9f3b34d077bce547e48f770770625c6013679e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5181e0de7b61eb03a81e347d6dd8797bae9da5146707b51077e2d71a54ec0ceb" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2d6914041f254d6e9176c01941b21115dcfb7089e55135a35411081bd106ef3f" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-queue" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "803d13fb3b09d88be9f4dbc29062c66b19bf7170867ceb746d2a8689bf6c7a26" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61803da095bee82a81bb1a452ecc25d3b2f1416d1897eb86430c6159ef717c17" + +[[package]] +name = "crunchy" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "460fbee9c2c2f33933d720630a6a0bac33ba7053db5344fac858d4b8952d77d5" + +[[package]] +name = "crypto-common" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78c8292055d1c1df0cce5d180393dc8cce0abec0a7102adb6c7b1eef6016d60a" +dependencies = [ + "generic-array", + "typenum", +] + +[[package]] +name = "csv" +version = "1.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52cd9d68cf7efc6ddfaaee42e7288d3a99d613d4b50f76ce9827ae0c6e14f938" +dependencies = [ + "csv-core", + "itoa", + "ryu", + "serde_core", +] + +[[package]] +name = "csv-core" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "704a3c26996a80471189265814dbc2c257598b96b8a7feae2d31ace646bb9782" +dependencies = [ + "memchr", +] + +[[package]] +name = "ctor" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83cf0d42651b16c6dfe68685716d18480d18a9c39c62d76e8cf3eb6ed5d8bcbf" +dependencies = [ + "dtor", +] + +[[package]] +name = "cursor-icon" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f27ae1dd37df86211c42e150270f82743308803d90a6f6e6651cd730d5e1732f" + +[[package]] +name = "data-url" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "be1e0bca6c3637f992fc1cc7cbc52a78c1ef6db076dbf1059c4323d6a2048376" + +[[package]] +name = "deadpool" +version = "0.12.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0be2b1d1d6ec8d846f05e137292d0b89133caf95ef33695424c09568bdd39b1b" +dependencies = [ + "deadpool-runtime", + "lazy_static", + "num_cpus", + "tokio", +] + +[[package]] +name = "deadpool-runtime" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "092966b41edc516079bdf31ec78a2e0588d1d0c08f78b91d8307215928642b2b" + +[[package]] +name = "der" +version = "0.7.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e7c1832837b905bbfb5101e07cc24c8deddf52f93225eee6ead5f4d63d53ddcb" +dependencies = [ + "const-oid", + "pem-rfc7468", + "zeroize", +] + +[[package]] +name = "deranged" +version = "0.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7cd812cc2bc1d69d4764bd80df88b4317eaef9e773c75226407d9bc0876b211c" + +[[package]] +name = "derive_arbitrary" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e567bd82dcff979e4b03460c307b3cdc9e96fde3d73bed1496d2bc75d9dd62a" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "derive_more" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d751e9e49156b02b44f9c1815bcb94b984cdcc4396ecc32521c739452808b134" +dependencies = [ + "derive_more-impl", +] + +[[package]] +name = "derive_more-impl" +version = "2.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "799a97264921d8623a957f6c3b9011f3b5492f557bbb7a5a19b7fa6d06ba8dcb" +dependencies = [ + "convert_case", + "proc-macro2", + "quote", + "rustc_version", + "syn", + "unicode-xid", +] + +[[package]] +name = "derive_utils" +version = "0.15.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "362f47930db19fe7735f527e6595e4900316b893ebf6d48ad3d31be928d57dd6" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "diff" +version = "0.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8" + +[[package]] +name = "digest" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" +dependencies = [ + "block-buffer", + "const-oid", + "crypto-common", + "subtle", +] + +[[package]] +name = "directories" +version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "16f5094c54661b38d03bd7e50df373292118db60b585c08a411c6d840017fe7d" +dependencies = [ + "dirs-sys", +] + +[[package]] +name = "dirs-sys" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e01a3366d27ee9890022452ee61b2b63a67e6f13f58900b651ff5665f0bb1fab" +dependencies = [ + "libc", + "option-ext", + "redox_users", + "windows-sys 0.61.2", +] + +[[package]] +name = "dispatch" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bd0c93bb4b0c6d9b77f4435b0ae98c24d17f1c45b2ff844c6151a07256ca923b" + +[[package]] +name = "dispatch2" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e0e367e4e7da84520dedcac1901e4da967309406d1e51017ae1abfb97adbd38" +dependencies = [ + "bitflags 2.13.0", + "block2 0.6.2", + "libc", + "objc2 0.6.4", +] + +[[package]] +name = "displaydoc" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ac70aa55017e108007fbaf5aa0f54b021c98f92ff8af59d42eda9da96e3dd4f" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "dlib" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab8ecd87370524b461f8557c119c405552c396ed91fc0a8eec68679eab26f94a" +dependencies = [ + "libloading", +] + +[[package]] +name = "dotenvy" +version = "0.15.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" + +[[package]] +name = "downcast-rs" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75b325c5dbd37f80359721ad39aca5a29fb04c89279657cffdda8736d0c0b9d2" + +[[package]] +name = "dpi" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8b14ccef22fc6f5a8f4d7d768562a182c04ce9a3b3157b91390b52ddfdf1a76" + +[[package]] +name = "drm" +version = "0.14.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "80bc8c5c6c2941f70a55c15f8d9f00f9710ebda3ffda98075f996a0e6c92756f" +dependencies = [ + "bitflags 2.13.0", + "bytemuck", + "drm-ffi", + "drm-fourcc", + "libc", + "rustix 0.38.44", +] + +[[package]] +name = "drm-ffi" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51a91c9b32ac4e8105dec255e849e0d66e27d7c34d184364fb93e469db08f690" +dependencies = [ + "drm-sys", + "rustix 1.1.4", +] + +[[package]] +name = "drm-fourcc" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0aafbcdb8afc29c1a7ee5fbe53b5d62f4565b35a042a662ca9fecd0b54dae6f4" + +[[package]] +name = "drm-sys" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ecc8e1361066d91f5ffccff060a3c3be9c3ecde15be2959c1937595f7a82a9f8" +dependencies = [ + "libc", + "linux-raw-sys 0.9.4", +] + +[[package]] +name = "dtor" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "edf234dd1594d6dd434a8fb8cada51ddbbc593e40e4a01556a0b31c62da2775b" + +[[package]] +name = "either" +version = "1.16.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91622ff5e7162018101f2fea40d6ebf4a78bbe5a49736a2020649edf9693679e" +dependencies = [ + "serde", +] + +[[package]] +name = "endi" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "66b7e2430c6dff6a955451e2cfc438f09cea1965a9d6f87f7e3b90decc014099" + +[[package]] +name = "enumflags2" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1027f7680c853e056ebcec683615fb6fbbc07dbaa13b4d5d9442b146ded4ecef" +dependencies = [ + "enumflags2_derive", + "serde", +] + +[[package]] +name = "enumflags2_derive" +version = "0.7.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "67c78a4d8fdf9953a5c9d458f9efe940fd97a0cab0941c075a813ac594733827" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "equator" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4711b213838dfee0117e3be6ac926007d7f433d7bbe33595975d4190cb07e6fc" +dependencies = [ + "equator-macro", +] + +[[package]] +name = "equator-macro" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44f23cf4b44bfce11a86ace86f8a73ffdec849c9fd00a386a53d278bd9e81fb3" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "equivalent" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" + +[[package]] +name = "errno" +version = "0.3.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + +[[package]] +name = "error-code" +version = "3.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dea2df4cf52843e0452895c455a1a2cfbb842a1e7329671acf418fdc53ed4c59" + +[[package]] +name = "etcetera" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "136d1b5283a1ab77bd9257427ffd09d8667ced0570b6f938942bc7568ed5b943" +dependencies = [ + "cfg-if", + "home", + "windows-sys 0.48.0", +] + +[[package]] +name = "euclid" +version = "0.22.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1a05365e3b1c6d1650318537c7460c6923f1abdd272ad6842baa2b509957a06" +dependencies = [ + "num-traits", +] + +[[package]] +name = "event-listener" +version = "5.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13b66accf52311f30a0db42147dadea9850cb48cd070028831ae5f5d4b856ab" +dependencies = [ + "concurrent-queue", + "parking", + "pin-project-lite", +] + +[[package]] +name = "event-listener-strategy" +version = "0.5.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8be9f3dfaaffdae2972880079a491a1a8bb7cbed0b8dd7a347f668b4150a3b93" +dependencies = [ + "event-listener", + "pin-project-lite", +] + +[[package]] +name = "exr" +version = "1.74.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "711fe42c9964295e01ee3fba3f9fe0e1d24b98886950d68efe81b1c76e21adf3" +dependencies = [ + "bit_field", + "half", + "lebe", + "miniz_oxide", + "num-complex", + "pulp", + "rayon-core", + "smallvec", + "zune-inflate", +] + +[[package]] +name = "fastrand" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f1f227452a390804cdb637b74a86990f2a7d7ba4b7d5693aac9b4dd6defd8d6" + +[[package]] +name = "fax" +version = "0.2.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "caf1079563223d5d59d83c85886a56e586cfd5c1a26292e971a0fa266531ac5a" + +[[package]] +name = "fdeflate" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e6853b52649d4ac5c0bd02320cddc5ba956bdb407c4b75a2c6b75bf51500f8c" +dependencies = [ + "simd-adler32", +] + +[[package]] +name = "femtovg" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f43d05da42e81724c16d34a150fb7fda53d3f786e5a94673ee526ff8602f0f6a" +dependencies = [ + "bitflags 2.13.0", + "bytemuck", + "fnv", + "glow", + "imgref", + "itertools 0.14.0", + "log", + "rgb", + "slotmap", + "swash", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "field-offset" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38e2275cc4e4fc009b0669731a1e5ab7ebf11f469eaede2bab9309a5b4d6057f" +dependencies = [ + "memoffset", + "rustc_version", +] + +[[package]] +name = "filetime" +version = "0.2.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c287a33c7f0a620c38e641e7f60827713987b3c0f26e8ddc9462cc69cf75759" +dependencies = [ + "cfg-if", + "libc", +] + +[[package]] +name = "find-msvc-tools" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5baebc0774151f905a1a2cc41989300b1e6fbb29aff0ceffa1064fdd3088d582" + +[[package]] +name = "fixed_decimal" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "79c3c892f121fff406e5dd6b28c1b30096b95111c30701a899d4f2b18da6d1bd" +dependencies = [ + "displaydoc", + "smallvec", + "writeable", +] + +[[package]] +name = "flate2" +version = "1.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "843fba2746e448b37e26a819579957415c8cef339bf08564fe8b7ddbd959573c" +dependencies = [ + "crc32fast", + "miniz_oxide", + "zlib-rs", +] + +[[package]] +name = "float-cmp" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "98de4bbd547a563b716d8dfa9aad1cb19bfab00f4fa09a6a4ed21dbcf44ce9c4" + +[[package]] +name = "flume" +version = "0.11.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da0e4dd2a88388a1f4ccc7c9ce104604dab68d9f408dc34cd45823d5a9069095" +dependencies = [ + "futures-core", + "futures-sink", + "spin", +] + +[[package]] +name = "fnv" +version = "1.0.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" + +[[package]] +name = "foldhash" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" + +[[package]] +name = "foldhash" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" + +[[package]] +name = "font-types" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b38ad915f6dadd993ced50848a8291a543bd41ca62bc10740d5e64e2ab4cfd7" +dependencies = [ + "bytemuck", +] + +[[package]] +name = "fontdb" +version = "0.23.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "457e789b3d1202543297a350643cf459f836cade38934e7a4cf6a39e7cde2905" +dependencies = [ + "log", + "slotmap", + "tinyvec", + "ttf-parser", +] + +[[package]] +name = "fontique" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "274fa4f0f0a926ae182c7c076c078cce8a38471d15e61a102a02cac984be9813" +dependencies = [ + "hashbrown 0.17.1", + "linebender_resource_handle", + "memmap2", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-core-text", + "objc2-foundation 0.3.2", + "parlance", + "read-fonts", + "roxmltree", + "smallvec", + "windows", + "windows-core", + "yeslogic-fontconfig-sys", +] + +[[package]] +name = "foreign-types" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" +dependencies = [ + "foreign-types-macros", + "foreign-types-shared", +] + +[[package]] +name = "foreign-types-macros" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "foreign-types-shared" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" + +[[package]] +name = "form_urlencoded" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb4cb245038516f5f85277875cdaa4f7d2c9a0fa0468de06ed190163b1581fcf" +dependencies = [ + "percent-encoding", +] + +[[package]] +name = "futures" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b147ee9d1f6d097cef9ce628cd2ee62288d963e16fb287bd9286455b241382d" +dependencies = [ + "futures-channel", + "futures-core", + "futures-executor", + "futures-io", + "futures-sink", + "futures-task", + "futures-util", +] + +[[package]] +name = "futures-channel" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07bbe89c50d7a535e539b8c17bc0b49bdb77747034daa8087407d655f3f7cc1d" +dependencies = [ + "futures-core", + "futures-sink", +] + +[[package]] +name = "futures-core" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7e3450815272ef58cec6d564423f6e755e25379b217b0bc688e295ba24df6b1d" + +[[package]] +name = "futures-executor" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "baf29c38818342a3b26b5b923639e7b1f4a61fc5e76102d4b1981c6dc7a7579d" +dependencies = [ + "futures-core", + "futures-task", + "futures-util", +] + +[[package]] +name = "futures-intrusive" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d930c203dd0b6ff06e0201a4a2fe9149b43c684fd4420555b26d21b1a02956f" +dependencies = [ + "futures-core", + "lock_api", + "parking_lot", +] + +[[package]] +name = "futures-io" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cecba35d7ad927e23624b22ad55235f2239cfa44fd10428eecbeba6d6a717718" + +[[package]] +name = "futures-lite" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f78e10609fe0e0b3f4157ffab1876319b5b0db102a2c60dc4626306dc46b44ad" +dependencies = [ + "fastrand", + "futures-core", + "futures-io", + "parking", + "pin-project-lite", +] + +[[package]] +name = "futures-macro" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e835b70203e41293343137df5c0664546da5745f82ec9b84d40be8336958447b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "futures-sink" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c39754e157331b013978ec91992bde1ac089843443c49cbc7f46150b0fad0893" + +[[package]] +name = "futures-task" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "037711b3d59c33004d3856fbdc83b99d4ff37a24768fa1be9ce3538a1cde4393" + +[[package]] +name = "futures-util" +version = "0.3.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "389ca41296e6190b48053de0321d02a77f32f8a5d2461dd38762c0593805c6d6" +dependencies = [ + "futures-channel", + "futures-core", + "futures-io", + "futures-macro", + "futures-sink", + "futures-task", + "memchr", + "pin-project-lite", + "slab", +] + +[[package]] +name = "gbm" +version = "0.18.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce852e998d3ca5e4a97014fb31c940dc5ef344ec7d364984525fd11e8a547e6a" +dependencies = [ + "bitflags 2.13.0", + "drm", + "drm-fourcc", + "gbm-sys", + "libc", +] + +[[package]] +name = "gbm-sys" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c13a5f2acc785d8fb6bf6b7ab6bfb0ef5dad4f4d97e8e70bb8e470722312f76f" +dependencies = [ + "libc", +] + +[[package]] +name = "generic-array" +version = "0.14.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +dependencies = [ + "typenum", + "version_check", +] + +[[package]] +name = "gethostname" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1bd49230192a3797a9a4d6abe9b3eed6f7fa4c8a8a4947977c6f80025f92cbd8" +dependencies = [ + "rustix 1.1.4", + "windows-link", +] + +[[package]] +name = "getopts" +version = "0.2.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfe4fbac503b8d1f88e6676011885f34b7174f46e59956bba534ba83abded4df" +dependencies = [ + "unicode-width", +] + +[[package]] +name = "getrandom" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff2abc00be7fca6ebc474524697ae276ad847ad0a6b3faa4bcb027e9a4614ad0" +dependencies = [ + "cfg-if", + "js-sys", + "libc", + "wasi", + "wasm-bindgen", +] + +[[package]] +name = "getrandom" +version = "0.3.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" +dependencies = [ + "cfg-if", + "libc", + "r-efi 5.3.0", + "wasip2", +] + +[[package]] +name = "getrandom" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "300e883d756b2e4ec94e02791f39b04b522276138852cfc41d9fb7e904106099" +dependencies = [ + "cfg-if", + "js-sys", + "libc", + "r-efi 6.0.0", + "rand_core 0.10.1", + "wasm-bindgen", +] + +[[package]] +name = "gif" +version = "0.14.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee8cfcc411d9adbbaba82fb72661cc1bcca13e8bba98b364e62b2dba8f960159" +dependencies = [ + "color_quant", + "weezl", +] + +[[package]] +name = "gl_generator" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a95dfc23a2b4a9a2f5ab41d194f8bfda3cabec42af4e39f08c339eb2a0c124d" +dependencies = [ + "khronos_api", + "log", + "xml-rs", +] + +[[package]] +name = "glob" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280" + +[[package]] +name = "glow" +version = "0.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29038e1c483364cc6bb3cf78feee1816002e127c331a1eec55a4d202b9e1adb5" +dependencies = [ + "js-sys", + "slotmap", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "glutin" +version = "0.32.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "12124de845cacfebedff80e877bb37b5b75c34c5a4c89e47e1cdd67fb6041325" +dependencies = [ + "bitflags 2.13.0", + "cfg_aliases", + "cgl", + "dispatch2", + "glutin_egl_sys", + "glutin_glx_sys", + "glutin_wgl_sys", + "libloading", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "once_cell", + "raw-window-handle", + "wayland-sys", + "windows-sys 0.52.0", + "x11-dl", +] + +[[package]] +name = "glutin-winit" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85edca7075f8fc728f28cb8fbb111a96c3b89e930574369e3e9c27eb75d3788f" +dependencies = [ + "cfg_aliases", + "glutin", + "raw-window-handle", + "winit", +] + +[[package]] +name = "glutin_egl_sys" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4c4680ba6195f424febdc3ba46e7a42a0e58743f2edb115297b86d7f8ecc02d2" +dependencies = [ + "gl_generator", + "windows-sys 0.52.0", +] + +[[package]] +name = "glutin_glx_sys" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7bb2938045a88b612499fbcba375a77198e01306f52272e692f8c1f3751185" +dependencies = [ + "gl_generator", + "x11-dl", +] + +[[package]] +name = "glutin_wgl_sys" +version = "0.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c4ee00b289aba7a9e5306d57c2d05499b2e5dc427f84ac708bd2c090212cf3e" +dependencies = [ + "gl_generator", +] + +[[package]] +name = "grid" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b40ca9252762c466af32d0b1002e91e4e1bc5398f77455e55474deb466355ff5" + +[[package]] +name = "h2" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6cb093c84e8bd9b188d4c4a8cb6579fc016968d14c99882163cd3ff402a4f155" +dependencies = [ + "atomic-waker", + "bytes", + "fnv", + "futures-core", + "futures-sink", + "http", + "indexmap", + "slab", + "tokio", + "tokio-util", + "tracing", +] + +[[package]] +name = "half" +version = "2.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ea2d84b969582b4b1864a92dc5d27cd2b77b622a8d79306834f1be5ba20d84b" +dependencies = [ + "cfg-if", + "crunchy", + "zerocopy", +] + +[[package]] +name = "harfrust" +version = "0.8.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d12c7c642d4ce8c2e784b4751a6634bd89583912265add4a679a8882d123fbcd" +dependencies = [ + "bitflags 2.13.0", + "bytemuck", + "read-fonts", + "smallvec", +] + +[[package]] +name = "hashbrown" +version = "0.14.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" + +[[package]] +name = "hashbrown" +version = "0.15.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" +dependencies = [ + "allocator-api2", + "equivalent", + "foldhash 0.1.5", +] + +[[package]] +name = "hashbrown" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" +dependencies = [ + "allocator-api2", + "equivalent", + "foldhash 0.2.0", +] + +[[package]] +name = "hashbrown" +version = "0.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed5909b6e89a2db4456e54cd5f673791d7eca6732202bbf2a9cc504fe2f9b84a" +dependencies = [ + "foldhash 0.2.0", +] + +[[package]] +name = "hashlink" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7382cf6263419f2d8df38c55d7da83da5c18aef87fc7a7fc1fb1e344edfe14c1" +dependencies = [ + "hashbrown 0.15.5", +] + +[[package]] +name = "heck" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" + +[[package]] +name = "hermit-abi" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" + +[[package]] +name = "hermit-abi" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fc0fef456e4baa96da950455cd02c081ca953b141298e41db3fc7e36b1da849c" + +[[package]] +name = "hex" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" + +[[package]] +name = "hkdf" +version = "0.12.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b5f8eb2ad728638ea2c7d47a21db23b7b58a72ed6a38256b8a1849f15fbbdf7" +dependencies = [ + "hmac", +] + +[[package]] +name = "hmac" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" +dependencies = [ + "digest", +] + +[[package]] +name = "home" +version = "0.5.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cc627f471c528ff0c4a49e1d5e60450c8f6461dd6d10ba9dcd3a61d3dff7728d" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "htmlparser" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "48ce8546b993eaf241d69ded33b1be6d205dd9857ec879d9d18bd05d3676e144" + +[[package]] +name = "http" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6970f50e31d6fc17d3fa27329444bfa74e196cf62e95052a3f6fee181dba6425" +dependencies = [ + "bytes", + "itoa", +] + +[[package]] +name = "http-body" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1efedce1fb8e6913f23e0c92de8e62cd5b772a67e7b3946df930a62566c93184" +dependencies = [ + "bytes", + "http", +] + +[[package]] +name = "http-body-util" +version = "0.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b021d93e26becf5dc7e1b75b1bed1fd93124b374ceb73f43d4d4eafec896a64a" +dependencies = [ + "bytes", + "futures-core", + "http", + "http-body", + "pin-project-lite", +] + +[[package]] +name = "httparse" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" + +[[package]] +name = "httpdate" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df3b46402a9d5adb4c86a0cf463f42e19994e3ee891101b1841f30a545cb49a9" + +[[package]] +name = "hyper" +version = "1.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55281c53a1894c864990125767da440a4e630446785086f52523b20033b74498" +dependencies = [ + "atomic-waker", + "bytes", + "futures-channel", + "futures-core", + "h2", + "http", + "http-body", + "httparse", + "httpdate", + "itoa", + "pin-project-lite", + "smallvec", + "tokio", + "want", +] + +[[package]] +name = "hyper-rustls" +version = "0.27.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "33ca68d021ef39cf6463ab54c1d0f5daf03377b70561305bb89a8f83aab66e0f" +dependencies = [ + "http", + "hyper", + "hyper-util", + "rustls", + "tokio", + "tokio-rustls", + "tower-service", + "webpki-roots 1.0.8", +] + +[[package]] +name = "hyper-util" +version = "0.1.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96547c2556ec9d12fb1578c4eaf448b04993e7fb79cbaad930a656880a6bdfa0" +dependencies = [ + "base64", + "bytes", + "futures-channel", + "futures-util", + "http", + "http-body", + "hyper", + "ipnet", + "libc", + "percent-encoding", + "pin-project-lite", + "socket2", + "tokio", + "tower-service", + "tracing", +] + +[[package]] +name = "i-slint-backend-linuxkms" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68e76f2b13846ca54bba6b8eb3b5454b26879ad987396d0a2d8abedc31a6c469" +dependencies = [ + "bytemuck", + "calloop 0.14.4", + "cfg_aliases", + "drm", + "gbm", + "glutin", + "i-slint-common", + "i-slint-core", + "i-slint-renderer-femtovg", + "i-slint-renderer-software", + "input", + "memmap2", + "nix", + "raw-window-handle", + "xkbcommon", +] + +[[package]] +name = "i-slint-backend-selector" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2247a4590a02a466b2f4916cc789dfe66247f6af826f00eb84a2685259a45c1c" +dependencies = [ + "cfg-if", + "cfg_aliases", + "i-slint-backend-linuxkms", + "i-slint-backend-testing", + "i-slint-backend-winit", + "i-slint-common", + "i-slint-core", + "i-slint-core-macros", + "i-slint-renderer-femtovg", +] + +[[package]] +name = "i-slint-backend-testing" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521e901e3d47ab829c0ef500c63155776208707cd93259e6a7803ed627fa2786" +dependencies = [ + "cfg_aliases", + "i-slint-common", + "i-slint-core", + "i-slint-renderer-software", + "vtable", +] + +[[package]] +name = "i-slint-backend-winit" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a27c7e8f53418d3017362465367b6612b6e439a68097d627d1b91c94b885f0a6" +dependencies = [ + "accesskit", + "accesskit_winit", + "block2 0.6.2", + "bytemuck", + "cfg-if", + "cfg_aliases", + "copypasta", + "derive_more", + "futures", + "glutin", + "glutin-winit", + "i-slint-common", + "i-slint-core", + "i-slint-core-macros", + "i-slint-renderer-femtovg", + "i-slint-renderer-skia", + "i-slint-renderer-software", + "imgref", + "lyon_path", + "muda", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-foundation 0.3.2", + "objc2-quartz-core 0.3.2", + "objc2-ui-kit 0.3.2", + "pin-weak", + "raw-window-handle", + "rgb", + "scoped-tls-hkt", + "scopeguard", + "softbuffer", + "strum", + "vtable", + "wasm-bindgen", + "web-sys", + "webbrowser", + "windows", + "winit", + "zbus", +] + +[[package]] +name = "i-slint-common" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52e63f8ea55ba21e44567ae67d2b01a4f5d09bb1fab693b1e6c79d96bef9e456" +dependencies = [ + "derive_more", + "fontique", + "htmlparser", + "icu_decimal", + "icu_locale_core", + "icu_provider", + "pulldown-cmark", + "resvg", + "skrifa", +] + +[[package]] +name = "i-slint-compiler" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "45ea275b15a425c7f2f77481151e1f5f8f1ea83feae580273090ef6b9e192218" +dependencies = [ + "annotate-snippets", + "by_address", + "data-url", + "derive_more", + "i-slint-common", + "icu_normalizer", + "image", + "itertools 0.14.0", + "linked_hash_set", + "lyon_extra", + "lyon_path", + "num_enum", + "proc-macro2", + "quote", + "rayon", + "resvg", + "rowan", + "rspolib", + "skrifa", + "smol_str 0.3.6", + "strum", + "swash", + "typed-index-collections", + "unicode-segmentation", + "url", +] + +[[package]] +name = "i-slint-core" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4e407dc2bd5385dcbdd9c1cf927213d2e4bacda667545abf8839c60f8290f754" +dependencies = [ + "async-channel", + "auto_enums", + "bitflags 2.13.0", + "cfg-if", + "chrono", + "clru", + "const-field-offset", + "derive_more", + "euclid", + "i-slint-common", + "i-slint-core-macros", + "icu_normalizer", + "image", + "ksni", + "lyon_algorithms", + "lyon_extra", + "lyon_geom", + "lyon_path", + "num-traits", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-foundation 0.3.2", + "once_cell", + "parley", + "pin-project", + "pin-weak", + "portable-atomic", + "raw-window-handle", + "resvg", + "rgb", + "scopeguard", + "skrifa", + "slab", + "strum", + "swash", + "sys-locale", + "taffy", + "unicode-linebreak", + "unicode-script", + "unicode-segmentation", + "vtable", + "wasm-bindgen", + "web-sys", + "web-time", + "windows", +] + +[[package]] +name = "i-slint-core-macros" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a842640da4c4d0909d25cc5a51e1f9cde02bd48f7fdfa94df10d595d4e3c80a" +dependencies = [ + "quote", + "serde_json", + "syn", +] + +[[package]] +name = "i-slint-renderer-femtovg" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "78d0d99a18d66738b684758fe8460743a0aa0f64a96e05940942231a340085b1" +dependencies = [ + "cfg-if", + "const-field-offset", + "derive_more", + "femtovg", + "glow", + "i-slint-common", + "i-slint-core", + "i-slint-core-macros", + "imgref", + "lyon_path", + "pin-weak", + "rgb", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "i-slint-renderer-skia" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b6eed7f3f0a9a3d3ca6e8b9d4ca233371d989351fdb2a7ab88ec368b99e7b57" +dependencies = [ + "bytemuck", + "cfg-if", + "cfg_aliases", + "clru", + "const-field-offset", + "derive_more", + "glow", + "glutin", + "i-slint-common", + "i-slint-core", + "i-slint-core-macros", + "lyon_path", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "objc2-metal 0.3.2", + "objc2-quartz-core 0.3.2", + "pin-weak", + "raw-window-handle", + "raw-window-metal", + "read-fonts", + "scoped-tls-hkt", + "skia-safe", + "softbuffer", + "unicode-segmentation", + "vtable", + "windows", + "write-fonts", +] + +[[package]] +name = "i-slint-renderer-software" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73496f164f8e471877c35e0fadb996dcc674922712abd9c2be2cbe80c58859bd" +dependencies = [ + "bytemuck", + "clru", + "derive_more", + "euclid", + "i-slint-common", + "i-slint-core", + "integer-sqrt", + "lyon_path", + "num-traits", + "skrifa", + "swash", + "zeno", +] + +[[package]] +name = "iana-time-zone" +version = "0.1.65" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e31bc9ad994ba00e440a8aa5c9ef0ec67d5cb5e5cb0cc7f8b744a35b389cc470" +dependencies = [ + "android_system_properties", + "core-foundation-sys", + "iana-time-zone-haiku", + "js-sys", + "log", + "wasm-bindgen", + "windows-core", +] + +[[package]] +name = "iana-time-zone-haiku" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" +dependencies = [ + "cc", +] + +[[package]] +name = "icu_collections" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2984d1cd16c883d7935b9e07e44071dca8d917fd52ecc02c04d5fa0b5a3f191c" +dependencies = [ + "displaydoc", + "potential_utf", + "utf8_iter", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "icu_decimal" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "288247df2e32aa776ac54fdd64de552149ac43cb840f2761811f0e8d09719dd4" +dependencies = [ + "displaydoc", + "fixed_decimal", + "icu_decimal_data", + "icu_locale", + "icu_locale_core", + "icu_plurals", + "icu_provider", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_decimal_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6f14a5ca9e8af29eef62064f269078424283d90dbaffeac5225addf62aaabc22" + +[[package]] +name = "icu_locale" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5a396343c7208121dc86e35623d3dfe19814a7613cfd14964994cdc9c9a2e26" +dependencies = [ + "icu_collections", + "icu_locale_core", + "icu_locale_data", + "icu_provider", + "potential_utf", + "tinystr", + "zerovec", +] + +[[package]] +name = "icu_locale_core" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92219b62b3e2b4d88ac5119f8904c10f8f61bf7e95b640d25ba3075e6cac2c29" +dependencies = [ + "displaydoc", + "litemap", + "serde", + "tinystr", + "writeable", + "zerovec", +] + +[[package]] +name = "icu_locale_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5fdcc9ac77c6d74ff5cf6e65ef3181d6af32003b16fce3a77fb451d2f695993" + +[[package]] +name = "icu_normalizer" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c56e5ee99d6e3d33bd91c5d85458b6005a22140021cc324cea84dd0e72cff3b4" +dependencies = [ + "icu_collections", + "icu_normalizer_data", + "icu_properties", + "icu_provider", + "smallvec", + "zerovec", +] + +[[package]] +name = "icu_normalizer_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da3be0ae77ea334f4da67c12f149704f19f81d1adf7c51cf482943e84a2bad38" + +[[package]] +name = "icu_plurals" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a50023f1d49ad5c4333380328a0d4a19e4b9d6d842ec06639affd5ba47c8103" +dependencies = [ + "fixed_decimal", + "icu_locale", + "icu_plurals_data", + "icu_provider", + "zerovec", +] + +[[package]] +name = "icu_plurals_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8485497155dc865f901decb93ecc20d3e467df67bfeceb91e3ba34e2b11e8e1d" + +[[package]] +name = "icu_properties" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bee3b67d0ea5c2cca5003417989af8996f8604e34fb9ddf96208a033901e70de" +dependencies = [ + "icu_collections", + "icu_locale_core", + "icu_properties_data", + "icu_provider", + "zerotrie", + "zerovec", +] + +[[package]] +name = "icu_properties_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e2bbb201e0c04f7b4b3e14382af113e17ba4f63e2c9d2ee626b720cbce54a14" + +[[package]] +name = "icu_provider" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "139c4cf31c8b5f33d7e199446eff9c1e02decfc2f0eec2c8d71f65befa45b421" +dependencies = [ + "displaydoc", + "icu_locale_core", + "serde", + "stable_deref_trait", + "writeable", + "yoke", + "zerofrom", + "zerotrie", + "zerovec", +] + +[[package]] +name = "icu_segmenter" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c0794db0b1a86193ac9c48768d0e6c52c54448e0870ad87907d456ee0dac964" +dependencies = [ + "icu_collections", + "icu_locale", + "icu_provider", + "icu_segmenter_data", + "potential_utf", + "utf8_iter", + "zerovec", +] + +[[package]] +name = "icu_segmenter_data" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4a2c462a4d927d512f5f882a033ddd62f33a05bb9f230d98f736ac3dc85938f" + +[[package]] +name = "idna" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b0875f23caa03898994f6ddc501886a45c7d3d62d04d2d90788d47be1b1e4de" +dependencies = [ + "idna_adapter", + "smallvec", + "utf8_iter", +] + +[[package]] +name = "idna_adapter" +version = "1.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb68373c0d6620ef8105e855e7745e18b0d00d3bdb07fb532e434244cdb9a714" +dependencies = [ + "icu_normalizer", + "icu_properties", +] + +[[package]] +name = "image" +version = "0.25.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ab80394333c02fe689eaf900ab500fbd0c2213da414687ebf995a65d5a6104" +dependencies = [ + "bytemuck", + "byteorder-lite", + "color_quant", + "exr", + "gif", + "image-webp", + "moxcms", + "num-traits", + "png", + "qoi", + "ravif", + "rayon", + "rgb", + "tiff", + "zune-core", + "zune-jpeg", +] + +[[package]] +name = "image-webp" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "525e9ff3e1a4be2fbea1fdf0e98686a6d98b4d8f937e1bf7402245af1909e8c3" +dependencies = [ + "byteorder-lite", + "quick-error", +] + +[[package]] +name = "imagesize" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09e54e57b4c48b40f7aec75635392b12b3421fa26fe8b4332e63138ed278459c" + +[[package]] +name = "imgref" +version = "1.12.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "89194689a993ab15268672e99e7b0e19da2da3268ac682e8f02d29d4d1434cd7" + +[[package]] +name = "indexmap" +version = "2.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9" +dependencies = [ + "equivalent", + "hashbrown 0.17.1", +] + +[[package]] +name = "input" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f9793345a65d71317763a33066b5d8351f8760dde8d4930fe9e39b5f14a7959d" +dependencies = [ + "bitflags 2.13.0", + "input-sys", + "libc", + "log", + "udev", +] + +[[package]] +name = "input-sys" +version = "1.19.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36eee07d8e02bd95bf52b2e642cf13d33701b94c6e4b04fbf1d1fb07e9cb19e7" + +[[package]] +name = "integer-sqrt" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "276ec31bcb4a9ee45f58bec6f9ec700ae4cf4f4f8f2fa7e06cb406bd5ffdd770" +dependencies = [ + "num-traits", +] + +[[package]] +name = "interpolate_name" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c34819042dc3d3971c46c2190835914dfbe0c3c13f61449b2997f4e9722dfa60" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "io-lifetimes" +version = "1.0.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" +dependencies = [ + "hermit-abi 0.3.9", + "libc", + "windows-sys 0.48.0", +] + +[[package]] +name = "ipnet" +version = "2.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d98f6fed1fde3f8c21bc40a1abb88dd75e67924f9cffc3ef95607bad8017f8e2" + +[[package]] +name = "itertools" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" +dependencies = [ + "either", +] + +[[package]] +name = "itertools" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b192c782037fadd9cfa75548310488aabdbf3d2da73885b31bd0abd03351285" +dependencies = [ + "either", +] + +[[package]] +name = "itoa" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682" + +[[package]] +name = "jni" +version = "0.22.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5efd9a482cf3a427f00d6b35f14332adc7902ce91efb778580e180ff90fa3498" +dependencies = [ + "cfg-if", + "combine", + "jni-macros", + "jni-sys 0.4.1", + "log", + "simd_cesu8", + "thiserror 2.0.18", + "walkdir", + "windows-link", +] + +[[package]] +name = "jni-macros" +version = "0.22.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a00109accc170f0bdb141fed3e393c565b6f5e072365c3bd58f5b062591560a3" +dependencies = [ + "proc-macro2", + "quote", + "rustc_version", + "simd_cesu8", + "syn", +] + +[[package]] +name = "jni-sys" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41a652e1f9b6e0275df1f15b32661cf0d4b78d4d87ddec5e0c3c20f097433258" +dependencies = [ + "jni-sys 0.4.1", +] + +[[package]] +name = "jni-sys" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6377a88cb3910bee9b0fa88d4f42e1d2da8e79915598f65fb0c7ee14c878af2" +dependencies = [ + "jni-sys-macros", +] + +[[package]] +name = "jni-sys-macros" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38c0b942f458fe50cdac086d2f946512305e5631e720728f2a61aabcd47a6264" +dependencies = [ + "quote", + "syn", +] + +[[package]] +name = "jobserver" +version = "0.1.35" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1c00acbd29eabad4a2392fa0e921c874934dbbf4194312ad20f04a0ed67a3cb3" +dependencies = [ + "getrandom 0.4.3", + "libc", +] + +[[package]] +name = "js-sys" +version = "0.3.103" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53b44bfcdb3f8d5837a46dae1ca9660a837176eee74a28b229bc626816589102" +dependencies = [ + "cfg-if", + "futures-util", + "wasm-bindgen", +] + +[[package]] +name = "keyboard-types" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b750dcadc39a09dbadd74e118f6dd6598df77fa01df0cfcdc52c28dece74528a" +dependencies = [ + "bitflags 2.13.0", + "serde", + "unicode-segmentation", +] + +[[package]] +name = "keyring" +version = "3.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eebcc3aff044e5944a8fbaf69eb277d11986064cba30c468730e8b9909fb551c" +dependencies = [ + "log", + "zeroize", +] + +[[package]] +name = "khronos_api" +version = "3.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2db585e1d738fc771bf08a151420d3ed193d9d895a36df7f6f8a9456b911ddc" + +[[package]] +name = "ksni" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da9eeb3f510b6148ae68f963af2c1fbb0de4d9e4e05f82813cfb319837c3ad2b" +dependencies = [ + "async-executor", + "async-io", + "async-lock", + "futures-channel", + "futures-lite", + "futures-util", + "pastey 0.2.3", + "serde", + "zbus", +] + +[[package]] +name = "kurbo" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b60dfc32f652b926df6192e55525b16d186c69d47876c3ead4da5cc9f8450e2" +dependencies = [ + "arrayvec", + "euclid", + "polycool", + "smallvec", +] + +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +dependencies = [ + "spin", +] + +[[package]] +name = "lebe" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a79a3332a6609480d7d0c9eab957bca6b455b91bb84e66d19f5ff66294b85b8" + +[[package]] +name = "libc" +version = "0.2.186" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68ab91017fe16c622486840e4c83c9a37afeff978bd239b5293d61ece587de66" + +[[package]] +name = "libfuzzer-sys" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a9fd2f41a1cba099f79a0b6b6c35656cf7c03351a7bae8ff0f28f25270f929d2" +dependencies = [ + "arbitrary", + "cc", +] + +[[package]] +name = "libloading" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d7c4b02199fee7c5d21a5ae7d8cfa79a6ef5bb2fc834d6e9058e89c825efdc55" +dependencies = [ + "cfg-if", + "windows-link", +] + +[[package]] +name = "libm" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981" + +[[package]] +name = "libredox" +version = "0.1.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c943259e342f1e06ff2da7a83eabdfe7f92ce10262688dbf1895ff0b3e6e4652" +dependencies = [ + "bitflags 2.13.0", + "libc", + "plain", + "redox_syscall 0.9.0", +] + +[[package]] +name = "libsqlite3-sys" +version = "0.30.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2e99fb7a497b1e3339bc746195567ed8d3e24945ecd636e3619d20b9de9e9149" +dependencies = [ + "cc", + "pkg-config", + "vcpkg", +] + +[[package]] +name = "libudev-sys" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c8469b4a23b962c1396b9b451dda50ef5b283e8dd309d69033475fa9b334324" +dependencies = [ + "libc", + "pkg-config", +] + +[[package]] +name = "linebender_resource_handle" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d4a5ff6bcca6c4867b1c4fd4ef63e4db7436ef363e0ad7531d1558856bae64f4" + +[[package]] +name = "linked-hash-map" +version = "0.5.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" + +[[package]] +name = "linked_hash_set" +version = "0.1.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "984fb35d06508d1e69fc91050cceba9c0b748f983e6739fa2c7a9237154c52c8" +dependencies = [ + "linked-hash-map", +] + +[[package]] +name = "linux-raw-sys" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" + +[[package]] +name = "linux-raw-sys" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cd945864f07fe9f5371a27ad7b52a172b4b499999f1d97574c9fa68373937e12" + +[[package]] +name = "linux-raw-sys" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a66949e030da00e8c7d4434b251670a91556f4144941d37452769c25d58a53" + +[[package]] +name = "litemap" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92daf443525c4cce67b150400bc2316076100ce0b3686209eb8cf3c31612e6f0" + +[[package]] +name = "lock_api" +version = "0.4.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "224399e74b87b5f3557511d98dff8b14089b3dadafcab6bb93eab67d3aace965" +dependencies = [ + "scopeguard", +] + +[[package]] +name = "log" +version = "0.4.33" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad" + +[[package]] +name = "loop9" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fae87c125b03c1d2c0150c90365d7d6bcc53fb73a9acaef207d2d065860f062" +dependencies = [ + "imgref", +] + +[[package]] +name = "lru-slab" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154" + +[[package]] +name = "lyon_algorithms" +version = "1.0.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8575c0d003ae459399623c4def180c63b77f343b1a7fee64f249b349e7699a31" +dependencies = [ + "lyon_path", + "num-traits", +] + +[[package]] +name = "lyon_extra" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7755f08423275157ad1680aaecc9ccb7e0cc633da3240fea2d1522935cc15c72" +dependencies = [ + "lyon_path", + "thiserror 2.0.18", +] + +[[package]] +name = "lyon_geom" +version = "1.0.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4336502e29e32af93cf2dad2214ed6003c17ceb5bd499df77b1de663b9042b92" +dependencies = [ + "arrayvec", + "euclid", + "num-traits", +] + +[[package]] +name = "lyon_path" +version = "1.0.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c463f9c428b7fc5ec885dcd39ce4aa61e29111d0e33483f6f98c74e89d8621e" +dependencies = [ + "lyon_geom", + "num-traits", +] + +[[package]] +name = "matchers" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1525a2a28c7f4fa0fc98bb91ae755d1e2d1505079e05539e35bc876b5d65ae9" +dependencies = [ + "regex-automata", +] + +[[package]] +name = "maybe-rayon" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ea1f30cedd69f0a2954655f7188c6a834246d2bcf1e315e2ac40c4b24dc9519" +dependencies = [ + "cfg-if", + "rayon", +] + +[[package]] +name = "md-5" +version = "0.10.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d89e7ee0cfbedfc4da3340218492196241d89eefb6dab27de5df917a6d2e78cf" +dependencies = [ + "cfg-if", + "digest", +] + +[[package]] +name = "memchr" +version = "2.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" + +[[package]] +name = "memmap2" +version = "0.9.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1219ed1b7f229ee7104d281dd01d6802fe28bb6e95d292942c4daacdeb798c0" +dependencies = [ + "libc", +] + +[[package]] +name = "memoffset" +version = "0.9.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a" +dependencies = [ + "autocfg", +] + +[[package]] +name = "minimal-lexical" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" + +[[package]] +name = "miniz_oxide" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" +dependencies = [ + "adler2", + "simd-adler32", +] + +[[package]] +name = "mio" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "02bd0af71c67b473010cbbc60715ee815645a4dc942899111f494b4b737d6fda" +dependencies = [ + "libc", + "wasi", + "windows-sys 0.61.2", +] + +[[package]] +name = "moxcms" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb85c154ba489f01b25c0d36ae69a87e4a1c73a72631fc6c0eb6dde34a73e44b" +dependencies = [ + "num-traits", + "pxfm", +] + +[[package]] +name = "muda" +version = "0.19.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1dd04e60bc0b07438a6771710ee1698f98f6ebbc7f89b61264af1563b8aeb878" +dependencies = [ + "crossbeam-channel", + "dpi", + "keyboard-types", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "once_cell", + "png", + "thiserror 2.0.18", + "windows-sys 0.61.2", +] + +[[package]] +name = "natord" +version = "1.0.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "308d96db8debc727c3fd9744aac51751243420e46edf401010908da7f8d5e57c" + +[[package]] +name = "ndk" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3f42e7bbe13d351b6bead8286a43aac9534b82bd3cc43e47037f012ebfd62d4" +dependencies = [ + "bitflags 2.13.0", + "jni-sys 0.3.1", + "log", + "ndk-sys", + "num_enum", + "raw-window-handle", + "thiserror 1.0.69", +] + +[[package]] +name = "ndk-context" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27b02d87554356db9e9a873add8782d4ea6e3e58ea071a9adb9a2e8ddb884a8b" + +[[package]] +name = "ndk-sys" +version = "0.6.0+11769913" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee6cda3051665f1fb8d9e08fc35c96d5a244fb1be711a03b71118828afc9a873" +dependencies = [ + "jni-sys 0.3.1", +] + +[[package]] +name = "new_debug_unreachable" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "650eef8c711430f1a879fdd01d4745a7deea475becfb90269c06775983bbf086" + +[[package]] +name = "nix" +version = "0.31.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf20d2fde8ff38632c426f1165ed7436270b44f199fc55284c38276f9db47c3d" +dependencies = [ + "bitflags 2.13.0", + "cfg-if", + "cfg_aliases", + "libc", +] + +[[package]] +name = "no_std_io2" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "418abd1b6d34fbf6cae440dc874771b0525a604428704c76e48b29a5e67b8003" +dependencies = [ + "memchr", +] + +[[package]] +name = "nom" +version = "7.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d273983c5a657a70a3e8f2a01329822f3b8c8172b73826411a55751e404a0a4a" +dependencies = [ + "memchr", + "minimal-lexical", +] + +[[package]] +name = "nom" +version = "8.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "df9761775871bdef83bee530e60050f7e54b1105350d6884eb0fb4f46c2f9405" +dependencies = [ + "memchr", +] + +[[package]] +name = "noop_proc_macro" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0676bb32a98c1a483ce53e500a81ad9c3d5b3f7c920c28c24e9cb0980d0b5bc8" + +[[package]] +name = "nu-ansi-term" +version = "0.50.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "num-bigint" +version = "0.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c89e69e7e0f03bea5ef08013795c25018e101932225a656383bd384495ecc367" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-bigint-dig" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e661dda6640fad38e827a6d4a310ff4763082116fe217f279885c97f511bb0b7" +dependencies = [ + "lazy_static", + "libm", + "num-integer", + "num-iter", + "num-traits", + "rand 0.8.6", + "smallvec", + "zeroize", +] + +[[package]] +name = "num-complex" +version = "0.4.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495" +dependencies = [ + "bytemuck", + "num-traits", +] + +[[package]] +name = "num-conv" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521739c6d2bac4aa25192232afe6841231376b2b26d4d9fae5ecf8ca5772e441" + +[[package]] +name = "num-derive" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed3955f1a9c7c0c15e092f9c887db08b1fc683305fdf6eb6684f22555355e202" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "num-integer" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7969661fd2958a5cb096e56c8e1ad0444ac2bbcd0061bd28660485a44879858f" +dependencies = [ + "num-traits", +] + +[[package]] +name = "num-iter" +version = "0.1.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c92800bd69a1eac91786bcfe9da64a897eb72911b8dc3095decbd07429e8048b" +dependencies = [ + "num-integer", + "num-traits", +] + +[[package]] +name = "num-rational" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824" +dependencies = [ + "num-bigint", + "num-integer", + "num-traits", +] + +[[package]] +name = "num-traits" +version = "0.2.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" +dependencies = [ + "autocfg", + "libm", +] + +[[package]] +name = "num_cpus" +version = "1.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91df4bbde75afed763b708b7eee1e8e7651e02d97f6d5dd763e89367e957b23b" +dependencies = [ + "hermit-abi 0.5.2", + "libc", +] + +[[package]] +name = "num_enum" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0bca838442ec211fa11de3a8b0e0e8f3a4522575b5c4c06ed722e005036f26" +dependencies = [ + "num_enum_derive", + "rustversion", +] + +[[package]] +name = "num_enum_derive" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "680998035259dcfcafe653688bf2aa6d3e2dc05e98be6ab46afb089dc84f1df8" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "objc-sys" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdb91bdd390c7ce1a8607f35f3ca7151b65afc0ff5ff3b34fa350f7d7c7e4310" + +[[package]] +name = "objc2" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "46a785d4eeff09c14c487497c162e92766fbb3e4059a71840cecc03d9a50b804" +dependencies = [ + "objc-sys", + "objc2-encode", +] + +[[package]] +name = "objc2" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3a12a8ed07aefc768292f076dc3ac8c48f3781c8f2d5851dd3d98950e8c5a89f" +dependencies = [ + "objc2-encode", +] + +[[package]] +name = "objc2-app-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e4e89ad9e3d7d297152b17d39ed92cd50ca8063a89a9fa569046d41568891eff" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "libc", + "objc2 0.5.2", + "objc2-core-data 0.2.2", + "objc2-core-image 0.2.2", + "objc2-foundation 0.2.2", + "objc2-quartz-core 0.2.2", +] + +[[package]] +name = "objc2-app-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d49e936b501e5c5bf01fda3a9452ff86dc3ea98ad5f283e1455153142d97518c" +dependencies = [ + "bitflags 2.13.0", + "block2 0.6.2", + "libc", + "objc2 0.6.4", + "objc2-cloud-kit 0.3.2", + "objc2-core-data 0.3.2", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-core-image 0.3.2", + "objc2-core-text", + "objc2-core-video", + "objc2-foundation 0.3.2", + "objc2-quartz-core 0.3.2", +] + +[[package]] +name = "objc2-cloud-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "74dd3b56391c7a0596a295029734d3c1c5e7e510a4cb30245f8221ccea96b009" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-core-location", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-cloud-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73ad74d880bb43877038da939b7427bba67e9dd42004a18b809ba7d87cee241c" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-foundation 0.3.2", +] + +[[package]] +name = "objc2-contacts" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a5ff520e9c33812fd374d8deecef01d4a840e7b41862d849513de77e44aa4889" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-core-data" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "617fbf49e071c178c0b24c080767db52958f716d9eabdf0890523aeae54773ef" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-core-data" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b402a653efbb5e82ce4df10683b6b28027616a2715e90009947d50b8dd298fa" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-foundation 0.3.2", +] + +[[package]] +name = "objc2-core-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a180dd8642fa45cdb7dd721cd4c11b1cadd4929ce112ebd8b9f5803cc79d536" +dependencies = [ + "bitflags 2.13.0", + "dispatch2", + "objc2 0.6.4", +] + +[[package]] +name = "objc2-core-graphics" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e022c9d066895efa1345f8e33e584b9f958da2fd4cd116792e15e07e4720a807" +dependencies = [ + "bitflags 2.13.0", + "dispatch2", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-io-surface", +] + +[[package]] +name = "objc2-core-image" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "55260963a527c99f1819c4f8e3b47fe04f9650694ef348ffd2227e8196d34c80" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", + "objc2-metal 0.2.2", +] + +[[package]] +name = "objc2-core-image" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e5d563b38d2b97209f8e861173de434bd0214cf020e3423a52624cd1d989f006" +dependencies = [ + "objc2 0.6.4", + "objc2-foundation 0.3.2", +] + +[[package]] +name = "objc2-core-location" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "000cfee34e683244f284252ee206a27953279d370e309649dc3ee317b37e5781" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.2", + "objc2-contacts", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-core-text" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0cde0dfb48d25d2b4862161a4d5fcc0e3c24367869ad306b0c9ec0073bfed92d" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-core-graphics", +] + +[[package]] +name = "objc2-core-video" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d425caf1df73233f29fd8a5c3e5edbc30d2d4307870f802d18f00d83dc5141a6" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-io-surface", +] + +[[package]] +name = "objc2-encode" +version = "4.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef25abbcd74fb2609453eb695bd2f860d389e457f67dc17cafc8b8cbc89d0c33" + +[[package]] +name = "objc2-foundation" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ee638a5da3799329310ad4cfa62fbf045d5f56e3ef5ba4149e7452dcf89d5a8" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "dispatch", + "libc", + "objc2 0.5.2", +] + +[[package]] +name = "objc2-foundation" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3e0adef53c21f888deb4fa59fc59f7eb17404926ee8a6f59f5df0fd7f9f3272" +dependencies = [ + "bitflags 2.13.0", + "block2 0.6.2", + "objc2 0.6.4", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-io-surface" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "180788110936d59bab6bd83b6060ffdfffb3b922ba1396b312ae795e1de9d81d" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-core-foundation", +] + +[[package]] +name = "objc2-link-presentation" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1a1ae721c5e35be65f01a03b6d2ac13a54cb4fa70d8a5da293d7b0020261398" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.2", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-metal" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd0cba1276f6023976a406a14ffa85e1fdd19df6b0f737b063b95f6c8c7aadd6" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-metal" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a0125f776a10d00af4152d74616409f0d4a2053a6f57fa5b7d6aa2854ac04794" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-foundation 0.3.2", +] + +[[package]] +name = "objc2-quartz-core" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e42bee7bff906b14b167da2bac5efe6b6a07e6f7c0a21a7308d40c960242dc7a" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", + "objc2-metal 0.2.2", +] + +[[package]] +name = "objc2-quartz-core" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "96c1358452b371bf9f104e21ec536d37a650eb10f7ee379fff67d2e08d537f1f" +dependencies = [ + "bitflags 2.13.0", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "objc2-metal 0.3.2", +] + +[[package]] +name = "objc2-symbols" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a684efe3dec1b305badae1a28f6555f6ddd3bb2c2267896782858d5a78404dc" +dependencies = [ + "objc2 0.5.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-ui-kit" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8bb46798b20cd6b91cbd113524c490f1686f4c4e8f49502431415f3512e2b6f" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-cloud-kit 0.2.2", + "objc2-core-data 0.2.2", + "objc2-core-image 0.2.2", + "objc2-core-location", + "objc2-foundation 0.2.2", + "objc2-link-presentation", + "objc2-quartz-core 0.2.2", + "objc2-symbols", + "objc2-uniform-type-identifiers", + "objc2-user-notifications", +] + +[[package]] +name = "objc2-ui-kit" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d87d638e33c06f577498cbcc50491496a3ed4246998a7fbba7ccb98b1e7eab22" +dependencies = [ + "bitflags 2.13.0", + "block2 0.6.2", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "objc2-quartz-core 0.3.2", +] + +[[package]] +name = "objc2-uniform-type-identifiers" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44fa5f9748dbfe1ca6c0b79ad20725a11eca7c2218bceb4b005cb1be26273bfe" +dependencies = [ + "block2 0.5.1", + "objc2 0.5.2", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "objc2-user-notifications" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76cfcbf642358e8689af64cee815d139339f3ed8ad05103ed5eaf73db8d84cb3" +dependencies = [ + "bitflags 2.13.0", + "block2 0.5.1", + "objc2 0.5.2", + "objc2-core-location", + "objc2-foundation 0.2.2", +] + +[[package]] +name = "once_cell" +version = "1.21.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50" +dependencies = [ + "critical-section", + "portable-atomic", +] + +[[package]] +name = "option-ext" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" + +[[package]] +name = "orbclient" +version = "0.3.55" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5df339f526ea9a60e371768d50efc2f2508c7203290731565d1f7a6f71d21747" +dependencies = [ + "libc", + "libredox", +] + +[[package]] +name = "ordered-stream" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9aa2b01e1d916879f73a53d01d1d6cee68adbb31d6d9177a8cfce093cced1d50" +dependencies = [ + "futures-core", + "pin-project-lite", +] + +[[package]] +name = "owned_ttf_parser" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "36820e9051aca1014ddc75770aab4d68bc1e9e632f0f5627c4086bc216fb583b" +dependencies = [ + "ttf-parser", +] + +[[package]] +name = "parking" +version = "2.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f38d5652c16fde515bb1ecef450ab0f6a219d619a7274976324d5e377f7dceba" + +[[package]] +name = "parking_lot" +version = "0.12.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93857453250e3077bd71ff98b6a65ea6621a19bb0f559a85248955ac12c45a1a" +dependencies = [ + "lock_api", + "parking_lot_core", +] + +[[package]] +name = "parking_lot_core" +version = "0.9.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2621685985a2ebf1c516881c026032ac7deafcda1a2c9b7850dc81e3dfcb64c1" +dependencies = [ + "cfg-if", + "libc", + "redox_syscall 0.5.18", + "smallvec", + "windows-link", +] + +[[package]] +name = "parlance" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b6937eda350acc1a5d05872c3cbf99fe78619c269096e2be3d4a350058639d5" + +[[package]] +name = "parley" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b1cfcf399c774719fb1fa51bc6b91e86bdf003b03202a0902f1827ba6750746" +dependencies = [ + "fontique", + "harfrust", + "hashbrown 0.17.1", + "icu_normalizer", + "icu_properties", + "icu_segmenter", + "linebender_resource_handle", + "parlance", + "parley_data", + "skrifa", +] + +[[package]] +name = "parley_data" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1d3755e2cc12c0625b0cd2f2773c6a37dd11d1531940c945ade4aeb78f2b145" +dependencies = [ + "icu_properties", +] + +[[package]] +name = "paste" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + +[[package]] +name = "pastey" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35fb2e5f958ec131621fdd531e9fc186ed768cbe395337403ae56c17a74c68ec" + +[[package]] +name = "pastey" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2ee67f1008b1ba2321834326597b8e186293b049a023cdef258527550b9935b4" + +[[package]] +name = "pem-rfc7468" +version = "0.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "88b39c9bfcfc231068454382784bb460aae594343fb030d46e9f50a645418412" +dependencies = [ + "base64ct", +] + +[[package]] +name = "percent-encoding" +version = "2.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220" + +[[package]] +name = "phf" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1562dc717473dbaa4c1f85a36410e03c047b2e7df7f45ee938fbef64ae7fadf" +dependencies = [ + "phf_macros", + "phf_shared", + "serde", +] + +[[package]] +name = "phf_generator" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "135ace3a761e564ec88c03a77317a7c6b80bb7f7135ef2544dbe054243b89737" +dependencies = [ + "fastrand", + "phf_shared", +] + +[[package]] +name = "phf_macros" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "812f032b54b1e759ccd5f8b6677695d5268c588701effba24601f6932f8269ef" +dependencies = [ + "phf_generator", + "phf_shared", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "phf_shared" +version = "0.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e57fef6bc5981e38c2ce2d63bfa546861309f875b8a75f092d1d54ae2d64f266" +dependencies = [ + "siphasher", +] + +[[package]] +name = "pico-args" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5be167a7af36ee22fe3115051bc51f6e6c7054c9348e28deb4f49bd6f705a315" + +[[package]] +name = "pin-project" +version = "1.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2466b2336ed02bcdca6b294417127b90ec92038d1d5c4fbeac971a922e0e0924" +dependencies = [ + "pin-project-internal", +] + +[[package]] +name = "pin-project-internal" +version = "1.1.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c96395f0a926bc13b1c17622aaddda1ecb55d49c8f1bf9777e4d877800a43f8b" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "pin-project-lite" +version = "0.2.17" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a89322df9ebe1c1578d689c92318e070967d1042b512afbe49518723f4e6d5cd" + +[[package]] +name = "pin-utils" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184" + +[[package]] +name = "pin-weak" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b330c9d1b92dfe68442ca20b009c717d5f0b1e3cf4965e62f704c3c6e95a1305" + +[[package]] +name = "piper" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c835479a4443ded371d6c535cbfd8d31ad92c5d23ae9770a61bc155e4992a3c1" +dependencies = [ + "atomic-waker", + "fastrand", + "futures-io", +] + +[[package]] +name = "pkcs1" +version = "0.7.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8ffb9f10fa047879315e6625af03c164b16962a5368d724ed16323b68ace47f" +dependencies = [ + "der", + "pkcs8", + "spki", +] + +[[package]] +name = "pkcs8" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f950b2377845cebe5cf8b5165cb3cc1a5e0fa5cfa3e1f7f55707d8fd82e0a7b7" +dependencies = [ + "der", + "spki", +] + +[[package]] +name = "pkg-config" +version = "0.3.33" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19f132c84eca552bf34cab8ec81f1c1dcc229b811638f9d283dceabe58c5569e" + +[[package]] +name = "plain" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" + +[[package]] +name = "png" +version = "0.18.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "60769b8b31b2a9f263dae2776c37b1b28ae246943cf719eb6946a1db05128a61" +dependencies = [ + "bitflags 2.13.0", + "crc32fast", + "fdeflate", + "flate2", + "miniz_oxide", +] + +[[package]] +name = "polling" +version = "3.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d0e4f59085d47d8241c88ead0f274e8a0cb551f3625263c05eb8dd897c34218" +dependencies = [ + "cfg-if", + "concurrent-queue", + "hermit-abi 0.5.2", + "pin-project-lite", + "rustix 1.1.4", + "windows-sys 0.61.2", +] + +[[package]] +name = "pollster" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f3a9f18d041e6d0e102a0a46750538147e5e8992d3b4873aaafee2520b00ce3" + +[[package]] +name = "polycool" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50596ddc09eb5ad5f75cacd40209568e66df71baf86e1499a0e99c4cff12a5a6" +dependencies = [ + "arrayvec", +] + +[[package]] +name = "portable-atomic" +version = "1.13.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49" +dependencies = [ + "critical-section", +] + +[[package]] +name = "potential_utf" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0103b1cef7ec0cf76490e969665504990193874ea05c85ff9bab8b911d0a0564" +dependencies = [ + "serde_core", + "writeable", + "zerovec", +] + +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" + +[[package]] +name = "ppv-lite86" +version = "0.2.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85eae3c4ed2f50dcfe72643da4befc30deadb458a9b590d720cde2f2b1e97da9" +dependencies = [ + "zerocopy", +] + +[[package]] +name = "pretty_assertions" +version = "1.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ae130e2f271fbc2ac3a40fb1d07180839cdbbe443c7a27e1e3c13c5cac0116d" +dependencies = [ + "diff", + "yansi", +] + +[[package]] +name = "prettyplease" +version = "0.2.37" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "479ca8adacdd7ce8f1fb39ce9ecccbfe93a3f1344b3d0d97f20bc0196208f62b" +dependencies = [ + "proc-macro2", + "syn", +] + +[[package]] +name = "proc-macro-crate" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" +dependencies = [ + "toml_edit", +] + +[[package]] +name = "proc-macro2" +version = "1.0.106" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "profiling" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3d595e54a326bc53c1c197b32d295e14b169e3cfeaa8dc82b529f947fba6bcf5" +dependencies = [ + "profiling-procmacros", +] + +[[package]] +name = "profiling-procmacros" +version = "1.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4488a4a36b9a4ba6b9334a32a39971f77c1436ec82c38707bce707699cc3bbcb" +dependencies = [ + "quote", + "syn", +] + +[[package]] +name = "pulldown-cmark" +version = "0.13.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e9f068eba8e7071c5f9511831b44f32c740d5adf574e990f946ddb53db2f314e" +dependencies = [ + "bitflags 2.13.0", + "getopts", + "memchr", + "pulldown-cmark-escape", + "unicase", +] + +[[package]] +name = "pulldown-cmark-escape" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "007d8adb5ddab6f8e3f491ac63566a7d5002cc7ed73901f72057943fa71ae1ae" + +[[package]] +name = "pulp" +version = "0.22.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "046aa45b989642ec2e4717c8e72d677b13edd831a4d3b6cf37d9a3e54912496a" +dependencies = [ + "bytemuck", + "cfg-if", + "libm", + "num-complex", + "paste", + "pulp-wasm-simd-flag", + "raw-cpuid", + "reborrow", + "version_check", +] + +[[package]] +name = "pulp-wasm-simd-flag" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d8f70e07b9c3962945a74e59ca1c511bba65b6419468acc217c457d93f3c740" + +[[package]] +name = "pxfm" +version = "0.1.30" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d55d956fa96f5ec02be2e13af0e20391a5aa83d6a074e3ad368959d0fab299ea" + +[[package]] +name = "qoi" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7f6d64c71eb498fe9eae14ce4ec935c555749aef511cca85b5568910d6e48001" +dependencies = [ + "bytemuck", +] + +[[package]] +name = "quick-error" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" + +[[package]] +name = "quick-xml" +version = "0.39.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cdcc8dd4e2f670d309a5f0e83fe36dfdc05af317008fea29144da1a2ac858e5e" +dependencies = [ + "memchr", +] + +[[package]] +name = "quinn" +version = "0.11.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c1a41e437b6bbd489372cd4971de128e85c855f56c57f283d20ff016cf7c0a8" +dependencies = [ + "bytes", + "cfg_aliases", + "pin-project-lite", + "quinn-proto", + "quinn-udp", + "rustc-hash 2.1.3", + "rustls", + "socket2", + "thiserror 2.0.18", + "tokio", + "tracing", + "web-time", +] + +[[package]] +name = "quinn-proto" +version = "0.11.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f4bfc015262b9df63c8845072ce59068853ff5872180c2ce2f13038b970e560" +dependencies = [ + "bytes", + "getrandom 0.4.3", + "lru-slab", + "rand 0.10.2", + "rand_pcg", + "ring", + "rustc-hash 2.1.3", + "rustls", + "rustls-pki-types", + "slab", + "thiserror 2.0.18", + "tinyvec", + "tracing", + "web-time", +] + +[[package]] +name = "quinn-udp" +version = "0.5.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "35a133f956daabe89a61a685c2649f13d82d5aa4bd5d12d1277e1072a21c0694" +dependencies = [ + "cfg_aliases", + "libc", + "once_cell", + "socket2", + "tracing", + "windows-sys 0.61.2", +] + +[[package]] +name = "quote" +version = "1.0.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfbc457d0c7a0759a614551b11a6409e5951f6c7537be1f1b7682b9ae9230368" +dependencies = [ + "proc-macro2", +] + +[[package]] +name = "r-efi" +version = "5.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" + +[[package]] +name = "r-efi" +version = "6.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8dcc9c7d52a811697d2151c701e0d08956f92b0e24136cf4cf27b57a6a0d9bf" + +[[package]] +name = "rand" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ca0ecfa931c29007047d1bc58e623ab12e5590e8c7cc53200d5202b69266d8a" +dependencies = [ + "libc", + "rand_chacha 0.3.1", + "rand_core 0.6.4", +] + +[[package]] +name = "rand" +version = "0.9.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "44c5af06bb1b7d3216d91932aed5265164bf384dc89cd6ba05cf59a35f5f76ea" +dependencies = [ + "rand_chacha 0.9.0", + "rand_core 0.9.5", +] + +[[package]] +name = "rand" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c7f5fa3a058cd35567ef9bfa5e75732bee0f9e4c55fa90477bef2dfcdbc4be80" +dependencies = [ + "chacha20", + "getrandom 0.4.3", + "rand_core 0.10.1", +] + +[[package]] +name = "rand_chacha" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6c10a63a0fa32252be49d21e7709d4d4baf8d231c2dbce1eaa8141b9b127d88" +dependencies = [ + "ppv-lite86", + "rand_core 0.6.4", +] + +[[package]] +name = "rand_chacha" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3022b5f1df60f26e1ffddd6c66e8aa15de382ae63b3a0c1bfc0e4d3e3f325cb" +dependencies = [ + "ppv-lite86", + "rand_core 0.9.5", +] + +[[package]] +name = "rand_core" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" +dependencies = [ + "getrandom 0.2.17", +] + +[[package]] +name = "rand_core" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76afc826de14238e6e8c374ddcc1fa19e374fd8dd986b0d2af0d02377261d83c" +dependencies = [ + "getrandom 0.3.4", +] + +[[package]] +name = "rand_core" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63b8176103e19a2643978565ca18b50549f6101881c443590420e4dc998a3c69" + +[[package]] +name = "rand_pcg" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "caa0f4137e1c0a72f4c651489402276c8e8e1cf081f3b0ba156d2cbeef09e86a" +dependencies = [ + "rand_core 0.10.1", +] + +[[package]] +name = "rav1e" +version = "0.8.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "43b6dd56e85d9483277cde964fd1bdb0428de4fec5ebba7540995639a21cb32b" +dependencies = [ + "aligned-vec", + "arbitrary", + "arg_enum_proc_macro", + "arrayvec", + "av-scenechange", + "av1-grain", + "bitstream-io", + "built", + "cfg-if", + "interpolate_name", + "itertools 0.14.0", + "libc", + "libfuzzer-sys", + "log", + "maybe-rayon", + "new_debug_unreachable", + "noop_proc_macro", + "num-derive", + "num-traits", + "paste", + "profiling", + "rand 0.9.4", + "rand_chacha 0.9.0", + "simd_helpers", + "thiserror 2.0.18", + "v_frame", + "wasm-bindgen", +] + +[[package]] +name = "ravif" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e52310197d971b0f5be7fe6b57530dcd27beb35c1b013f29d66c1ad73fbbcc45" +dependencies = [ + "avif-serialize", + "imgref", + "loop9", + "quick-error", + "rav1e", + "rayon", + "rgb", +] + +[[package]] +name = "raw-cpuid" +version = "11.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "498cd0dc59d73224351ee52a95fee0f1a617a2eae0e7d9d720cc622c73a54186" +dependencies = [ + "bitflags 2.13.0", +] + +[[package]] +name = "raw-window-handle" +version = "0.6.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "20675572f6f24e9e76ef639bc5552774ed45f1c30e2951e1e99c59888861c539" + +[[package]] +name = "raw-window-metal" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40d213455a5f1dc59214213c7330e074ddf8114c9a42411eb890c767357ce135" +dependencies = [ + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "objc2-quartz-core 0.3.2", +] + +[[package]] +name = "rayon" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb39b166781f92d482534ef4b4b1b2568f42613b53e5b6c160e24cfbfa30926d" +dependencies = [ + "either", + "rayon-core", +] + +[[package]] +name = "rayon-core" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22e18b0f0062d30d4230b2e85ff77fdfe4326feb054b9783a3460d8435c8ab91" +dependencies = [ + "crossbeam-deque", + "crossbeam-utils", +] + +[[package]] +name = "read-fonts" +version = "0.39.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4ed38b89c2c77ff968c524145ad65fb010f38af5c7a224b53b81d47ac2daa81" +dependencies = [ + "bytemuck", + "font-types", +] + +[[package]] +name = "reborrow" +version = "0.5.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "03251193000f4bd3b042892be858ee50e8b3719f2b08e5833ac4353724632430" + +[[package]] +name = "redox_syscall" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4722d768eff46b75989dd134e5c353f0d6296e5aaa3132e776cbdb56be7731aa" +dependencies = [ + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.5.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" +dependencies = [ + "bitflags 2.13.0", +] + +[[package]] +name = "redox_syscall" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c5102a6aaa05aa011a238e178e6bca86d2cb56fc9f586d37cb80f5bca6e07759" +dependencies = [ + "bitflags 2.13.0", +] + +[[package]] +name = "redox_users" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4e608c6638b9c18977b00b475ac1f28d14e84b27d8d42f70e0bf1e3dec127ac" +dependencies = [ + "getrandom 0.2.17", + "libredox", + "thiserror 2.0.18", +] + +[[package]] +name = "regex" +version = "1.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a0e75113e14dc5acb068cd0786884f214f1312650a3d36d269f5c4f3cdee8a2" +dependencies = [ + "aho-corasick", + "memchr", + "regex-automata", + "regex-syntax", +] + +[[package]] +name = "regex-automata" +version = "0.4.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f388202e4b80542a0921078cc23b6333bcf1409c1e3f86404cae4766a6131db" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d6f6ff9a378485b298a5286656da665ba74413d36db0979633275d2e708145d4" + +[[package]] +name = "reqwest" +version = "0.12.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eddd3ca559203180a307f12d114c268abf583f59b03cb906fd0b3ff8646c1147" +dependencies = [ + "base64", + "bytes", + "futures-core", + "futures-util", + "http", + "http-body", + "http-body-util", + "hyper", + "hyper-rustls", + "hyper-util", + "js-sys", + "log", + "percent-encoding", + "pin-project-lite", + "quinn", + "rustls", + "rustls-pki-types", + "serde", + "serde_json", + "serde_urlencoded", + "sync_wrapper", + "tokio", + "tokio-rustls", + "tokio-util", + "tower", + "tower-http", + "tower-service", + "url", + "wasm-bindgen", + "wasm-bindgen-futures", + "wasm-streams", + "web-sys", + "webpki-roots 1.0.8", +] + +[[package]] +name = "resvg" +version = "0.47.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9be183ad6a216aa96f33e4c8033b0988b8b3ea6fd2359d19af5bac4643fd8e81" +dependencies = [ + "gif", + "image-webp", + "log", + "pico-args", + "rgb", + "svgtypes", + "tiny-skia 0.12.0", + "usvg", + "zune-jpeg", +] + +[[package]] +name = "rfd" +version = "0.15.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef2bee61e6cffa4635c72d7d81a84294e28f0930db0ddcb0f66d10244674ebed" +dependencies = [ + "ashpd", + "block2 0.6.2", + "dispatch2", + "js-sys", + "log", + "objc2 0.6.4", + "objc2-app-kit 0.3.2", + "objc2-core-foundation", + "objc2-foundation 0.3.2", + "pollster", + "raw-window-handle", + "urlencoding", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", + "windows-sys 0.59.0", +] + +[[package]] +name = "rgb" +version = "0.8.53" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47b34b781b31e5d73e9fbc8689c70551fd1ade9a19e3e28cfec8580a79290cc4" +dependencies = [ + "bytemuck", +] + +[[package]] +name = "ring" +version = "0.17.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7" +dependencies = [ + "cc", + "cfg-if", + "getrandom 0.2.17", + "libc", + "untrusted", + "windows-sys 0.52.0", +] + +[[package]] +name = "rowan" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "417a3a9f582e349834051b8a10c8d71ca88da4211e4093528e36b9845f6b5f21" +dependencies = [ + "countme", + "hashbrown 0.14.5", + "rustc-hash 1.1.0", + "text-size", +] + +[[package]] +name = "roxmltree" +version = "0.21.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1964b10c76125c36f8afe190065a4bf9a87bf324842c05701330bba9f1cacbb" +dependencies = [ + "memchr", +] + +[[package]] +name = "rsa" +version = "0.9.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8573f03f5883dcaebdfcf4725caa1ecb9c15b2ef50c43a07b816e06799bb12d" +dependencies = [ + "const-oid", + "digest", + "num-bigint-dig", + "num-integer", + "num-traits", + "pkcs1", + "pkcs8", + "rand_core 0.6.4", + "signature", + "spki", + "subtle", + "zeroize", +] + +[[package]] +name = "rspolib" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fda9a7796aff63a7b1b39ccc93fffaaf65e20042984b4843041a49ca4677535" +dependencies = [ + "lazy_static", + "natord", + "snafu", + "unicode-linebreak", + "unicode-width", +] + +[[package]] +name = "rust_xlsxwriter" +version = "0.90.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2be778223b36bb449b2ef2df4856ced2d311680818a7310db5c5dc370170f935" +dependencies = [ + "zip", +] + +[[package]] +name = "rustc-hash" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" + +[[package]] +name = "rustc-hash" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b1e7f9a428571be2dc5bc0505c13fb6bf936822b894ec87abf8a08a4e51742d" + +[[package]] +name = "rustc_version" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" +dependencies = [ + "semver", +] + +[[package]] +name = "rustix" +version = "0.38.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" +dependencies = [ + "bitflags 2.13.0", + "errno", + "libc", + "linux-raw-sys 0.4.15", + "windows-sys 0.59.0", +] + +[[package]] +name = "rustix" +version = "1.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6fe4565b9518b83ef4f91bb47ce29620ca828bd32cb7e408f0062e9930ba190" +dependencies = [ + "bitflags 2.13.0", + "errno", + "libc", + "linux-raw-sys 0.12.1", + "windows-sys 0.61.2", +] + +[[package]] +name = "rustls" +version = "0.23.41" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b92b125634d9b795e7beca796cc790df15a7fb38323bf3196fda83292d06b1f" +dependencies = [ + "once_cell", + "ring", + "rustls-pki-types", + "rustls-webpki", + "subtle", + "zeroize", +] + +[[package]] +name = "rustls-pki-types" +version = "1.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "764899a24af3980067ee14bc143654f297b22eaebfe3c7b6b211920a5a59b046" +dependencies = [ + "web-time", + "zeroize", +] + +[[package]] +name = "rustls-webpki" +version = "0.103.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "61c429a8649f110dddef65e2a5ad240f747e85f7758a6bccc7e5777bd33f756e" +dependencies = [ + "ring", + "rustls-pki-types", + "untrusted", +] + +[[package]] +name = "rustversion" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f" + +[[package]] +name = "rustybuzz" +version = "0.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fd3c7c96f8a08ee34eff8857b11b49b07d71d1c3f4e88f8a88d4c9e9f90b1702" +dependencies = [ + "bitflags 2.13.0", + "bytemuck", + "core_maths", + "log", + "smallvec", + "ttf-parser", + "unicode-bidi-mirroring", + "unicode-ccc", + "unicode-properties", + "unicode-script", +] + +[[package]] +name = "ryu" +version = "1.0.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9774ba4a74de5f7b1c1451ed6cd5285a32eddb5cccb8cc655a4e50009e06477f" + +[[package]] +name = "same-file" +version = "1.0.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "93fc1dc3aaa9bfed95e02e6eadabb4baf7e3078b0bd1b4d7b6b0b68378900502" +dependencies = [ + "winapi-util", +] + +[[package]] +name = "scoped-tls" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" + +[[package]] +name = "scoped-tls-hkt" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e9603871ffe5df3ac39cb624790c296dbd47a400d202f56bf3e414045099524d" + +[[package]] +name = "scopeguard" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" + +[[package]] +name = "sctk-adwaita" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6277f0217056f77f1d8f49f2950ac6c278c0d607c45f5ee99328d792ede24ec" +dependencies = [ + "ab_glyph", + "log", + "memmap2", + "smithay-client-toolkit 0.19.2", + "tiny-skia 0.11.4", +] + +[[package]] +name = "semver" +version = "1.0.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd" + +[[package]] +name = "serde" +version = "1.0.228" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e" +dependencies = [ + "serde_core", + "serde_derive", +] + +[[package]] +name = "serde_core" +version = "1.0.228" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad" +dependencies = [ + "serde_derive", +] + +[[package]] +name = "serde_derive" +version = "1.0.228" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_json" +version = "1.0.150" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e8014e44b4736ed0538adeecded0fce2a272f22dc9578a7eb6b2d9993c74cfb9" +dependencies = [ + "itoa", + "memchr", + "serde", + "serde_core", + "zmij", +] + +[[package]] +name = "serde_repr" +version = "0.1.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "175ee3e80ae9982737ca543e96133087cbd9a485eecc3bc4de9c1a37b47ea59c" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "serde_spanned" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6662b5879511e06e8999a8a235d848113e942c9124f211511b16466ee2995f26" +dependencies = [ + "serde_core", +] + +[[package]] +name = "serde_urlencoded" +version = "0.7.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" +dependencies = [ + "form_urlencoded", + "itoa", + "ryu", + "serde", +] + +[[package]] +name = "sha1" +version = "0.10.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a978451301f4db1d02937a4ab3ccce137717b81826e79b7d49ffe3244a13c3b8" +dependencies = [ + "cfg-if", + "cpufeatures 0.2.17", + "digest", +] + +[[package]] +name = "sha2" +version = "0.10.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7507d819769d01a365ab707794a4084392c824f54a7a6a7862f8c3d0892b283" +dependencies = [ + "cfg-if", + "cpufeatures 0.2.17", + "digest", +] + +[[package]] +name = "sharded-slab" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" +dependencies = [ + "lazy_static", +] + +[[package]] +name = "shlex" +version = "1.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64" + +[[package]] +name = "shlex" +version = "2.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8fadd59c855ef2080decdef8ff161eb6661b86933c9d82e5ba29dc602a55aba" + +[[package]] +name = "signal-hook-registry" +version = "1.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c4db69cba1110affc0e9f7bcd48bbf87b3f4fc7c61fc9155afd4c469eb3d6c1b" +dependencies = [ + "errno", + "libc", +] + +[[package]] +name = "signature" +version = "2.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77549399552de45a898a580c1b41d445bf730df867cc44e6c0233bbc4b8329de" +dependencies = [ + "digest", + "rand_core 0.6.4", +] + +[[package]] +name = "simd-adler32" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "703d5c7ef118737c72f1af64ad2f6f8c5e1921f818cdcb97b8fe6fc69bf66214" + +[[package]] +name = "simd_cesu8" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "94f90157bb87cddf702797c5dadfa0be7d266cdf49e22da2fcaa32eff75b2c33" +dependencies = [ + "rustc_version", + "simdutf8", +] + +[[package]] +name = "simd_helpers" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "95890f873bec569a0362c235787f3aca6e1e887302ba4840839bcc6459c42da6" +dependencies = [ + "quote", +] + +[[package]] +name = "simdutf8" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e3a9fe34e3e7a50316060351f37187a3f546bce95496156754b601a5fa71b76e" + +[[package]] +name = "simplecss" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a9c6883ca9c3c7c90e888de77b7a5c849c779d25d74a1269b0218b14e8b136c" +dependencies = [ + "log", +] + +[[package]] +name = "siphasher" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ee5873ec9cce0195efcb7a4e9507a04cd49aec9c83d0389df45b1ef7ba2e649" + +[[package]] +name = "skia-bindings" +version = "0.99.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3e2d1c3ebd697c0cbded0145e9204a38fa6b268446051b7196d0a096414ea7f3" +dependencies = [ + "bindgen", + "cc", + "flate2", + "heck", + "pkg-config", + "regex", + "serde_json", + "tar", + "toml", +] + +[[package]] +name = "skia-safe" +version = "0.99.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f512ac418a64194842dd05566320805dad1c957c521039db2486fd6368865bc" +dependencies = [ + "bitflags 2.13.0", + "skia-bindings", + "windows", +] + +[[package]] +name = "skrifa" +version = "0.42.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c34617370ae968efb7161bb2beb517d9084659aae19e24b89e3db25b46e4564" +dependencies = [ + "bytemuck", + "read-fonts", +] + +[[package]] +name = "slab" +version = "0.4.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c790de23124f9ab44544d7ac05d60440adc586479ce501c1d6d7da3cd8c9cf5" + +[[package]] +name = "slint" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce12038f57f8f3a423564b0c9301a2ab3fda4246e4cbadd6b97acf9124bdc315" +dependencies = [ + "const-field-offset", + "i-slint-backend-selector", + "i-slint-common", + "i-slint-core", + "i-slint-core-macros", + "i-slint-renderer-femtovg", + "i-slint-renderer-software", + "num-traits", + "once_cell", + "pin-weak", + "slint-macros", + "unicode-segmentation", + "vtable", +] + +[[package]] +name = "slint-build" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "76684c11441f775b10bbc7b0e6b3016a39f17efdd659ffca112f17cfd6bdaed1" +dependencies = [ + "derive_more", + "fontique", + "i-slint-compiler", + "spin_on", + "toml_edit", +] + +[[package]] +name = "slint-macros" +version = "1.17.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9f2a763e72e1e53c496f571d36327e777da1eb0d9e58fceb83890c2a83ee7223" +dependencies = [ + "i-slint-compiler", + "proc-macro2", + "quote", + "spin_on", +] + +[[package]] +name = "slotmap" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bdd58c3c93c3d278ca835519292445cb4b0d4dc59ccfdf7ceadaab3f8aeb4038" +dependencies = [ + "version_check", +] + +[[package]] +name = "smallvec" +version = "1.15.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ed6a63f02c8539c91a8685a86f4099661ba3da017932f6ebbea6de3f0fa7c90" +dependencies = [ + "serde", +] + +[[package]] +name = "smithay-client-toolkit" +version = "0.19.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3457dea1f0eb631b4034d61d4d8c32074caa6cd1ab2d59f2327bd8461e2c0016" +dependencies = [ + "bitflags 2.13.0", + "calloop 0.13.0", + "calloop-wayland-source 0.3.0", + "cursor-icon", + "libc", + "log", + "memmap2", + "rustix 0.38.44", + "thiserror 1.0.69", + "wayland-backend", + "wayland-client", + "wayland-csd-frame", + "wayland-cursor", + "wayland-protocols", + "wayland-protocols-wlr", + "wayland-scanner", + "xkeysym", +] + +[[package]] +name = "smithay-client-toolkit" +version = "0.20.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0512da38f5e2b31201a93524adb8d3136276fa4fe4aafab4e1f727a82b534cc0" +dependencies = [ + "bitflags 2.13.0", + "calloop 0.14.4", + "calloop-wayland-source 0.4.1", + "cursor-icon", + "libc", + "log", + "memmap2", + "rustix 1.1.4", + "thiserror 2.0.18", + "wayland-backend", + "wayland-client", + "wayland-csd-frame", + "wayland-cursor", + "wayland-protocols", + "wayland-protocols-experimental", + "wayland-protocols-misc", + "wayland-protocols-wlr", + "wayland-scanner", + "xkeysym", +] + +[[package]] +name = "smithay-clipboard" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "71704c03f739f7745053bde45fa203a46c58d25bc5c4efba1d9a60e9dba81226" +dependencies = [ + "libc", + "smithay-client-toolkit 0.20.0", + "wayland-backend", +] + +[[package]] +name = "smol_str" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dd538fb6910ac1099850255cf94a94df6551fbdd602454387d0adb2d1ca6dead" +dependencies = [ + "serde", +] + +[[package]] +name = "smol_str" +version = "0.3.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4aaa7368fcf4852a4c2dd92df0cace6a71f2091ca0a23391ce7f3a31833f1523" +dependencies = [ + "borsh", + "serde_core", +] + +[[package]] +name = "snafu" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e84b3f4eacbf3a1ce05eac6763b4d629d60cbc94d632e4092c54ade71f1e1a2" +dependencies = [ + "snafu-derive", +] + +[[package]] +name = "snafu-derive" +version = "0.8.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1c97747dbf44bb1ca44a561ece23508e99cb592e862f22222dcf42f51d1e451" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "socket2" +version = "0.6.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "52d1cfed4120b4d927bf7c0f86d2087a4a7d6027c906d9f9d525a80573b9be51" +dependencies = [ + "libc", + "windows-sys 0.61.2", +] + +[[package]] +name = "softbuffer" +version = "0.4.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aac18da81ebbf05109ab275b157c22a653bb3c12cf884450179942f81bcbf6c3" +dependencies = [ + "as-raw-xcb-connection", + "bytemuck", + "fastrand", + "js-sys", + "memmap2", + "ndk", + "objc2 0.6.4", + "objc2-core-foundation", + "objc2-core-graphics", + "objc2-foundation 0.3.2", + "objc2-quartz-core 0.3.2", + "raw-window-handle", + "redox_syscall 0.5.18", + "rustix 1.1.4", + "tiny-xlib", + "tracing", + "wasm-bindgen", + "wayland-backend", + "wayland-client", + "wayland-sys", + "web-sys", + "windows-sys 0.61.2", + "x11rb", +] + +[[package]] +name = "spin" +version = "0.9.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6980e8d7511241f8acf4aebddbb1ff938df5eebe98691418c4468d0b72a96a67" +dependencies = [ + "lock_api", +] + +[[package]] +name = "spin_on" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "076e103ed41b9864aa838287efe5f4e3a7a0362dd00671ae62a212e5e4612da2" +dependencies = [ + "pin-utils", +] + +[[package]] +name = "spki" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d91ed6c858b01f942cd56b37a94b3e0a1798290327d1236e4d9cf4eaca44d29d" +dependencies = [ + "base64ct", + "der", +] + +[[package]] +name = "sqlx" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1fefb893899429669dcdd979aff487bd78f4064e5e7907e4269081e0ef7d97dc" +dependencies = [ + "sqlx-core", + "sqlx-macros", + "sqlx-mysql", + "sqlx-postgres", + "sqlx-sqlite", +] + +[[package]] +name = "sqlx-core" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee6798b1838b6a0f69c007c133b8df5866302197e404e8b6ee8ed3e3a5e68dc6" +dependencies = [ + "base64", + "bytes", + "chrono", + "crc", + "crossbeam-queue", + "either", + "event-listener", + "futures-core", + "futures-intrusive", + "futures-io", + "futures-util", + "hashbrown 0.15.5", + "hashlink", + "indexmap", + "log", + "memchr", + "once_cell", + "percent-encoding", + "rustls", + "serde", + "serde_json", + "sha2", + "smallvec", + "thiserror 2.0.18", + "tokio", + "tokio-stream", + "tracing", + "url", + "webpki-roots 0.26.11", +] + +[[package]] +name = "sqlx-macros" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2d452988ccaacfbf5e0bdbc348fb91d7c8af5bee192173ac3636b5fb6e6715d" +dependencies = [ + "proc-macro2", + "quote", + "sqlx-core", + "sqlx-macros-core", + "syn", +] + +[[package]] +name = "sqlx-macros-core" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "19a9c1841124ac5a61741f96e1d9e2ec77424bf323962dd894bdb93f37d5219b" +dependencies = [ + "dotenvy", + "either", + "heck", + "hex", + "once_cell", + "proc-macro2", + "quote", + "serde", + "serde_json", + "sha2", + "sqlx-core", + "sqlx-mysql", + "sqlx-postgres", + "sqlx-sqlite", + "syn", + "tokio", + "url", +] + +[[package]] +name = "sqlx-mysql" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aa003f0038df784eb8fecbbac13affe3da23b45194bd57dba231c8f48199c526" +dependencies = [ + "atoi", + "base64", + "bitflags 2.13.0", + "byteorder", + "bytes", + "chrono", + "crc", + "digest", + "dotenvy", + "either", + "futures-channel", + "futures-core", + "futures-io", + "futures-util", + "generic-array", + "hex", + "hkdf", + "hmac", + "itoa", + "log", + "md-5", + "memchr", + "once_cell", + "percent-encoding", + "rand 0.8.6", + "rsa", + "serde", + "sha1", + "sha2", + "smallvec", + "sqlx-core", + "stringprep", + "thiserror 2.0.18", + "tracing", + "whoami", +] + +[[package]] +name = "sqlx-postgres" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db58fcd5a53cf07c184b154801ff91347e4c30d17a3562a635ff028ad5deda46" +dependencies = [ + "atoi", + "base64", + "bitflags 2.13.0", + "byteorder", + "chrono", + "crc", + "dotenvy", + "etcetera", + "futures-channel", + "futures-core", + "futures-util", + "hex", + "hkdf", + "hmac", + "home", + "itoa", + "log", + "md-5", + "memchr", + "once_cell", + "rand 0.8.6", + "serde", + "serde_json", + "sha2", + "smallvec", + "sqlx-core", + "stringprep", + "thiserror 2.0.18", + "tracing", + "whoami", +] + +[[package]] +name = "sqlx-sqlite" +version = "0.8.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2d12fe70b2c1b4401038055f90f151b78208de1f9f89a7dbfd41587a10c3eea" +dependencies = [ + "atoi", + "chrono", + "flume", + "futures-channel", + "futures-core", + "futures-executor", + "futures-intrusive", + "futures-util", + "libsqlite3-sys", + "log", + "percent-encoding", + "serde", + "serde_urlencoded", + "sqlx-core", + "thiserror 2.0.18", + "tracing", + "url", +] + +[[package]] +name = "stable_deref_trait" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596" + +[[package]] +name = "static_assertions" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" + +[[package]] +name = "strict-num" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6637bab7722d379c8b41ba849228d680cc12d0a45ba1fa2b48f2a30577a06731" +dependencies = [ + "float-cmp", +] + +[[package]] +name = "stringprep" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7b4df3d392d81bd458a8a621b8bffbd2302a12ffe288a9d931670948749463b1" +dependencies = [ + "unicode-bidi", + "unicode-normalization", + "unicode-properties", +] + +[[package]] +name = "strum" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9628de9b8791db39ceda2b119bbe13134770b56c138ec1d3af810d045c04f9bd" +dependencies = [ + "strum_macros", +] + +[[package]] +name = "strum_macros" +version = "0.28.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ab85eea0270ee17587ed4156089e10b9e6880ee688791d45a905f5b1ca36f664" +dependencies = [ + "heck", + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "subtle" +version = "2.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" + +[[package]] +name = "svgtypes" +version = "0.16.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "695b5790b3131dafa99b3bbfd25a216edb3d216dad9ca208d4657bfb8f2abc3d" +dependencies = [ + "kurbo", + "siphasher", +] + +[[package]] +name = "swash" +version = "0.2.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0811b01ca2c4e8718760713911feaf4675c24f94e50530a015ec646cfb622f7c" +dependencies = [ + "skrifa", + "yazi", + "zeno", +] + +[[package]] +name = "symlink" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7973cce6668464ea31f176d85b13c7ab3bba2cb3b77a2ed26abd7801688010a" + +[[package]] +name = "syn" +version = "2.0.118" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b9ae57f904213ebb649ce6895b8a66c66f0203b9319718f69a5612a065b1422" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "sync_wrapper" +version = "1.0.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0bf256ce5efdfa370213c1dabab5935a12e49f2c58d15e9eac2870d3b4f27263" +dependencies = [ + "futures-core", +] + +[[package]] +name = "synstructure" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "728a70f3dbaf5bab7f0c4b1ac8d7ae5ea60a4b5549c8a5914361c99147a709d2" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "sys-locale" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8eab9a99a024a169fe8a903cf9d4a3b3601109bcc13bd9e3c6fff259138626c4" +dependencies = [ + "js-sys", + "libc", + "wasm-bindgen", + "web-sys", +] + +[[package]] +name = "taffy" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aea22054047c16c3f34d3ac473a2170be1424b1115b2a3adcf28cfb067c88859" +dependencies = [ + "arrayvec", + "grid", + "serde", + "slotmap", +] + +[[package]] +name = "tar" +version = "0.4.46" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f6221d9a6003c78398e3b239969f352578258df48c8eb051caadae0015bc840" +dependencies = [ + "filetime", + "libc", + "xattr", +] + +[[package]] +name = "tempfile" +version = "3.27.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32497e9a4c7b38532efcdebeef879707aa9f794296a4f0244f6f69e9bc8574bd" +dependencies = [ + "fastrand", + "getrandom 0.4.3", + "once_cell", + "rustix 1.1.4", + "windows-sys 0.61.2", +] + +[[package]] +name = "text-size" +version = "1.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f18aa187839b2bdb1ad2fa35ead8c4c2976b64e4363c386d45ac0f7ee85c9233" + +[[package]] +name = "thiserror" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52" +dependencies = [ + "thiserror-impl 1.0.69", +] + +[[package]] +name = "thiserror" +version = "2.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4288b5bcbc7920c07a1149a35cf9590a2aa808e0bc1eafaade0b80947865fbc4" +dependencies = [ + "thiserror-impl 2.0.18", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.69" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebc4ee7f67670e9b64d05fa4253e753e016c6c95ff35b89b7941d6b856dec1d5" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "thread_local" +version = "1.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ad99c4c6d32803332c548b1af0540b357b3f5fc0be8f6c6bfe8b2e6ae784070" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "tiff" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b63feaf3343d35b6ca4d50483f94843803b0f51634937cc2ec519fc32232bc52" +dependencies = [ + "fax", + "flate2", + "half", + "quick-error", + "weezl", + "zune-jpeg", +] + +[[package]] +name = "time" +version = "0.3.53" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18dfaaeddcb932337b5e7866ee7d0ce9b76d2fd092997146f187ec09b4558a50" +dependencies = [ + "deranged", + "num-conv", + "powerfmt", + "serde_core", + "time-core", + "time-macros", +] + +[[package]] +name = "time-core" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9e1c906769ad99c88eaa54e728060edef082f8e358ff32030cb7c7d315e81109" + +[[package]] +name = "time-macros" +version = "0.2.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c431b87111666e491a90baa837f914fb45cd5dc3c268591b0220ff5057f2085f" +dependencies = [ + "num-conv", + "time-core", +] + +[[package]] +name = "tiny-skia" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83d13394d44dae3207b52a326c0c85a8bf87f1541f23b0d143811088497b09ab" +dependencies = [ + "arrayref", + "arrayvec", + "bytemuck", + "cfg-if", + "log", + "tiny-skia-path 0.11.4", +] + +[[package]] +name = "tiny-skia" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "47ffee5eaaf5527f630fb0e356b90ebdec84d5d18d937c5e440350f88c5a91ea" +dependencies = [ + "arrayref", + "arrayvec", + "bytemuck", + "cfg-if", + "log", + "png", + "tiny-skia-path 0.12.0", +] + +[[package]] +name = "tiny-skia-path" +version = "0.11.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c9e7fc0c2e86a30b117d0462aa261b72b7a99b7ebd7deb3a14ceda95c5bdc93" +dependencies = [ + "arrayref", + "bytemuck", + "strict-num", +] + +[[package]] +name = "tiny-skia-path" +version = "0.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "edca365c3faccca67d06593c5980fa6c57687de727a03131735bb85f01fdeeb9" +dependencies = [ + "arrayref", + "bytemuck", + "strict-num", +] + +[[package]] +name = "tiny-xlib" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a90a0ca3ee6a69f2ad28fd11621a4c3f03b371f366be500b64df260c4ffbafb4" +dependencies = [ + "as-raw-xcb-connection", + "ctor", + "libloading", + "pkg-config", + "tracing", +] + +[[package]] +name = "tinystr" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c8323304221c2a851516f22236c5722a72eaa19749016521d6dff0824447d96d" +dependencies = [ + "displaydoc", + "serde_core", + "zerovec", +] + +[[package]] +name = "tinyvec" +version = "1.12.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bb4ebadaa0af04fab11ae01eb5f9fdb5f9c5b875506e210e71c07873528baa7f" +dependencies = [ + "tinyvec_macros", +] + +[[package]] +name = "tinyvec_macros" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" + +[[package]] +name = "tokio" +version = "1.52.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8fc7f01b389ac15039e4dc9531aa973a135d7a4135281b12d7c1bc79fd57fffe" +dependencies = [ + "bytes", + "libc", + "mio", + "pin-project-lite", + "socket2", + "tokio-macros", + "windows-sys 0.61.2", +] + +[[package]] +name = "tokio-macros" +version = "2.7.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "385a6cb71ab9ab790c5fe8d67f1645e6c450a7ce006a33de03daa956cf70a496" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tokio-rustls" +version = "0.26.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1729aa945f29d91ba541258c8df89027d5792d85a8841fb65e8bf0f4ede4ef61" +dependencies = [ + "rustls", + "tokio", +] + +[[package]] +name = "tokio-stream" +version = "0.1.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32da49809aab5c3bc678af03902d4ccddea2a87d028d86392a4b1560c6906c70" +dependencies = [ + "futures-core", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "tokio-util" +version = "0.7.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ae9cec805b01e8fc3fd2fe289f89149a9b66dd16786abd8b19cfa7b48cb0098" +dependencies = [ + "bytes", + "futures-core", + "futures-sink", + "futures-util", + "pin-project-lite", + "tokio", +] + +[[package]] +name = "toml" +version = "1.1.2+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81f3d15e84cbcd896376e6730314d59fb5a87f31e4b038454184435cd57defee" +dependencies = [ + "indexmap", + "serde_core", + "serde_spanned", + "toml_datetime", + "toml_parser", + "toml_writer", + "winnow", +] + +[[package]] +name = "toml_datetime" +version = "1.1.1+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3165f65f62e28e0115a00b2ebdd37eb6f3b641855f9d636d3cd4103767159ad7" +dependencies = [ + "serde_core", +] + +[[package]] +name = "toml_edit" +version = "0.25.12+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2153edc6955a6c354fad8f5efd38b6a8769bdccf9fe50f8e1329f81b0baa5d7" +dependencies = [ + "indexmap", + "toml_datetime", + "toml_parser", + "toml_writer", + "winnow", +] + +[[package]] +name = "toml_parser" +version = "1.1.2+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a2abe9b86193656635d2411dc43050282ca48aa31c2451210f4202550afb7526" +dependencies = [ + "winnow", +] + +[[package]] +name = "toml_writer" +version = "1.1.1+spec-1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "756daf9b1013ebe47a8776667b466417e2d4c5679d441c26230efd9ef78692db" + +[[package]] +name = "tower" +version = "0.5.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebe5ef63511595f1344e2d5cfa636d973292adc0eec1f0ad45fae9f0851ab1d4" +dependencies = [ + "futures-core", + "futures-util", + "pin-project-lite", + "sync_wrapper", + "tokio", + "tower-layer", + "tower-service", +] + +[[package]] +name = "tower-http" +version = "0.6.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4cfcf7e2740e6fc6d4d688b4ef00650406bb94adf4731e43c096c3a19fe40840" +dependencies = [ + "bitflags 2.13.0", + "bytes", + "futures-util", + "http", + "http-body", + "pin-project-lite", + "tower", + "tower-layer", + "tower-service", + "url", +] + +[[package]] +name = "tower-layer" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "121c2a6cda46980bb0fcd1647ffaf6cd3fc79a013de288782836f6df9c48780e" + +[[package]] +name = "tower-service" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8df9b6e13f2d32c91b9bd719c00d1958837bc7dec474d94952798cc8e69eeec3" + +[[package]] +name = "tracing" +version = "0.1.44" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "63e71662fa4b2a2c3a26f570f037eb95bb1f85397f3cd8076caed2f026a6d100" +dependencies = [ + "log", + "pin-project-lite", + "tracing-attributes", + "tracing-core", +] + +[[package]] +name = "tracing-appender" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "050686193eb999b4bb3bc2acfa891a13da00f79734704c4b8b4ef1a10b368a3c" +dependencies = [ + "crossbeam-channel", + "symlink", + "thiserror 2.0.18", + "time", + "tracing-subscriber", +] + +[[package]] +name = "tracing-attributes" +version = "0.1.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7490cfa5ec963746568740651ac6781f701c9c5ea257c58e057f3ba8cf69e8da" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "tracing-core" +version = "0.1.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "db97caf9d906fbde555dd62fa95ddba9eecfd14cb388e4f491a66d74cd5fb79a" +dependencies = [ + "once_cell", + "valuable", +] + +[[package]] +name = "tracing-log" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" +dependencies = [ + "log", + "once_cell", + "tracing-core", +] + +[[package]] +name = "tracing-subscriber" +version = "0.3.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb7f578e5945fb242538965c2d0b04418d38ec25c79d160cd279bf0731c8d319" +dependencies = [ + "matchers", + "nu-ansi-term", + "once_cell", + "regex-automata", + "sharded-slab", + "smallvec", + "thread_local", + "tracing", + "tracing-core", + "tracing-log", +] + +[[package]] +name = "try-lock" +version = "0.2.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" + +[[package]] +name = "ttf-parser" +version = "0.25.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d2df906b07856748fa3f6e0ad0cbaa047052d4a7dd609e231c4f72cee8c36f31" +dependencies = [ + "core_maths", +] + +[[package]] +name = "typed-index-collections" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "898160f1dfd383b4e92e17f0512a7d62f3c51c44937b23b6ffc3a1614a8eaccd" +dependencies = [ + "bincode", + "serde", +] + +[[package]] +name = "typenum" +version = "1.20.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6f5e870be6c3b371b77fe0ee0bafb859fa4964b4404c27de1d380043c4dda20" + +[[package]] +name = "udev" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "af4e37e9ea4401fc841ff54b9ddfc9be1079b1e89434c1a6a865dd68980f7e9f" +dependencies = [ + "io-lifetimes", + "libc", + "libudev-sys", + "pkg-config", +] + +[[package]] +name = "uds_windows" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e" +dependencies = [ + "memoffset", + "tempfile", + "windows-sys 0.61.2", +] + +[[package]] +name = "unicase" +version = "2.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dbc4bc3a9f746d862c45cb89d705aa10f187bb96c76001afab07a0d35ce60142" + +[[package]] +name = "unicode-bidi" +version = "0.3.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c1cb5db39152898a79168971543b1cb5020dff7fe43c8dc468b0885f5e29df5" + +[[package]] +name = "unicode-bidi-mirroring" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5dfa6e8c60bb66d49db113e0125ee8711b7647b5579dc7f5f19c42357ed039fe" + +[[package]] +name = "unicode-ccc" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ce61d488bcdc9bc8b5d1772c404828b17fc481c0a582b5581e95fb233aef503e" + +[[package]] +name = "unicode-ident" +version = "1.0.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75" + +[[package]] +name = "unicode-linebreak" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3b09c83c3c29d37506a3e260c08c03743a6bb66a9cd432c6934ab501a190571f" + +[[package]] +name = "unicode-normalization" +version = "0.1.25" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5fd4f6878c9cb28d874b009da9e8d183b5abc80117c40bbd187a1fde336be6e8" +dependencies = [ + "tinyvec", +] + +[[package]] +name = "unicode-properties" +version = "0.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7df058c713841ad818f1dc5d3fd88063241cc61f49f5fbea4b951e8cf5a8d71d" + +[[package]] +name = "unicode-script" +version = "0.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "383ad40bb927465ec0ce7720e033cb4ca06912855fc35db31b5755d0de75b1ee" + +[[package]] +name = "unicode-segmentation" +version = "1.13.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6f5d3c3b1bf09027a88a6bc961fc00497d651009560b5463668dc81b0fa87a8" + +[[package]] +name = "unicode-vo" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b1d386ff53b415b7fe27b50bb44679e2cc4660272694b7b6f3326d8480823a94" + +[[package]] +name = "unicode-width" +version = "0.2.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b4ac048d71ede7ee76d585517add45da530660ef4390e49b098733c6e897f254" + +[[package]] +name = "unicode-xid" +version = "0.2.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ebc1c04c71510c7f702b52b7c350734c9ff1295c464a03335b00bb84fc54f853" + +[[package]] +name = "untrusted" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" + +[[package]] +name = "unty" +version = "0.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6d49784317cd0d1ee7ec5c716dd598ec5b4483ea832a2dced265471cc0f690ae" + +[[package]] +name = "url" +version = "2.5.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed" +dependencies = [ + "form_urlencoded", + "idna", + "percent-encoding", + "serde", + "serde_derive", +] + +[[package]] +name = "urlencoding" +version = "2.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "daf8dba3b7eb870caf1ddeed7bc9d2a049f3cfdfae7cb521b087cc33ae4c49da" + +[[package]] +name = "usvg" +version = "0.47.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d46cf96c5f498d36b7a9693bc6a7075c0bb9303189d61b2249b0dc3d309c07de" +dependencies = [ + "base64", + "data-url", + "flate2", + "fontdb", + "imagesize", + "kurbo", + "log", + "pico-args", + "roxmltree", + "rustybuzz", + "simplecss", + "siphasher", + "strict-num", + "svgtypes", + "tiny-skia-path 0.12.0", + "ttf-parser", + "unicode-bidi", + "unicode-script", + "unicode-vo", + "xmlwriter", +] + +[[package]] +name = "utf8_iter" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be" + +[[package]] +name = "uuid" +version = "1.23.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf80a72845275afea99e7f2b434723d3bc7e38470fcd1c7ed39a599c73319a53" +dependencies = [ + "getrandom 0.4.3", + "js-sys", + "serde_core", + "wasm-bindgen", +] + +[[package]] +name = "v_frame" +version = "0.3.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "666b7727c8875d6ab5db9533418d7c764233ac9c0cff1d469aec8fa127597be2" +dependencies = [ + "aligned-vec", + "num-traits", + "wasm-bindgen", +] + +[[package]] +name = "valuable" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" + +[[package]] +name = "vcpkg" +version = "0.2.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "accd4ea62f7bb7a82fe23066fb0957d48ef677f6eeb8215f372f52e48bb32426" + +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + +[[package]] +name = "vtable" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5ea953f65593feb5287b022b83c35046d1ff49c7417b6f5851a079d8a231fe31" +dependencies = [ + "const-field-offset", + "portable-atomic", + "stable_deref_trait", + "vtable-macro", +] + +[[package]] +name = "vtable-macro" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "482a37f9777480673d3a99c80ac2edc69f92382230440946855fa27ebc47cba6" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "walkdir" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" +dependencies = [ + "same-file", + "winapi-util", +] + +[[package]] +name = "want" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" +dependencies = [ + "try-lock", +] + +[[package]] +name = "wasi" +version = "0.11.1+wasi-snapshot-preview1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" + +[[package]] +name = "wasip2" +version = "1.0.4+wasi-0.2.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b67efb37e106e55ce722a510d6b5f9c17f083e5fc79afc2badeb12cc313d9487" +dependencies = [ + "wit-bindgen", +] + +[[package]] +name = "wasite" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8dad83b4f25e74f184f64c43b150b91efe7647395b42289f38e50566d82855b" + +[[package]] +name = "wasm-bindgen" +version = "0.2.126" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4b067c0c11094aef6b7a801c1e34a26affafdf3d051dba08456b868789aaf9a4" +dependencies = [ + "cfg-if", + "once_cell", + "rustversion", + "wasm-bindgen-macro", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-futures" +version = "0.4.76" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c62df1340f32221cb9c54d6a27b030e3dba64361d4a95bed55f9aacb44da291d" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "wasm-bindgen-macro" +version = "0.2.126" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "167ce5e579f6bcf889c4f7175a8a5a585de84e8ff93976ce393efa5f2837aab1" +dependencies = [ + "quote", + "wasm-bindgen-macro-support", +] + +[[package]] +name = "wasm-bindgen-macro-support" +version = "0.2.126" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f3997c7839262f4ef12cf90b818d6340c18e80f263f1a94bf157d0ec4420380e" +dependencies = [ + "bumpalo", + "proc-macro2", + "quote", + "syn", + "wasm-bindgen-shared", +] + +[[package]] +name = "wasm-bindgen-shared" +version = "0.2.126" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc1b4cb0cc549fcf58d7dfc081778139b3d283a081644e833e84682ad71cea24" +dependencies = [ + "unicode-ident", +] + +[[package]] +name = "wasm-streams" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "15053d8d85c7eccdbefef60f06769760a563c7f0a9d6902a13d35c7800b0ad65" +dependencies = [ + "futures-util", + "js-sys", + "wasm-bindgen", + "wasm-bindgen-futures", + "web-sys", +] + +[[package]] +name = "wayland-backend" +version = "0.3.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2857dd20b54e916ec7253b3d6b4d5c4d7d4ca2c33c2e11c6c76a99bd8744755d" +dependencies = [ + "cc", + "downcast-rs", + "rustix 1.1.4", + "scoped-tls", + "smallvec", + "wayland-sys", +] + +[[package]] +name = "wayland-client" +version = "0.31.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "645c7c96bb74690c3189b5c9cb4ca1627062bb23693a4fad9d8c3de958260144" +dependencies = [ + "bitflags 2.13.0", + "rustix 1.1.4", + "wayland-backend", + "wayland-scanner", +] + +[[package]] +name = "wayland-csd-frame" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "625c5029dbd43d25e6aa9615e88b829a5cad13b2819c4ae129fdbb7c31ab4c7e" +dependencies = [ + "bitflags 2.13.0", + "cursor-icon", + "wayland-backend", +] + +[[package]] +name = "wayland-cursor" +version = "0.31.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4a52d18780be9b1314328a3de5f930b73d2200112e3849ca6cb11822793fb34d" +dependencies = [ + "rustix 1.1.4", + "wayland-client", + "xcursor", +] + +[[package]] +name = "wayland-protocols" +version = "0.32.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23d0c813de3daa2ed6520af85a3bd49b0e722a3078506899aa9686fea58dc4b6" +dependencies = [ + "bitflags 2.13.0", + "wayland-backend", + "wayland-client", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-experimental" +version = "20250721.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "40a1f863128dcaaec790d7b4b396cc9b9a7a079e878e18c47e6c2d2c5a8dcbb1" +dependencies = [ + "bitflags 2.13.0", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-misc" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e9567599ef23e09b8dad6e429e5738d4509dfc46b3b21f32841a304d16b29c8" +dependencies = [ + "bitflags 2.13.0", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-plasma" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b6d8cf1eb2c1c31ed1f5643c88a6e53538129d4af80030c8cabd1f9fa884d91" +dependencies = [ + "bitflags 2.13.0", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-protocols-wlr" +version = "0.3.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb04e52f7836d7c7976c78ca0250d61e33873c34156a2a1fc9474828ec268234" +dependencies = [ + "bitflags 2.13.0", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-scanner", +] + +[[package]] +name = "wayland-scanner" +version = "0.31.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9c324a910fd86ebdc364a3e61ec1f11737d3b1d6c273c0239ee8ff4bc0d24b4a" +dependencies = [ + "proc-macro2", + "quick-xml", + "quote", +] + +[[package]] +name = "wayland-sys" +version = "0.31.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8eab23fefc9e41f8e841df4a9c707e8a8c4ed26e944ef69297184de2785e3be" +dependencies = [ + "dlib", + "log", + "once_cell", + "pkg-config", +] + +[[package]] +name = "web-sys" +version = "0.3.103" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8622dcb61c0bcc9fffa6938bed81210af2da9a7e4a1a834b2e37a59b6dfb6141" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "web-time" +version = "1.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb" +dependencies = [ + "js-sys", + "wasm-bindgen", +] + +[[package]] +name = "webbrowser" +version = "1.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0fc95580916af1e68ff6a7be07446fc5db73ebf71cf092de939bbf5f7e189f72" +dependencies = [ + "core-foundation 0.10.1", + "jni", + "log", + "ndk-context", + "objc2 0.6.4", + "objc2-foundation 0.3.2", + "url", + "web-sys", +] + +[[package]] +name = "webpki-roots" +version = "0.26.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "521bc38abb08001b01866da9f51eb7c5d647a19260e00054a8c7fd5f9e57f7a9" +dependencies = [ + "webpki-roots 1.0.8", +] + +[[package]] +name = "webpki-roots" +version = "1.0.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bf85cb06032201fa7c6f829d7db5a7e5aa45bcc0655327713065f6f0576731bf" +dependencies = [ + "rustls-pki-types", +] + +[[package]] +name = "weezl" +version = "0.1.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a28ac98ddc8b9274cb41bb4d9d4d5c425b6020c50c46f25559911905610b4a88" + +[[package]] +name = "whoami" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5d4a4db5077702ca3015d3d02d74974948aba2ad9e12ab7df718ee64ccd7e97d" +dependencies = [ + "libredox", + "wasite", +] + +[[package]] +name = "winapi-util" +version = "0.1.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" +dependencies = [ + "windows-sys 0.61.2", +] + +[[package]] +name = "windows" +version = "0.62.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "527fadee13e0c05939a6a05d5bd6eec6cd2e3dbd648b9f8e447c6518133d8580" +dependencies = [ + "windows-collections", + "windows-core", + "windows-future", + "windows-numerics", +] + +[[package]] +name = "windows-collections" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23b2d95af1a8a14a3c7367e1ed4fc9c20e0a26e79551b1454d72583c97cc6610" +dependencies = [ + "windows-core", +] + +[[package]] +name = "windows-core" +version = "0.62.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" +dependencies = [ + "windows-implement", + "windows-interface", + "windows-link", + "windows-result", + "windows-strings", +] + +[[package]] +name = "windows-future" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e1d6f90251fe18a279739e78025bd6ddc52a7e22f921070ccdc67dde84c605cb" +dependencies = [ + "windows-core", + "windows-link", + "windows-threading", +] + +[[package]] +name = "windows-implement" +version = "0.60.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "windows-interface" +version = "0.59.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "windows-link" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" + +[[package]] +name = "windows-numerics" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6e2e40844ac143cdb44aead537bbf727de9b044e107a0f1220392177d15b0f26" +dependencies = [ + "windows-core", + "windows-link", +] + +[[package]] +name = "windows-result" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-strings" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.5", +] + +[[package]] +name = "windows-sys" +version = "0.52.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" +dependencies = [ + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets 0.52.6", +] + +[[package]] +name = "windows-sys" +version = "0.61.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows-targets" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9a2fa6e2155d7247be68c096456083145c183cbbbc2764150dda45a87197940c" +dependencies = [ + "windows_aarch64_gnullvm 0.48.5", + "windows_aarch64_msvc 0.48.5", + "windows_i686_gnu 0.48.5", + "windows_i686_msvc 0.48.5", + "windows_x86_64_gnu 0.48.5", + "windows_x86_64_gnullvm 0.48.5", + "windows_x86_64_msvc 0.48.5", +] + +[[package]] +name = "windows-targets" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" +dependencies = [ + "windows_aarch64_gnullvm 0.52.6", + "windows_aarch64_msvc 0.52.6", + "windows_i686_gnu 0.52.6", + "windows_i686_gnullvm", + "windows_i686_msvc 0.52.6", + "windows_x86_64_gnu 0.52.6", + "windows_x86_64_gnullvm 0.52.6", + "windows_x86_64_msvc 0.52.6", +] + +[[package]] +name = "windows-threading" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3949bd5b99cafdf1c7ca86b43ca564028dfe27d66958f2470940f73d86d75b37" +dependencies = [ + "windows-link", +] + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" + +[[package]] +name = "windows_i686_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" + +[[package]] +name = "windows_i686_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" + +[[package]] +name = "winit" +version = "0.30.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a6755fa58a9f8350bd1e472d4c3fcc25f824ec358933bba33306d0b63df5978d" +dependencies = [ + "ahash", + "android-activity", + "atomic-waker", + "bitflags 2.13.0", + "block2 0.5.1", + "bytemuck", + "calloop 0.13.0", + "cfg_aliases", + "concurrent-queue", + "core-foundation 0.9.4", + "core-graphics", + "cursor-icon", + "dpi", + "js-sys", + "libc", + "memmap2", + "ndk", + "objc2 0.5.2", + "objc2-app-kit 0.2.2", + "objc2-foundation 0.2.2", + "objc2-ui-kit 0.2.2", + "orbclient", + "percent-encoding", + "pin-project", + "raw-window-handle", + "redox_syscall 0.4.1", + "rustix 0.38.44", + "sctk-adwaita", + "smithay-client-toolkit 0.19.2", + "smol_str 0.2.2", + "tracing", + "unicode-segmentation", + "wasm-bindgen", + "wasm-bindgen-futures", + "wayland-backend", + "wayland-client", + "wayland-protocols", + "wayland-protocols-plasma", + "web-sys", + "web-time", + "windows-sys 0.52.0", + "x11-dl", + "x11rb", + "xkbcommon-dl", +] + +[[package]] +name = "winnow" +version = "1.0.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0592e1c9d151f854e6fd382574c3a0855250e1d9b2f99d9281c6e6391af352f1" +dependencies = [ + "memchr", +] + +[[package]] +name = "wiremock" +version = "0.6.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08db1edfb05d9b3c1542e521aea074442088292f00b5f28e435c714a98f85031" +dependencies = [ + "assert-json-diff", + "base64", + "deadpool", + "futures", + "http", + "http-body-util", + "hyper", + "hyper-util", + "log", + "once_cell", + "regex", + "serde", + "serde_json", + "tokio", + "url", +] + +[[package]] +name = "wit-bindgen" +version = "0.57.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" + +[[package]] +name = "write-fonts" +version = "0.48.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb731d4c4d93eacc69a1ad2f270f905788a98e4a3438267bcafbe08d3431c8d8" +dependencies = [ + "font-types", + "indexmap", + "kurbo", + "log", + "read-fonts", +] + +[[package]] +name = "writeable" +version = "0.6.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4" + +[[package]] +name = "x11-clipboard" +version = "0.9.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "662d74b3d77e396b8e5beb00b9cad6a9eccf40b2ef68cc858784b14c41d535a3" +dependencies = [ + "libc", + "x11rb", +] + +[[package]] +name = "x11-dl" +version = "2.21.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "38735924fedd5314a6e548792904ed8c6de6636285cb9fec04d5b1db85c1516f" +dependencies = [ + "libc", + "once_cell", + "pkg-config", +] + +[[package]] +name = "x11rb" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9993aa5be5a26815fe2c3eacfc1fde061fc1a1f094bf1ad2a18bf9c495dd7414" +dependencies = [ + "as-raw-xcb-connection", + "gethostname", + "libc", + "libloading", + "once_cell", + "rustix 1.1.4", + "x11rb-protocol", +] + +[[package]] +name = "x11rb-protocol" +version = "0.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ea6fc2961e4ef194dcbfe56bb845534d0dc8098940c7e5c012a258bfec6701bd" + +[[package]] +name = "xattr" +version = "1.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "32e45ad4206f6d2479085147f02bc2ef834ac85886624a23575ae137c8aa8156" +dependencies = [ + "libc", + "rustix 1.1.4", +] + +[[package]] +name = "xcursor" +version = "0.3.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bec9e4a500ca8864c5b47b8b482a73d62e4237670e5b5f1d6b9e3cae50f28f2b" + +[[package]] +name = "xkbcommon" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a974f48060a14e95705c01f24ad9c3345022f4d97441b8a36beb7ed5c4a02d" +dependencies = [ + "libc", + "memmap2", + "xkeysym", +] + +[[package]] +name = "xkbcommon-dl" +version = "0.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d039de8032a9a8856a6be89cea3e5d12fdd82306ab7c94d74e6deab2460651c5" +dependencies = [ + "bitflags 2.13.0", + "dlib", + "log", + "once_cell", + "xkeysym", +] + +[[package]] +name = "xkeysym" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b9cc00251562a284751c9973bace760d86c0276c471b4be569fe6b068ee97a56" + +[[package]] +name = "xml-rs" +version = "0.8.28" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3ae8337f8a065cfc972643663ea4279e04e7256de865aa66fe25cec5fb912d3f" + +[[package]] +name = "xmlwriter" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ec7a2a501ed189703dba8b08142f057e887dfc4b2cc4db2d343ac6376ba3e0b9" + +[[package]] +name = "xpost-archiver" +version = "0.1.0" +dependencies = [ + "anyhow", + "bytes", + "chrono", + "csv", + "directories", + "futures-util", + "keyring", + "pretty_assertions", + "reqwest", + "rfd", + "rust_xlsxwriter", + "serde", + "serde_json", + "sha2", + "slint", + "slint-build", + "sqlx", + "tempfile", + "thiserror 2.0.18", + "tokio", + "tokio-util", + "tracing", + "tracing-appender", + "tracing-subscriber", + "url", + "uuid", + "wiremock", +] + +[[package]] +name = "y4m" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a5a4b21e1a62b67a2970e6831bc091d7b87e119e7f9791aef9702e3bef04448" + +[[package]] +name = "yansi" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cfe53a6657fd280eaa890a3bc59152892ffa3e30101319d168b781ed6529b049" + +[[package]] +name = "yazi" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e01738255b5a16e78bbb83e7fbba0a1e7dd506905cfc53f4622d89015a03fbb5" + +[[package]] +name = "yeslogic-fontconfig-sys" +version = "6.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1d8b8abf912b9a29ff112e1671c97c33636903d13a69712037190e6805af4f76" +dependencies = [ + "dlib", + "once_cell", + "pkg-config", +] + +[[package]] +name = "yoke" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "709fe23a0424b6a435d82152b1bd3fdfb0833487d5fa90d05d42762a9891fef5" +dependencies = [ + "stable_deref_trait", + "yoke-derive", + "zerofrom", +] + +[[package]] +name = "yoke-derive" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "synstructure", +] + +[[package]] +name = "zbus" +version = "5.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a28b97f866896a4be7aefd2b5a8e01bb6773d19a775d54ab28b4d094b9a4480e" +dependencies = [ + "async-broadcast", + "async-executor", + "async-io", + "async-lock", + "async-process", + "async-recursion", + "async-task", + "async-trait", + "blocking", + "enumflags2", + "event-listener", + "futures-core", + "futures-lite", + "hex", + "libc", + "ordered-stream", + "rustix 1.1.4", + "serde", + "serde_repr", + "tracing", + "uds_windows", + "uuid", + "windows-sys 0.61.2", + "winnow", + "zbus_macros", + "zbus_names", + "zvariant", +] + +[[package]] +name = "zbus-lockstep" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6998de05217a084b7578728a9443d04ea4cd80f2a0839b8d78770b76ccd45863" +dependencies = [ + "zbus_xml", + "zvariant", +] + +[[package]] +name = "zbus-lockstep-macros" +version = "0.5.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10da05367f3a7b7553c8cdf8fa91aee6b64afebe32b51c95177957efc47ca3a0" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "zbus-lockstep", + "zbus_xml", + "zvariant", +] + +[[package]] +name = "zbus_macros" +version = "5.17.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5e05ad887425eecf5e8384dc2406a4a9313eb73468712fc1cdea362eb4fe0469" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn", + "zbus_names", + "zvariant", + "zvariant_utils", +] + +[[package]] +name = "zbus_names" +version = "4.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1039ca249fee9559680f3a9f05b55e0761fee51af4f6c1e7d8c1f31e549721d2" +dependencies = [ + "serde", + "winnow", + "zvariant", +] + +[[package]] +name = "zbus_xml" +version = "5.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "59ab0513c0a66a60a8718d5ad712a5094845a20d95b5c1c81e2bd8e904a52b4f" +dependencies = [ + "serde", + "winnow", + "zbus_names", + "zvariant", +] + +[[package]] +name = "zeno" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6df3dc4292935e51816d896edcd52aa30bc297907c26167fec31e2b0c6a32524" + +[[package]] +name = "zerocopy" +version = "0.8.54" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b7cbbc0a705a0fd05cc3676525980d2bf5a9bc4adac6d6475209a7887cf59d19" +dependencies = [ + "zerocopy-derive", +] + +[[package]] +name = "zerocopy-derive" +version = "0.8.54" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2e817b7b52d0c7358d3246da9d69935ebb18116b2b102b4230dac079b4862f5" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zerofrom" +version = "0.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0ec05a11813ea801ff6d75110ad09cd0824ddba17dfe17128ea0d5f68e6c5272" +dependencies = [ + "zerofrom-derive", +] + +[[package]] +name = "zerofrom-derive" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1" +dependencies = [ + "proc-macro2", + "quote", + "syn", + "synstructure", +] + +[[package]] +name = "zeroize" +version = "1.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e13c156562582aa81c60cb29407084cdb54c4164760106ab78e6c5b0858cf64e" + +[[package]] +name = "zerotrie" +version = "0.2.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0f9152d31db0792fa83f70fb2f83148effb5c1f5b8c7686c3459e361d9bc20bf" +dependencies = [ + "displaydoc", + "yoke", + "zerofrom", + "zerovec", +] + +[[package]] +name = "zerovec" +version = "0.11.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90f911cbc359ab6af17377d242225f4d75119aec87ea711a880987b18cd7b239" +dependencies = [ + "serde", + "yoke", + "zerofrom", + "zerovec-derive", +] + +[[package]] +name = "zerovec-derive" +version = "0.11.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "625dc425cab0dca6dc3c3319506e6593dcb08a9f387ea3b284dbd52a92c40555" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + +[[package]] +name = "zip" +version = "4.6.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "caa8cd6af31c3b31c6631b8f483848b91589021b28fffe50adada48d4f4d2ed1" +dependencies = [ + "arbitrary", + "crc32fast", + "flate2", + "indexmap", + "memchr", + "zopfli", +] + +[[package]] +name = "zlib-rs" +version = "0.6.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b142a20ec14a91d5bc708c1dc21b080c550113d8aa77afa29635673a65dd02c5" + +[[package]] +name = "zmij" +version = "1.0.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b8848ee67ecc8aedbaf3e4122217aff892639231befc6a1b58d29fff4c2cabaa" + +[[package]] +name = "zopfli" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f05cd8797d63865425ff89b5c4a48804f35ba0ce8d125800027ad6017d2b5249" +dependencies = [ + "bumpalo", + "crc32fast", + "log", + "simd-adler32", +] + +[[package]] +name = "zune-core" +version = "0.5.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "cb8a0807f7c01457d0379ba880ba6322660448ddebc890ce29bb64da71fb40f9" + +[[package]] +name = "zune-inflate" +version = "0.2.54" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "73ab332fe2f6680068f3582b16a24f90ad7096d5d39b974d1c0aff0125116f02" +dependencies = [ + "simd-adler32", +] + +[[package]] +name = "zune-jpeg" +version = "0.5.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "27bc9d5b815bc103f142aa054f561d9187d191692ec7c2d1e2b4737f8dbd7296" +dependencies = [ + "zune-core", +] + +[[package]] +name = "zvariant" +version = "5.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7cf057bb00bf5c9ad77abb6147b0ca4818236a1858416e9d988e40d6322fefa7" +dependencies = [ + "endi", + "enumflags2", + "serde", + "url", + "winnow", + "zvariant_derive", + "zvariant_utils", +] + +[[package]] +name = "zvariant_derive" +version = "5.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8118ca6bda77bfc0ab51d660db0c955f2505eef854c9a449435bccb616933b31" +dependencies = [ + "proc-macro-crate", + "proc-macro2", + "quote", + "syn", + "zvariant_utils", +] + +[[package]] +name = "zvariant_utils" +version = "3.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "90cb9383f9b45290407a1258b202d3f8f01db719eb60b4e4055c6375af4fc7c7" +dependencies = [ + "proc-macro2", + "quote", + "serde", + "syn", + "winnow", +] + diff --git a/XPostArchiver-clean-upload-20260711-225630/Cargo.toml b/XPostArchiver-clean-upload-20260711-225630/Cargo.toml new file mode 100644 index 0000000000000000000000000000000000000000..016c239d8b659968073641ca2a95fe80fbf3b38f --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/Cargo.toml @@ -0,0 +1,39 @@ +[package] +name = "xpost-archiver" +version = "0.1.0" +edition = "2024" +build = "build.rs" + +[dependencies] +slint = "1.13" +tokio = { version = "1.47", features = ["rt-multi-thread", "macros", "sync", "time", "fs"] } +tokio-util = { version = "0.7", features = ["rt"] } +reqwest = { version = "0.12", default-features = false, features = ["json", "stream", "rustls-tls"] } +serde = { version = "1.0", features = ["derive"] } +serde_json = "1.0" +sqlx = { version = "0.8", default-features = false, features = ["runtime-tokio-rustls", "sqlite", "migrate", "macros", "chrono", "json"] } +rfd = "0.15" +keyring = "3.6" +tracing = "0.1" +tracing-subscriber = { version = "0.3", features = ["env-filter"] } +tracing-appender = "0.2" +thiserror = "2.0" +anyhow = "1.0" +chrono = { version = "0.4", features = ["serde"] } +url = "2.5" +uuid = { version = "1.18", features = ["v4", "serde"] } +rust_xlsxwriter = "0.90" +csv = "1.3" +sha2 = "0.10" +directories = "6.0" +bytes = "1.10" +futures-util = "0.3" + +[build-dependencies] +slint-build = "1.13" + +[dev-dependencies] +tempfile = "3.21" +wiremock = "0.6" +pretty_assertions = "1.4" + diff --git a/XPostArchiver-clean-upload-20260711-225630/DECISIONS.md b/XPostArchiver-clean-upload-20260711-225630/DECISIONS.md new file mode 100644 index 0000000000000000000000000000000000000000..6217776ceab47b0f480c2f76753d30eab51752e4 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/DECISIONS.md @@ -0,0 +1,30 @@ +# 技术决策记录 + +## ADR-001:纯 Rust 桌面架构 + +项目采用 Rust stable、Edition 2024、Slint、Tokio、reqwest、SQLx、SQLite、keyring、tracing 和 Inno Setup。不得引入 Python、JavaScript、TypeScript、Node.js、Electron、Tauri、WebView、Docker、云数据库或浏览器自动化。 + +## ADR-002:Slint 作为桌面界面 + +Slint 提供纯 Rust 桌面 UI,避免网页前端栈。界面运行在主线程;后台任务通过消息通道或 Slint 安全事件循环返回结果,不从后台线程直接修改控件。 + +## ADR-003:SQLx 运行时查询与迁移 + +使用 SQLite + SQLx migrations。第一版优先使用运行时 SQL,避免构建期依赖用户数据库或 SQLx 离线元数据。迁移前必须备份用户数据库。 + +## ADR-004:仅使用官方允许的 X API + +不模拟登录,不收集账号密码或 Cookie,不绕过验证码、保护账号、付费权限、访问控制和频率限制。“尽可能完整”仅指 API 当前实际可访问并返回的范围。 + +## ADR-005:严格分离开发、安装和数据目录 + +正式程序不得依赖开发路径。安装目录仅放程序文件;数据库、媒体、导出、日志和备份由用户分别选择。配置只保存路径和非敏感偏好,凭据由 keyring 保存。 + +## ADR-006:数据语义 + +所有 X ID 按字符串保存;内部时间统一使用 UTC;接口未提供的数值使用 NULL,不用 0 冒充未知。原始 JSON 用于兼容和审计,但默认日志不记录完整响应。 + +## ADR-007:后台任务和受控写入 + +Tokio 运行在后台工作线程。网络、分页、导出和媒体下载不阻塞 Slint 主线程;SQLite 使用受控写入队列或单写者策略,防止大量任务无序写入。 + diff --git a/XPostArchiver-clean-upload-20260711-225630/PUBLIC_SAFETY_NOTES.md b/XPostArchiver-clean-upload-20260711-225630/PUBLIC_SAFETY_NOTES.md new file mode 100644 index 0000000000000000000000000000000000000000..f3eb731dccde9bab46b92295f9752fdc93b34955 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/PUBLIC_SAFETY_NOTES.md @@ -0,0 +1,8 @@ +# Public Safety Notes + +This project is designed to use the official X API only. It does not include credentials, cookies, databases, local archives, logs, or media files. + +Bearer Tokens are expected to be stored by the running app in the operating system keyring, not in this source package. + +Do not upload your own generated databases, archived media, logs, or keyring exports. + diff --git a/XPostArchiver-clean-upload-20260711-225630/README.md b/XPostArchiver-clean-upload-20260711-225630/README.md new file mode 100644 index 0000000000000000000000000000000000000000..bbe68915f96f4cd7c161acbe27cc211ee2b0f9ce --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/README.md @@ -0,0 +1,30 @@ +# X公开帖子归档器 + +内部英文标识:`XPostArchiver`。 + +这是纯本地 Windows 桌面软件项目,采用 Rust + Slint。软件计划通过 X 官方允许的 API,在当前权限、额度和平台可访问范围内尽可能归档公开帖子。 + +> 本软件会在当前X API权限、账户额度和平台可访问范围内,尽可能完整地获取公开内容。实际可获取数量和时间范围由X平台返回结果决定。 + +## 技术路线 + +- Rust stable,Edition 2024 +- Slint 桌面界面 +- Tokio 后台运行时 +- reqwest + rustls 网络请求 +- SQLx + SQLite + SQLx migrations +- keyring 保存 Windows 凭据 +- tracing 日志 +- rust_xlsxwriter、csv、serde_json 导出 +- Inno Setup 安装程序 + +## 目录边界 + +- 开发源码目录:``,仅供开发,不得写死到正式程序。 +- 安装目录:由最终用户在安装时选择。 +- 数据目录:数据库、媒体、导出、日志和备份分别由用户选择,禁止默认混入开发目录或安装目录。 + +## 当前状态 + +第零阶段进行中。Rust 工具链、Cargo、MSVC Build Tools 和 Windows SDK 已安装;最小 Slint 窗口和基础架构正在验收。 + diff --git a/XPostArchiver-clean-upload-20260711-225630/UPLOAD_MANIFEST.md b/XPostArchiver-clean-upload-20260711-225630/UPLOAD_MANIFEST.md new file mode 100644 index 0000000000000000000000000000000000000000..fe919e32342a736a74e6054228120a29b02a9f07 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/UPLOAD_MANIFEST.md @@ -0,0 +1,29 @@ +# Clean Upload Package Manifest + +This package is intended for uploading to Hugging Face or another public code hosting platform. + +Included: + +- Rust source code under `src/` +- Slint UI under `ui/` +- SQLite migrations under `migrations/` +- Tests under `tests/` +- Public documentation under `docs/` +- Cargo project files +- Public changelog and version history + +Excluded: + +- `.git/` +- `target/` +- `backups/` +- local release staging folders +- local database files +- logs +- media archives +- system keyring credentials +- local environment reports +- machine-specific project state/inventory files + +Before public release, review README and docs once more for wording and platform policy fit. + diff --git a/XPostArchiver-clean-upload-20260711-225630/VERSION_HISTORY.md b/XPostArchiver-clean-upload-20260711-225630/VERSION_HISTORY.md new file mode 100644 index 0000000000000000000000000000000000000000..d0e4750f31fbb56204ea4e45c1459578e16eba7c --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/VERSION_HISTORY.md @@ -0,0 +1,31 @@ +# Version History + +This file is generated for the clean upload package. It keeps commit hashes and public commit messages only. The `.git` directory is intentionally not included, so local author identity and repository metadata are not packaged. + +- `c87d83e` chore: initialize Rust and Slint application architecture +- `9d0fe80` feat: add database selection and migration foundation +- `9a060a2` feat: add configurable data directories +- `465a24c` feat: warn for system drive data paths +- `e565f9e` feat: add database maintenance actions +- `97b3c98` feat: add first-run configuration flow +- `dcd036c` feat: add local X API credential storage +- `2f2365f` feat: validate X API bearer token +- `90c0a0b` feat: add public account lookup +- `977b16d` feat: add crawl task creation skeleton +- `222e9fb` feat: fetch first page of public posts +- `39c8fc4` feat: continue public post pagination +- `eb2e698` feat: store public post media metadata +- `78f25df` feat: download archived media files +- `8f6ad1b` feat: add automatic paged crawl skeleton +- `485e471` feat: run automatic crawl in background +- `19031e1` feat: add automatic crawl stop and limits +- `7e2b770` feat: persist stopped crawl status +- `1a7ce21` feat: show recent crawl tasks +- `392a4c8` feat: improve resizable window constraints +- `f4bc9f6` feat: autofill selected crawl task id +- `e8e4fca` feat: mask bearer token input +- `39c3741` feat: show crawl status labels and errors +- `d46776e` feat: preview and export archived posts +- `c1676f0` feat: retry failed media and guard auto crawl +- `57275ed` docs: add maintenance and optimization notes + diff --git a/XPostArchiver-clean-upload-20260711-225630/build.rs b/XPostArchiver-clean-upload-20260711-225630/build.rs new file mode 100644 index 0000000000000000000000000000000000000000..9e3412561644dca89ee85e6ae5cbcfad9813631a --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/build.rs @@ -0,0 +1,4 @@ +fn main() { + slint_build::compile("ui/app-window.slint").expect("failed to compile Slint UI"); +} + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/01-\351\234\200\346\261\202\350\247\204\346\240\274\350\257\264\346\230\216.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/01-\351\234\200\346\261\202\350\247\204\346\240\274\350\257\264\346\230\216.md" new file mode 100644 index 0000000000000000000000000000000000000000..8820d7912c67e11185492851cae49e0ae9e81f06 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/01-\351\234\200\346\261\202\350\247\204\346\240\274\350\257\264\346\230\216.md" @@ -0,0 +1,38 @@ +# 需求规格说明 + +## 软件目标 + +用户输入 `@username`、用户名或 X 账号主页链接,经确认后通过 X 官方允许的 API 创建任务,把接口实际返回的公开帖子保存到用户选择的 SQLite 数据库,并在本地浏览、筛选和导出。 + +## 支持范围 + +- 查询并确认公开账号。 +- 保存原创、回复、转发、引用及其原始引用关系。 +- 保存接口返回的正文、长文信息、互动指标和媒体元数据。 +- 分页、去重、断点续传、增量更新、暂停、继续和停止。 +- 可选媒体下载及失败重试。 +- 本地搜索、筛选和排序。 +- 导出 Excel、CSV、JSON、JSON Lines、Markdown 和 TXT。 + +## 不能保证 + +软件不保证获得已删除、受保护、无权访问、被平台隐藏、超出 API 权限或额度、接口没有返回的帖子和媒体,也不保证取得账号创建以来绝对完整的历史内容。 + +界面统一显示: + +> 本软件会在当前X API权限、账户额度和平台可访问范围内,尽可能完整地获取公开内容。实际可获取数量和时间范围由X平台返回结果决定。 + +## 核心约束 + +- 用户确认目标账号后才能采集。 +- 不绕过登录、验证码、付费、访问控制和频率限制。 +- 不要求 X 账号密码,不窃取 Cookie。 +- X ID 必须按字符串保存;时间内部统一为 UTC。 +- 未返回字段使用空值,并区分明确为 0、未提供、权限不足和解析失败。 +- 数据库路径失效时不得自动建立替代空库。 +- 正式程序不得依赖开发目录。 + +## 验收原则 + +每阶段必须运行相关测试并实际启动检查。测试失败、环境缺失或未实际运行时,不得宣称阶段完成或软件正常运行。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/02-\346\212\200\346\234\257\346\236\266\346\236\204.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/02-\346\212\200\346\234\257\346\236\266\346\236\204.md" new file mode 100644 index 0000000000000000000000000000000000000000..fa01123ec82662b9c59c2cc5dcbdc3928c5c5d31 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/02-\346\212\200\346\234\257\346\236\266\346\236\204.md" @@ -0,0 +1,33 @@ +# 技术架构 + +## 技术栈 + +项目使用 Rust stable、Edition 2024、Slint、Tokio、reqwest + rustls、serde、SQLx + SQLite + SQLx migrations、rfd、keyring、tracing、thiserror、anyhow、chrono、url、uuid、rust_xlsxwriter、csv、sha2、directories、Inno Setup。 + +## 模块分层 + +- `ui`:Slint 界面文件。 +- `ui_bridge`:Rust 与 Slint 的回调、模型和通知桥接。 +- `api`:官方 X API 客户端、认证、账号、帖子、分页、限流、响应和错误分类。 +- `database`:SQLx 连接、迁移、仓储、账号、帖子、任务、断点和媒体访问。 +- `domain`:账号、帖子、媒体、采集任务和断点领域模型。 +- `tasks`:Tokio 运行时、命令、事件、采集工作者、单一数据库写入任务、媒体工作者和取消控制。 +- `services`:账号、采集、媒体、数据库和导出应用服务。 +- `exporters`:Excel、CSV、JSON、Markdown、TXT。 +- `config`:非敏感设置和路径。 +- `security`:Windows 凭据保存和脱敏。 +- `logging`:tracing 日志和轮转。 +- `utils`:文件名、时间、URL 和磁盘工具。 + +## 线程与异步 + +Slint 界面运行在主线程。Tokio 后台运行时处理 HTTP、分页、媒体下载、导出和数据库写入命令。后台任务不得直接修改 Slint 控件;必须通过消息通道或 Slint 安全事件循环返回结果。 + +## 数据库并发 + +使用 SQLx 连接用户选择的 SQLite 文件。采用多个受控读取连接和单一数据库写入任务。每页帖子在事务中保存,提交成功后才更新断点。 + +## 禁止方案 + +不得引入覆盖指令禁止的跨语言脚本栈、网页前端栈、浏览器壳、浏览器自动化、远程服务器、云数据库或容器化方案。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/03-\346\225\260\346\215\256\345\272\223\350\256\276\350\256\241.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/03-\346\225\260\346\215\256\345\272\223\350\256\276\350\256\241.md" new file mode 100644 index 0000000000000000000000000000000000000000..e2618db4622fe62870a918b862f904428dfbbfad --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/03-\346\225\260\346\215\256\345\272\223\350\256\276\350\256\241.md" @@ -0,0 +1,52 @@ +# 数据库设计 + +## 原则 + +数据库由用户新建或选择。使用 SQLite、SQLx 和 SQLx migrations。迁移前创建备份,失败时保留原数据库。X ID 使用 TEXT,时间统一存 UTC,未知指标使用 NULL,API 凭据绝不入库。 + +## 迁移 + +迁移文件保存在 `migrations`。构建软件时不得要求用户数据库存在。第一版优先使用 SQLx 运行时查询接口,不依赖构建期数据库连接或离线查询元数据。 + +## 数据表 + +### app_metadata + +保存数据库创建时间、结构版本、应用版本、最后打开时间等非敏感数据库级信息。 + +### accounts + +保存 `x_user_id`(唯一)、用户名、显示名、简介、头像、X 创建时间、protected、verified、粉丝/关注/帖子数量、首次和最后发现时间、raw_json。 + +### posts + +保存 `x_post_id`(唯一)、作者账号 ID/用户名/显示名、正文、发布时间、原始链接、语言、conversation_id、回复对象、帖子分类、长文标记、可空互动指标、媒体标志、首次和最后采集时间、数据来源、来源任务及 raw_json。 + +### post_references + +保存 source_post_id、reference_type 和 target_x_post_id。类型包括 `replied_to`、`quoted`、`reposted`,允许一条帖子存在多种关系。 + +### media 与 post_media + +媒体表保存 media_key、类型、原始/预览 URL、相对媒体根目录路径、MIME、文件大小、宽高、时长、下载状态、时间、校验和、错误及 raw_json;关联表保存帖子、媒体和显示顺序。 + +### crawl_jobs + +保存目标、任务模式、日期、数量上限、类型开关、媒体开关、状态、时间和统计。状态至少包括 pending、running、pausing、paused、completed、completed_with_warnings、failed、cancelled、rate_limited、quota_exhausted。 + +### crawl_checkpoints + +保存任务、分页令牌、最早/最新帖子 ID 和时间、成功页数、最后成功请求时间和更新时间。 + +### fetch_errors + +保存任务、阶段、脱敏请求标识、错误类别、HTTP 状态、消息、是否可重试、重试次数、创建和解决时间。 + +## 去重、分页和事务 + +以 `x_post_id` 唯一约束和 upsert 双重去重。重复返回时更新接口实际提供的字段,不用缺失字段覆盖已有有效值。每页数据成功提交后才更新断点;失败回滚本页,不破坏此前页面。 + +## 打开、检查和迁移 + +检查 SQLite 文件头、读写权限、完整性、迁移版本和必要数据表。迁移前复制备份;失败则关闭连接并保留原库。不得覆盖同名数据库或在旧路径失效时创建替代空库。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/04-\347\225\214\351\235\242\344\270\216\344\272\244\344\272\222\350\256\276\350\256\241.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/04-\347\225\214\351\235\242\344\270\216\344\272\244\344\272\222\350\256\276\350\256\241.md" new file mode 100644 index 0000000000000000000000000000000000000000..a8d9d0d2ae1b6528354ccece8627fe1604b459f6 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/04-\347\225\214\351\235\242\344\270\216\344\272\244\344\272\222\350\256\276\350\256\241.md" @@ -0,0 +1,30 @@ +# 界面与交互设计 + +## 首次启动向导 + +1. 欢迎页说明 API 权限、额度和可访问范围限制。 +2. 新建数据库、打开已有数据库或退出。无有效数据库时禁止采集。 +3. 选择媒体目录,或暂不下载媒体。 +4. 分别设置导出、日志、临时和备份目录。 +5. 设置 Bearer Token 等必要凭据,提供保存、测试、删除和状态显示,不完整展示已保存密钥。 +6. 汇总数据库、各目录、API 状态、写权限和磁盘空间。 + +新建数据库自动补 `.db`,同名文件存在时不得覆盖。打开已有库需要检查 SQLite 有效性、读写权限、结构版本、必要表和完整性;迁移先备份,失败恢复。 + +## 页面 + +- 首页/新建任务:账号输入、查询、预览、范围、日期、数量、类型、媒体选项、当前数据库和 API 状态。 +- 任务管理:状态、页数、接收/新增/更新/重复、媒体数量、当前日期和最近错误;支持开始、暂停、继续、停止、重试、报告和日志。总量未知时不显示虚假百分比。 +- 帖子数据库:账号、关键词、日期、类型、媒体和互动指标筛选;分页列表、详情和多种排序。 +- 数据库管理:新建、打开、切换、备份、检查、统计、迁移和打开文件夹。 +- 导出:当前筛选、账号、任务、日期范围或勾选项。 +- 设置:API、数据库、媒体、导出、日志、备份、网络重试、界面、隐私和关于。 + +## 账号输入 + +去除首尾空格和开头 `@`;解析 x.com / www.x.com 主页链接并去掉查询参数和多余斜杠;拒绝帖子链接及明显无效用户名。查询只显示预览,用户点击确认后才创建任务。 + +## 路径失效 + +上次数据库不可访问时,提示用户连接对应磁盘或重新选择文件;不自动建空库、不改用系统盘、不删除路径记录,也不武断声称数据丢失。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/05-X\346\216\245\345\217\243\344\270\216\346\235\203\351\231\220\350\257\264\346\230\216.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/05-X\346\216\245\345\217\243\344\270\216\346\235\203\351\231\220\350\257\264\346\230\216.md" new file mode 100644 index 0000000000000000000000000000000000000000..ef68863829cca3b0fc6024cb8c9d3c8837686376 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/05-X\346\216\245\345\217\243\344\270\216\346\235\203\351\231\220\350\257\264\346\230\216.md" @@ -0,0 +1,26 @@ +# X接口与权限说明 + +## 官方接口 + +软件只使用 X 官方当前允许的 API 和用户自行申请的凭据。第一版至少支持 Bearer Token。具体 endpoint、字段、分页令牌、历史范围和价格在实现时必须依据当时官方文档核验,不能把易变化的套餐能力写成永久承诺。 + +## 权限、额度和费用 + +不同 API 产品和账号层级可能具有不同额度、历史范围、字段和媒体 URL 权限,并可能收费。401 通常表示认证失败;403 可能是权限、保护状态或产品限制;404 表示不存在或不可见;429 表示频率限制;额度耗尽时必须停止请求并报告。 + +## 可获取边界 + +软件不保证取得已删除、受保护、隐藏、超历史范围、超额度、无权限或接口未返回的数据和媒体源文件。“尽可能完整”只是沿当前接口分页获取实际可访问的公开内容。 + +当权限不足时显示: + +> 当前接口权限无法继续获取更早的数据。本次任务已经保存所有实际返回的内容,但不能据此保证账号历史内容绝对完整。 + +## 合规要求 + +不绕过登录、验证码、付费、保护账号、访问控制和频率限制;不轮换账号或密钥规避限制;不使用浏览器自动化;不索取账号密码;不窃取 Cookie。 + +## 错误与重试 + +只重试可能恢复的错误,使用有限指数退避并尊重 Retry-After 等限流信息。401、403 不无限重试。任务报告应说明分页末尾、日期/数量停止、限流、额度、权限及仍可能缺失的内容。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/06-\345\256\211\350\243\205\344\270\216\346\225\260\346\215\256\347\233\256\345\275\225\350\256\276\350\256\241.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/06-\345\256\211\350\243\205\344\270\216\346\225\260\346\215\256\347\233\256\345\275\225\350\256\276\350\256\241.md" new file mode 100644 index 0000000000000000000000000000000000000000..fedee01238560d5c2e9d47b02524c1b04a4fd3e3 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/06-\345\256\211\350\243\205\344\270\216\346\225\260\346\215\256\347\233\256\345\275\225\350\256\276\350\256\241.md" @@ -0,0 +1,28 @@ +# 安装与数据目录设计 + +## 三类目录 + +- 开发目录固定为 ``,只保存源码、测试、脚本、文档和构建结果;正式程序不得依赖或写死该路径。 +- 安装目录由用户在安装程序中选择,只保存 EXE、DLL、Qt 资源、图标、必要资源和卸载程序。 +- 数据目录由用户分别选择数据库、媒体、导出、日志、临时下载和备份位置,不默认写入开发目录或安装目录。 + +## 配置与凭据 + +使用 platformdirs 对应的 Windows 用户配置目录保存上次数据库路径、媒体/导出/日志/备份目录、界面设置和非敏感偏好。API 凭据使用 Windows 凭据管理能力和 keyring,不得写入配置文件、SQLite 或日志。 + +## 路径兼容 + +使用 pathlib 与 Qt 路径 API,支持中文、空格、不同盘符、外接硬盘和较长目录名。媒体记录保存相对于媒体根目录的路径,并允许用户移动后重新绑定。磁盘断开时保留原设置,禁止自动转到系统盘或创建空库。 + +## 系统盘提醒 + +安装时和首次选择数据库或媒体目录时检测 Windows 系统盘。若选择系统盘,建议改用空间充足的非系统盘,但允许继续;数据位置提醒可选择不再提示,避免反复弹窗。推荐安装目录不得是开发目录。 + +## 卸载和升级 + +卸载默认只删除程序文件,并明确说明不会删除用户数据库、媒体、导出和备份;可以让用户选择删除小型设置,但不得默认删除数据。升级保留路径、凭据和媒体;数据库结构升级前先备份,失败恢复。 + +## 便携版 + +便携版仍允许选择独立数据库和媒体目录,不把“便携”解释为所有数据必须放在程序目录。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/07-\346\265\213\350\257\225\346\226\271\346\241\210.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/07-\346\265\213\350\257\225\346\226\271\346\241\210.md" new file mode 100644 index 0000000000000000000000000000000000000000..e5e3891c51751402bb50201782c68cbf700ff447 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/07-\346\265\213\350\257\225\346\226\271\346\241\210.md" @@ -0,0 +1,45 @@ +# 测试方案 + +## 基础命令 + +每个阶段至少执行: + +```powershell +cargo fmt --all -- --check +cargo clippy --all-targets --all-features -- -D warnings +cargo test --all +cargo check +``` + +完成可运行阶段后还必须执行: + +```powershell +cargo run +``` + +发布前执行: + +```powershell +cargo build --release +``` + +## 单元测试 + +覆盖用户名规范化、X 主页链接解析和帖子链接拒绝、帖子分类、ID 去重、UTC/本地时间转换、路径处理、Windows 文件名清理、分页断点、API 错误分类、敏感信息脱敏、各导出格式和数据库迁移。 + +## 数据库测试 + +覆盖新建、打开、拒绝无效库、重复帖子 upsert、字段更新、断点恢复、迁移前备份、迁移失败回滚、未知值与 0 区分、长 ID 字符串保存。 + +## 界面测试 + +覆盖首次向导、无数据库时禁止采集、API 失败中文提示、开始/暂停/恢复/停止、切换数据库、导出筛选结果、路径失效提示和主线程响应性。每阶段必须实际检查 Slint 窗口能打开、移动和关闭。 + +## 模拟 API 测试 + +使用 wiremock 模拟正常分页、空结果、无下一页、401、403、404、429、5xx、额度不足、超时、字段缺失、重复帖子和媒体失败。自动测试不得大量调用真实 X API,不使用真实密钥。 + +## 发布验收 + +在无 Rust 开发环境的 Windows 10/11 上测试 release 程序;验证中文和空格路径、不同盘符、安装、卸载、升级、数据库备份恢复、磁盘断开和数据保留。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/08-\346\211\223\345\214\205\345\217\221\345\270\203\346\226\271\346\241\210.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/08-\346\211\223\345\214\205\345\217\221\345\270\203\346\226\271\346\241\210.md" new file mode 100644 index 0000000000000000000000000000000000000000..0a9dc650fbdab8b99a0ffc875f8d8a591c76a509 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/08-\346\211\223\345\214\205\345\217\221\345\270\203\346\226\271\346\241\210.md" @@ -0,0 +1,28 @@ +# 打包发布方案 + +## Release 构建 + +开发阶段使用 `cargo run`。发布构建使用: + +```powershell +cargo build --release +``` + +生成的可执行文件通常位于 `target\release\xpost-archiver.exe`。最终发布文件复制到 `dist`。不得要求最终用户安装 Rust、Cargo 或开发工具链。 + +## 资源 + +打包时包含 EXE、必要动态库、Slint 运行资源、图标和软件内部只读资源。数据库、媒体、导出和备份不得默认写入安装目录。 + +## Inno Setup + +安装器允许用户选择安装位置,显示目标磁盘剩余空间和快捷方式选项。若安装到系统盘,只提醒并提供返回修改或继续安装,不强制阻止。 + +## 卸载和升级 + +卸载默认保留数据库、媒体、导出和备份,只删除程序文件;小型设置可由用户选择删除。升级保留路径、凭据和用户数据,数据库迁移前创建备份,并显示版本变化。 + +## 发布检查 + +执行全量 Cargo 测试、安全与隐私检查、安装/卸载/升级测试、备份恢复和无开发环境启动测试。最终输出安装版 EXE、便携版 ZIP、`SHA256SUMS.txt` 和发布说明。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/09-\351\232\220\347\247\201\344\270\216\345\256\211\345\205\250\350\257\264\346\230\216.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/09-\351\232\220\347\247\201\344\270\216\345\256\211\345\205\250\350\257\264\346\230\216.md" new file mode 100644 index 0000000000000000000000000000000000000000..bde65ad7aca12998d80f30ea9cd97b0de81cf7a7 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/09-\351\232\220\347\247\201\344\270\216\345\256\211\345\205\250\350\257\264\346\230\216.md" @@ -0,0 +1,22 @@ +# 隐私与安全说明 + +## 数据最小化 + +软件第一版纯本地运行,不主动上传用户数据库、媒体、导出或诊断信息。默认日志不记录完整帖子正文和完整 API 响应。 + +## 凭据 + +Bearer Token、API Secret 等仅由 keyring 保存;界面只显示状态或掩码。禁止将密钥写入源码、Git、SQLite、日志、错误弹窗、诊断报告、导出文件和测试。复制诊断信息时清理 Authorization、token、secret、cookie 等敏感字段。 + +## 文件安全 + +新建数据库不得覆盖同名文件;迁移前备份,失败恢复。媒体使用临时扩展名下载,成功后原子重命名,可校验文件大小和 SHA-256。磁盘断开时安全停止,不删除原路径或已有数据。 + +## 平台边界 + +不索取 X 密码、不窃取 Cookie、不绕过验证码、登录、保护账号、付费权限、访问控制和频率限制,不轮换密钥,不以高并发轰炸接口,不使用来源不明的代理或免登录库。 + +## 日志与诊断 + +日志按日期或大小轮转,可设置保留天数。诊断报告只包含软件版本、Windows 版本、打包版本、数据库结构版本、错误类别、脱敏请求信息和任务状态,不包含凭据和不必要的完整个人数据。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/10-\345\274\200\345\217\221\351\230\266\346\256\265\350\256\241\345\210\222.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/10-\345\274\200\345\217\221\351\230\266\346\256\265\350\256\241\345\210\222.md" new file mode 100644 index 0000000000000000000000000000000000000000..e2833334646f083c22663c456245a2fa039e8f56 --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/10-\345\274\200\345\217\221\351\230\266\346\256\265\350\256\241\345\210\222.md" @@ -0,0 +1,21 @@ +# 开发阶段计划 + +## 阶段 + +0. Rust 项目初始化:检查 Rust 环境、Cargo 项目、Slint、Tokio、基础依赖、统一错误、脱敏日志、SQLx 迁移草案、文档修订、Cargo 验收和实际窗口运行。 +1. 数据库与首次启动向导:用户选择数据库、新建/打开 SQLite、SQLx 迁移、备份、路径设置、配置文件和无效路径提示。 +2. X API 凭据和账号查询:Windows 凭据管理、Bearer Token 测试、用户名规范化、账号查询、账号确认和 API 错误分类。 +3. 保存一页帖子:获取帖子、解析、保存数据库、唯一去重、本地列表和详情查看。 +4. 分页和断点续传:自动分页、任务状态机、数据库检查点、暂停、继续、停止和软件重启恢复。 +5. 搜索和筛选:关键词搜索、日期筛选、帖子类型筛选、排序、本地分页和大数据量列表优化。 +6. 媒体下载:流式下载、临时文件、重试、校验、目录重新绑定和下载失败记录。 +7. 导出:Excel、CSV、JSON、JSON Lines、Markdown、TXT。 +8. Release 构建:release 编译、Windows 图标、版本资源、独立电脑测试和运行依赖检查。 +9. 安装程序:Inno Setup、自定义安装目录、系统盘提醒、快捷方式、卸载、升级保留配置和用户数据保留。 + +## 每次工作顺序 + +读取 `PROJECT_STATE.md`;检查 Git 状态;检查当前可运行版本;只处理一个阶段;做最少必要修改;运行 Cargo 验收;实际启动;更新状态和变更记录;建立提交。 + +不得因局部错误推倒重写,也不得未经备份使用 `git reset --hard`、`git clean -fd`、清空目录、覆盖数据库等危险操作。 + diff --git "a/XPostArchiver-clean-upload-20260711-225630/docs/11-\345\220\216\346\234\237\344\274\230\345\214\226\350\267\257\347\272\277.md" "b/XPostArchiver-clean-upload-20260711-225630/docs/11-\345\220\216\346\234\237\344\274\230\345\214\226\350\267\257\347\272\277.md" new file mode 100644 index 0000000000000000000000000000000000000000..e2e8b41ca0021f469ee7dd5ddb9afac4eb04428f --- /dev/null +++ "b/XPostArchiver-clean-upload-20260711-225630/docs/11-\345\220\216\346\234\237\344\274\230\345\214\226\350\267\257\347\272\277.md" @@ -0,0 +1,155 @@ +# 后期优化路线 + +本文记录暂缓但值得后续继续做的优化。当前软件已经具备本地配置、官方 X API 凭据保存、公开账号查询、采集任务、分页采集、媒体下载、失败写回、归档预览和 Markdown 导出能力。后续优化优先围绕减少手动操作、增强长期运行稳定性和提升导出可用性。 + +## 一、任务操作体验 + +### 1. 真正可点击任务列表 + +当前任务列表是文本展示,并会自动把最新任务 ID 填入输入框。后续可改成可选择列表: + +- 点击某个任务后自动设置为当前任务。 +- 当前任务用于拉取下一页、自动采集、预览、导出和媒体下载。 +- 任务行显示账号、中文状态、页数、保存数量、失败原因。 +- 失败任务可突出显示,但不要用吓人的警告样式。 + +实现建议: + +- 优先保持数据库结构不变。 +- 如果 Slint 标准控件不方便做表格,先做简单列表加“选择第 N 个任务”也可以。 +- 不要为了这个功能引入 WebView、Electron、Tauri 或前端框架。 + +### 2. 任务详情区 + +点击任务后显示更清楚的任务详情: + +- 任务 ID +- 目标账号 +- 当前状态 +- 已采集页数 +- 收到/保存/更新/重复帖子数量 +- 最近错误 +- 下一页游标是否存在 +- 创建、开始、暂停、完成时间 + +## 二、采集任务长期运行 + +### 1. 暂停和恢复 + +当前有“停止自动采集”,并会写回 `stopped`。后续可以把“停止”细分为: + +- 暂停:保留分页游标,状态写为 `paused` 或继续使用 `stopped` 但 UI 显示为“已暂停”。 +- 恢复:从 `crawl_checkpoints.pagination_token` 继续采集。 + +注意:如果要新增状态值,必须同步更新 UI 中文状态映射和测试。 + +### 2. 更清楚的运行保护 + +当前已阻止自动采集运行中重复启动第二个自动采集。后续可继续增强: + +- 切换数据库前检查是否有运行任务。 +- 关闭窗口前提示是否仍有后台采集。 +- 记录自动采集开始和结束日志。 +- 长时间无进度时显示“仍在运行”而不是让用户以为卡住。 + +### 3. 速率限制处理 + +官方 X API 可能返回 429。后续可做: + +- 识别 429 并显示“达到 X API 频率限制”。 +- 如果响应头包含重置时间,显示大概可继续时间。 +- 不绕过、不并发冲击、不伪造登录状态。 + +## 三、媒体下载 + +### 1. 重试策略细化 + +当前已有“重试失败媒体”入口,会把 `metadata_only` 和 `failed` 状态的媒体纳入下载。后续可继续: + +- 区分临时失败和永久失败。 +- 记录每个媒体的重试次数。 +- 对 404 或无 URL 的媒体减少重复重试。 +- 显示最近失败媒体列表。 + +如需增加字段,优先新增迁移,不要直接修改历史迁移文件。 + +### 2. 文件校验 + +后续可补: + +- 下载后记录文件大小。 +- 可选 checksum。 +- 本地文件丢失时重新下载。 + +## 四、归档查看和导出 + +### 1. 导出格式扩展 + +当前支持按任务导出 Markdown 文本索引。后续可扩展: + +- CSV +- JSON +- XLSX +- 带媒体相对路径的 Markdown +- 按账号导出 +- 按时间范围导出 + +导出仍应写入用户选择的导出目录,不要默认写入开发目录或 C 盘。 + +### 2. 归档搜索 + +后续可做简单本地搜索: + +- 按账号 +- 按关键词 +- 按任务 +- 按是否含媒体 +- 按采集时间或 X 发布时间 + +第一版建议直接使用 SQLite 查询,不引入额外搜索引擎。 + +## 五、数据库维护 + +### 1. 恢复备份 + +当前已有检查和备份入口。后续可以加恢复功能: + +- 恢复前必须再次备份当前数据库。 +- 恢复时不能有运行中的采集任务。 +- 恢复后重新检查数据库完整性。 + +### 2. 数据统计页 + +可以显示: + +- 总账号数 +- 总任务数 +- 总帖子数 +- 总媒体数 +- 已下载媒体数 +- 失败媒体数 +- 数据库文件大小 + +## 六、打包和安装 + +后续正式发版前需要: + +- 更新 README 当前状态。 +- 检查安装程序是否不写死开发目录。 +- 确认配置目录、日志目录、数据库目录可由用户选择。 +- 在干净机器或新用户环境测试启动。 + +## 七、优先级建议 + +建议顺序: + +1. 真正可点击任务列表。 +2. 任务详情区。 +3. 导出 CSV/JSON。 +4. 暂停/恢复语义优化。 +5. 数据库恢复 UI。 +6. 速率限制友好提示。 +7. 归档搜索。 + +每个优化继续保持小步提交:实现、严格验收、窗口确认、更新文档、提交。 + diff --git a/XPostArchiver-clean-upload-20260711-225630/migrations/0001_initial.sql b/XPostArchiver-clean-upload-20260711-225630/migrations/0001_initial.sql new file mode 100644 index 0000000000000000000000000000000000000000..f0d26be50db4fa438690eefc641c96d5241b989f --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/migrations/0001_initial.sql @@ -0,0 +1,142 @@ +CREATE TABLE IF NOT EXISTS app_metadata ( + key TEXT PRIMARY KEY NOT NULL, + value TEXT NOT NULL, + updated_at TEXT NOT NULL +); + +CREATE TABLE IF NOT EXISTS accounts ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + x_user_id TEXT NOT NULL UNIQUE, + username TEXT NOT NULL, + display_name TEXT, + description TEXT, + profile_image_url TEXT, + created_at_x TEXT, + protected INTEGER, + verified INTEGER, + followers_count INTEGER, + following_count INTEGER, + post_count INTEGER, + first_seen_at TEXT NOT NULL, + last_seen_at TEXT NOT NULL, + raw_json TEXT +); + +CREATE TABLE IF NOT EXISTS posts ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + x_post_id TEXT NOT NULL UNIQUE, + author_x_user_id TEXT NOT NULL, + author_username TEXT, + author_display_name TEXT, + text TEXT, + created_at_x TEXT, + original_url TEXT, + language TEXT, + conversation_id TEXT, + in_reply_to_user_id TEXT, + in_reply_to_post_id TEXT, + quote_target_post_id TEXT, + repost_source_post_id TEXT, + post_type TEXT, + possibly_long_text INTEGER, + like_count INTEGER, + reply_count INTEGER, + repost_count INTEGER, + quote_count INTEGER, + bookmark_count INTEGER, + view_count INTEGER, + has_media INTEGER NOT NULL DEFAULT 0, + first_fetched_at TEXT NOT NULL, + last_fetched_at TEXT NOT NULL, + source_job_id TEXT, + raw_json TEXT, + data_source TEXT +); + +CREATE TABLE IF NOT EXISTS post_references ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + source_post_id TEXT NOT NULL, + reference_type TEXT NOT NULL, + target_x_post_id TEXT NOT NULL, + UNIQUE(source_post_id, reference_type, target_x_post_id) +); + +CREATE TABLE IF NOT EXISTS media ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + media_key TEXT NOT NULL UNIQUE, + media_type TEXT NOT NULL, + original_url TEXT, + preview_url TEXT, + local_relative_path TEXT, + mime_type TEXT, + file_size INTEGER, + width INTEGER, + height INTEGER, + duration_ms INTEGER, + download_status TEXT NOT NULL, + downloaded_at TEXT, + checksum TEXT, + last_error TEXT, + raw_json TEXT +); + +CREATE TABLE IF NOT EXISTS post_media ( + post_id TEXT NOT NULL, + media_key TEXT NOT NULL, + display_order INTEGER NOT NULL, + PRIMARY KEY (post_id, media_key) +); + +CREATE TABLE IF NOT EXISTS crawl_jobs ( + id TEXT PRIMARY KEY NOT NULL, + target_x_user_id TEXT, + target_username TEXT NOT NULL, + task_mode TEXT NOT NULL, + date_start TEXT, + date_end TEXT, + maximum_posts INTEGER, + include_original INTEGER NOT NULL, + include_replies INTEGER NOT NULL, + include_reposts INTEGER NOT NULL, + include_quotes INTEGER NOT NULL, + download_media INTEGER NOT NULL, + status TEXT NOT NULL, + created_at TEXT NOT NULL, + started_at TEXT, + paused_at TEXT, + finished_at TEXT, + pages_fetched INTEGER NOT NULL DEFAULT 0, + posts_received INTEGER NOT NULL DEFAULT 0, + posts_inserted INTEGER NOT NULL DEFAULT 0, + posts_updated INTEGER NOT NULL DEFAULT 0, + posts_duplicated INTEGER NOT NULL DEFAULT 0, + media_downloaded INTEGER NOT NULL DEFAULT 0, + error_count INTEGER NOT NULL DEFAULT 0, + last_error TEXT +); + +CREATE TABLE IF NOT EXISTS crawl_checkpoints ( + job_id TEXT PRIMARY KEY NOT NULL, + pagination_token TEXT, + oldest_post_id TEXT, + oldest_post_time TEXT, + newest_post_id TEXT, + newest_post_time TEXT, + last_successful_page INTEGER NOT NULL DEFAULT 0, + updated_at TEXT NOT NULL +); + +CREATE TABLE IF NOT EXISTS fetch_errors ( + id INTEGER PRIMARY KEY AUTOINCREMENT, + job_id TEXT, + stage TEXT NOT NULL, + request_identifier TEXT, + error_category TEXT NOT NULL, + http_status INTEGER, + message TEXT NOT NULL, + retryable INTEGER NOT NULL, + retry_count INTEGER NOT NULL DEFAULT 0, + created_at TEXT NOT NULL, + resolved_at TEXT +); + diff --git a/XPostArchiver-clean-upload-20260711-225630/migrations/README.md b/XPostArchiver-clean-upload-20260711-225630/migrations/README.md new file mode 100644 index 0000000000000000000000000000000000000000..bd777b2d08735fb157ccc4a959e7040d3c21ead5 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/migrations/README.md @@ -0,0 +1,4 @@ +# SQLx Migrations + +数据库迁移文件必须随源码提交。程序打开用户选择的 SQLite 数据库时运行迁移;迁移前必须先备份用户数据库。 + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/api/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/api/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..0fd4dd41141fe45e3d8d19cffe064184c90e0048 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/api/mod.rs @@ -0,0 +1,2 @@ + + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/app.rs b/XPostArchiver-clean-upload-20260711-225630/src/app.rs new file mode 100644 index 0000000000000000000000000000000000000000..e87e1d8c6449522391b0080de4c44eee04188e9a --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/app.rs @@ -0,0 +1,824 @@ +use std::cell::RefCell; +use std::path::Path; +use std::rc::Rc; +use std::sync::{ + Arc, + atomic::{AtomicBool, Ordering}, +}; +use std::thread; +use std::time::Duration; + +use crate::config::settings::{AppSettings, ConfigPathKind}; +use crate::logging::rotation::redact_secret; +use crate::logging::{LoggingGuard, init_logging}; +use crate::services::account_service::lookup_account; +use crate::services::archive_export_service::{ + export_posts_for_job_markdown, preview_posts_for_job, +}; +use crate::services::crawl_task_service::{create_crawl_task, list_recent_crawl_tasks}; +use crate::services::credential_service::{ + bearer_token_status, clear_bearer_token, read_bearer_token, save_bearer_token, +}; +use crate::services::database_service::{ + backup_current_database, check_current_database, choose_existing_database, create_database, +}; +use crate::services::media_download_service::{download_pending_media, retry_failed_media}; +use crate::services::path_service::choose_config_directory; +use crate::services::post_fetch_service::{ + auto_fetch_pages_for_task_owned_async, fetch_one_page_for_task, +}; +use crate::services::x_api_service::validate_bearer_token; +use crate::tasks::runtime::BackgroundRuntime; + +slint::include_modules!(); + +pub struct App { + _logging: LoggingGuard, + runtime: Rc, + settings: Rc>, +} + +impl App { + pub fn bootstrap() -> anyhow::Result { + let logging = init_logging()?; + tracing::info!( + module = "app", + "{}", + redact_secret("starting XPostArchiver") + ); + let runtime = Rc::new(BackgroundRuntime::new()?); + let settings = Rc::new(RefCell::new(AppSettings::load()?)); + Ok(Self { + _logging: logging, + runtime, + settings, + }) + } + + pub fn run(self) -> anyhow::Result<()> { + let _shutdown_token = self.runtime.cancellation_token(); + let window = AppWindow::new()?; + load_saved_settings(&window, &self.settings.borrow()); + register_database_callbacks(&window, Rc::clone(&self.runtime), Rc::clone(&self.settings)); + register_path_callbacks(&window, Rc::clone(&self.settings)); + register_media_mode_callbacks(&window, Rc::clone(&self.settings)); + register_credential_callbacks(&window, Rc::clone(&self.runtime)); + register_account_callbacks(&window, Rc::clone(&self.runtime), Rc::clone(&self.settings)); + register_crawl_task_callbacks(&window, Rc::clone(&self.runtime), Rc::clone(&self.settings)); + + window.run()?; + tracing::info!(module = "app", "application closed"); + Ok(()) + } +} + +fn load_saved_settings(window: &AppWindow, settings: &AppSettings) { + if let Some(path) = settings.last_database_path.as_ref() { + window.set_database_path(display_path(path).into()); + if path.exists() { + window.set_status_message("已加载上次数据库路径。".into()); + window.set_database_ready(true); + } else { + window.set_status_message( + "上次使用的数据库当前无法访问。请连接对应磁盘,或重新选择数据库文件。".into(), + ); + window.set_database_ready(false); + } + } + + set_optional_path( + window, + ConfigPathKind::MediaRoot, + settings.get_path(ConfigPathKind::MediaRoot), + ); + set_optional_path( + window, + ConfigPathKind::ExportDir, + settings.get_path(ConfigPathKind::ExportDir), + ); + set_optional_path( + window, + ConfigPathKind::LogDir, + settings.get_path(ConfigPathKind::LogDir), + ); + set_optional_path( + window, + ConfigPathKind::BackupDir, + settings.get_path(ConfigPathKind::BackupDir), + ); + set_optional_path( + window, + ConfigPathKind::TempDir, + settings.get_path(ConfigPathKind::TempDir), + ); + window.set_save_media_files(settings.save_media_files); + set_credential_status(window); +} + +fn register_database_callbacks( + window: &AppWindow, + runtime: Rc, + settings: Rc>, +) { + { + let weak_window = window.as_weak(); + let runtime = Rc::clone(&runtime); + let settings = Rc::clone(&settings); + window.on_create_database(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match create_database(&runtime, &mut settings.borrow_mut()) { + Ok(Some(result)) => { + window.set_database_path(display_path(&result.path).into()); + window.set_status_message(result.message.into()); + window.set_database_ready(true); + } + Ok(None) => { + window.set_status_message("已取消新建数据库。".into()); + } + Err(error) => { + window.set_status_message(format!("新建数据库失败:{error}").into()); + window.set_database_ready(false); + } + } + }); + } + + { + let weak_window = window.as_weak(); + let runtime = Rc::clone(&runtime); + let settings = Rc::clone(&settings); + window.on_open_database(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match choose_existing_database(&runtime, &mut settings.borrow_mut()) { + Ok(Some(result)) => { + window.set_database_path(display_path(&result.path).into()); + window.set_status_message(result.message.into()); + window.set_database_ready(true); + } + Ok(None) => { + window.set_status_message("已取消打开数据库。".into()); + } + Err(error) => { + window.set_status_message(format!("打开数据库失败:{error}").into()); + window.set_database_ready(false); + } + } + }); + } + + { + let weak_window = window.as_weak(); + let runtime = Rc::clone(&runtime); + let settings = Rc::clone(&settings); + window.on_check_database(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match check_current_database(&runtime, &settings.borrow()) { + Ok(result) => { + window.set_status_message(result.message.into()); + } + Err(error) => { + window.set_status_message(format!("检查数据库失败:{error}").into()); + } + } + }); + } + + { + let weak_window = window.as_weak(); + let settings = Rc::clone(&settings); + window.on_backup_database(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match backup_current_database(&settings.borrow()) { + Ok(result) => { + window.set_status_message(result.message.into()); + } + Err(error) => { + window.set_status_message(format!("备份数据库失败:{error}").into()); + } + } + }); + } +} + +fn register_path_callbacks(window: &AppWindow, settings: Rc>) { + register_one_path_callback(window, Rc::clone(&settings), ConfigPathKind::MediaRoot); + register_one_path_callback(window, Rc::clone(&settings), ConfigPathKind::ExportDir); + register_one_path_callback(window, Rc::clone(&settings), ConfigPathKind::LogDir); + register_one_path_callback(window, Rc::clone(&settings), ConfigPathKind::BackupDir); + register_one_path_callback(window, settings, ConfigPathKind::TempDir); +} + +fn register_one_path_callback( + window: &AppWindow, + settings: Rc>, + kind: ConfigPathKind, +) { + let weak_window = window.as_weak(); + let callback = move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match choose_config_directory(kind, &mut settings.borrow_mut()) { + Ok(Some(result)) => { + set_optional_path(&window, result.kind, Some(&result.path)); + window.set_status_message(result.message.into()); + } + Ok(None) => { + window.set_status_message(format!("已取消设置{}。", kind.label()).into()); + } + Err(error) => { + window.set_status_message(format!("设置{}失败:{error}", kind.label()).into()); + } + } + }; + + match kind { + ConfigPathKind::MediaRoot => window.on_choose_media_root(callback), + ConfigPathKind::ExportDir => window.on_choose_export_dir(callback), + ConfigPathKind::LogDir => window.on_choose_log_dir(callback), + ConfigPathKind::BackupDir => window.on_choose_backup_dir(callback), + ConfigPathKind::TempDir => window.on_choose_temp_dir(callback), + } +} + +fn register_account_callbacks( + window: &AppWindow, + runtime: Rc, + settings: Rc>, +) { + let weak_window = window.as_weak(); + window.on_lookup_account(move |username| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let Some(database_path) = settings.borrow().last_database_path.clone() else { + window.set_account_status("请先选择或新建数据库。".into()); + return; + }; + match lookup_account(&runtime, &database_path, username.as_str()) { + Ok(result) => { + let display_name = result + .display_name + .unwrap_or_else(|| "未提供显示名".to_owned()); + window.set_account_status( + format!( + "{} 显示名:{} 用户名:@{}", + result.message, display_name, result.username + ) + .into(), + ); + } + Err(error) => { + window.set_account_status(format!("查询账号失败:{error}").into()); + } + } + }); +} + +fn register_crawl_task_callbacks( + window: &AppWindow, + runtime: Rc, + settings: Rc>, +) { + let auto_stop_signal: Rc>>> = Rc::new(RefCell::new(None)); + let auto_running = Arc::new(AtomicBool::new(false)); + + let weak_window = window.as_weak(); + let create_runtime = Rc::clone(&runtime); + let create_settings = Rc::clone(&settings); + window.on_create_crawl_task(move |username| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = create_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_crawl_task_status("请先选择或新建数据库。".into()); + return; + }; + match create_runtime.block_on(create_crawl_task( + database_path, + username.as_str(), + &settings_ref, + )) { + Ok(Ok(result)) => { + window.set_selected_job_id(result.job_id.clone().into()); + window.set_crawl_task_status( + format!("{} 任务ID:{}", result.message, result.job_id).into(), + ); + } + Ok(Err(error)) | Err(error) => { + window.set_crawl_task_status(format!("创建采集任务失败:{error}").into()); + } + } + }); + + let weak_window = window.as_weak(); + let list_runtime = Rc::clone(&runtime); + let list_settings = Rc::clone(&settings); + window.on_refresh_crawl_tasks(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = list_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_crawl_task_list("请先选择或新建数据库。".into()); + return; + }; + match list_runtime.block_on(list_recent_crawl_tasks(database_path, 8)) { + Ok(Ok(tasks)) => { + if tasks.is_empty() { + window.set_crawl_task_list("当前数据库还没有采集任务。".into()); + } else { + if let Some(first_task) = tasks.first() { + window.set_selected_job_id(first_task.job_id.clone().into()); + } + let lines = tasks + .iter() + .map(|task| { + let error_suffix = task + .last_error + .as_ref() + .map(|error| format!(" 错误:{}", error)) + .unwrap_or_default(); + format!( + "{} @{} 状态:{} 页:{} 收到:{} 保存:{} 创建:{}{}", + task.job_id, + task.username, + crawl_status_label(&task.status), + task.pages_fetched, + task.posts_received, + task.posts_inserted, + task.created_at, + error_suffix + ) + }) + .collect::>() + .join("\n"); + window.set_crawl_task_list(lines.into()); + } + } + Ok(Err(error)) | Err(error) => { + window.set_crawl_task_list(format!("刷新任务列表失败:{error}").into()); + } + } + }); + + let weak_window = window.as_weak(); + let fetch_runtime = Rc::clone(&runtime); + let fetch_settings = Rc::clone(&settings); + window.on_fetch_one_page(move |job_id| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = fetch_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_fetch_status("请先选择或新建数据库。".into()); + return; + }; + match fetch_one_page_for_task(&fetch_runtime, database_path, job_id.as_str()) { + Ok(result) => window.set_fetch_status( + format!( + "{} 收到:{} 保存:{} 媒体:{} 状态:{}", + result.message, + result.received, + result.saved, + result.media_saved, + if result.has_next_page { + "可继续" + } else { + "已完成" + } + ) + .into(), + ), + Err(error) => window.set_fetch_status(format!("拉取帖子失败:{error}").into()), + } + }); + + let weak_window = window.as_weak(); + let auto_settings = Rc::clone(&settings); + let auto_stop_signal_for_start = Rc::clone(&auto_stop_signal); + let auto_running_for_start = Arc::clone(&auto_running); + window.on_auto_fetch_pages(move |job_id, page_limit, delay_seconds| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = auto_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref().cloned() else { + window.set_auto_crawl_status("请先选择或新建数据库。".into()); + return; + }; + let token = match read_bearer_token() { + Ok(Some(token)) => token, + Ok(None) => { + window.set_auto_crawl_status("请先保存 X API Bearer Token。".into()); + return; + } + Err(error) => { + window.set_auto_crawl_status(format!("读取系统密钥库失败:{error}").into()); + return; + } + }; + let page_limit = match page_limit.trim().parse::() { + Ok(value) => value, + Err(_) => { + window + .set_auto_crawl_status("页数上限请输入数字;0 表示直到末页或手动停止。".into()); + return; + } + }; + let delay_seconds = match delay_seconds.trim().parse::() { + Ok(value) => value, + Err(_) => { + window.set_auto_crawl_status("每页等待秒数请输入数字。".into()); + return; + } + }; + let job_id = job_id.to_string(); + if job_id.trim().is_empty() { + window.set_auto_crawl_status("请先填写任务 ID。".into()); + return; + } + if auto_running_for_start.swap(true, Ordering::Relaxed) { + window.set_auto_crawl_status("已有自动采集正在运行,请先停止或等待完成。".into()); + return; + } + let completion_window = weak_window.clone(); + let running_signal = Arc::clone(&auto_running_for_start); + let stop_requested = Arc::new(AtomicBool::new(false)); + *auto_stop_signal_for_start.borrow_mut() = Some(Arc::clone(&stop_requested)); + window.set_auto_crawl_status( + format!( + "自动采集已在后台启动;页数上限:{};每页等待:{} 秒。", + if page_limit == 0 { + "直到末页或手动停止".to_owned() + } else { + page_limit.to_string() + }, + delay_seconds + ) + .into(), + ); + thread::spawn(move || { + let result = tokio::runtime::Builder::new_current_thread() + .enable_all() + .build() + .map_err(anyhow::Error::from) + .and_then(|runtime| { + runtime.block_on(auto_fetch_pages_for_task_owned_async( + database_path, + job_id, + token, + page_limit, + Duration::from_secs(delay_seconds), + stop_requested, + )) + }); + let message = match result { + Ok(result) => format!( + "{} 页数:{} 收到:{} 保存:{} 媒体:{} 状态:{}", + result.message, + result.pages_fetched, + result.posts_received, + result.posts_saved, + result.media_saved, + if result.stopped_by_request { + "已停止" + } else if result.stopped_because_complete { + "已完成" + } else { + "可继续" + } + ), + Err(error) => format!("自动采集失败:{error}"), + }; + running_signal.store(false, Ordering::Relaxed); + let _ = slint::invoke_from_event_loop(move || { + if let Some(window) = completion_window.upgrade() { + window.set_auto_crawl_status(message.into()); + } + }); + }); + }); + + let weak_window = window.as_weak(); + let auto_stop_signal_for_stop = Rc::clone(&auto_stop_signal); + window.on_stop_auto_crawl(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + if let Some(stop_requested) = auto_stop_signal_for_stop.borrow().as_ref() { + stop_requested.store(true, Ordering::Relaxed); + window.set_auto_crawl_status("已请求停止自动采集;当前页完成后会停下。".into()); + } else { + window.set_auto_crawl_status("当前没有正在运行的自动采集。".into()); + } + }); + + let weak_window = window.as_weak(); + let preview_runtime = Rc::clone(&runtime); + let preview_settings = Rc::clone(&settings); + window.on_preview_archive(move |job_id| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = preview_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_archive_preview("请先选择或新建数据库。".into()); + return; + }; + match preview_runtime.block_on(preview_posts_for_job(database_path, job_id.as_str(), 5)) { + Ok(Ok(result)) => { + if result.posts.is_empty() { + window.set_archive_preview("这个任务还没有已保存帖子。".into()); + } else { + let lines = result + .posts + .iter() + .map(|post| { + format!( + "{} @{} {}\n{}", + post.x_post_id, + post.author_username.as_deref().unwrap_or("未知账号"), + post.created_at_x.as_deref().unwrap_or("未知时间"), + post.text.as_deref().unwrap_or("") + ) + }) + .collect::>() + .join("\n---\n"); + window.set_archive_preview(format!("{}\n{}", result.message, lines).into()); + } + } + Ok(Err(error)) | Err(error) => { + window.set_archive_preview(format!("预览归档失败:{error}").into()); + } + } + }); + + let weak_window = window.as_weak(); + let export_runtime = Rc::clone(&runtime); + let export_settings = Rc::clone(&settings); + window.on_export_archive(move |job_id| { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = export_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_archive_preview("请先选择或新建数据库。".into()); + return; + }; + let Some(export_dir) = settings_ref.export_dir.as_ref() else { + window.set_archive_preview("请先选择导出目录。".into()); + return; + }; + match export_runtime.block_on(export_posts_for_job_markdown( + database_path, + export_dir, + job_id.as_str(), + )) { + Ok(Ok(result)) => window.set_archive_preview( + format!( + "{} 文件:{} 帖子数:{}", + result.message, + result.path.display(), + result.post_count + ) + .into(), + ), + Ok(Err(error)) | Err(error) => { + window.set_archive_preview(format!("导出归档失败:{error}").into()); + } + } + }); + + let weak_window = window.as_weak(); + let download_runtime = Rc::clone(&runtime); + let download_settings = Rc::clone(&settings); + window.on_download_media(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = download_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_media_download_status("请先选择或新建数据库。".into()); + return; + }; + let Some(archive_root) = settings_ref.media_root.as_ref() else { + window.set_media_download_status("请先选择归档内容目录。".into()); + return; + }; + if !settings_ref.save_media_files { + window.set_media_download_status("当前设置为只保存文本,已跳过媒体文件下载。".into()); + return; + } + match download_pending_media(&download_runtime, database_path, archive_root, 20) { + Ok(result) => window.set_media_download_status( + format!( + "{} 尝试:{} 成功:{} 跳过:{} 失败:{}", + result.message, + result.attempted, + result.downloaded, + result.skipped, + result.failed + ) + .into(), + ), + Err(error) => window.set_media_download_status(format!("下载媒体失败:{error}").into()), + } + }); + + let weak_window = window.as_weak(); + let retry_runtime = Rc::clone(&runtime); + let retry_settings = Rc::clone(&settings); + window.on_retry_failed_media(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + let settings_ref = retry_settings.borrow(); + let Some(database_path) = settings_ref.last_database_path.as_ref() else { + window.set_media_download_status("请先选择或新建数据库。".into()); + return; + }; + let Some(archive_root) = settings_ref.media_root.as_ref() else { + window.set_media_download_status("请先选择归档内容目录。".into()); + return; + }; + if !settings_ref.save_media_files { + window.set_media_download_status("当前设置为只保存文本,已跳过媒体文件下载。".into()); + return; + } + match retry_failed_media(&retry_runtime, database_path, archive_root, 20) { + Ok(result) => window.set_media_download_status( + format!( + "{} 尝试:{} 成功:{} 跳过:{} 失败:{}", + result.message, + result.attempted, + result.downloaded, + result.skipped, + result.failed + ) + .into(), + ), + Err(error) => { + window.set_media_download_status(format!("重试失败媒体失败:{error}").into()); + } + } + }); +} + +fn register_credential_callbacks(window: &AppWindow, runtime: Rc) { + { + let weak_window = window.as_weak(); + window.on_save_bearer_token(move |token| { + let Some(window) = weak_window.upgrade() else { + return; + }; + match save_bearer_token(token.as_str()) { + Ok(status) => apply_credential_status(&window, status), + Err(error) => { + window.set_credentials_ready(false); + window.set_credential_status(format!("保存凭据失败:{error}").into()); + } + } + }); + } + + { + let weak_window = window.as_weak(); + let runtime = Rc::clone(&runtime); + window.on_validate_bearer_token(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match read_bearer_token() { + Ok(Some(token)) => match runtime.block_on(validate_bearer_token(&token)) { + Ok(Ok(result)) => { + window.set_credentials_ready(result.valid); + window.set_credential_status(result.message.into()); + } + Ok(Err(error)) | Err(error) => { + window.set_credentials_ready(false); + window.set_credential_status(format!("检查凭据失败:{error}").into()); + } + }, + Ok(None) => { + window.set_credentials_ready(false); + window.set_credential_status("请先保存 X API Bearer Token。".into()); + } + Err(error) => { + window.set_credentials_ready(false); + window.set_credential_status(format!("读取系统密钥库失败:{error}").into()); + } + } + }); + } + + { + let weak_window = window.as_weak(); + window.on_clear_bearer_token(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + match clear_bearer_token() { + Ok(status) => apply_credential_status(&window, status), + Err(error) => { + window.set_credentials_ready(false); + window.set_credential_status(format!("清除凭据失败:{error}").into()); + } + } + }); + } +} + +fn set_credential_status(window: &AppWindow) { + apply_credential_status(window, bearer_token_status()); +} + +fn apply_credential_status( + window: &AppWindow, + status: crate::services::credential_service::CredentialStatus, +) { + window.set_credentials_ready(status.configured); + window.set_credential_status(status.message.into()); +} + +fn register_media_mode_callbacks(window: &AppWindow, settings: Rc>) { + { + let weak_window = window.as_weak(); + let settings = Rc::clone(&settings); + window.on_enable_media_files(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + let mut settings = settings.borrow_mut(); + settings.save_media_files = true; + match settings.save() { + Ok(()) => { + window.set_save_media_files(true); + window.set_status_message("已设置为保存文本和媒体文件。".into()); + } + Err(error) => { + window.set_status_message(format!("保存媒体设置失败:{error}").into()); + } + } + }); + } + + { + let weak_window = window.as_weak(); + window.on_disable_media_files(move || { + let Some(window) = weak_window.upgrade() else { + return; + }; + let mut settings = settings.borrow_mut(); + settings.save_media_files = false; + match settings.save() { + Ok(()) => { + window.set_save_media_files(false); + window.set_status_message("已设置为只保存文本和媒体链接信息。".into()); + } + Err(error) => { + window.set_status_message(format!("保存媒体设置失败:{error}").into()); + } + } + }); + } +} + +fn set_optional_path(window: &AppWindow, kind: ConfigPathKind, path: Option<&Path>) { + let value = path + .map(display_path) + .unwrap_or_else(|| "未设置".to_owned()); + match kind { + ConfigPathKind::MediaRoot => window.set_media_root(value.into()), + ConfigPathKind::ExportDir => window.set_export_dir(value.into()), + ConfigPathKind::LogDir => window.set_log_dir(value.into()), + ConfigPathKind::BackupDir => window.set_backup_dir(value.into()), + ConfigPathKind::TempDir => window.set_temp_dir(value.into()), + } +} + +fn crawl_status_label(status: &str) -> &'static str { + match status { + "created" => "已创建", + "running" => "正在采集", + "page_fetched" => "可继续", + "completed" => "已完成", + "stopped" => "已停止", + "failed" => "失败", + _ => "未知", + } +} + +fn display_path(path: &Path) -> String { + path.display().to_string() +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/config/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/config/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..bea93cd93af076c273c0a04261ce58237878e0d8 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/config/mod.rs @@ -0,0 +1,3 @@ +pub mod paths; +pub mod settings; + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/config/paths.rs b/XPostArchiver-clean-upload-20260711-225630/src/config/paths.rs new file mode 100644 index 0000000000000000000000000000000000000000..84f189e50a204ca2d2bc3a7b26a52aad7aaf2d2b --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/config/paths.rs @@ -0,0 +1,13 @@ +use std::path::PathBuf; + +use directories::ProjectDirs; + +pub fn project_dirs() -> anyhow::Result { + ProjectDirs::from("cn", "XPostArchiver", "XPostArchiver") + .ok_or_else(|| anyhow::anyhow!("无法取得用户配置目录")) +} + +pub fn config_file_path() -> anyhow::Result { + Ok(project_dirs()?.config_dir().join("settings.json")) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/config/settings.rs b/XPostArchiver-clean-upload-20260711-225630/src/config/settings.rs new file mode 100644 index 0000000000000000000000000000000000000000..ac45be10b31714840ef74ee358d6c7425bb344b5 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/config/settings.rs @@ -0,0 +1,105 @@ +use std::path::{Path, PathBuf}; + +use serde::{Deserialize, Serialize}; + +use crate::config::paths::config_file_path; + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct AppSettings { + pub last_database_path: Option, + pub media_root: Option, + pub export_dir: Option, + pub log_dir: Option, + pub backup_dir: Option, + pub temp_dir: Option, + #[serde(default = "default_save_media_files")] + pub save_media_files: bool, + pub system_drive_warning_acknowledged: bool, +} + +fn default_save_media_files() -> bool { + true +} + +impl Default for AppSettings { + fn default() -> Self { + Self { + last_database_path: None, + media_root: None, + export_dir: None, + log_dir: None, + backup_dir: None, + temp_dir: None, + save_media_files: true, + system_drive_warning_acknowledged: false, + } + } +} + +impl AppSettings { + pub fn load() -> anyhow::Result { + let path = config_file_path()?; + if !path.exists() { + return Ok(Self::default()); + } + let text = std::fs::read_to_string(path)?; + Ok(serde_json::from_str(&text)?) + } + + pub fn save(&self) -> anyhow::Result<()> { + let path = config_file_path()?; + if let Some(parent) = path.parent() { + std::fs::create_dir_all(parent)?; + } + let text = serde_json::to_string_pretty(self)?; + std::fs::write(path, text)?; + Ok(()) + } + + pub fn set_database_path(&mut self, path: impl AsRef) { + self.last_database_path = Some(path.as_ref().to_path_buf()); + } + + pub fn set_path(&mut self, kind: ConfigPathKind, path: impl AsRef) { + let path = Some(path.as_ref().to_path_buf()); + match kind { + ConfigPathKind::MediaRoot => self.media_root = path, + ConfigPathKind::ExportDir => self.export_dir = path, + ConfigPathKind::LogDir => self.log_dir = path, + ConfigPathKind::BackupDir => self.backup_dir = path, + ConfigPathKind::TempDir => self.temp_dir = path, + } + } + + pub fn get_path(&self, kind: ConfigPathKind) -> Option<&Path> { + match kind { + ConfigPathKind::MediaRoot => self.media_root.as_deref(), + ConfigPathKind::ExportDir => self.export_dir.as_deref(), + ConfigPathKind::LogDir => self.log_dir.as_deref(), + ConfigPathKind::BackupDir => self.backup_dir.as_deref(), + ConfigPathKind::TempDir => self.temp_dir.as_deref(), + } + } +} + +#[derive(Debug, Clone, Copy)] +pub enum ConfigPathKind { + MediaRoot, + ExportDir, + LogDir, + BackupDir, + TempDir, +} + +impl ConfigPathKind { + pub fn label(self) -> &'static str { + match self { + Self::MediaRoot => "归档内容目录", + Self::ExportDir => "导出目录", + Self::LogDir => "日志目录", + Self::BackupDir => "备份目录", + Self::TempDir => "临时下载目录", + } + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/database/connection.rs b/XPostArchiver-clean-upload-20260711-225630/src/database/connection.rs new file mode 100644 index 0000000000000000000000000000000000000000..55c211e96f7b34676ba1cd7b46871b39eac6afdf --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/database/connection.rs @@ -0,0 +1,34 @@ +use std::path::Path; + +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; + +use crate::database::migrations::run_migrations; + +pub async fn open_or_create_database(path: &Path) -> anyhow::Result<()> { + if let Some(parent) = path.parent() { + std::fs::create_dir_all(parent)?; + } + + let options = SqliteConnectOptions::new() + .filename(path) + .create_if_missing(true); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + connection.close().await?; + Ok(()) +} + +pub async fn open_existing_database(path: &Path) -> anyhow::Result<()> { + if !path.exists() { + anyhow::bail!("数据库文件不存在:{}", path.display()); + } + + let options = SqliteConnectOptions::new() + .filename(path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + connection.close().await?; + Ok(()) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/database/maintenance.rs b/XPostArchiver-clean-upload-20260711-225630/src/database/maintenance.rs new file mode 100644 index 0000000000000000000000000000000000000000..a25f548d041b4c5806c50ab1098e5d4fefa380ce --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/database/maintenance.rs @@ -0,0 +1,64 @@ +use std::path::{Path, PathBuf}; + +use chrono::Local; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; + +#[derive(Debug, Clone)] +pub struct DatabaseBackupResult { + pub path: PathBuf, +} + +pub async fn check_database_integrity(path: &Path) -> anyhow::Result { + if !path.exists() { + anyhow::bail!("数据库文件不存在:{}", path.display()); + } + + let options = SqliteConnectOptions::new() + .filename(path) + .read_only(true) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + let result: String = sqlx::query_scalar("PRAGMA integrity_check;") + .fetch_one(&mut connection) + .await?; + connection.close().await?; + + if result == "ok" { + Ok("数据库完整性检查通过。".to_owned()) + } else { + anyhow::bail!("数据库完整性检查异常:{result}"); + } +} + +pub fn backup_database( + database_path: &Path, + backup_dir: &Path, +) -> anyhow::Result { + if !database_path.exists() { + anyhow::bail!("数据库文件不存在:{}", database_path.display()); + } + + std::fs::create_dir_all(backup_dir)?; + if !backup_dir.is_dir() { + anyhow::bail!("备份位置不是目录:{}", backup_dir.display()); + } + + let stem = database_path + .file_stem() + .and_then(|name| name.to_str()) + .unwrap_or("X公开帖子归档"); + let extension = database_path + .extension() + .and_then(|name| name.to_str()) + .unwrap_or("db"); + let timestamp = Local::now().format("%Y%m%d-%H%M%S"); + let backup_path = backup_dir.join(format!("{stem}-{timestamp}.{extension}")); + + if backup_path.exists() { + anyhow::bail!("备份文件已存在,请稍后重试:{}", backup_path.display()); + } + + std::fs::copy(database_path, &backup_path)?; + Ok(DatabaseBackupResult { path: backup_path }) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/database/migrations.rs b/XPostArchiver-clean-upload-20260711-225630/src/database/migrations.rs new file mode 100644 index 0000000000000000000000000000000000000000..be2e1349db9c614d652ef36aed598c054f4e15ab --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/database/migrations.rs @@ -0,0 +1,9 @@ +use sqlx::{SqliteConnection, migrate::Migrator}; + +static MIGRATOR: Migrator = sqlx::migrate!("./migrations"); + +pub async fn run_migrations(connection: &mut SqliteConnection) -> anyhow::Result<()> { + MIGRATOR.run(connection).await?; + Ok(()) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/database/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/database/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..b70bbd56405f0216d6af4241cc4c4a02888206b5 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/database/mod.rs @@ -0,0 +1,4 @@ +pub mod connection; +pub mod maintenance; +pub mod migrations; + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/domain/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/domain/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..0fd4dd41141fe45e3d8d19cffe064184c90e0048 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/domain/mod.rs @@ -0,0 +1,2 @@ + + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/error.rs b/XPostArchiver-clean-upload-20260711-225630/src/error.rs new file mode 100644 index 0000000000000000000000000000000000000000..3c163deef504e101a677f92869c6f898af253581 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/error.rs @@ -0,0 +1,27 @@ +use std::path::PathBuf; + +use thiserror::Error; + +#[allow(dead_code)] +#[derive(Debug, Error)] +pub enum AppError { + #[error("API请求失败:{0}")] + Api(String), + #[error("数据库错误:{0}")] + Database(String), + #[error("凭据错误:{0}")] + Credential(String), + #[error("导出失败:{0}")] + Export(String), + #[error("媒体处理失败:{0}")] + Media(String), + #[error("配置错误:{0}")] + Configuration(String), + #[error("任务错误:{0}")] + Task(String), + #[error("路径不可用:{path}")] + PathUnavailable { path: PathBuf }, + #[error("操作已取消")] + Cancelled, +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/exporters/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/exporters/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..0fd4dd41141fe45e3d8d19cffe064184c90e0048 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/exporters/mod.rs @@ -0,0 +1,2 @@ + + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/lib.rs b/XPostArchiver-clean-upload-20260711-225630/src/lib.rs new file mode 100644 index 0000000000000000000000000000000000000000..60074bd7e123a5099694aa13779a23350e827f68 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/lib.rs @@ -0,0 +1,8 @@ +pub mod config; +pub mod database; +pub mod error; +pub mod logging; +pub mod services; +pub mod tasks; +pub mod utils; + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/logging/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/logging/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..395cb9e9c78ac75140c74bd6e3bda0ccfe623ef9 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/logging/mod.rs @@ -0,0 +1,37 @@ +pub mod rotation; + +use std::path::PathBuf; + +use directories::ProjectDirs; +use tracing_subscriber::{EnvFilter, Layer, layer::SubscriberExt, util::SubscriberInitExt}; + +pub struct LoggingGuard { + _file_guard: tracing_appender::non_blocking::WorkerGuard, +} + +pub fn init_logging() -> anyhow::Result { + let log_dir = default_log_dir()?; + std::fs::create_dir_all(&log_dir)?; + + let file_appender = tracing_appender::rolling::daily(&log_dir, "xpost-archiver.log"); + let (file_writer, file_guard) = tracing_appender::non_blocking(file_appender); + + let filter = EnvFilter::try_from_default_env().unwrap_or_else(|_| EnvFilter::new("info")); + let file_layer = tracing_subscriber::fmt::layer() + .with_ansi(false) + .with_writer(file_writer) + .with_filter(filter); + + tracing_subscriber::registry().with(file_layer).try_init()?; + + Ok(LoggingGuard { + _file_guard: file_guard, + }) +} + +fn default_log_dir() -> anyhow::Result { + let dirs = ProjectDirs::from("cn", "XPostArchiver", "XPostArchiver") + .ok_or_else(|| anyhow::anyhow!("无法取得用户配置目录"))?; + Ok(dirs.data_local_dir().join("logs")) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/logging/rotation.rs b/XPostArchiver-clean-upload-20260711-225630/src/logging/rotation.rs new file mode 100644 index 0000000000000000000000000000000000000000..34374d8a89fa7de6309c2eb2e894b322e914fd0b --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/logging/rotation.rs @@ -0,0 +1,34 @@ +pub fn redact_secret(input: &str) -> String { + let mut output = input.to_owned(); + for marker in [ + "Bearer ", + "token=", + "api_key=", + "api_secret=", + "Authorization:", + ] { + if let Some(index) = output + .to_ascii_lowercase() + .find(&marker.to_ascii_lowercase()) + { + let end = output[index..] + .find(['\n', '\r', '&']) + .map(|offset| index + offset) + .unwrap_or(output.len()); + output.replace_range(index..end, "[REDACTED]"); + } + } + output +} + +#[cfg(test)] +mod tests { + use super::redact_secret; + + #[test] + fn redacts_bearer_token() { + let text = "Authorization: Bearer abcdefghijklmnopqrstuvwxyz"; + assert!(!redact_secret(text).contains("abcdefghijklmnopqrstuvwxyz")); + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/main.rs b/XPostArchiver-clean-upload-20260711-225630/src/main.rs new file mode 100644 index 0000000000000000000000000000000000000000..8bbb3f602e85bd10fa77c275d9038c26b79188ab --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/main.rs @@ -0,0 +1,13 @@ +mod app; +mod config; +mod database; +mod error; +mod logging; +mod services; +mod tasks; +mod utils; + +fn main() -> anyhow::Result<()> { + app::App::bootstrap()?.run() +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/security/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/security/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..0fd4dd41141fe45e3d8d19cffe064184c90e0048 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/security/mod.rs @@ -0,0 +1,2 @@ + + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/account_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/account_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..86cc9ac5e8f60c5f5814020f0decf0be02a0b566 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/account_service.rs @@ -0,0 +1,137 @@ +use chrono::Utc; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; + +use crate::database::migrations::run_migrations; +use crate::services::credential_service::read_bearer_token; +use crate::services::x_api_service::{XAccountProfile, lookup_public_account}; +use crate::tasks::runtime::BackgroundRuntime; + +#[derive(Debug, Clone)] +pub struct AccountLookupResult { + pub username: String, + pub display_name: Option, + pub message: String, +} + +pub fn lookup_account( + runtime: &BackgroundRuntime, + database_path: &std::path::Path, + username: &str, +) -> anyhow::Result { + let token = + read_bearer_token()?.ok_or_else(|| anyhow::anyhow!("请先保存 X API Bearer Token。"))?; + let profile = runtime.block_on(lookup_public_account(&token, username))??; + runtime.block_on(save_account_profile(database_path, &profile))??; + + Ok(AccountLookupResult { + username: profile.username.clone(), + display_name: profile.name.clone(), + message: format!("已查询并保存公开账号:@{}。", profile.username), + }) +} + +pub async fn save_account_profile( + database_path: &std::path::Path, + profile: &XAccountProfile, +) -> anyhow::Result<()> { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + + let now = Utc::now().to_rfc3339(); + let metrics = profile.public_metrics.as_ref(); + sqlx::query( + r#" + INSERT INTO accounts ( + x_user_id, username, display_name, description, profile_image_url, created_at_x, + protected, verified, followers_count, following_count, post_count, + first_seen_at, last_seen_at, raw_json + ) + VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) + ON CONFLICT(x_user_id) DO UPDATE SET + username = excluded.username, + display_name = excluded.display_name, + description = excluded.description, + profile_image_url = excluded.profile_image_url, + created_at_x = excluded.created_at_x, + protected = excluded.protected, + verified = excluded.verified, + followers_count = excluded.followers_count, + following_count = excluded.following_count, + post_count = excluded.post_count, + last_seen_at = excluded.last_seen_at, + raw_json = excluded.raw_json + "#, + ) + .bind(&profile.id) + .bind(&profile.username) + .bind(&profile.name) + .bind(&profile.description) + .bind(&profile.profile_image_url) + .bind(&profile.created_at) + .bind(profile.protected.map(bool_to_i64)) + .bind(profile.verified.map(bool_to_i64)) + .bind(metrics.and_then(|value| value.followers_count)) + .bind(metrics.and_then(|value| value.following_count)) + .bind(metrics.and_then(|value| value.tweet_count)) + .bind(&now) + .bind(&now) + .bind(serde_json::to_string(&profile.raw_json)?) + .execute(&mut connection) + .await?; + + connection.close().await?; + Ok(()) +} + +fn bool_to_i64(value: bool) -> i64 { + if value { 1 } else { 0 } +} + +#[cfg(test)] +mod tests { + use tempfile::tempdir; + + use super::save_account_profile; + use crate::database::connection::open_or_create_database; + use crate::services::x_api_service::{XAccountProfile, XAccountPublicMetrics}; + + #[tokio::test] + async fn saves_account_profile() -> anyhow::Result<()> { + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + + let profile = XAccountProfile { + id: "123".to_owned(), + username: "alice".to_owned(), + name: Some("Alice".to_owned()), + description: Some("public".to_owned()), + profile_image_url: None, + created_at: None, + protected: Some(false), + verified: Some(true), + public_metrics: Some(XAccountPublicMetrics { + followers_count: Some(10), + following_count: Some(2), + tweet_count: Some(30), + }), + raw_json: serde_json::json!({"data":{"id":"123"}}), + }; + + save_account_profile(&database_path, &profile).await?; + + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + let username: String = + sqlx::query_scalar("SELECT username FROM accounts WHERE x_user_id = '123'") + .fetch_one(&pool) + .await?; + + assert_eq!(username, "alice"); + Ok(()) + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/archive_export_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/archive_export_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..bb459352e0dcc6fc95abf4a8865956282c71f15b --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/archive_export_service.rs @@ -0,0 +1,167 @@ +use chrono::Utc; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; +use std::path::{Path, PathBuf}; + +use crate::database::migrations::run_migrations; + +#[derive(Debug, Clone)] +pub struct ArchivedPostSummary { + pub x_post_id: String, + pub author_username: Option, + pub text: Option, + pub created_at_x: Option, + pub original_url: Option, +} + +#[derive(Debug, Clone)] +pub struct ArchivePreviewResult { + pub posts: Vec, + pub message: String, +} + +#[derive(Debug, Clone)] +pub struct ArchiveExportResult { + pub path: PathBuf, + pub post_count: usize, + pub message: String, +} + +pub async fn preview_posts_for_job( + database_path: &Path, + job_id: &str, + limit: i64, +) -> anyhow::Result { + let posts = load_posts_for_job(database_path, job_id, limit.clamp(1, 50)).await?; + Ok(ArchivePreviewResult { + message: format!("已读取 {} 条已保存帖子。", posts.len()), + posts, + }) +} + +pub async fn export_posts_for_job_markdown( + database_path: &Path, + export_dir: &Path, + job_id: &str, +) -> anyhow::Result { + let posts = load_posts_for_job(database_path, job_id, 500).await?; + std::fs::create_dir_all(export_dir)?; + let safe_job_id = job_id + .trim() + .replace(|ch: char| !ch.is_ascii_alphanumeric() && ch != '-', "_"); + let path = export_dir.join(format!( + "x-posts-{}-{}.md", + safe_job_id, + Utc::now().format("%Y%m%d-%H%M%S") + )); + std::fs::write(&path, render_markdown(job_id, &posts))?; + Ok(ArchiveExportResult { + path, + post_count: posts.len(), + message: format!("已导出 {} 条帖子。", posts.len()), + }) +} + +async fn load_posts_for_job( + database_path: &Path, + job_id: &str, + limit: i64, +) -> anyhow::Result> { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + let rows = sqlx::query_as::< + _, + ( + String, + Option, + Option, + Option, + Option, + ), + >( + r#" + SELECT x_post_id, author_username, text, created_at_x, original_url + FROM posts + WHERE source_job_id = ? + ORDER BY COALESCE(created_at_x, first_fetched_at) DESC + LIMIT ? + "#, + ) + .bind(job_id.trim()) + .bind(limit) + .fetch_all(&mut connection) + .await?; + connection.close().await?; + Ok(rows + .into_iter() + .map( + |(x_post_id, author_username, text, created_at_x, original_url)| ArchivedPostSummary { + x_post_id, + author_username, + text, + created_at_x, + original_url, + }, + ) + .collect()) +} + +fn render_markdown(job_id: &str, posts: &[ArchivedPostSummary]) -> String { + let mut text = format!( + "# X 帖子归档\n\n任务 ID:`{}`\n\n共 {} 条帖子。\n\n", + job_id, + posts.len() + ); + for post in posts { + text.push_str(&format!("## {}\n\n", post.x_post_id)); + if let Some(author) = &post.author_username { + text.push_str(&format!("账号:@{}\n\n", author)); + } + if let Some(created_at) = &post.created_at_x { + text.push_str(&format!("时间:{}\n\n", created_at)); + } + if let Some(body) = &post.text { + text.push_str(body); + text.push_str("\n\n"); + } + if let Some(url) = &post.original_url { + text.push_str(&format!("原始链接:{}\n\n", url)); + } + text.push_str("---\n\n"); + } + text +} + +#[cfg(test)] +mod tests { + use tempfile::tempdir; + + use super::{export_posts_for_job_markdown, preview_posts_for_job}; + use crate::database::connection::open_or_create_database; + + #[tokio::test] + async fn previews_and_exports_posts_for_job() -> anyhow::Result<()> { + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + sqlx::query( + "INSERT INTO posts (x_post_id, author_x_user_id, author_username, text, created_at_x, original_url, first_fetched_at, last_fetched_at, source_job_id) VALUES ('post-1', '123', 'alice', 'hello', '2026-07-11T00:00:00Z', 'https://x.com/alice/status/post-1', 'now', 'now', 'job-1')", + ) + .execute(&pool) + .await?; + + let preview = preview_posts_for_job(&database_path, "job-1", 10).await?; + assert_eq!(preview.posts.len(), 1); + let export = + export_posts_for_job_markdown(&database_path, temp_dir.path(), "job-1").await?; + let exported = std::fs::read_to_string(export.path)?; + assert!(exported.contains("hello")); + assert_eq!(export.post_count, 1); + Ok(()) + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/crawl_task_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/crawl_task_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..7411ce7e704a1111870196ee1ceded6dcc18fc8a --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/crawl_task_service.rs @@ -0,0 +1,199 @@ +use chrono::Utc; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; +use uuid::Uuid; + +use crate::config::settings::AppSettings; +use crate::database::migrations::run_migrations; + +#[derive(Debug, Clone)] +pub struct CrawlTaskResult { + pub job_id: String, + pub message: String, +} + +#[derive(Debug, Clone)] +pub struct CrawlTaskSummary { + pub job_id: String, + pub username: String, + pub status: String, + pub pages_fetched: i64, + pub posts_received: i64, + pub posts_inserted: i64, + pub last_error: Option, + pub created_at: String, +} + +pub async fn create_crawl_task( + database_path: &std::path::Path, + username: &str, + settings: &AppSettings, +) -> anyhow::Result { + let username = username.trim().trim_start_matches('@'); + if username.is_empty() { + anyhow::bail!("用户名不能为空。") + } + + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + + let account_exists: Option = sqlx::query_scalar( + "SELECT x_user_id FROM accounts WHERE lower(username) = lower(?) LIMIT 1", + ) + .bind(username) + .fetch_optional(&mut connection) + .await?; + + let Some(target_x_user_id) = account_exists else { + anyhow::bail!("请先查询并保存公开账号:@{}。", username) + }; + + let job_id = Uuid::new_v4().to_string(); + let now = Utc::now().to_rfc3339(); + sqlx::query( + r#" + INSERT INTO crawl_jobs ( + id, target_x_user_id, target_username, task_mode, + include_original, include_replies, include_reposts, include_quotes, + download_media, status, created_at + ) + VALUES (?, ?, ?, 'timeline', 1, 1, 0, 1, ?, 'created', ?) + "#, + ) + .bind(&job_id) + .bind(&target_x_user_id) + .bind(username) + .bind(if settings.save_media_files { + 1_i64 + } else { + 0_i64 + }) + .bind(&now) + .execute(&mut connection) + .await?; + + connection.close().await?; + Ok(CrawlTaskResult { + job_id, + message: format!( + "已创建采集任务:@{}。当前只建立任务,不拉取帖子。", + username + ), + }) +} + +pub async fn list_recent_crawl_tasks( + database_path: &std::path::Path, + limit: i64, +) -> anyhow::Result> { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + + let rows = sqlx::query_as::<_, (String, String, String, i64, i64, i64, Option, String)>( + r#" + SELECT id, target_username, status, pages_fetched, posts_received, posts_inserted, last_error, created_at + FROM crawl_jobs + ORDER BY created_at DESC + LIMIT ? + "#, + ) + .bind(limit.clamp(1, 50)) + .fetch_all(&mut connection) + .await?; + + connection.close().await?; + Ok(rows + .into_iter() + .map( + |( + job_id, + username, + status, + pages_fetched, + posts_received, + posts_inserted, + last_error, + created_at, + )| CrawlTaskSummary { + job_id, + username, + status, + pages_fetched, + posts_received, + posts_inserted, + last_error, + created_at, + }, + ) + .collect()) +} + +#[cfg(test)] +mod tests { + use tempfile::tempdir; + + use super::{create_crawl_task, list_recent_crawl_tasks}; + use crate::config::settings::AppSettings; + use crate::database::connection::open_or_create_database; + use crate::services::account_service::save_account_profile; + use crate::services::x_api_service::XAccountProfile; + + #[tokio::test] + async fn creates_crawl_task_for_saved_account() -> anyhow::Result<()> { + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + + let result = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + assert!(result.message.contains("已创建采集任务")); + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + let status: String = sqlx::query_scalar("SELECT status FROM crawl_jobs WHERE id = ?") + .bind(result.job_id) + .fetch_one(&pool) + .await?; + assert_eq!(status, "created"); + Ok(()) + } + + #[tokio::test] + async fn lists_recent_crawl_tasks() -> anyhow::Result<()> { + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + let created = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + let tasks = list_recent_crawl_tasks(&database_path, 10).await?; + + assert_eq!(tasks.len(), 1); + assert_eq!(tasks[0].job_id, created.job_id); + assert_eq!(tasks[0].username, "alice"); + assert_eq!(tasks[0].status, "created"); + assert_eq!(tasks[0].pages_fetched, 0); + Ok(()) + } + + fn test_profile() -> XAccountProfile { + XAccountProfile { + id: "123".to_owned(), + username: "alice".to_owned(), + name: Some("Alice".to_owned()), + description: None, + profile_image_url: None, + created_at: None, + protected: Some(false), + verified: None, + public_metrics: None, + raw_json: serde_json::json!({"data":{"id":"123"}}), + } + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/credential_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/credential_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..f919ee8a61799cf30442bfcc6a4b41df01779d22 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/credential_service.rs @@ -0,0 +1,69 @@ +use keyring::Entry; + +const SERVICE_NAME: &str = "XPostArchiver"; +const BEARER_TOKEN_ACCOUNT: &str = "x-api-bearer-token"; + +#[derive(Debug, Clone)] +pub struct CredentialStatus { + pub configured: bool, + pub message: String, +} + +pub fn save_bearer_token(token: &str) -> anyhow::Result { + let token = token.trim(); + if token.is_empty() { + anyhow::bail!("Bearer Token 不能为空。") + } + + let entry = bearer_token_entry()?; + entry.set_password(token)?; + Ok(CredentialStatus { + configured: true, + message: "X API Bearer Token 已保存到系统密钥库。".to_owned(), + }) +} + +pub fn clear_bearer_token() -> anyhow::Result { + let entry = bearer_token_entry()?; + match entry.delete_credential() { + Ok(()) => {} + Err(keyring::Error::NoEntry) => {} + Err(error) => return Err(error.into()), + } + + Ok(CredentialStatus { + configured: false, + message: "X API Bearer Token 已清除。".to_owned(), + }) +} + +pub fn bearer_token_status() -> CredentialStatus { + match read_bearer_token() { + Ok(Some(_)) => CredentialStatus { + configured: true, + message: "已配置 X API Bearer Token。".to_owned(), + }, + Ok(None) => CredentialStatus { + configured: false, + message: "尚未配置 X API Bearer Token。".to_owned(), + }, + Err(error) => CredentialStatus { + configured: false, + message: format!("读取系统密钥库失败:{error}"), + }, + } +} + +pub fn read_bearer_token() -> anyhow::Result> { + let entry = bearer_token_entry()?; + match entry.get_password() { + Ok(token) => Ok(Some(token)), + Err(keyring::Error::NoEntry) => Ok(None), + Err(error) => Err(error.into()), + } +} + +fn bearer_token_entry() -> anyhow::Result { + Ok(Entry::new(SERVICE_NAME, BEARER_TOKEN_ACCOUNT)?) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/database_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/database_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..864e00d90251e6eaf0e1edc1499f2058eb1a658b --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/database_service.rs @@ -0,0 +1,110 @@ +use std::path::{Path, PathBuf}; + +use rfd::FileDialog; + +use crate::config::settings::AppSettings; +use crate::database::connection::{open_existing_database, open_or_create_database}; +use crate::database::maintenance::{backup_database, check_database_integrity}; +use crate::tasks::runtime::BackgroundRuntime; +use crate::utils::disk::system_drive_warning; + +#[derive(Debug, Clone)] +pub struct DatabaseSelectionResult { + pub path: PathBuf, + pub message: String, +} + +#[derive(Debug, Clone)] +pub struct DatabaseMaintenanceResult { + pub message: String, +} + +pub fn choose_existing_database( + runtime: &BackgroundRuntime, + settings: &mut AppSettings, +) -> anyhow::Result> { + let Some(path) = FileDialog::new() + .add_filter("SQLite 数据库", &["db", "sqlite", "sqlite3"]) + .pick_file() + else { + return Ok(None); + }; + + runtime.block_on(open_existing_database(&path))??; + settings.set_database_path(&path); + settings.save()?; + Ok(Some(DatabaseSelectionResult { + message: message_with_warning("已打开数据库", &path), + path, + })) +} + +pub fn create_database( + runtime: &BackgroundRuntime, + settings: &mut AppSettings, +) -> anyhow::Result> { + let Some(mut path) = FileDialog::new() + .add_filter("SQLite 数据库", &["db"]) + .set_file_name("X公开帖子归档.db") + .save_file() + else { + return Ok(None); + }; + + if path.extension().is_none() { + path.set_extension("db"); + } + + if path.exists() { + anyhow::bail!( + "文件已存在,请选择打开已有数据库或更换文件名:{}", + path.display() + ); + } + + runtime.block_on(open_or_create_database(&path))??; + + settings.set_database_path(&path); + settings.save()?; + Ok(Some(DatabaseSelectionResult { + message: message_with_warning("已创建数据库", &path), + path, + })) +} + +pub fn check_current_database( + runtime: &BackgroundRuntime, + settings: &AppSettings, +) -> anyhow::Result { + let database_path = settings + .last_database_path + .as_deref() + .ok_or_else(|| anyhow::anyhow!("请先选择或新建数据库。"))?; + let message = runtime.block_on(check_database_integrity(database_path))??; + Ok(DatabaseMaintenanceResult { message }) +} + +pub fn backup_current_database( + settings: &AppSettings, +) -> anyhow::Result { + let database_path = settings + .last_database_path + .as_deref() + .ok_or_else(|| anyhow::anyhow!("请先选择或新建数据库。"))?; + let backup_dir = settings + .backup_dir + .as_deref() + .ok_or_else(|| anyhow::anyhow!("请先设置备份目录。"))?; + let result = backup_database(database_path, backup_dir)?; + Ok(DatabaseMaintenanceResult { + message: format!("数据库已备份到:{}", result.path.display()), + }) +} + +fn message_with_warning(action: &str, path: &Path) -> String { + match system_drive_warning(path) { + Some(warning) => format!("{action}。{warning}"), + None => action.to_owned(), + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/media_download_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/media_download_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..77d9f7e809ccf91ce613e267c666d0534353decd --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/media_download_service.rs @@ -0,0 +1,324 @@ +use std::path::{Path, PathBuf}; + +use chrono::Utc; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; + +use crate::database::migrations::run_migrations; +use crate::tasks::runtime::BackgroundRuntime; + +#[derive(Debug, Clone)] +pub struct MediaDownloadResult { + pub attempted: usize, + pub downloaded: usize, + pub skipped: usize, + pub failed: usize, + pub message: String, +} + +#[derive(Debug)] +struct PendingMedia { + media_key: String, + media_type: String, + original_url: Option, + preview_url: Option, +} + +pub fn download_pending_media( + runtime: &BackgroundRuntime, + database_path: &Path, + media_root: &Path, + max_items: usize, +) -> anyhow::Result { + runtime.block_on(download_pending_media_async( + database_path, + media_root, + max_items, + ))? +} + +pub fn retry_failed_media( + runtime: &BackgroundRuntime, + database_path: &Path, + media_root: &Path, + max_items: usize, +) -> anyhow::Result { + runtime.block_on(download_media_async( + database_path, + media_root, + max_items, + true, + ))? +} + +pub async fn download_pending_media_async( + database_path: &Path, + media_root: &Path, + max_items: usize, +) -> anyhow::Result { + download_media_async(database_path, media_root, max_items, false).await +} + +async fn download_media_async( + database_path: &Path, + media_root: &Path, + max_items: usize, + include_failed: bool, +) -> anyhow::Result { + if max_items == 0 { + anyhow::bail!("下载数量必须大于 0。") + } + std::fs::create_dir_all(media_root)?; + + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + + let status_filter = if include_failed { + "download_status IN ('metadata_only', 'failed')" + } else { + "download_status = 'metadata_only'" + }; + let pending_query = format!( + "SELECT media_key, media_type, original_url, preview_url FROM media WHERE {status_filter} LIMIT ?" + ); + let pending_rows: Vec<(String, String, Option, Option)> = + sqlx::query_as(&pending_query) + .bind(max_items as i64) + .fetch_all(&mut connection) + .await?; + let pending: Vec = pending_rows + .into_iter() + .map( + |(media_key, media_type, original_url, preview_url)| PendingMedia { + media_key, + media_type, + original_url, + preview_url, + }, + ) + .collect(); + + let client = reqwest::Client::new(); + let mut downloaded = 0_usize; + let mut skipped = 0_usize; + let mut failed = 0_usize; + + for item in &pending { + let Some(url) = item.original_url.as_ref().or(item.preview_url.as_ref()) else { + mark_media_failed(&mut connection, &item.media_key, "没有可下载的媒体 URL。").await?; + skipped += 1; + continue; + }; + + match download_one_media(&client, media_root, item, url).await { + Ok(relative_path) => { + mark_media_downloaded(&mut connection, &item.media_key, &relative_path).await?; + downloaded += 1; + } + Err(error) => { + mark_media_failed(&mut connection, &item.media_key, &error.to_string()).await?; + failed += 1; + } + } + } + + connection.close().await?; + Ok(MediaDownloadResult { + attempted: pending.len(), + downloaded, + skipped, + failed, + message: format!( + "媒体下载完成:尝试 {} 个,成功 {} 个,跳过 {} 个,失败 {} 个。", + pending.len(), + downloaded, + skipped, + failed + ), + }) +} + +async fn download_one_media( + client: &reqwest::Client, + media_root: &Path, + item: &PendingMedia, + url: &str, +) -> anyhow::Result { + let response = client.get(url).send().await?; + if !response.status().is_success() { + anyhow::bail!("媒体下载返回状态:{}。", response.status().as_u16()) + } + let content_type = response + .headers() + .get(reqwest::header::CONTENT_TYPE) + .and_then(|value| value.to_str().ok()) + .map(str::to_owned); + let bytes = response.bytes().await?; + if bytes.is_empty() { + anyhow::bail!("媒体响应为空。") + } + + let extension = extension_for(url, content_type.as_deref(), &item.media_type); + let relative_path = PathBuf::from("media").join(format!("{}.{}", item.media_key, extension)); + let absolute_path = media_root.join(&relative_path); + if let Some(parent) = absolute_path.parent() { + std::fs::create_dir_all(parent)?; + } + std::fs::write(&absolute_path, &bytes)?; + Ok(relative_path.to_string_lossy().replace('\\', "/")) +} + +fn extension_for(url: &str, content_type: Option<&str>, media_type: &str) -> &'static str { + if let Some(content_type) = content_type { + if content_type.contains("png") { + return "png"; + } + if content_type.contains("webp") { + return "webp"; + } + if content_type.contains("gif") { + return "gif"; + } + if content_type.contains("mp4") { + return "mp4"; + } + if content_type.contains("jpeg") || content_type.contains("jpg") { + return "jpg"; + } + } + let lower_url = url.to_ascii_lowercase(); + for extension in ["png", "webp", "gif", "mp4", "jpg", "jpeg"] { + if lower_url.contains(&format!(".{extension}")) { + return if extension == "jpeg" { + "jpg" + } else { + extension + }; + } + } + match media_type { + "video" | "animated_gif" => "mp4", + _ => "jpg", + } +} + +async fn mark_media_downloaded( + connection: &mut SqliteConnection, + media_key: &str, + relative_path: &str, +) -> anyhow::Result<()> { + sqlx::query( + "UPDATE media SET download_status = 'downloaded', local_relative_path = ?, downloaded_at = ?, last_error = NULL WHERE media_key = ?", + ) + .bind(relative_path) + .bind(Utc::now().to_rfc3339()) + .bind(media_key) + .execute(connection) + .await?; + Ok(()) +} + +async fn mark_media_failed( + connection: &mut SqliteConnection, + media_key: &str, + error: &str, +) -> anyhow::Result<()> { + sqlx::query("UPDATE media SET download_status = 'failed', last_error = ? WHERE media_key = ?") + .bind(error) + .bind(media_key) + .execute(connection) + .await?; + Ok(()) +} + +#[cfg(test)] +mod tests { + use tempfile::tempdir; + use wiremock::matchers::{method, path}; + use wiremock::{Mock, MockServer, ResponseTemplate}; + + use super::{download_media_async, download_pending_media_async}; + use crate::database::connection::open_or_create_database; + + #[tokio::test] + async fn downloads_pending_media_file() -> anyhow::Result<()> { + let server = MockServer::start().await; + Mock::given(method("GET")) + .and(path("/image.jpg")) + .respond_with( + ResponseTemplate::new(200) + .insert_header("content-type", "image/jpeg") + .set_body_bytes(vec![1_u8, 2, 3]), + ) + .mount(&server) + .await; + + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + let media_root = temp_dir.path().join("archive"); + open_or_create_database(&database_path).await?; + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + sqlx::query( + "INSERT INTO media (media_key, media_type, original_url, download_status) VALUES ('media-1', 'photo', ?, 'metadata_only')", + ) + .bind(format!("{}/image.jpg", server.uri())) + .execute(&pool) + .await?; + + let result = download_pending_media_async(&database_path, &media_root, 10).await?; + + assert_eq!(result.attempted, 1); + assert_eq!(result.downloaded, 1); + let relative_path: String = + sqlx::query_scalar("SELECT local_relative_path FROM media WHERE media_key = 'media-1'") + .fetch_one(&pool) + .await?; + assert_eq!(relative_path, "media/media-1.jpg"); + assert!(media_root.join(relative_path).exists()); + Ok(()) + } + + #[tokio::test] + async fn retries_failed_media_file() -> anyhow::Result<()> { + let server = MockServer::start().await; + Mock::given(method("GET")) + .and(path("/image.jpg")) + .respond_with( + ResponseTemplate::new(200) + .insert_header("content-type", "image/jpeg") + .set_body_bytes(vec![4_u8, 5, 6]), + ) + .mount(&server) + .await; + + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + let media_root = temp_dir.path().join("archive"); + open_or_create_database(&database_path).await?; + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + sqlx::query( + "INSERT INTO media (media_key, media_type, original_url, download_status, last_error) VALUES ('media-retry', 'photo', ?, 'failed', 'old error')", + ) + .bind(format!("{}/image.jpg", server.uri())) + .execute(&pool) + .await?; + + let result = download_media_async(&database_path, &media_root, 10, true).await?; + + assert_eq!(result.attempted, 1); + assert_eq!(result.downloaded, 1); + let (status, last_error): (String, Option) = sqlx::query_as( + "SELECT download_status, last_error FROM media WHERE media_key = 'media-retry'", + ) + .fetch_one(&pool) + .await?; + assert_eq!(status, "downloaded"); + assert_eq!(last_error, None); + Ok(()) + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..8317bf03c0f9f38e8509e4a6ac7e2990dbce16bc --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/mod.rs @@ -0,0 +1,10 @@ +pub mod account_service; +pub mod archive_export_service; +pub mod crawl_task_service; +pub mod credential_service; +pub mod database_service; +pub mod media_download_service; +pub mod path_service; +pub mod post_fetch_service; +pub mod x_api_service; + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/path_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/path_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..0d9e248e6ce1d475943ea043d63167546d8b32d5 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/path_service.rs @@ -0,0 +1,44 @@ +use std::path::{Path, PathBuf}; + +use rfd::FileDialog; + +use crate::config::settings::{AppSettings, ConfigPathKind}; +use crate::utils::disk::system_drive_warning; + +#[derive(Debug, Clone)] +pub struct PathSelectionResult { + pub kind: ConfigPathKind, + pub path: PathBuf, + pub message: String, +} + +pub fn choose_config_directory( + kind: ConfigPathKind, + settings: &mut AppSettings, +) -> anyhow::Result> { + let Some(path) = FileDialog::new().set_title(kind.label()).pick_folder() else { + return Ok(None); + }; + + if !path.exists() { + anyhow::bail!("目录不存在:{}", path.display()); + } + + settings.set_path(kind, &path); + settings.save()?; + + Ok(Some(PathSelectionResult { + kind, + message: message_with_warning(kind, &path), + path, + })) +} + +fn message_with_warning(kind: ConfigPathKind, path: &Path) -> String { + let action = format!("已设置{}", kind.label()); + match system_drive_warning(path) { + Some(warning) => format!("{action}。{warning}"), + None => action, + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/post_fetch_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/post_fetch_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..8e3a8f051b7562ce6e5da67d1d0930d339081d17 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/post_fetch_service.rs @@ -0,0 +1,649 @@ +use chrono::Utc; +use sqlx::{Connection, SqliteConnection, sqlite::SqliteConnectOptions}; +use std::sync::{ + Arc, + atomic::{AtomicBool, Ordering}, +}; +use std::time::Duration; + +use crate::database::migrations::run_migrations; +use crate::services::credential_service::read_bearer_token; +use crate::services::x_api_service::{XMedia, XPost, fetch_user_posts_page}; +use crate::tasks::runtime::BackgroundRuntime; + +#[derive(Debug, Clone)] +pub struct PostFetchResult { + pub received: usize, + pub saved: usize, + pub media_saved: usize, + pub has_next_page: bool, + pub message: String, +} + +#[derive(Debug, Clone)] +pub struct AutoCrawlResult { + pub pages_fetched: usize, + pub posts_received: usize, + pub posts_saved: usize, + pub media_saved: usize, + pub stopped_because_complete: bool, + pub stopped_by_request: bool, + pub message: String, +} + +pub fn fetch_one_page_for_task( + runtime: &BackgroundRuntime, + database_path: &std::path::Path, + job_id: &str, +) -> anyhow::Result { + let token = + read_bearer_token()?.ok_or_else(|| anyhow::anyhow!("请先保存 X API Bearer Token。"))?; + runtime.block_on(fetch_one_page_for_task_async(database_path, job_id, &token))? +} + +pub async fn auto_fetch_pages_for_task_owned_async( + database_path: std::path::PathBuf, + job_id: String, + token: String, + max_pages: usize, + delay_between_pages: Duration, + stop_requested: Arc, +) -> anyhow::Result { + auto_fetch_pages_for_task_async( + &database_path, + &job_id, + &token, + max_pages, + delay_between_pages, + &stop_requested, + ) + .await +} + +pub async fn auto_fetch_pages_for_task_async( + database_path: &std::path::Path, + job_id: &str, + token: &str, + max_pages: usize, + delay_between_pages: Duration, + stop_requested: &AtomicBool, +) -> anyhow::Result { + let mut pages_fetched = 0_usize; + let mut posts_received = 0_usize; + let mut posts_saved = 0_usize; + let mut media_saved = 0_usize; + let mut stopped_because_complete = false; + let mut stopped_by_request = false; + + while max_pages == 0 || pages_fetched < max_pages { + if stop_requested.load(Ordering::Relaxed) { + stopped_by_request = true; + break; + } + let page = match fetch_one_page_for_task_async(database_path, job_id, token).await { + Ok(page) => page, + Err(error) => { + mark_job_failed(database_path, job_id, &error.to_string()).await?; + return Err(error); + } + }; + pages_fetched += 1; + posts_received += page.received; + posts_saved += page.saved; + media_saved += page.media_saved; + if !page.has_next_page { + stopped_because_complete = true; + break; + } + if (max_pages == 0 || pages_fetched < max_pages) && !delay_between_pages.is_zero() { + tokio::time::sleep(delay_between_pages).await; + } + if stop_requested.load(Ordering::Relaxed) { + stopped_by_request = true; + mark_job_stopped(database_path, job_id).await?; + break; + } + } + + if stopped_by_request && pages_fetched == 0 { + mark_job_stopped(database_path, job_id).await?; + } + + Ok(AutoCrawlResult { + pages_fetched, + posts_received, + posts_saved, + media_saved, + stopped_because_complete, + stopped_by_request, + message: format!( + "自动采集结束:拉取 {} 页,收到 {} 条,保存 {} 条,记录媒体 {} 个。{}", + pages_fetched, + posts_received, + posts_saved, + media_saved, + if stopped_by_request { + "已按停止请求结束。" + } else if stopped_because_complete { + "任务已到末页。" + } else { + "已达到本次页数上限。" + } + ), + }) +} + +async fn mark_job_stopped(database_path: &std::path::Path, job_id: &str) -> anyhow::Result<()> { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + sqlx::query( + "UPDATE crawl_jobs SET status = 'stopped', finished_at = ?, paused_at = ? WHERE id = ?", + ) + .bind(Utc::now().to_rfc3339()) + .bind(Utc::now().to_rfc3339()) + .bind(job_id.trim()) + .execute(&mut connection) + .await?; + Ok(()) +} + +async fn mark_job_failed( + database_path: &std::path::Path, + job_id: &str, + error: &str, +) -> anyhow::Result<()> { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + sqlx::query( + "UPDATE crawl_jobs SET status = 'failed', finished_at = ?, error_count = error_count + 1, last_error = ? WHERE id = ?", + ) + .bind(Utc::now().to_rfc3339()) + .bind(error.chars().take(1000).collect::()) + .bind(job_id.trim()) + .execute(&mut connection) + .await?; + Ok(()) +} + +pub async fn fetch_one_page_for_task_async( + database_path: &std::path::Path, + job_id: &str, + token: &str, +) -> anyhow::Result { + let options = SqliteConnectOptions::new() + .filename(database_path) + .create_if_missing(false); + let mut connection = SqliteConnection::connect_with(&options).await?; + run_migrations(&mut connection).await?; + + let job: Option<(String, String)> = sqlx::query_as( + "SELECT target_x_user_id, target_username FROM crawl_jobs WHERE id = ? LIMIT 1", + ) + .bind(job_id.trim()) + .fetch_optional(&mut connection) + .await?; + let Some((target_x_user_id, target_username)) = job else { + anyhow::bail!("未找到采集任务:{}。", job_id) + }; + + sqlx::query("UPDATE crawl_jobs SET status = 'running', started_at = COALESCE(started_at, ?) WHERE id = ?") + .bind(Utc::now().to_rfc3339()) + .bind(job_id) + .execute(&mut connection) + .await?; + + let pagination_token: Option = sqlx::query_scalar( + "SELECT pagination_token FROM crawl_checkpoints WHERE job_id = ? LIMIT 1", + ) + .bind(job_id.trim()) + .fetch_optional(&mut connection) + .await?; + let page = match fetch_user_posts_page( + token, + &target_x_user_id, + 10, + pagination_token.as_deref(), + ) + .await + { + Ok(page) => page, + Err(error) => { + let now = Utc::now().to_rfc3339(); + sqlx::query( + "UPDATE crawl_jobs SET status = 'failed', finished_at = ?, error_count = error_count + 1, last_error = ? WHERE id = ?", + ) + .bind(&now) + .bind(error.to_string().chars().take(1000).collect::()) + .bind(job_id.trim()) + .execute(&mut connection) + .await?; + return Err(error); + } + }; + let posts = page.posts; + let media = page.media; + let received = posts.len(); + let mut media_saved = 0_usize; + for item in &media { + save_media(&mut connection, item).await?; + media_saved += 1; + } + let mut saved = 0_usize; + for post in &posts { + save_post( + &mut connection, + post, + &target_x_user_id, + &target_username, + job_id, + ) + .await?; + saved += 1; + } + + let has_next_page = page.next_token.is_some(); + let next_status = if has_next_page { + "page_fetched" + } else { + "completed" + }; + let checkpoint_updated_at = Utc::now().to_rfc3339(); + sqlx::query( + "INSERT INTO crawl_checkpoints (job_id, pagination_token, last_successful_page, updated_at) VALUES (?, ?, 1, ?) ON CONFLICT(job_id) DO UPDATE SET pagination_token = excluded.pagination_token, last_successful_page = crawl_checkpoints.last_successful_page + 1, updated_at = excluded.updated_at", + ) + .bind(job_id) + .bind(&page.next_token) + .bind(&checkpoint_updated_at) + .execute(&mut connection) + .await?; + + sqlx::query( + "UPDATE crawl_jobs SET status = ?, finished_at = ?, pages_fetched = pages_fetched + 1, posts_received = posts_received + ?, posts_inserted = posts_inserted + ? WHERE id = ?", + ) + .bind(next_status) + .bind(Utc::now().to_rfc3339()) + .bind(received as i64) + .bind(saved as i64) + .bind(job_id) + .execute(&mut connection) + .await?; + + connection.close().await?; + Ok(PostFetchResult { + received, + saved, + media_saved, + has_next_page, + message: format!( + "已拉取下一页公开帖子:收到 {} 条,保存 {} 条,记录媒体 {} 个。{}", + received, + saved, + media_saved, + if has_next_page { + "还有下一页。" + } else { + "已经没有下一页。" + } + ), + }) +} + +async fn save_post( + connection: &mut SqliteConnection, + post: &XPost, + author_x_user_id: &str, + author_username: &str, + job_id: &str, +) -> anyhow::Result<()> { + let now = Utc::now().to_rfc3339(); + let original_url = format!("https://x.com/{}/status/{}", author_username, post.id); + sqlx::query( + r#" + INSERT INTO posts ( + x_post_id, author_x_user_id, author_username, text, created_at_x, + original_url, conversation_id, like_count, reply_count, repost_count, quote_count, + first_fetched_at, last_fetched_at, source_job_id, raw_json, data_source + ) + VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 'x_api') + ON CONFLICT(x_post_id) DO UPDATE SET + text = excluded.text, + created_at_x = excluded.created_at_x, + original_url = excluded.original_url, + conversation_id = excluded.conversation_id, + like_count = excluded.like_count, + reply_count = excluded.reply_count, + repost_count = excluded.repost_count, + quote_count = excluded.quote_count, + last_fetched_at = excluded.last_fetched_at, + source_job_id = excluded.source_job_id, + raw_json = excluded.raw_json, + data_source = excluded.data_source + "#, + ) + .bind(&post.id) + .bind(author_x_user_id) + .bind(author_username) + .bind(&post.text) + .bind(&post.created_at) + .bind(original_url) + .bind(&post.conversation_id) + .bind( + post.public_metrics + .as_ref() + .and_then(|value| value.like_count), + ) + .bind( + post.public_metrics + .as_ref() + .and_then(|value| value.reply_count), + ) + .bind( + post.public_metrics + .as_ref() + .and_then(|value| value.retweet_count), + ) + .bind( + post.public_metrics + .as_ref() + .and_then(|value| value.quote_count), + ) + .bind(&now) + .bind(&now) + .bind(job_id) + .bind(serde_json::to_string(&post.raw_json)?) + .execute(&mut *connection) + .await?; + + for (index, media_key) in post.media_keys.iter().enumerate() { + sqlx::query( + "INSERT OR REPLACE INTO post_media (post_id, media_key, display_order) VALUES (?, ?, ?)", + ) + .bind(&post.id) + .bind(media_key) + .bind(index as i64) + .execute(&mut *connection) + .await?; + } + Ok(()) +} + +async fn save_media(connection: &mut SqliteConnection, media: &XMedia) -> anyhow::Result<()> { + sqlx::query( + r#" + INSERT INTO media ( + media_key, media_type, original_url, preview_url, width, height, duration_ms, + download_status, raw_json + ) + VALUES (?, ?, ?, ?, ?, ?, ?, 'metadata_only', ?) + ON CONFLICT(media_key) DO UPDATE SET + media_type = excluded.media_type, + original_url = excluded.original_url, + preview_url = excluded.preview_url, + width = excluded.width, + height = excluded.height, + duration_ms = excluded.duration_ms, + raw_json = excluded.raw_json + "#, + ) + .bind(&media.media_key) + .bind(&media.media_type) + .bind(&media.url) + .bind(&media.preview_image_url) + .bind(media.width) + .bind(media.height) + .bind(media.duration_ms) + .bind(serde_json::to_string(&media.raw_json)?) + .execute(connection) + .await?; + Ok(()) +} + +#[cfg(test)] +mod tests { + use sqlx::{Connection, SqliteConnection}; + use std::sync::atomic::AtomicBool; + use std::time::Duration; + use tempfile::tempdir; + use wiremock::matchers::{header, method, path, query_param}; + use wiremock::{Mock, MockServer, ResponseTemplate}; + + use super::{auto_fetch_pages_for_task_async, fetch_one_page_for_task_async}; + use crate::config::settings::AppSettings; + use crate::database::connection::open_or_create_database; + use crate::services::account_service::save_account_profile; + use crate::services::crawl_task_service::create_crawl_task; + use crate::services::x_api_service::{XAccountProfile, set_scoped_test_base_url}; + + #[tokio::test] + async fn fetches_and_saves_one_page() -> anyhow::Result<()> { + let server = MockServer::start().await; + let _base_url_guard = set_scoped_test_base_url(server.uri()); + Mock::given(method("GET")) + .and(path("/2/users/123/tweets")) + .and(query_param("max_results", "10")) + .and(header("authorization", "Bearer test-token")) + .respond_with(ResponseTemplate::new(200).set_body_json(serde_json::json!({ + "data": [ + { "id": "post-1", "text": "hello", "created_at": "2026-07-11T00:00:00Z", "public_metrics": { "like_count": 1, "reply_count": 2, "retweet_count": 3, "quote_count": 4 }, "attachments": { "media_keys": ["media-1"] } } + ], + "includes": { + "media": [ + { "media_key": "media-1", "type": "photo", "url": "https://example.com/image.jpg", "width": 640, "height": 480 } + ] + }, + "meta": { "next_token": "next-page" } + }))) + .up_to_n_times(1) + .mount(&server) + .await; + Mock::given(method("GET")) + .and(path("/2/users/123/tweets")) + .and(query_param("max_results", "10")) + .and(query_param("pagination_token", "next-page")) + .and(header("authorization", "Bearer test-token")) + .respond_with(ResponseTemplate::new(200).set_body_json(serde_json::json!({ + "data": [ + { "id": "post-2", "text": "world", "created_at": "2026-07-11T00:01:00Z" } + ], + "meta": { "result_count": 1 } + }))) + .mount(&server) + .await; + + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + let job = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + let result = + fetch_one_page_for_task_async(&database_path, &job.job_id, "test-token").await?; + + assert_eq!(result.received, 1); + assert_eq!(result.saved, 1); + assert_eq!(result.media_saved, 1); + assert!(result.has_next_page); + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + let text: String = sqlx::query_scalar("SELECT text FROM posts WHERE x_post_id = 'post-1'") + .fetch_one(&pool) + .await?; + assert_eq!(text, "hello"); + let media_type: String = + sqlx::query_scalar("SELECT media_type FROM media WHERE media_key = 'media-1'") + .fetch_one(&pool) + .await?; + assert_eq!(media_type, "photo"); + let linked_media: String = + sqlx::query_scalar("SELECT media_key FROM post_media WHERE post_id = 'post-1'") + .fetch_one(&pool) + .await?; + assert_eq!(linked_media, "media-1"); + let checkpoint: String = + sqlx::query_scalar("SELECT pagination_token FROM crawl_checkpoints WHERE job_id = ?") + .bind(&job.job_id) + .fetch_one(&pool) + .await?; + assert_eq!(checkpoint, "next-page"); + + let second_result = + fetch_one_page_for_task_async(&database_path, &job.job_id, "test-token").await?; + assert_eq!(second_result.received, 1); + assert_eq!(second_result.saved, 1); + assert_eq!(second_result.media_saved, 0); + assert!(!second_result.has_next_page); + let second_text: String = + sqlx::query_scalar("SELECT text FROM posts WHERE x_post_id = 'post-2'") + .fetch_one(&pool) + .await?; + assert_eq!(second_text, "world"); + let checkpoint_after_second: Option = + sqlx::query_scalar("SELECT pagination_token FROM crawl_checkpoints WHERE job_id = ?") + .bind(&job.job_id) + .fetch_one(&pool) + .await?; + assert_eq!(checkpoint_after_second, None); + Ok(()) + } + + #[tokio::test] + async fn marks_job_failed_when_post_fetch_fails() -> anyhow::Result<()> { + let server = MockServer::start().await; + let _base_url_guard = set_scoped_test_base_url(server.uri()); + Mock::given(method("GET")) + .and(path("/2/users/123/tweets")) + .and(query_param("max_results", "10")) + .and(header("authorization", "Bearer test-token")) + .respond_with(ResponseTemplate::new(500).set_body_string("server error")) + .mount(&server) + .await; + + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + let job = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + let result = fetch_one_page_for_task_async(&database_path, &job.job_id, "test-token").await; + + assert!(result.is_err()); + let pool = + sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + let (status, error_count, last_error): (String, i64, Option) = + sqlx::query_as("SELECT status, error_count, last_error FROM crawl_jobs WHERE id = ?") + .bind(&job.job_id) + .fetch_one(&pool) + .await?; + assert_eq!(status, "failed"); + assert_eq!(error_count, 1); + assert!( + last_error + .unwrap_or_default() + .contains("X API 返回异常状态") + ); + Ok(()) + } + + #[tokio::test] + async fn auto_fetches_until_last_page() -> anyhow::Result<()> { + let server = MockServer::start().await; + let _base_url_guard = set_scoped_test_base_url(server.uri()); + Mock::given(method("GET")) + .and(path("/2/users/123/tweets")) + .and(query_param("max_results", "10")) + .and(header("authorization", "Bearer test-token")) + .respond_with(ResponseTemplate::new(200).set_body_json(serde_json::json!({ + "data": [{ "id": "post-a", "text": "first" }], + "meta": { "next_token": "next-page" } + }))) + .up_to_n_times(1) + .mount(&server) + .await; + Mock::given(method("GET")) + .and(path("/2/users/123/tweets")) + .and(query_param("max_results", "10")) + .and(query_param("pagination_token", "next-page")) + .and(header("authorization", "Bearer test-token")) + .respond_with(ResponseTemplate::new(200).set_body_json(serde_json::json!({ + "data": [{ "id": "post-b", "text": "second" }], + "meta": { "result_count": 1 } + }))) + .mount(&server) + .await; + + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + let job = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + let stop_requested = AtomicBool::new(false); + let result = auto_fetch_pages_for_task_async( + &database_path, + &job.job_id, + "test-token", + 3, + Duration::ZERO, + &stop_requested, + ) + .await?; + + assert_eq!(result.pages_fetched, 2); + assert_eq!(result.posts_received, 2); + assert!(result.stopped_because_complete); + assert!(!result.stopped_by_request); + Ok(()) + } + + #[tokio::test] + async fn auto_fetch_respects_stop_request_before_next_page() -> anyhow::Result<()> { + let temp_dir = tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + open_or_create_database(&database_path).await?; + save_account_profile(&database_path, &test_profile()).await?; + let job = create_crawl_task(&database_path, "alice", &AppSettings::default()).await?; + + let stop_requested = AtomicBool::new(true); + let result = auto_fetch_pages_for_task_async( + &database_path, + &job.job_id, + "test-token", + 3, + Duration::ZERO, + &stop_requested, + ) + .await?; + + let status: String = sqlx::query_scalar("SELECT status FROM crawl_jobs WHERE id = ?") + .bind(&job.job_id) + .fetch_one(&mut SqliteConnection::connect(&database_path.to_string_lossy()).await?) + .await?; + + assert_eq!(result.pages_fetched, 0); + assert_eq!(result.posts_received, 0); + assert!(result.stopped_by_request); + assert!(!result.stopped_because_complete); + assert_eq!(status, "stopped"); + Ok(()) + } + + fn test_profile() -> XAccountProfile { + XAccountProfile { + id: "123".to_owned(), + username: "alice".to_owned(), + name: Some("Alice".to_owned()), + description: None, + profile_image_url: None, + created_at: None, + protected: Some(false), + verified: None, + public_metrics: None, + raw_json: serde_json::json!({"data":{"id":"123"}}), + } + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/services/x_api_service.rs b/XPostArchiver-clean-upload-20260711-225630/src/services/x_api_service.rs new file mode 100644 index 0000000000000000000000000000000000000000..ee0b8c459a59eeba8e4872745846969594e6c0c2 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/services/x_api_service.rs @@ -0,0 +1,437 @@ +use reqwest::StatusCode; +use serde::{Deserialize, Serialize}; +use std::sync::{Mutex, OnceLock}; + +const DEFAULT_BASE_URL: &str = "https://api.x.com"; +const DEFAULT_VERIFY_USERNAME: &str = "X"; +pub(crate) const USER_FIELDS: &str = + "id,username,name,description,profile_image_url,created_at,protected,verified,public_metrics"; +const POST_FIELDS: &str = "id,text,created_at,conversation_id,public_metrics,attachments"; +const MEDIA_FIELDS: &str = "media_key,type,url,preview_image_url,width,height,duration_ms"; + +static TEST_BASE_URL: OnceLock>> = OnceLock::new(); +#[cfg(test)] +static TEST_BASE_URL_LOCK: OnceLock> = OnceLock::new(); + +#[cfg(test)] +#[allow(dead_code)] +pub(crate) struct TestBaseUrlGuard(std::sync::MutexGuard<'static, ()>); + +#[cfg(test)] +impl Drop for TestBaseUrlGuard { + fn drop(&mut self) { + set_test_base_url(None); + } +} + +#[cfg(test)] +pub(crate) fn set_scoped_test_base_url(value: String) -> TestBaseUrlGuard { + let guard = TEST_BASE_URL_LOCK + .get_or_init(|| Mutex::new(())) + .lock() + .expect("test base url lock poisoned"); + set_test_base_url(Some(value)); + TestBaseUrlGuard(guard) +} + +#[cfg(test)] +pub(crate) fn set_test_base_url(value: Option) { + let mut guard = TEST_BASE_URL + .get_or_init(|| Mutex::new(None)) + .lock() + .expect("test base url mutex poisoned"); + *guard = value; +} + +fn effective_base_url() -> String { + TEST_BASE_URL + .get_or_init(|| Mutex::new(None)) + .lock() + .expect("test base url mutex poisoned") + .clone() + .unwrap_or_else(|| DEFAULT_BASE_URL.to_owned()) +} + +#[derive(Debug, Clone)] +pub struct ApiValidationResult { + pub valid: bool, + pub message: String, +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct XAccountProfile { + pub id: String, + pub username: String, + pub name: Option, + pub description: Option, + pub profile_image_url: Option, + pub created_at: Option, + pub protected: Option, + pub verified: Option, + pub public_metrics: Option, + pub raw_json: serde_json::Value, +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct XAccountPublicMetrics { + pub followers_count: Option, + pub following_count: Option, + pub tweet_count: Option, +} + +pub async fn validate_bearer_token(token: &str) -> anyhow::Result { + validate_bearer_token_with_base_url(token, &effective_base_url(), DEFAULT_VERIFY_USERNAME).await +} + +pub async fn validate_bearer_token_with_base_url( + token: &str, + base_url: &str, + username: &str, +) -> anyhow::Result { + let profile = lookup_public_account_with_base_url(token, base_url, username).await?; + Ok(ApiValidationResult { + valid: true, + message: format!( + "X API 凭据验证通过。可访问公开账号:@{}。", + profile.username + ), + }) +} + +pub async fn lookup_public_account(token: &str, username: &str) -> anyhow::Result { + lookup_public_account_with_base_url(token, &effective_base_url(), username).await +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct XPost { + pub id: String, + pub text: String, + pub created_at: Option, + pub conversation_id: Option, + pub public_metrics: Option, + pub media_keys: Vec, + pub raw_json: serde_json::Value, +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct XPostPublicMetrics { + pub like_count: Option, + pub reply_count: Option, + pub retweet_count: Option, + pub quote_count: Option, +} + +#[derive(Debug, Clone)] +pub struct XPostPage { + pub posts: Vec, + pub media: Vec, + pub next_token: Option, +} + +#[derive(Debug, Clone, Serialize, Deserialize)] +pub struct XMedia { + pub media_key: String, + #[serde(rename = "type")] + pub media_type: String, + pub url: Option, + pub preview_image_url: Option, + pub width: Option, + pub height: Option, + pub duration_ms: Option, + pub raw_json: serde_json::Value, +} + +pub async fn fetch_user_posts_page( + token: &str, + user_id: &str, + max_results: u8, + pagination_token: Option<&str>, +) -> anyhow::Result { + fetch_user_posts_page_with_base_url( + token, + &effective_base_url(), + user_id, + max_results, + pagination_token, + ) + .await +} + +pub async fn fetch_user_posts_page_with_base_url( + token: &str, + base_url: &str, + user_id: &str, + max_results: u8, + pagination_token: Option<&str>, +) -> anyhow::Result { + let token = token.trim(); + let user_id = user_id.trim(); + if token.is_empty() { + anyhow::bail!("Bearer Token 不能为空。") + } + if user_id.is_empty() { + anyhow::bail!("用户ID不能为空。") + } + + let mut url = format!( + "{}/2/users/{}/tweets?max_results={}&tweet.fields={}&expansions=attachments.media_keys&media.fields={}", + base_url.trim_end_matches('/'), + user_id, + max_results, + POST_FIELDS, + MEDIA_FIELDS + ); + if let Some(token) = pagination_token + .map(str::trim) + .filter(|value| !value.is_empty()) + { + url.push_str("&pagination_token="); + url.push_str(token); + } + let response = reqwest::Client::new() + .get(url) + .bearer_auth(token) + .send() + .await?; + let status = response.status(); + + match status { + StatusCode::OK => { + let raw_json = response.json::().await?; + let body = serde_json::from_value::(raw_json.clone())?; + let posts = body + .data + .unwrap_or_default() + .into_iter() + .map(|tweet| XPost { + id: tweet.id, + text: tweet.text, + created_at: tweet.created_at, + conversation_id: tweet.conversation_id, + public_metrics: tweet.public_metrics, + media_keys: tweet + .attachments + .map(|attachments| attachments.media_keys) + .unwrap_or_default(), + raw_json: raw_json.clone(), + }) + .collect(); + let media = body + .includes + .and_then(|includes| includes.media) + .unwrap_or_default() + .into_iter() + .map(|media| XMedia { + media_key: media.media_key, + media_type: media.media_type, + url: media.url, + preview_image_url: media.preview_image_url, + width: media.width, + height: media.height, + duration_ms: media.duration_ms, + raw_json: raw_json.clone(), + }) + .collect(); + Ok(XPostPage { + posts, + media, + next_token: body.meta.and_then(|meta| meta.next_token), + }) + } + StatusCode::UNAUTHORIZED => anyhow::bail!("X API 凭据无效或已过期。"), + StatusCode::FORBIDDEN => anyhow::bail!("X API 凭据权限不足,无法访问该账号帖子接口。"), + StatusCode::TOO_MANY_REQUESTS => anyhow::bail!("X API 速率限制已触发,请稍后再试。"), + _ => anyhow::bail!("X API 返回异常状态:{}。", status.as_u16()), + } +} + +pub async fn lookup_public_account_with_base_url( + token: &str, + base_url: &str, + username: &str, +) -> anyhow::Result { + let token = token.trim(); + let username = username.trim().trim_start_matches('@'); + if token.is_empty() { + anyhow::bail!("Bearer Token 不能为空。") + } + if username.is_empty() { + anyhow::bail!("用户名不能为空。") + } + + let url = format!( + "{}/2/users/by/username/{}?user.fields={}", + base_url.trim_end_matches('/'), + username, + USER_FIELDS + ); + let response = reqwest::Client::new() + .get(url) + .bearer_auth(token) + .send() + .await?; + let status = response.status(); + + match status { + StatusCode::OK => { + let raw_json = response.json::().await?; + let body = serde_json::from_value::(raw_json.clone())?; + Ok(XAccountProfile { + id: body.data.id, + username: body.data.username, + name: body.data.name, + description: body.data.description, + profile_image_url: body.data.profile_image_url, + created_at: body.data.created_at, + protected: body.data.protected, + verified: body.data.verified, + public_metrics: body.data.public_metrics, + raw_json, + }) + } + StatusCode::UNAUTHORIZED => anyhow::bail!("X API 凭据无效或已过期。"), + StatusCode::FORBIDDEN => anyhow::bail!("X API 凭据权限不足,无法访问该账号查询接口。"), + StatusCode::NOT_FOUND => anyhow::bail!("未找到公开账号:@{}。", username), + StatusCode::TOO_MANY_REQUESTS => anyhow::bail!("X API 速率限制已触发,请稍后再试。"), + _ => anyhow::bail!("X API 返回异常状态:{}。", status.as_u16()), + } +} + +#[derive(Debug, Deserialize)] +struct TweetLookupResponse { + data: Option>, + includes: Option, + meta: Option, +} + +#[derive(Debug, Deserialize)] +struct TweetIncludes { + media: Option>, +} + +#[derive(Debug, Deserialize)] +struct MediaData { + media_key: String, + #[serde(rename = "type")] + media_type: String, + url: Option, + preview_image_url: Option, + width: Option, + height: Option, + duration_ms: Option, +} + +#[derive(Debug, Deserialize)] +struct TweetMeta { + next_token: Option, +} + +#[derive(Debug, Deserialize)] +struct TweetData { + id: String, + text: String, + created_at: Option, + conversation_id: Option, + public_metrics: Option, + attachments: Option, +} + +#[derive(Debug, Deserialize)] +struct TweetAttachments { + media_keys: Vec, +} + +#[derive(Debug, Deserialize)] +struct UserLookupResponse { + data: UserData, +} + +#[derive(Debug, Deserialize)] +struct UserData { + id: String, + username: String, + name: Option, + description: Option, + profile_image_url: Option, + created_at: Option, + protected: Option, + verified: Option, + public_metrics: Option, +} + +#[cfg(test)] +mod tests { + use super::{ + USER_FIELDS, lookup_public_account_with_base_url, validate_bearer_token_with_base_url, + }; + use wiremock::matchers::{header, method, path, query_param}; + use wiremock::{Mock, MockServer, ResponseTemplate}; + + #[tokio::test] + async fn validates_ok_response() -> anyhow::Result<()> { + let server = MockServer::start().await; + mount_account_response(&server, "X", 200).await; + + let result = validate_bearer_token_with_base_url("test-token", &server.uri(), "X").await?; + + assert!(result.valid); + assert!(result.message.contains("验证通过")); + Ok(()) + } + + #[tokio::test] + async fn reports_unauthorized_response() -> anyhow::Result<()> { + let server = MockServer::start().await; + Mock::given(method("GET")) + .and(path("/2/users/by/username/X")) + .respond_with(ResponseTemplate::new(401)) + .mount(&server) + .await; + + let error = validate_bearer_token_with_base_url("bad-token", &server.uri(), "X") + .await + .unwrap_err(); + + assert!(error.to_string().contains("无效")); + Ok(()) + } + + #[tokio::test] + async fn looks_up_public_account() -> anyhow::Result<()> { + let server = MockServer::start().await; + mount_account_response(&server, "alice", 200).await; + + let profile = + lookup_public_account_with_base_url("test-token", &server.uri(), "alice").await?; + + assert_eq!(profile.id, "1"); + assert_eq!(profile.username, "alice"); + assert_eq!(profile.public_metrics.unwrap().followers_count, Some(10)); + Ok(()) + } + + async fn mount_account_response(server: &MockServer, username: &str, status: u16) { + Mock::given(method("GET")) + .and(path(format!("/2/users/by/username/{username}"))) + .and(query_param("user.fields", USER_FIELDS)) + .and(header("authorization", "Bearer test-token")) + .respond_with( + ResponseTemplate::new(status).set_body_json(serde_json::json!({ + "data": { + "id": "1", + "username": username, + "name": "Alice", + "description": "public account", + "public_metrics": { + "followers_count": 10, + "following_count": 2, + "tweet_count": 30 + } + } + })), + ) + .mount(server) + .await; + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/tasks/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/tasks/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..21e225be3b80ab317e792474b27b9fec238674d9 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/tasks/mod.rs @@ -0,0 +1,2 @@ +pub mod runtime; + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/tasks/runtime.rs b/XPostArchiver-clean-upload-20260711-225630/src/tasks/runtime.rs new file mode 100644 index 0000000000000000000000000000000000000000..98edbda8fa9ffb448d8f553f1f290958ed892316 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/tasks/runtime.rs @@ -0,0 +1,47 @@ +use tokio::runtime::{Builder, Runtime}; +use tokio_util::sync::CancellationToken; + +pub struct BackgroundRuntime { + runtime: Option, + cancellation: CancellationToken, +} + +impl BackgroundRuntime { + pub fn new() -> anyhow::Result { + let runtime = Builder::new_multi_thread() + .worker_threads(2) + .enable_all() + .thread_name("xpost-archiver-worker") + .build()?; + let cancellation = CancellationToken::new(); + Ok(Self { + runtime: Some(runtime), + cancellation, + }) + } + + pub fn cancellation_token(&self) -> CancellationToken { + self.cancellation.clone() + } + + pub fn block_on(&self, future: F) -> anyhow::Result + where + F: std::future::Future, + { + let runtime = self + .runtime + .as_ref() + .ok_or_else(|| anyhow::anyhow!("后台运行时已关闭"))?; + Ok(runtime.block_on(future)) + } +} + +impl Drop for BackgroundRuntime { + fn drop(&mut self) { + self.cancellation.cancel(); + if let Some(runtime) = self.runtime.take() { + runtime.shutdown_timeout(std::time::Duration::from_secs(3)); + } + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/ui_bridge/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/ui_bridge/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..0fd4dd41141fe45e3d8d19cffe064184c90e0048 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/ui_bridge/mod.rs @@ -0,0 +1,2 @@ + + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/utils/disk.rs b/XPostArchiver-clean-upload-20260711-225630/src/utils/disk.rs new file mode 100644 index 0000000000000000000000000000000000000000..6e7e2f1dddfdb3dcb0150f1fbdadc642b6c31a72 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/utils/disk.rs @@ -0,0 +1,33 @@ +use std::path::Path; + +pub fn is_on_system_drive(path: &Path) -> bool { + let Some(system_drive) = std::env::var_os("SystemDrive") else { + return false; + }; + let system_drive = system_drive.to_string_lossy().to_ascii_lowercase(); + let path_text = path.as_os_str().to_string_lossy().to_ascii_lowercase(); + path_text.starts_with(&system_drive) +} + +pub fn system_drive_warning(path: &Path) -> Option<&'static str> { + if is_on_system_drive(path) { + Some( + "当前数据位置位于Windows系统盘。帖子数据库、图片和视频可能持续增长,建议使用空间较充足的非系统盘。", + ) + } else { + None + } +} + +#[cfg(test)] +mod tests { + use std::path::Path; + + use super::is_on_system_drive; + + #[test] + fn detects_system_drive_prefix_without_panicking() { + let _ = is_on_system_drive(Path::new("C:\\example")); + } +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/src/utils/mod.rs b/XPostArchiver-clean-upload-20260711-225630/src/utils/mod.rs new file mode 100644 index 0000000000000000000000000000000000000000..313affa5cfccf2754b9311421697485464d6ccd2 --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/src/utils/mod.rs @@ -0,0 +1,2 @@ +pub mod disk; + diff --git a/XPostArchiver-clean-upload-20260711-225630/tests/database_migration.rs b/XPostArchiver-clean-upload-20260711-225630/tests/database_migration.rs new file mode 100644 index 0000000000000000000000000000000000000000..132665a95f7a39bfd3c3dee6dd3d2033652d13ae --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/tests/database_migration.rs @@ -0,0 +1,51 @@ +use xpost_archiver::database::connection::open_or_create_database; +use xpost_archiver::database::maintenance::{backup_database, check_database_integrity}; + +#[tokio::test] +async fn creates_database_and_runs_initial_migration() -> anyhow::Result<()> { + let temp_dir = tempfile::tempdir()?; + let database_path = temp_dir.path().join("测试 数据库.db"); + + open_or_create_database(&database_path).await?; + + let pool = sqlx::SqlitePool::connect(&format!("sqlite://{}", database_path.display())).await?; + let table_count: i64 = sqlx::query_scalar( + "SELECT COUNT(*) FROM sqlite_master WHERE type = 'table' AND name IN ('accounts', 'posts', 'crawl_jobs', 'crawl_checkpoints')", + ) + .fetch_one(&pool) + .await?; + + assert_eq!(table_count, 4); + Ok(()) +} + +#[tokio::test] +async fn integrity_check_passes_for_new_database() -> anyhow::Result<()> { + let temp_dir = tempfile::tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + + open_or_create_database(&database_path).await?; + let message = check_database_integrity(&database_path).await?; + + assert_eq!(message, "数据库完整性检查通过。"); + Ok(()) +} + +#[tokio::test] +async fn backup_database_creates_timestamped_copy() -> anyhow::Result<()> { + let temp_dir = tempfile::tempdir()?; + let database_path = temp_dir.path().join("archive.db"); + let backup_dir = temp_dir.path().join("backups"); + + open_or_create_database(&database_path).await?; + let backup = backup_database(&database_path, &backup_dir)?; + + assert!(backup.path.exists()); + assert!(backup.path.starts_with(&backup_dir)); + assert_eq!( + std::fs::metadata(&database_path)?.len(), + std::fs::metadata(&backup.path)?.len() + ); + Ok(()) +} + diff --git a/XPostArchiver-clean-upload-20260711-225630/ui/app-window.slint b/XPostArchiver-clean-upload-20260711-225630/ui/app-window.slint new file mode 100644 index 0000000000000000000000000000000000000000..ad649e9daa1d038752fea497a0e3eea7d256d0fe --- /dev/null +++ b/XPostArchiver-clean-upload-20260711-225630/ui/app-window.slint @@ -0,0 +1,219 @@ +import { Button, LineEdit, ScrollView } from "std-widgets.slint"; + +component Section inherits Rectangle { + in property title; + in property subtitle; + + border-width: 1px; + border-color: #b9c0cc; + border-radius: 6px; + background: #f7f8fa; + + VerticalLayout { + padding: 14px; + spacing: 8px; + + Text { text: root.title; font-size: 18px; font-weight: 700; } + Text { text: root.subtitle; wrap: word-wrap; font-size: 13px; color: #44515f; } + @children + } +} + +export component AppWindow inherits Window { + callback create-database(); + callback open-database(); + callback check-database(); + callback backup-database(); + callback choose-media-root(); + callback choose-export-dir(); + callback choose-log-dir(); + callback choose-backup-dir(); + callback choose-temp-dir(); + callback enable-media-files(); + callback disable-media-files(); + callback save-bearer-token(string); + callback validate-bearer-token(); + callback clear-bearer-token(); + callback lookup-account(string); + callback create-crawl-task(string); + callback refresh-crawl-tasks(); + callback fetch-one-page(string); + callback auto-fetch-pages(string, string, string); + callback stop-auto-crawl(); + callback preview-archive(string); + callback export-archive(string); + callback download-media(); + callback retry-failed-media(); + + in-out property database-path: "未选择数据库"; + in-out property media-root: "未设置"; + in-out property export-dir: "未设置"; + in-out property log-dir: "未设置"; + in-out property backup-dir: "未设置"; + in-out property temp-dir: "未设置"; + in-out property status-message: "请选择或新建SQLite数据库后再开始采集。"; + in-out property credential-status: "尚未配置 X API Bearer Token。"; + in-out property account-status: "尚未查询公开账号。"; + in-out property crawl-task-status: "尚未创建采集任务。"; + in-out property crawl-task-list: "尚未刷新任务列表。"; + in-out property selected-job-id: ""; + in-out property fetch-status: "尚未拉取帖子。"; + in-out property auto-crawl-status: "尚未自动采集。"; + in-out property archive-preview: "尚未预览归档。"; + in-out property media-download-status: "尚未下载媒体文件。"; + in-out property database-ready: false; + in-out property save-media-files: true; + in-out property credentials-ready: false; + + title: "X公开帖子归档器"; + min-width: 760px; + min-height: 560px; + + ScrollView { + VerticalLayout { + padding: 24px; + spacing: 12px; + + Text { + text: "X公开帖子归档器"; + font-size: 28px; + horizontal-alignment: center; + } + + Text { + text: "首次启动先完成数据库、目录和维护设置;采集只会在X API权限和公开可访问范围内工作。"; + wrap: word-wrap; + font-size: 15px; + horizontal-alignment: center; + } + + Section { + title: "步骤 1:数据库"; + subtitle: "选择一个SQLite数据库文件。新建或打开后会自动执行迁移。"; + height: 190px; + + Text { text: root.database-path; wrap: word-wrap; font-size: 13px; } + Text { + text: root.status-message; + wrap: word-wrap; + color: root.database-ready ? #216e39 : #8a4b00; + font-size: 13px; + } + + HorizontalLayout { + alignment: start; + spacing: 10px; + Button { text: "新建数据库"; clicked => { root.create-database(); } } + Button { text: "打开已有数据库"; clicked => { root.open-database(); } } + Button { text: "检查数据库"; clicked => { root.check-database(); } } + Button { text: "备份数据库"; clicked => { root.backup-database(); } } + } + } + + Section { + title: "步骤 2:归档内容"; + subtitle: "文本记录始终进入数据库;可选择是否把图片、视频、GIF等媒体文件一并保存到同一份归档内容目录。"; + height: 300px; + + HorizontalLayout { + spacing: 10px; + Text { + text: root.save-media-files ? "保存媒体文件:是" : "保存媒体文件:否,只保存文本和媒体链接信息"; + font-weight: 700; + } + Button { text: "保存媒体"; clicked => { root.enable-media-files(); } } + Button { text: "只保存文本"; clicked => { root.disable-media-files(); } } + } + + GridLayout { + spacing: 8px; + + Text { text: "归档内容目录"; font-weight: 700; } + Text { text: root.media-root; wrap: word-wrap; } + Button { text: "选择"; clicked => { root.choose-media-root(); } } + + Text { text: "导出目录"; font-weight: 700; } + Text { text: root.export-dir; wrap: word-wrap; } + Button { text: "选择"; clicked => { root.choose-export-dir(); } } + + Text { text: "日志目录"; font-weight: 700; } + Text { text: root.log-dir; wrap: word-wrap; } + Button { text: "选择"; clicked => { root.choose-log-dir(); } } + + Text { text: "备份目录"; font-weight: 700; } + Text { text: root.backup-dir; wrap: word-wrap; } + Button { text: "选择"; clicked => { root.choose-backup-dir(); } } + + Text { text: "临时下载目录"; font-weight: 700; } + Text { text: root.temp-dir; wrap: word-wrap; } + Button { text: "选择"; clicked => { root.choose-temp-dir(); } } + } + } + + Section { + title: "步骤 3:X API 凭据"; + subtitle: "Bearer Token 保存到系统密钥库,不写入普通配置文件。"; + height: 138px; + + Text { text: root.credential-status; color: root.credentials-ready ? #216e39 : #8a4b00; } + HorizontalLayout { + spacing: 10px; + token-input := LineEdit { placeholder-text: "粘贴 X API Bearer Token"; input-type: InputType.password; } + Button { text: "保存凭据"; clicked => { root.save-bearer-token(token-input.text); token-input.text = ""; } } + Button { text: "检查凭据"; clicked => { root.validate-bearer-token(); } } + Button { text: "清除凭据"; clicked => { root.clear-bearer-token(); token-input.text = ""; } } + } + } + + Section { + title: "步骤 4:公开账号"; + subtitle: "输入 X 用户名,查询公开账号基础信息并保存到当前数据库;这里不会采集帖子。"; + height: 138px; + + Text { text: root.account-status; wrap: word-wrap; } + HorizontalLayout { + spacing: 10px; + account-input := LineEdit { placeholder-text: "例如:X 或 elonmusk"; } + Button { text: "查询账号"; clicked => { root.lookup-account(account-input.text); } } + } + } + + Section { + title: "步骤 5:采集任务"; + subtitle: "先创建任务记录,再手动按页拉取公开帖子;媒体文件可按设置另行下载。"; + height: 420px; + + Text { text: root.crawl-task-status; wrap: word-wrap; } + Text { text: root.crawl-task-list; wrap: word-wrap; font-size: 12px; } + Text { text: root.fetch-status; wrap: word-wrap; } + Text { text: root.auto-crawl-status; wrap: word-wrap; } + Text { text: root.archive-preview; wrap: word-wrap; font-size: 12px; } + Text { text: root.media-download-status; wrap: word-wrap; } + HorizontalLayout { + spacing: 10px; + crawl-input := LineEdit { placeholder-text: "输入已查询过的用户名"; } + Button { text: "创建采集任务"; clicked => { root.create-crawl-task(crawl-input.text); } } + Button { text: "刷新任务列表"; clicked => { root.refresh-crawl-tasks(); } } + } + HorizontalLayout { + spacing: 10px; + job-input := LineEdit { text <=> root.selected-job-id; placeholder-text: "任务ID会在刷新列表后自动填入"; } + page-limit-input := LineEdit { text: "3"; placeholder-text: "页数上限,0=直到末页"; } + delay-input := LineEdit { text: "1"; placeholder-text: "每页等待秒数"; } + Button { text: "拉取下一页帖子"; clicked => { root.fetch-one-page(job-input.text); } } + Button { text: "开始自动采集"; clicked => { root.auto-fetch-pages(job-input.text, page-limit-input.text, delay-input.text); } } + Button { text: "停止自动采集"; clicked => { root.stop-auto-crawl(); } } + } + HorizontalLayout { + spacing: 10px; + Rectangle { height: 1px; } + Button { text: "预览任务帖子"; clicked => { root.preview-archive(job-input.text); } } + Button { text: "导出Markdown"; clicked => { root.export-archive(job-input.text); } } + Button { text: "下载待保存媒体"; clicked => { root.download-media(); } } + Button { text: "重试失败媒体"; clicked => { root.retry-failed-media(); } } + } + } + } +} +} +