You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-08-09 04:22:45 +03:00
Bump Clippy to 1.75 and Rust to 1.76
This commit is contained in:
4
.github/workflows/ci.yaml
vendored
4
.github/workflows/ci.yaml
vendored
@@ -195,8 +195,8 @@ jobs:
|
|||||||
|
|
||||||
- name: Install toolchain
|
- name: Install toolchain
|
||||||
run: |
|
run: |
|
||||||
rustup toolchain install 1.74.0
|
rustup toolchain install 1.75.0
|
||||||
rustup default 1.74.0
|
rustup default 1.75.0
|
||||||
rustup component add clippy
|
rustup component add clippy
|
||||||
|
|
||||||
- name: Setup OPA
|
- name: Setup OPA
|
||||||
|
@@ -8,15 +8,15 @@
|
|||||||
# The Debian version and version name must be in sync
|
# The Debian version and version name must be in sync
|
||||||
ARG DEBIAN_VERSION=12
|
ARG DEBIAN_VERSION=12
|
||||||
ARG DEBIAN_VERSION_NAME=bookworm
|
ARG DEBIAN_VERSION_NAME=bookworm
|
||||||
ARG RUSTC_VERSION=1.74.0
|
ARG RUSTC_VERSION=1.76.0
|
||||||
# XXX: Upgrade to 0.10.0 blocked by https://github.com/ziglang/zig/issues/10915#issuecomment-1354548110
|
# XXX: Upgrade to 0.10.0 blocked by https://github.com/ziglang/zig/issues/10915#issuecomment-1354548110
|
||||||
# XXX: Upgrade to 0.11.0 blocked by https://github.com/rust-cross/cargo-zigbuild/issues/162
|
# XXX: Upgrade to 0.11.0 blocked by https://github.com/rust-cross/cargo-zigbuild/issues/162
|
||||||
ARG ZIG_VERSION=0.9.1
|
ARG ZIG_VERSION=0.9.1
|
||||||
ARG NODEJS_VERSION=20.9.0
|
ARG NODEJS_VERSION=20.9.0
|
||||||
ARG OPA_VERSION=0.59.0
|
ARG OPA_VERSION=0.59.0
|
||||||
ARG CARGO_AUDITABLE_VERSION=0.6.1
|
ARG CARGO_AUDITABLE_VERSION=0.6.2
|
||||||
ARG CARGO_CHEF_VERSION=0.1.62
|
ARG CARGO_CHEF_VERSION=0.1.64
|
||||||
ARG CARGO_ZIGBUILD_VERSION=0.17.5
|
ARG CARGO_ZIGBUILD_VERSION=0.18.3
|
||||||
|
|
||||||
##########################################
|
##########################################
|
||||||
## Build stage that builds the frontend ##
|
## Build stage that builds the frontend ##
|
||||||
|
@@ -34,7 +34,7 @@ struct Error {
|
|||||||
|
|
||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
async fn test_http_errors() {
|
async fn test_http_errors() {
|
||||||
async fn handle<B>(_request: Request<B>) -> Result<Response<String>, Infallible> {
|
async fn handle<B>(_: Request<B>) -> Result<Response<String>, Infallible> {
|
||||||
let mut res = Response::new(r#"{"error": "invalid_request"}"#.to_owned());
|
let mut res = Response::new(r#"{"error": "invalid_request"}"#.to_owned());
|
||||||
*res.status_mut() = StatusCode::BAD_REQUEST;
|
*res.status_mut() = StatusCode::BAD_REQUEST;
|
||||||
|
|
||||||
|
@@ -69,7 +69,7 @@ impl Context {
|
|||||||
});
|
});
|
||||||
|
|
||||||
let key = translatable
|
let key = translatable
|
||||||
.key
|
.name
|
||||||
.split('.')
|
.split('.')
|
||||||
.chain(if translatable.kind == Kind::Plural {
|
.chain(if translatable.kind == Kind::Plural {
|
||||||
Some("other")
|
Some("other")
|
||||||
@@ -111,15 +111,15 @@ pub struct Location {
|
|||||||
#[derive(Debug, Clone)]
|
#[derive(Debug, Clone)]
|
||||||
pub struct Key {
|
pub struct Key {
|
||||||
kind: Kind,
|
kind: Kind,
|
||||||
key: String,
|
name: String,
|
||||||
location: Option<Location>,
|
location: Option<Location>,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Key {
|
impl Key {
|
||||||
pub fn new(kind: Kind, key: String) -> Self {
|
pub fn new(kind: Kind, name: String) -> Self {
|
||||||
Self {
|
Self {
|
||||||
kind,
|
kind,
|
||||||
key,
|
name,
|
||||||
location: None,
|
location: None,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -122,7 +122,7 @@ fn find_in_call<'a>(
|
|||||||
if var_.id == context.func() {
|
if var_.id == context.func() {
|
||||||
let key = call
|
let key = call
|
||||||
.args
|
.args
|
||||||
.get(0)
|
.first()
|
||||||
.and_then(as_const)
|
.and_then(as_const)
|
||||||
.and_then(|const_| const_.value.as_str())
|
.and_then(|const_| const_.value.as_str())
|
||||||
.ok_or(minijinja::Error::new(
|
.ok_or(minijinja::Error::new(
|
||||||
|
@@ -368,6 +368,7 @@ impl RequestClientCredentials {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[allow(clippy::struct_field_names)] // All the fields start with `client_`
|
||||||
#[skip_serializing_none]
|
#[skip_serializing_none]
|
||||||
#[derive(Debug, Clone, PartialEq, Eq, Serialize)]
|
#[derive(Debug, Clone, PartialEq, Eq, Serialize)]
|
||||||
pub(crate) struct BodyClientCredentials {
|
pub(crate) struct BodyClientCredentials {
|
||||||
|
@@ -49,6 +49,7 @@ impl<'c> PgBrowserSessionRepository<'c> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[allow(clippy::struct_field_names)]
|
||||||
#[derive(sqlx::FromRow)]
|
#[derive(sqlx::FromRow)]
|
||||||
#[sea_query::enum_def]
|
#[sea_query::enum_def]
|
||||||
struct SessionLookup {
|
struct SessionLookup {
|
||||||
|
Reference in New Issue
Block a user