Bump to Rust 1.80.0 (#954)

<!-- The PR description should answer 2 important questions: -->

### What

Upgrade to [Rust
1.80.0](https://blog.rust-lang.org/2024/07/25/Rust-1.80.0.html)

### How

Update `rust-toolchain.yaml` and Dockerfiles, fix warnings.

V3_GIT_ORIGIN_REV_ID: ba797e1aba6b9623a921734473a6b70a2a38c8b7
This commit is contained in:
Daniel Harvey 2024-08-12 11:44:28 +01:00 committed by hasura-bot
parent db80b37ece
commit 69c3011633
10 changed files with 29 additions and 29 deletions

View File

@ -1,5 +1,5 @@
# This should match the Rust version in rust-toolchain.yaml and the other Dockerfiles.
FROM rust:1.79.0 as chef
FROM rust:1.80.0 as chef
WORKDIR app

View File

@ -264,9 +264,9 @@ pub(crate) fn plan_selection_set<'s, 'ir>(
/// the NDC IR for that field
///
/// - if the selection set DOES NOT contain the field, insert it into the NDC IR
/// (with an internal alias), and return the alias
/// (with an internal alias), and return the alias
/// - if the selection set already contains the field, do not insert the field
/// in NDC IR, and return the existing alias
/// in NDC IR, and return the existing alias
fn process_remote_relationship_field_mapping(
selection: &ResultSelectionSet<'_>,
field_mapping: &FieldMapping,

View File

@ -57,17 +57,17 @@
//! 1. Make the first top-level NDC query, and call the response as LHS response.
//!
//! 2. Traverse the join tree to get to the next remote join. Iterate through
//! all the rows in the LHS response, use the field mapping in the remote join node
//! to collect the values of those fields. In the above example, these would be
//! collecting the city codes from the LHS city query.
//! all the rows in the LHS response, use the field mapping in the remote join node
//! to collect the values of those fields. In the above example, these would be
//! collecting the city codes from the LHS city query.
//!
//! 3. Get the NDC query from the remote join node, and attach the values in the
//! above step as variables in the NDC query. This NDC query already has a
//! "where" filter clause with a variable on the join mapping field. Make the
//! NDC query, and call the response as RHS response.
//! above step as variables in the NDC query. This NDC query already has a
//! "where" filter clause with a variable on the join mapping field. Make the
//! NDC query, and call the response as RHS response.
//!
//! 4. If there is a sub-tree from this remote join node, recursively perform
//! this algorithm.
//! this algorithm.
//!
//! 5. Perform join on LHS response and RHS response
//!

View File

@ -113,11 +113,11 @@ pub struct RemoteJoin<'s, 'ir> {
/// The HashMap has the following info -
/// - key: is the field name in the source
/// - value->first item: is the alias we create for the
/// source field. If the user did not request the join field in the
/// selection set, we include the join mapping field and call it a phantom
/// field.
/// source field. If the user did not request the join field in the
/// selection set, we include the join mapping field and call it a phantom
/// field.
/// - value->second item: is the target NDC field. This could be a model
/// field or an argument name.
/// field or an argument name.
pub join_mapping: HashMap<SourceFieldName, (SourceFieldAlias, TargetField)>,
/// Represents how to process the join response.
pub process_response_as: ProcessResponseAs<'ir>,

View File

@ -154,8 +154,8 @@ pub fn generate_command_info<'n, 's>(
/// containing headers and response fields; and the response field is also an
/// object type -
/// 1. Engine needs to generate fields selection IR such that it contains
/// `{"headers": ..., "response": ...}` shape, and the actual selection from the
/// user-facing query goes inside the `response` field
/// `{"headers": ..., "response": ...}` shape, and the actual selection from the
/// user-facing query goes inside the `response` field
fn wrap_selection_in_response_config<'a>(
command_source: &CommandSourceDetail,
original_selection: Option<NestedSelection<'a>>,

View File

@ -35,7 +35,7 @@ pub fn query_root_schema(
)?;
fields.insert(field_name, field);
}
for select_many in &model.graphql_api.select_many {
if let Some(select_many) = &model.graphql_api.select_many {
let (field_name, field) = select_many::select_many_field(
gds,
builder,

View File

@ -1,5 +1,5 @@
# This should match the Rust version in rust-toolchain.yaml and the other Dockerfiles.
FROM rust:1.79.0
FROM rust:1.80.0
WORKDIR app

View File

@ -1,5 +1,5 @@
# This should match the Rust version in rust-toolchain.yaml and the other Dockerfiles.
FROM rust:1.79.0 AS builder
FROM rust:1.80.0 AS builder
WORKDIR /app
COPY ./Cargo.toml ./Cargo.toml

View File

@ -7,11 +7,11 @@
]
},
"locked": {
"lastModified": 1715274763,
"narHash": "sha256-3Iv1PGHJn9sV3HO4FlOVaaztOxa9uGLfOmUWrH7v7+A=",
"lastModified": 1722960479,
"narHash": "sha256-NhCkJJQhD5GUib8zN9JrmYGMwt4lCRp6ZVNzIiYCl0Y=",
"owner": "ipetkov",
"repo": "crane",
"rev": "27025ab71bdca30e7ed0a16c88fd74c5970fc7f5",
"rev": "4c6c77920b8d44cd6660c1621dea6b3fc4b4c4f4",
"type": "github"
},
"original": {
@ -40,11 +40,11 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1719433836,
"narHash": "sha256-dRKjM4V29ZGrLMNV187TlEM65xDcXcwueZVEt6nzE5c=",
"lastModified": 1723449200,
"narHash": "sha256-t3Uj+ByTYZhKZW9/svSd7osQcnaWA3BD4t+sMgyf78M=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "ea9cd521db209a1f709c1681697249591db0271d",
"rev": "fbed97f97223fe8c3688ea9f9fb1beef78774d93",
"type": "github"
},
"original": {
@ -68,11 +68,11 @@
]
},
"locked": {
"lastModified": 1719368303,
"narHash": "sha256-vhkKOUs9eOZgcPrA6wMw7a7J48pEjVuhzQfitVwVv1g=",
"lastModified": 1723429325,
"narHash": "sha256-4x/32xTCd+xCwFoI/kKSiCr5LQA2ZlyTRYXKEni5HR8=",
"owner": "oxalica",
"repo": "rust-overlay",
"rev": "32415b22fd3b454e4a1385af64aa5cef9766ff4c",
"rev": "65e3dc0fe079fe8df087cd38f1fe6836a0373aad",
"type": "github"
},
"original": {

View File

@ -1,4 +1,4 @@
[toolchain]
channel = "1.79.0"
channel = "1.80.0"
profile = "default" # see https://rust-lang.github.io/rustup/concepts/profiles.html
components = ["llvm-tools-preview", "rust-analyzer", "rust-src"] # see https://rust-lang.github.io/rustup/concepts/components.html