Skip to content

Commit b63ea2e

Browse files
authored
Update Rust 1.99 (#152)
1 parent a917113 commit b63ea2e

41 files changed

Lines changed: 832 additions & 654 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/coverage.yaml‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,12 +202,22 @@ jobs:
202202
#
203203
# Every upload names its language and lane in `flags`, so Codecov can report each on its own. The two
204204
# DeepSource uploads carry `runner.os == 'Linux'`, for the one-report-per-key reason given on the job.
205+
#
206+
# `disable_search` keeps each upload to the one report it names. With search on, the action also sends every
207+
# coverage-looking file in the workspace, including the unfiltered intermediates the coverage tasks leave
208+
# under target/ (`agent-cov/all.lcov`, `agent-cov/cov-server.lcov`, `pic-viewer-cov/all.lcov`,
209+
# `wasi-cov/wasi.lcov`). Their records for files the tasks deliberately drop land on the real sources, which
210+
# showed as hits and misses on blank and doc-comment lines of services/ws-web-runner/src/runtime.rs at commit
211+
# https://github.com/edge-toolkit/core/commit/e2f650920e0179f4ff877fc2faf704e0b7a02684, upload log
212+
# `Found 10 coverage files to report` at
213+
# https://github.com/edge-toolkit/core/actions/runs/39376279480/job/118475035669.
205214
- name: Upload Rust coverage to Codecov (OIDC)
206215
if: ${{ !cancelled() && hashFiles('lcov.info') != '' }}
207216
uses: codecov/codecov-action@v7
208217
with:
209218
use_oidc: true
210219
files: lcov.info
220+
disable_search: true
211221
flags: rust,${{ matrix.os_flag }}
212222
fail_ci_if_error: true
213223

@@ -217,6 +227,7 @@ jobs:
217227
with:
218228
use_oidc: true
219229
files: coverage-python.xml
230+
disable_search: true
220231
flags: python,${{ matrix.os_flag }}
221232
fail_ci_if_error: true
222233

‎.github/workflows/test.yaml‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,19 @@ jobs:
219219
uses: $/.github/actions/install-mise-tools
220220
timeout-minutes: 60
221221

222+
# Restore the portable MSVC + Windows SDK that prefetch:msvc stages, so a hit never reaches Microsoft.
223+
# The stage is a pure function of config.msvc.toml -- the pinned script and its version flags live there --
224+
# so that file's hash is the key and any edit to it restages. Only target/msvc/msvc is cached: the task
225+
# renders msvc.env and the two junctions on every run. actions/cache saves only from a successful job, so a
226+
# partial stage is never stored. The licence does not allow republishing these files, which is why this is
227+
# a runner cache and not an upstream-cache mirror.
228+
- name: Cache portable MSVC
229+
if: matrix.compiler == 'msvc'
230+
uses: actions/cache@v6
231+
with:
232+
path: target/msvc/msvc
233+
key: portable-msvc-${{ hashFiles('.mise/config.msvc.toml') }}
234+
222235
- name: Prefetch dependencies
223236
timeout-minutes: 20
224237
env:

‎.mise/config.msvc.toml‎

Lines changed: 19 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,18 @@ version = "{{ vars.rust_nightly }}-x86_64-pc-windows-gnullvm"
3131
[vars]
3232
# portable-msvc script pin: gist id + revision (immutable content address) + sha256 of that revision.
3333
# Bump all three together after reviewing a new upstream revision.
34+
# The floor is the revision that matches SDK payload names with either path separator. The Visual Studio
35+
# manifest moved them from `Installers\\` to `Installers/`, so older revisions find no SDK package, download
36+
# none, and die at their `versions` step:
37+
#
38+
# sdkv = first((OUTPUT / "Windows Kits/10/bin").glob("*")).name
39+
# AttributeError: 'NoneType' object has no attribute 'name'
40+
#
41+
# Seen on commit https://github.com/edge-toolkit/core/commit/fc2e5639cb63d541269501663973a94d3138ea5f at
42+
# https://github.com/edge-toolkit/core/actions/runs/39527031634/job/118983994353.
3443
a_pmsvc_gist = "7f3162ec2988e81e56d5c4e22cde9977"
35-
a_pmsvc_rev = "ba48b0a3d9ea05c6caa5e583eda60fa7510da4bc"
36-
a_pmsvc_sha = "295a6d7e3e6a7132199ec51224216b07c54af29df9c8ba9bf01166ce12451c0a"
44+
a_pmsvc_rev = "49b58850aa5e5c1e65f090d4651ee76607883e11"
45+
a_pmsvc_sha = "1791cccca594ff083ce8d3e0a139e6156d2c312e24332a909e608010f0230a51"
3746
# Clear config.windows.toml's et-ws-web-runner exclusion.
3847
cargo_ws_excludes = ""
3948
# et-cli lands under the msvc target dir once CARGO_BUILD_TARGET below is flipped.
@@ -65,11 +74,13 @@ run = """
6574
base="{{ vars.msvc_base }}"
6675
coreutils mkdir -p "$base"
6776
script="$base/portable-msvc.py"
68-
if [ ! -f "$script" ]; then
77+
sha() { coreutils sha256sum -b "$script" | coreutils cut -c1-64; }
78+
# Fetched when absent or left over from a previous pin, so a bump takes effect on an existing checkout.
79+
if [ ! -f "$script" ] || [ "$(sha)" != "{{ vars.a_pmsvc_sha }}" ]; then
6980
src=":http:mmozeiko/{{ vars.a_pmsvc_gist }}/raw/{{ vars.a_pmsvc_rev }}/portable-msvc.py"
7081
rclone copyto "$src" "$script" --http-url https://gist.githubusercontent.com --progress
7182
fi
72-
actual=$(coreutils sha256sum -b "$script" | coreutils cut -c1-64)
83+
actual=$(sha)
7384
[ "$actual" = "{{ vars.a_pmsvc_sha }}" ] || {
7485
echo "portable-msvc.py checksum mismatch: $actual" >&2
7586
exit 1
@@ -78,7 +89,10 @@ actual=$(coreutils sha256sum -b "$script" | coreutils cut -c1-64)
7889
# The rendered msvc.env tracks whatever is installed, so a bump only needs these two flags changed and a
7990
# re-run after deleting target/msvc/msvc.
8091
py="{{ vars.py3_win_fwd }}"
81-
if [ ! -d "$base/msvc/VC" ]; then
92+
# A stage counts as complete only with both halves, so one missing its SDK is wiped and staged again.
93+
# The script writes the MSVC half before it unpacks the SDK, so a run that fails in between leaves `VC` behind.
94+
if [ ! -d "$base/msvc/VC" ] || [ ! -d "$base/msvc/Windows Kits/10/bin" ]; then
95+
coreutils rm -rf "$base/msvc"
8296
(cd "$base" && "$py" portable-msvc.py --accept-license --msvc-version 14.51 --sdk-version 26100)
8397
fi
8498
"$py" - "$base/msvc" "$base/msvc.env" <<'PY'

‎.mise/config.rust.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
# Browser wasm-pack builds are coverage-instrumented when ET_TEST_COVERAGE is set.
1212
# The web_cov_wrapper RUSTC_WORKSPACE_WRAPPER (built by build-wasm-cov-wrapper) instruments only workspace
13-
# crates -- never the dependency cdylibs (tracing-wasm, wasm-streams) that don't link minicov's
13+
# crates -- never dependency cdylibs such as wasm-streams that don't link minicov's
1414
# __llvm_profile_runtime -- while web_cov_feat enables et-web/coverage to supply minicov's runtime. et-web's
1515
# __et_capture_coverage export (folded by wasm-bindgen into every module's glue) lets the web-runner pull each
1616
# module's .profraw for wasm-cov.

‎.mise/mise.lock‎

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎CHANGELOG.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ Changelog 1.1.0.
3939
### Changed
4040

4141
- The workspace requires actix-web 4.17.
42+
- **Breaking:** the minimum supported Rust version is 1.99.0, up from 1.91.1, for every published crate.
4243
- **Breaking:** an agent's IP address is always known. `AgentSummary::last_known_ip` and
4344
`AgentRecord::last_known_ip` are `IpAddr` rather than `Option<String>`, and `AgentRegistry::connect_agent` takes
4445
an `IpAddr`. On the wire, `last_known_ip` in an `et-list-agents-response` is a required IP string, never null,

‎CHECKS.md‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
- **Tools:** 47
55
- **Shell-script checks:** 10
66
- **Checks with a repair pass:** 21
7-
- **Rules:** 342 custom local rules, or non-default strict linter settings
7+
- **Rules:** 343 custom local rules, or non-default strict linter settings
88

99
Every check is listed across every `MISE_ENV`, filed under the tool it runs. Each entry names the env whose config
1010
declares it, the aggregate that runs it as part of `mise run check`, the `fix` or `fmt` pass that repairs what it
@@ -42,6 +42,9 @@ Rules, from `config/ast-grep/rules`:
4242
status -- a raw `std` `Command`'s `.status()` / `.output()` / `.spawn()` errors carry none of that. If a call
4343
genuinely needs the raw outcome (e.g. a test that asserts a non-zero exit, or an exit-code proxy), fully-qualify
4444
`std::process::Command` at the call site instead of importing it, so this rule does not apply.
45+
- `const-at-top` -- Declare module-level `const` and `static` items at the top of the file, after the `use` lines and
46+
before any type, trait, `impl` or function. A reader then meets the module's fixed values before the code that uses
47+
them.
4548
- `derive-attribute-order` -- Put `#[derive(...)]` before every inert or helper attribute on the same item --
4649
`#[non_exhaustive]`, `#[repr]`, `#[cfg_attr]`, and derive helpers such as `#[serde]`, `#[command]`, `#[strum]` or
4750
`#[asyncapi]`. Only doc comments, `#[cfg]`, `#[expect]` and attribute macros that must see the item before the derive

0 commit comments

Comments
 (0)