Upgraded to Rust 1.97.0 & updated dependencies (#846)
Some checks are pending
Build and Release / Read metadata (push) Blocked by required conditions
Build and Release / Sync Flatpak repo (push) Blocked by required conditions
Build and Release / Determine run mode (push) Waiting to run
Build and Release / Collect Flatpak artifacts (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-aarch64-apple-darwin, osx-arm64, macos-latest, aarch64-apple-darwin, dmg,app,updater, dmg) (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-aarch64-unknown-linux-gnu, linux-arm64, ubuntu-22.04-arm, aarch64-unknown-linux-gnu, appimage,updater, appimage) (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-x86_64-apple-darwin, osx-x64, macos-latest, x86_64-apple-darwin, dmg,app,updater, dmg) (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-x86_64-pc-windows-msvc.exe, win-x64, windows-latest, x86_64-pc-windows-msvc, nsis,updater, nsis) (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-x86_64-unknown-linux-gnu, linux-x64, ubuntu-22.04, x86_64-unknown-linux-gnu, appimage,updater, appimage) (push) Blocked by required conditions
Build and Release / Prepare & create release (push) Blocked by required conditions
Build and Release / Publish release (push) Blocked by required conditions
Build and Release / Build app (${{ matrix.dotnet_runtime }}) (-aarch64-pc-windows-msvc.exe, win-arm64, windows-latest, aarch64-pc-windows-msvc, nsis,updater, nsis) (push) Blocked by required conditions

This commit is contained in:
Thorsten Sommer 2026-07-09 20:58:27 +02:00 committed by GitHub
parent 09fa5bc15b
commit 156cce380b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 77 additions and 92 deletions

View File

@ -3,9 +3,9 @@
244 244
9.0.118 (commit c8cbca4ed1) 9.0.118 (commit c8cbca4ed1)
9.0.17 (commit f2c8152eed) 9.0.17 (commit f2c8152eed)
1.96.1 (commit 31fca3adb) 1.97.0 (commit 2d8144b78)
8.15.0 8.15.0
2.11.2 2.11.5
4a15ff26655, release 4a15ff26655, release
osx-arm64 osx-arm64
148.0.7763.0 148.0.7763.0

121
runtime/Cargo.lock generated
View File

@ -459,11 +459,12 @@ dependencies = [
[[package]] [[package]]
name = "atoi_simd" name = "atoi_simd"
version = "0.17.0" version = "0.18.1"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8ad17c7c205c2c28b527b9845eeb91cf1b4d008b438f98ce0e628227a822758e" checksum = "f3cdb3708a128e559a30fb830e8a77a5022ee6902806925c216658652b452a44"
dependencies = [ dependencies = [
"debug_unsafe", "debug_unsafe",
"rustversion",
] ]
[[package]] [[package]]
@ -842,9 +843,9 @@ dependencies = [
[[package]] [[package]]
name = "bumpalo" name = "bumpalo"
version = "3.16.0" version = "3.20.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" checksum = "72f5acc6cb2ba439de613abc23857ec3d78374d8ed5ac84e9d11336e87da8649"
[[package]] [[package]]
name = "bytemuck" name = "bytemuck"
@ -880,9 +881,9 @@ checksum = "8f1fe948ff07f4bd06c30984e69f5b4899c516a3ef74f34df92a2df2ab535495"
[[package]] [[package]]
name = "bytes" name = "bytes"
version = "1.11.1" version = "1.12.1"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1e748733b7cbc798e1434b6ac524f0c1ff2ab456fe201501e6497c8417a4fc33" checksum = "fc652a48c352aef3ea3aed32080501cf3ef6ed5da78602a020c991775b0aff04"
dependencies = [ dependencies = [
"serde", "serde",
] ]
@ -933,9 +934,9 @@ dependencies = [
[[package]] [[package]]
name = "calamine" name = "calamine"
version = "0.35.0" version = "0.36.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8822fe6253ca47aa5ad9a3be09f6fe7cd20c6a74e41b0aa42e8f4e3d523508df" checksum = "6975084f43060e56343ffba7f9731fa52a7dcf2e1cd8e2459fd4c6bf4a1bff59"
dependencies = [ dependencies = [
"atoi_simd", "atoi_simd",
"byteorder", "byteorder",
@ -943,9 +944,9 @@ dependencies = [
"encoding_rs", "encoding_rs",
"fast-float2", "fast-float2",
"log", "log",
"quick-xml 0.39.2", "quick-xml 0.41.0",
"serde", "serde",
"zip 7.4.0", "zip 8.6.0",
] ]
[[package]] [[package]]
@ -1165,9 +1166,9 @@ dependencies = [
[[package]] [[package]]
name = "cmov" name = "cmov"
version = "0.5.3" version = "0.5.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3f88a43d011fc4a6876cb7344703e297c71dda42494fee094d5f7c76bf13f746" checksum = "0c9ea0ac24bc397ab3c98583a3c9ba74fa56b09a4449bbe172b9b1ddb016027a"
[[package]] [[package]]
name = "codepage" name = "codepage"
@ -1227,7 +1228,7 @@ dependencies = [
"ph", "ph",
"procfs", "procfs",
"quick_cache", "quick_cache",
"rand 0.10.1", "rand 0.10.2",
"roaring", "roaring",
"schemars", "schemars",
"self_cell", "self_cell",
@ -2517,7 +2518,7 @@ dependencies = [
"i_overlay", "i_overlay",
"log", "log",
"num-traits", "num-traits",
"rand 0.10.1", "rand 0.10.2",
"rand_pcg", "rand_pcg",
"robust", "robust",
"rstar", "rstar",
@ -2765,7 +2766,7 @@ dependencies = [
"log", "log",
"lz4_flex", "lz4_flex",
"parking_lot", "parking_lot",
"rand 0.10.1", "rand 0.10.2",
"serde", "serde",
"serde_cbor", "serde_cbor",
"serde_json", "serde_json",
@ -3874,17 +3875,11 @@ dependencies = [
"serde", "serde",
] ]
[[package]]
name = "lockfree-object-pool"
version = "0.1.6"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9374ef4228402d4b7e403e5838cb880d9ee663314b0a900d5a6aabf0c213552e"
[[package]] [[package]]
name = "log" name = "log"
version = "0.4.32" version = "0.4.33"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "953f07c43838f8e6f9758cab68bf5bed85465e7587ebe0b823f1bcd81978ad3a" checksum = "0ceec5bc11778974d1bcb055b18002eba7f4b3518b6a0081b3af5f21666da9ad"
[[package]] [[package]]
name = "lru-slab" name = "lru-slab"
@ -4025,7 +4020,7 @@ dependencies = [
"pdfium-render", "pdfium-render",
"pptx-to-md", "pptx-to-md",
"qdrant-edge", "qdrant-edge",
"rand 0.10.1", "rand 0.10.2",
"rand_chacha 0.10.0", "rand_chacha 0.10.0",
"rcgen", "rcgen",
"rustls", "rustls",
@ -4034,7 +4029,7 @@ dependencies = [
"sha2 0.11.0", "sha2 0.11.0",
"strum_macros", "strum_macros",
"sys-locale", "sys-locale",
"sysinfo 0.39.3", "sysinfo 0.39.6",
"tauri", "tauri",
"tauri-build", "tauri-build",
"tauri-plugin-dialog", "tauri-plugin-dialog",
@ -4835,9 +4830,9 @@ dependencies = [
[[package]] [[package]]
name = "pdfium-render" name = "pdfium-render"
version = "0.9.1" version = "0.9.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "076dd8f3a6c7da9298ddffbcc0d5a109f89caf967fa4871c9a172d5b3498b35b" checksum = "e06f0df3ca17554c1b8f31eb17bc77eedbbafa120d35b90b3096fa46b2fdc94c"
dependencies = [ dependencies = [
"bitflags 2.11.1", "bitflags 2.11.1",
"bytemuck", "bytemuck",
@ -5260,7 +5255,7 @@ dependencies = [
"log", "log",
"ordered-float 5.3.0", "ordered-float 5.3.0",
"parking_lot", "parking_lot",
"rand 0.10.1", "rand 0.10.2",
"segment", "segment",
"serde", "serde",
"serde_json", "serde_json",
@ -5303,7 +5298,7 @@ dependencies = [
"ordered-float 5.3.0", "ordered-float 5.3.0",
"parking_lot", "parking_lot",
"permutation_iterator", "permutation_iterator",
"rand 0.10.1", "rand 0.10.2",
"rayon", "rayon",
"serde", "serde",
"serde_json", "serde_json",
@ -5321,9 +5316,9 @@ dependencies = [
[[package]] [[package]]
name = "quick-xml" name = "quick-xml"
version = "0.39.2" version = "0.41.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "958f21e8e7ceb5a1aa7fa87fab28e7c75976e0bfe7e23ff069e0a260f894067d" checksum = "e660451e55124f798a69a5af3f49ccfbefbd41910eefd25caf2393e1f3473ec1"
dependencies = [ dependencies = [
"encoding_rs", "encoding_rs",
"memchr", "memchr",
@ -5442,9 +5437,9 @@ dependencies = [
[[package]] [[package]]
name = "rand" name = "rand"
version = "0.10.1" version = "0.10.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d2e8e8bcc7961af1fdac401278c6a831614941f6164ee3bf4ce61b7edb162207" checksum = "c7f5fa3a058cd35567ef9bfa5e75732bee0f9e4c55fa90477bef2dfcdbc4be80"
dependencies = [ dependencies = [
"chacha20", "chacha20",
"getrandom 0.4.2", "getrandom 0.4.2",
@ -5513,7 +5508,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4d431c2703ccf129de4d45253c03f49ebb22b97d6ad79ee3ecfc7e3f4862c1d8" checksum = "4d431c2703ccf129de4d45253c03f49ebb22b97d6ad79ee3ecfc7e3f4862c1d8"
dependencies = [ dependencies = [
"num-traits", "num-traits",
"rand 0.10.1", "rand 0.10.2",
] ]
[[package]] [[package]]
@ -6038,7 +6033,7 @@ dependencies = [
"procfs", "procfs",
"qdrant-rust-stemmers", "qdrant-rust-stemmers",
"quantization", "quantization",
"rand 0.10.1", "rand 0.10.2",
"rayon", "rayon",
"roaring", "roaring",
"schemars", "schemars",
@ -6355,7 +6350,7 @@ dependencies = [
"log", "log",
"ordered-float 5.3.0", "ordered-float 5.3.0",
"parking_lot", "parking_lot",
"rand 0.10.1", "rand 0.10.2",
"rmp-serde", "rmp-serde",
"schemars", "schemars",
"segment", "segment",
@ -6520,7 +6515,7 @@ dependencies = [
"memmap2", "memmap2",
"ordered-float 5.3.0", "ordered-float 5.3.0",
"parking_lot", "parking_lot",
"rand 0.10.1", "rand 0.10.2",
"schemars", "schemars",
"serde", "serde",
"serde_json", "serde_json",
@ -6677,9 +6672,9 @@ dependencies = [
[[package]] [[package]]
name = "sysinfo" name = "sysinfo"
version = "0.39.3" version = "0.39.6"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "21d0d938c10fcda3e897e28aaddf4ab462375d411f4378cd63b1c945f69aba96" checksum = "d2071df9448915b71c4fe6d25deaf1c22f12bd234f01540b77312bb8e41361e6"
dependencies = [ dependencies = [
"libc", "libc",
"memchr", "memchr",
@ -6779,9 +6774,9 @@ checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1"
[[package]] [[package]]
name = "tauri" name = "tauri"
version = "2.11.2" version = "2.11.5"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "437404997acf375d85f1177afa7e11bb971f274ed6a7b83a2a3e339015f4cc28" checksum = "667b20e2726d572dea2de7370da16e188eb06008faf9a92fab7cdc46791190b5"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"bytes", "bytes",
@ -6830,9 +6825,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-build" name = "tauri-build"
version = "2.6.2" version = "2.6.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4aa1f9055fc23919a54e4e125052bed16ed04aef0487086e758fe01a67b451c7" checksum = "bc9ce40b16101cb6ea63d3e221567affd1c3a9205f95d7bc574941a10636b632"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"cargo_toml", "cargo_toml",
@ -6851,9 +6846,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-codegen" name = "tauri-codegen"
version = "2.6.2" version = "2.6.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e4a0319528a025a38c4078e7dae2c446f4e63620ddb0659a643ede1cb38f90e9" checksum = "08279169ff42f8fc45a1dbc9dcae888893ba95288142e5880c59b93a26d2cfc5"
dependencies = [ dependencies = [
"base64 0.22.1", "base64 0.22.1",
"brotli", "brotli",
@ -6878,9 +6873,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-macros" name = "tauri-macros"
version = "2.6.2" version = "2.6.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ae6cb4e3896c21d2f6da5b31251d2faea0153bba56ed0e970f918115dbee4924" checksum = "e8b394794f399a421811d06966343e7933fcae92d59f5180b9388d1174497a45"
dependencies = [ dependencies = [
"heck 0.5.0", "heck 0.5.0",
"proc-macro2", "proc-macro2",
@ -7071,9 +7066,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-runtime" name = "tauri-runtime"
version = "2.11.2" version = "2.11.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "48222d7116c8807eaa6fe2f372e023fae125084e61e6eca6d70b7961cdf129ef" checksum = "b0b4bc95aed361b0019067d189a1174a603d460d0f6c72606512d59fc9c12ec8"
dependencies = [ dependencies = [
"cookie", "cookie",
"dpi", "dpi",
@ -7096,9 +7091,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-runtime-wry" name = "tauri-runtime-wry"
version = "2.11.2" version = "2.11.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b83849ee63ecb27a8e8d0fe51915ca215076914aca43f96db1179f0f415f6cd9" checksum = "4e6fac707727b7a2f48e4ded90976324267371073edbb415ffb73bb0458d203f"
dependencies = [ dependencies = [
"gtk", "gtk",
"http", "http",
@ -7122,9 +7117,9 @@ dependencies = [
[[package]] [[package]]
name = "tauri-utils" name = "tauri-utils"
version = "2.9.2" version = "2.9.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "092379df9a707631978e6c56b1bc2401d387f01e2d4a3c123360d167bbb9aa95" checksum = "3e176a18e67764923c4f1ce66f25ae4abe5f688384d5eb1a0fa6c77f3d90f887"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"brotli", "brotli",
@ -7609,9 +7604,9 @@ dependencies = [
[[package]] [[package]]
name = "tray-icon" name = "tray-icon"
version = "0.23.1" version = "0.24.1"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "15edbb0d80583e85ee8df283410038e17314df5cba30da2087a54a85216c0773" checksum = "65ba1e5f6b9ef9fd87e21b9c6f351554dbd717960089168fcfdef854686961dc"
dependencies = [ dependencies = [
"crossbeam-channel", "crossbeam-channel",
"dirs", "dirs",
@ -7933,7 +7928,7 @@ dependencies = [
"fs4", "fs4",
"log", "log",
"memmap2", "memmap2",
"rand 0.10.1", "rand 0.10.2",
"rand_distr", "rand_distr",
"rustix 1.1.4", "rustix 1.1.4",
"serde", "serde",
@ -8434,9 +8429,9 @@ checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5"
[[package]] [[package]]
name = "windows-native-keyring-store" name = "windows-native-keyring-store"
version = "1.0.0" version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b5fd986f648459dd29aa252ed3a5ad11a60c0b1251bf81625fb03a86c69d274e" checksum = "063426e76fdec7438d56bb777f67e318a84a25c707b07e575cb8b78e10c028f8"
dependencies = [ dependencies = [
"byteorder", "byteorder",
"keyring-core", "keyring-core",
@ -9340,9 +9335,9 @@ dependencies = [
[[package]] [[package]]
name = "zip" name = "zip"
version = "7.4.0" version = "8.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cc12baa6db2b15a140161ce53d72209dacea594230798c24774139b54ecaa980" checksum = "2d04a6b5381502aa6087c94c669499eb1602eb9c5e8198e534de571f7154809b"
dependencies = [ dependencies = [
"crc32fast", "crc32fast",
"flate2", "flate2",
@ -9366,15 +9361,13 @@ checksum = "dfcd145825aace48cff44a8844de64bf75feec3080e0aa5cdbde72961ae51a65"
[[package]] [[package]]
name = "zopfli" name = "zopfli"
version = "0.8.1" version = "0.8.3"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e5019f391bac5cf252e93bbcc53d039ffd62c7bfb7c150414d61369afe57e946" checksum = "f05cd8797d63865425ff89b5c4a48804f35ba0ce8d125800027ad6017d2b5249"
dependencies = [ dependencies = [
"bumpalo", "bumpalo",
"crc32fast", "crc32fast",
"lockfree-object-pool",
"log", "log",
"once_cell",
"simd-adler32", "simd-adler32",
] ]

View File

@ -6,10 +6,10 @@ description = "MindWork AI Studio"
authors = ["Thorsten Sommer"] authors = ["Thorsten Sommer"]
[build-dependencies] [build-dependencies]
tauri-build = { version = "2.6.2", features = [] } tauri-build = { version = "2.6.3", features = [] }
[dependencies] [dependencies]
tauri = { version = "2.11.2", features = [] } tauri = { version = "2.11.5", features = [] }
tauri-plugin-window-state = { version = "2.4.1" } tauri-plugin-window-state = { version = "2.4.1" }
tauri-plugin-shell = "2.3.5" tauri-plugin-shell = "2.3.5"
tauri-plugin-dialog = "2.7.1" tauri-plugin-dialog = "2.7.1"
@ -24,12 +24,12 @@ tokio-stream = "0.1.18"
futures = "0.3.32" futures = "0.3.32"
async-stream = "0.3.6" async-stream = "0.3.6"
flexi_logger = "0.31.9" flexi_logger = "0.31.9"
log = { version = "0.4.30", features = ["kv"] } log = { version = "0.4.33", features = ["kv"] }
once_cell = "1.21.4" once_cell = "1.21.4"
axum = { version = "0.8.9", features = ["http2", "json", "query", "tokio"] } axum = { version = "0.8.9", features = ["http2", "json", "query", "tokio"] }
axum-server = { version = "0.8.0", features = ["tls-rustls"] } axum-server = { version = "0.8.0", features = ["tls-rustls"] }
rustls = { version = "0.23.28", default-features = false, features = ["aws_lc_rs"] } rustls = { version = "0.23.28", default-features = false, features = ["aws_lc_rs"] }
rand = "0.10.1" rand = "0.10.2"
rand_chacha = "0.10.0" rand_chacha = "0.10.0"
base64 = "0.22.1" base64 = "0.22.1"
aes = "0.9.1" aes = "0.9.1"
@ -39,16 +39,16 @@ hmac = "0.13.0"
sha2 = "0.11.0" sha2 = "0.11.0"
rcgen = { version = "0.14.8", features = ["pem"] } rcgen = { version = "0.14.8", features = ["pem"] }
file-format = "0.29.0" file-format = "0.29.0"
calamine = "0.35.0" calamine = "0.36.0"
pdfium-render = "0.9.1" pdfium-render = "0.9.2"
sys-locale = "0.3.2" sys-locale = "0.3.2"
whoami = "2.1.2" whoami = "2.1.2"
cfg-if = "1.0.4" cfg-if = "1.0.4"
pptx-to-md = "0.4.0" pptx-to-md = "0.4.0"
tempfile = "3.27.0" tempfile = "3.27.0"
strum_macros = "0.28.0" strum_macros = "0.28.0"
sysinfo = "0.39.3" sysinfo = "0.39.6"
bytes = "1.11.1" bytes = "1.12.1"
qdrant-edge = "0.7.2" qdrant-edge = "0.7.2"
[patch.crates-io] [patch.crates-io]
@ -62,7 +62,7 @@ permutation_iterator = { git = "https://github.com/SommerEngineering/permutation
[target.'cfg(target_os = "windows")'.dependencies] [target.'cfg(target_os = "windows")'.dependencies]
windows-registry = "0.6.1" windows-registry = "0.6.1"
windows-native-keyring-store = "1.0.0" windows-native-keyring-store = "1.1.0"
[target.'cfg(target_os = "macos")'.dependencies] [target.'cfg(target_os = "macos")'.dependencies]
apple-native-keyring-store = { version = "1.0.0", features = ["keychain"] } apple-native-keyring-store = { version = "1.0.0", features = ["keychain"] }
@ -72,7 +72,7 @@ dbus-secret-service-keyring-store = { version = "1.0.0", features = ["crypto-rus
[target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies] [target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies]
tauri-plugin-global-shortcut = "2" tauri-plugin-global-shortcut = "2"
tauri-plugin-updater = "2.10.0" tauri-plugin-updater = "2.10.1"
[features] [features]
custom-protocol = ["tauri/custom-protocol"] custom-protocol = ["tauri/custom-protocol"]

View File

@ -223,7 +223,7 @@ fn file_logger_format(
write_kv_pairs(w, record)?; write_kv_pairs(w, record)?;
// Write the log message: // Write the log message:
write!(w, "{}", &record.args()) write!(w, "{}", record.args())
} }
pub async fn get_log_paths(_token: APIToken) -> Json<LogPathsResponse> { pub async fn get_log_paths(_token: APIToken) -> Json<LogPathsResponse> {

View File

@ -1,31 +1,23 @@
use std::error::Error; use std::error::Error;
use std::sync::Mutex; use std::sync::Mutex;
use once_cell::sync::Lazy; use once_cell::sync::{Lazy, OnceCell};
use pdfium_render::prelude::Pdfium; use pdfium_render::prelude::Pdfium;
use log::{error, info, warn}; use log::{error, info, warn};
pub static PDFIUM_LIB_PATH: Lazy<Mutex<Option<String>>> = Lazy::new(|| Mutex::new(None)); pub static PDFIUM_LIB_PATH: Lazy<Mutex<Option<String>>> = Lazy::new(|| Mutex::new(None));
static PDFIUM: Lazy<Mutex<Option<Pdfium>>> = Lazy::new(|| Mutex::new(None)); static PDFIUM: OnceCell<Pdfium> = OnceCell::new();
pub trait PdfiumInit { pub trait PdfiumInit {
fn ai_studio_init() -> Result<Pdfium, Box<dyn Error + Send + Sync>>; fn ai_studio_init() -> Result<&'static Pdfium, Box<dyn Error + Send + Sync>>;
} }
impl PdfiumInit for Pdfium { impl PdfiumInit for Pdfium {
/// Initializes the PDFium library for AI Studio. /// Initializes the PDFium library for AI Studio.
fn ai_studio_init() -> Result<Pdfium, Box<dyn Error + Send + Sync>> { fn ai_studio_init() -> Result<&'static Pdfium, Box<dyn Error + Send + Sync>> {
let mut pdfium = PDFIUM.lock().unwrap(); PDFIUM.get_or_try_init(|| load_pdfium().map_err(|error| {
if let Some(pdfium) = pdfium.as_ref() {
return Ok(pdfium.clone());
}
let loaded_pdfium = load_pdfium().map_err(|error| {
Box::new(std::io::Error::other(error)) as Box<dyn Error + Send + Sync> Box::new(std::io::Error::other(error)) as Box<dyn Error + Send + Sync>
})?; }))
*pdfium = Some(loaded_pdfium.clone());
Ok(loaded_pdfium)
} }
} }