From 6aeb6b934dd81ae0e1ebee9d80ee23c56a9ed409 Mon Sep 17 00:00:00 2001 From: Samir Talwar Date: Thu, 26 Oct 2023 10:35:49 +0200 Subject: [PATCH] Update ndc-spec to get the build working. ndc-spec v0.1.0-rc.8 uses workspace inheritance to set the version and edition, which unfortunately does not work with Crane for Nix (when using Git targets). I have inlined the version and edition to solve this, but we also need to release a new version of ndc-spec and update ndc-sdk. Until that happens, let's just override it (transitively) using `patch` in _Cargo.toml_. --- Cargo.lock | 4 ++-- Cargo.toml | 8 ++++++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 3e5f2e0a6..b19c8b5c7 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1411,7 +1411,7 @@ dependencies = [ [[package]] name = "ndc-client" version = "0.1.0" -source = "git+https://github.com/hasura/ndc-spec.git?tag=v0.1.0-rc.8#2c2def8a01af2f95100b4274599030c930525bee" +source = "git+https://github.com/hasura//ndc-spec.git?rev=3778605#3778605e9428d46e1f21ae02b077414afd0d0a68" dependencies = [ "async-trait", "indexmap 1.9.3", @@ -1498,7 +1498,7 @@ dependencies = [ [[package]] name = "ndc-test" version = "0.1.0" -source = "git+https://github.com/hasura/ndc-spec.git?tag=v0.1.0-rc.8#2c2def8a01af2f95100b4274599030c930525bee" +source = "git+https://github.com/hasura//ndc-spec.git?rev=3778605#3778605e9428d46e1f21ae02b077414afd0d0a68" dependencies = [ "async-trait", "clap", diff --git a/Cargo.toml b/Cargo.toml index a39bd4a3a..813dbab99 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,3 +15,11 @@ members = [ "crates/tests/other-db-tests", "crates/tests/tests-common" ] + +# Temporary patch to get the build working. We shall remove this once a new +# version of ndc-spec is published, and ndc-sdk is updated accordingly. +# The "//" is to convince Cargo to accept this, due to +# https://github.com/rust-lang/cargo/issues/10756 . +[patch."https://github.com/hasura/ndc-spec.git"] +ndc-client = { git = "https://github.com/hasura//ndc-spec.git", rev = "3778605" } +ndc-test = { git = "https://github.com/hasura//ndc-spec.git", rev = "3778605" }