mirror of
https://github.com/chatmail/core.git
synced 2026-05-07 08:56:30 +03:00
ci: update Rust to 1.80.0
This commit is contained in:
8
.github/workflows/ci.yml
vendored
8
.github/workflows/ci.yml
vendored
@@ -24,7 +24,7 @@ jobs:
|
|||||||
name: Lint Rust
|
name: Lint Rust
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
env:
|
env:
|
||||||
RUSTUP_TOOLCHAIN: 1.79.0
|
RUSTUP_TOOLCHAIN: 1.80.0
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
@@ -95,11 +95,11 @@ jobs:
|
|||||||
matrix:
|
matrix:
|
||||||
include:
|
include:
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
rust: 1.79.0
|
rust: 1.80.0
|
||||||
- os: windows-latest
|
- os: windows-latest
|
||||||
rust: 1.79.0
|
rust: 1.80.0
|
||||||
- os: macos-latest
|
- os: macos-latest
|
||||||
rust: 1.79.0
|
rust: 1.80.0
|
||||||
|
|
||||||
# Minimum Supported Rust Version = 1.77.0
|
# Minimum Supported Rust Version = 1.77.0
|
||||||
- os: ubuntu-latest
|
- os: ubuntu-latest
|
||||||
|
|||||||
@@ -190,3 +190,6 @@ vendored = [
|
|||||||
"rusqlite/bundled-sqlcipher-vendored-openssl",
|
"rusqlite/bundled-sqlcipher-vendored-openssl",
|
||||||
"reqwest/native-tls-vendored"
|
"reqwest/native-tls-vendored"
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[lints.rust]
|
||||||
|
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(fuzzing)'] }
|
||||||
|
|||||||
@@ -4418,7 +4418,7 @@ trait ResultExt<T, E> {
|
|||||||
/// Like `log_err()`, but:
|
/// Like `log_err()`, but:
|
||||||
/// - returns the default value instead of an Err value.
|
/// - returns the default value instead of an Err value.
|
||||||
/// - emits an error instead of a warning for an [Err] result. This means
|
/// - emits an error instead of a warning for an [Err] result. This means
|
||||||
/// that the error will be shown to the user in a small pop-up.
|
/// that the error will be shown to the user in a small pop-up.
|
||||||
fn unwrap_or_log_default(self, context: &context::Context, message: &str) -> T;
|
fn unwrap_or_log_default(self, context: &context::Context, message: &str) -> T;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ set -euo pipefail
|
|||||||
#
|
#
|
||||||
# Avoid using rustup here as it depends on reading /proc/self/exe and
|
# Avoid using rustup here as it depends on reading /proc/self/exe and
|
||||||
# has problems running under QEMU.
|
# has problems running under QEMU.
|
||||||
RUST_VERSION=1.79.0
|
RUST_VERSION=1.80.0
|
||||||
|
|
||||||
ARCH="$(uname -m)"
|
ARCH="$(uname -m)"
|
||||||
test -f "/lib/libc.musl-$ARCH.so.1" && LIBC=musl || LIBC=gnu
|
test -f "/lib/libc.musl-$ARCH.so.1" && LIBC=musl || LIBC=gnu
|
||||||
|
|||||||
@@ -82,11 +82,13 @@ impl Chatlist {
|
|||||||
/// not needed when DC_GCL_ARCHIVED_ONLY is already set)
|
/// not needed when DC_GCL_ARCHIVED_ONLY is already set)
|
||||||
/// - if the flag DC_GCL_ADD_ALLDONE_HINT is set, DC_CHAT_ID_ALLDONE_HINT
|
/// - if the flag DC_GCL_ADD_ALLDONE_HINT is set, DC_CHAT_ID_ALLDONE_HINT
|
||||||
/// is added as needed.
|
/// is added as needed.
|
||||||
|
///
|
||||||
/// `query`: An optional query for filtering the list. Only chats matching this query
|
/// `query`: An optional query for filtering the list. Only chats matching this query
|
||||||
/// are returned. When `is:unread` is contained in the query, the chatlist is
|
/// are returned. When `is:unread` is contained in the query, the chatlist is
|
||||||
/// filtered such that only chats with unread messages show up.
|
/// filtered such that only chats with unread messages show up.
|
||||||
|
///
|
||||||
/// `query_contact_id`: An optional contact ID for filtering the list. Only chats including this contact ID
|
/// `query_contact_id`: An optional contact ID for filtering the list. Only chats including this contact ID
|
||||||
/// are returned.
|
/// are returned.
|
||||||
pub async fn try_load(
|
pub async fn try_load(
|
||||||
context: &Context,
|
context: &Context,
|
||||||
listflags: usize,
|
listflags: usize,
|
||||||
|
|||||||
@@ -747,7 +747,7 @@ impl Contact {
|
|||||||
/// - "name": name passed as function argument, belonging to the given origin
|
/// - "name": name passed as function argument, belonging to the given origin
|
||||||
/// - "row_name": current name used in the database, typically set to "name"
|
/// - "row_name": current name used in the database, typically set to "name"
|
||||||
/// - "row_authname": name as authorized from a contact, set only through a From-header
|
/// - "row_authname": name as authorized from a contact, set only through a From-header
|
||||||
/// Depending on the origin, both, "row_name" and "row_authname" are updated from "name".
|
/// Depending on the origin, both, "row_name" and "row_authname" are updated from "name".
|
||||||
///
|
///
|
||||||
/// Returns the contact_id and a `Modifier` value indicating if a modification occurred.
|
/// Returns the contact_id and a `Modifier` value indicating if a modification occurred.
|
||||||
pub(crate) async fn add_or_lookup(
|
pub(crate) async fn add_or_lookup(
|
||||||
@@ -997,7 +997,7 @@ impl Contact {
|
|||||||
/// - if the flag DC_GCL_ADD_SELF is set, SELF is added to the list unless filtered by other parameters
|
/// - if the flag DC_GCL_ADD_SELF is set, SELF is added to the list unless filtered by other parameters
|
||||||
/// - if the flag DC_GCL_VERIFIED_ONLY is set, only verified contacts are returned.
|
/// - if the flag DC_GCL_VERIFIED_ONLY is set, only verified contacts are returned.
|
||||||
/// if DC_GCL_VERIFIED_ONLY is not set, verified and unverified contacts are returned.
|
/// if DC_GCL_VERIFIED_ONLY is not set, verified and unverified contacts are returned.
|
||||||
/// `query` is a string to filter the list.
|
/// `query` is a string to filter the list.
|
||||||
pub async fn get_all(
|
pub async fn get_all(
|
||||||
context: &Context,
|
context: &Context,
|
||||||
listflags: u32,
|
listflags: u32,
|
||||||
|
|||||||
@@ -632,9 +632,9 @@ pub(crate) async fn receive_imf_inner(
|
|||||||
/// Also returns whether it is blocked or not and its origin.
|
/// Also returns whether it is blocked or not and its origin.
|
||||||
///
|
///
|
||||||
/// * `prevent_rename`: if true, the display_name of this contact will not be changed. Useful for
|
/// * `prevent_rename`: if true, the display_name of this contact will not be changed. Useful for
|
||||||
/// mailing lists: In some mailing lists, many users write from the same address but with different
|
/// mailing lists: In some mailing lists, many users write from the same address but with different
|
||||||
/// display names. We don't want the display name to change every time the user gets a new email from
|
/// display names. We don't want the display name to change every time the user gets a new email from
|
||||||
/// a mailing list.
|
/// a mailing list.
|
||||||
///
|
///
|
||||||
/// Returns `None` if From field does not contain a valid contact address.
|
/// Returns `None` if From field does not contain a valid contact address.
|
||||||
pub async fn from_field_to_contact_id(
|
pub async fn from_field_to_contact_id(
|
||||||
|
|||||||
@@ -350,12 +350,12 @@ impl Sql {
|
|||||||
///
|
///
|
||||||
/// 1. As mentioned above, SQLite's locking mechanism is non-async and sleeps in a loop.
|
/// 1. As mentioned above, SQLite's locking mechanism is non-async and sleeps in a loop.
|
||||||
/// 2. If there are other write transactions, we block the db connection until
|
/// 2. If there are other write transactions, we block the db connection until
|
||||||
/// upgraded. If some reader comes then, it has to get the next, less used connection with a
|
/// upgraded. If some reader comes then, it has to get the next, less used connection with a
|
||||||
/// worse per-connection page cache (SQLite allows one write and any number of reads in parallel).
|
/// worse per-connection page cache (SQLite allows one write and any number of reads in parallel).
|
||||||
/// 3. If a transaction is blocked for more than `busy_timeout`, it fails with SQLITE_BUSY.
|
/// 3. If a transaction is blocked for more than `busy_timeout`, it fails with SQLITE_BUSY.
|
||||||
/// 4. If upon a successful upgrade to a write transaction the db has been modified,
|
/// 4. If upon a successful upgrade to a write transaction the db has been modified,
|
||||||
/// the transaction has to be rolled back and retried, which means extra work in terms of
|
/// the transaction has to be rolled back and retried, which means extra work in terms of
|
||||||
/// CPU/battery.
|
/// CPU/battery.
|
||||||
///
|
///
|
||||||
/// The only pro of making write transactions DEFERRED w/o the external locking would be some
|
/// The only pro of making write transactions DEFERRED w/o the external locking would be some
|
||||||
/// parallelism between them.
|
/// parallelism between them.
|
||||||
|
|||||||
@@ -258,6 +258,7 @@ async fn maybe_warn_on_outdated(context: &Context, now: i64, approx_compile_time
|
|||||||
/// Generate an ID. The generated ID should be as short and as unique as possible:
|
/// Generate an ID. The generated ID should be as short and as unique as possible:
|
||||||
/// - short, because it may also used as part of Message-ID headers or in QR codes
|
/// - short, because it may also used as part of Message-ID headers or in QR codes
|
||||||
/// - unique as two IDs generated on two devices should not be the same. However, collisions are not world-wide but only by the few contacts.
|
/// - unique as two IDs generated on two devices should not be the same. However, collisions are not world-wide but only by the few contacts.
|
||||||
|
///
|
||||||
/// IDs generated by this function are 66 bit wide and are returned as 11 base64 characters.
|
/// IDs generated by this function are 66 bit wide and are returned as 11 base64 characters.
|
||||||
///
|
///
|
||||||
/// Additional information when used as a message-id or group-id:
|
/// Additional information when used as a message-id or group-id:
|
||||||
|
|||||||
Reference in New Issue
Block a user