Skip to content

Commit 4001d79

Browse files
authored
ci: upgrade Rust from 1.84.1 to 1.86.0 (#6784)
1 parent dc87ba8 commit 4001d79

File tree

4 files changed

+34
-17
lines changed

4 files changed

+34
-17
lines changed

.github/workflows/ci.yml

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -20,20 +20,22 @@ permissions: {}
2020

2121
env:
2222
RUSTFLAGS: -Dwarnings
23+
RUST_VERSION: 1.86.0
24+
25+
# Minimum Supported Rust Version
26+
MSRV: 1.81.0
2327

2428
jobs:
2529
lint_rust:
2630
name: Lint Rust
2731
runs-on: ubuntu-latest
28-
env:
29-
RUSTUP_TOOLCHAIN: 1.84.1
3032
steps:
3133
- uses: actions/checkout@v4
3234
with:
3335
show-progress: false
3436
persist-credentials: false
3537
- name: Install rustfmt and clippy
36-
run: rustup toolchain install $RUSTUP_TOOLCHAIN --profile minimal --component rustfmt --component clippy
38+
run: rustup toolchain install $RUST_VERSION --profile minimal --component rustfmt --component clippy
3739
- name: Cache rust cargo artifacts
3840
uses: swatinem/rust-cache@v2
3941
- name: Run rustfmt
@@ -91,25 +93,36 @@ jobs:
9193
matrix:
9294
include:
9395
- os: ubuntu-latest
94-
rust: 1.84.1
96+
rust: latest
9597
- os: windows-latest
96-
rust: 1.84.1
98+
rust: latest
9799
- os: macos-latest
98-
rust: 1.84.1
100+
rust: latest
99101

100-
# Minimum Supported Rust Version = 1.81.0
102+
# Minimum Supported Rust Version
101103
- os: ubuntu-latest
102-
rust: 1.81.0
104+
rust: minimum
103105
runs-on: ${{ matrix.os }}
104106
steps:
107+
- run:
108+
echo "RUSTUP_TOOLCHAIN=$MSRV" >> $GITHUB_ENV
109+
shell: bash
110+
if: matrix.rust == 'minimum'
111+
- run:
112+
echo "RUSTUP_TOOLCHAIN=$RUST_VERSION" >> $GITHUB_ENV
113+
shell: bash
114+
if: matrix.rust == 'latest'
115+
105116
- uses: actions/checkout@v4
106117
with:
107118
show-progress: false
108119
persist-credentials: false
109120

110121
- name: Install Rust ${{ matrix.rust }}
111-
run: rustup toolchain install --profile minimal ${{ matrix.rust }}
112-
- run: rustup override set ${{ matrix.rust }}
122+
run: rustup toolchain install --profile minimal $RUSTUP_TOOLCHAIN
123+
shell: bash
124+
- run: rustup override set $RUSTUP_TOOLCHAIN
125+
shell: bash
113126

114127
- name: Cache rust cargo artifacts
115128
uses: swatinem/rust-cache@v2

deltachat-ffi/src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ pub unsafe extern "C" fn dc_event_get_id(event: *mut dc_event_t) -> libc::c_int
536536
EventType::IncomingReaction { .. } => 2002,
537537
EventType::IncomingWebxdcNotify { .. } => 2003,
538538
EventType::IncomingMsg { .. } => 2005,
539-
EventType::IncomingMsgBunch { .. } => 2006,
539+
EventType::IncomingMsgBunch => 2006,
540540
EventType::MsgsNoticed { .. } => 2008,
541541
EventType::MsgDelivered { .. } => 2010,
542542
EventType::MsgFailed { .. } => 2012,
@@ -594,7 +594,7 @@ pub unsafe extern "C" fn dc_event_get_data1_int(event: *mut dc_event_t) -> libc:
594594
| EventType::ConnectivityChanged
595595
| EventType::SelfavatarChanged
596596
| EventType::ConfigSynced { .. }
597-
| EventType::IncomingMsgBunch { .. }
597+
| EventType::IncomingMsgBunch
598598
| EventType::ErrorSelfNotInGroup(_)
599599
| EventType::AccountsBackgroundFetchDone
600600
| EventType::ChatlistChanged
@@ -669,7 +669,7 @@ pub unsafe extern "C" fn dc_event_get_data2_int(event: *mut dc_event_t) -> libc:
669669
| EventType::MsgsNoticed(_)
670670
| EventType::ConnectivityChanged
671671
| EventType::WebxdcInstanceDeleted { .. }
672-
| EventType::IncomingMsgBunch { .. }
672+
| EventType::IncomingMsgBunch
673673
| EventType::SelfavatarChanged
674674
| EventType::AccountsBackgroundFetchDone
675675
| EventType::ChatlistChanged
@@ -771,7 +771,7 @@ pub unsafe extern "C" fn dc_event_get_data2_str(event: *mut dc_event_t) -> *mut
771771
| EventType::AccountsBackgroundFetchDone
772772
| EventType::ChatEphemeralTimerModified { .. }
773773
| EventType::ChatDeleted { .. }
774-
| EventType::IncomingMsgBunch { .. }
774+
| EventType::IncomingMsgBunch
775775
| EventType::ChatlistItemChanged { .. }
776776
| EventType::ChatlistChanged
777777
| EventType::AccountsChanged

deltachat-jsonrpc/src/api.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -327,8 +327,12 @@ impl CommandApi {
327327
.get_config_bool(deltachat::config::Config::ProxyEnabled)
328328
.await?;
329329

330-
let provider_info =
331-
get_provider_info(&ctx, email.split('@').last().unwrap_or(""), proxy_enabled).await;
330+
let provider_info = get_provider_info(
331+
&ctx,
332+
email.split('@').next_back().unwrap_or(""),
333+
proxy_enabled,
334+
)
335+
.await;
332336
Ok(ProviderInfo::from_dc_type(provider_info))
333337
}
334338

scripts/coredeps/install-rust.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ set -euo pipefail
77
#
88
# Avoid using rustup here as it depends on reading /proc/self/exe and
99
# has problems running under QEMU.
10-
RUST_VERSION=1.84.1
10+
RUST_VERSION=1.86.0
1111

1212
ARCH="$(uname -m)"
1313
test -f "/lib/libc.musl-$ARCH.so.1" && LIBC=musl || LIBC=gnu

0 commit comments

Comments
 (0)