mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-23 04:33:48 +00:00
Upgraded to Rust v1.100.0 and .NET v10.0.15 (#1218)
This commit is contained in:
1 parent
78f5066bfd
commit
f96025529a
10 files changed
+72
-50
No files matched your search
@@ -89,6 +89,18 @@ blocking handler can hold up the whole app. Therefore:
|
||||
- `runtime_api::test_support::assert_runtime_stays_free` tests a handler which waits for a lock. Run
|
||||
such a test with `#[tokio::test(flavor = "multi_thread", worker_threads = 1)]`.
|
||||
|
||||
**The runtime builds with the Rust of the Flatpak, too.** Flathub builds the Flatpak with its own Rust,
|
||||
the extension `org.freedesktop.Sdk.Extension.rust-stable` of the branch named by
|
||||
`FLATPAK_FREEDESKTOP_VERSION` in the pipeline, and only after a release. That Rust often lags behind the
|
||||
toolchain in `metadata.txt` by a version or two. Therefore:
|
||||
|
||||
- `rust-version` in `Cargo.toml` names the Rust of the Flatpak, not our toolchain. Clippy refuses every
|
||||
API of the standard library which is newer (`incompatible_msrv`), so the quality gate catches it before
|
||||
the release does.
|
||||
- Raise `rust-version` only once Flathub ships the newer Rust on that branch, never together with
|
||||
`metadata.txt`. Keep the minor version only, such as `1.98`: the branches of Flathub differ in the patch.
|
||||
- Never silence `incompatible_msrv`. Write the code the way the older Rust allows instead.
|
||||
|
||||
## IPC Communication Flow
|
||||
1. Rust runtime starts and generates TLS certificate
|
||||
2. Rust starts internal HTTPS API on random port
|
||||
|
||||
@@ -2,6 +2,14 @@
|
||||
name = "mindwork-ai-studio"
|
||||
version = "26.11.1"
|
||||
edition = "2024"
|
||||
|
||||
# Not our toolchain, which metadata.txt names, but the oldest Rust which still has to build the runtime: Flathub
|
||||
# builds the Flatpak with the extension org.freedesktop.Sdk.Extension.rust-stable of the branch named by
|
||||
# FLATPAK_FREEDESKTOP_VERSION in the pipeline, which lags behind. Clippy refuses every API of the standard library
|
||||
# which is newer (incompatible_msrv), and Cargo prefers versions of crates which still build with it. Keep the
|
||||
# minor version only: patch releases add no APIs, and the branches of Flathub differ in the patch. Raise it only
|
||||
# once Flathub ships a newer Rust, see runtime/AGENTS.md.
|
||||
rust-version = "1.98"
|
||||
description = "MindWork AI Studio"
|
||||
authors = ["Thorsten Sommer"]
|
||||
|
||||
|
||||
+4
-4
@@ -136,11 +136,11 @@ fn update_cargo_toml(cargo_path: &str, version: &str) {
|
||||
let cargo_toml_lines = cargo_toml.lines();
|
||||
let mut new_cargo_toml = String::new();
|
||||
|
||||
// Return early when the version already matches to avoid unnecessary rewrites.
|
||||
// Return early when the version already matches to avoid unnecessary rewrites. The version of the
|
||||
// package is the one line which starts with `version = `, the same line the loop below replaces:
|
||||
// version = "26.11.1"
|
||||
let current_version = cargo_toml.lines().find_map(|line| {
|
||||
let trimmed = line.trim_start();
|
||||
let rest = trimmed.strip_prefix("\"version\": ")?;
|
||||
let quoted = rest.strip_prefix('"')?;
|
||||
let quoted = line.strip_prefix("version = \"")?;
|
||||
let end_idx = quoted.find('"')?;
|
||||
Some("ed[..end_idx])
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user