Skip to content

Commit e56be4e

Browse files
dependabot[bot]lutter
authored andcommitted
all: Bump graphql-tools from 0.4.0 to 0.5.0
This also switches us from the standalone graphql-parser to the parser bundled with graphql-tools. Bumps [graphql-tools](https://github.com/graphql-hive/router) from 0.4.0 to 0.5.0. - [Release notes](https://github.com/graphql-hive/router/releases) - [Changelog](https://github.com/graphql-hive/router/blob/main/RELEASE.md) - [Commits](https://github.com/graphql-hive/router/commits/graphql-tools/v0.5.0) --- updated-dependencies: - dependency-name: graphql-tools dependency-version: 0.5.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
1 parent cf6a014 commit e56be4e

File tree

16 files changed

+44
-49
lines changed

16 files changed

+44
-49
lines changed

Cargo.lock

Lines changed: 12 additions & 19 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ graph-store-postgres = { path = "./store/postgres" }
6666
graphman-server = { path = "./server/graphman" }
6767
graphman = { path = "./core/graphman" }
6868
graphman-store = { path = "./core/graphman_store" }
69+
graphql-tools = "0.5.0"
6970
itertools = "0.14.0"
7071
lazy_static = "1.5.0"
7172
prost = "0.13"

graph/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ http-body-util = "0.1"
3737
hyper-util = { version = "0.1", features = ["full"] }
3838
futures01 = { package = "futures", version = "0.1.31" }
3939
lru_time_cache = "0.11"
40-
graphql-parser = "0.4.1"
40+
graphql-tools = { workspace = true }
4141
lazy_static = "1.5.0"
4242
num-bigint = { version = "=0.2.6", features = ["serde"] }
4343
num-integer = { version = "=0.1.46" }

graph/examples/validate.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ use graph::data::subgraph::SPEC_VERSION_1_1_0;
3636
use graph::prelude::s;
3737
use graph::prelude::DeploymentHash;
3838
use graph::schema::InputSchema;
39-
use graphql_parser::parse_schema;
39+
use graphql_tools::parser::parse_schema;
4040
use serde::Deserialize;
4141
use std::alloc::GlobalAlloc;
4242
use std::alloc::Layout;
@@ -147,7 +147,7 @@ struct Opts {
147147
#[clap(long)]
148148
api: bool,
149149
#[clap(
150-
short, long, default_value = "validate",
150+
short, long, default_value = "validate",
151151
value_parser = clap::builder::PossibleValuesParser::new(&["validate", "size"])
152152
)]
153153
mode: RunMode,

graph/src/data/graphql/ext.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,7 @@ impl FieldExt for Field {
394394

395395
#[cfg(test)]
396396
mod directive_finder_tests {
397-
use graphql_parser::parse_schema;
397+
use graphql_tools::parser::parse_schema;
398398

399399
use super::*;
400400

graph/src/data/graphql/shape_hash.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ impl ShapeHash for q::Document {
3838

3939
impl ShapeHash for q::OperationDefinition {
4040
fn shape_hash(&self, hasher: &mut ShapeHasher) {
41-
use graphql_parser::query::OperationDefinition::*;
41+
use graphql_tools::parser::query::OperationDefinition::*;
4242
// We want `[query|subscription|mutation] things { BODY }` to hash
4343
// to the same thing as just `things { BODY }`
4444
match self {
@@ -69,7 +69,7 @@ impl ShapeHash for q::SelectionSet {
6969

7070
impl ShapeHash for q::Selection {
7171
fn shape_hash(&self, hasher: &mut ShapeHasher) {
72-
use graphql_parser::query::Selection::*;
72+
use graphql_tools::parser::query::Selection::*;
7373
match self {
7474
Field(field) => field.shape_hash(hasher),
7575
FragmentSpread(spread) => spread.shape_hash(hasher),
@@ -92,7 +92,7 @@ impl ShapeHash for q::Field {
9292

9393
impl ShapeHash for s::Value {
9494
fn shape_hash(&self, hasher: &mut ShapeHasher) {
95-
use graphql_parser::schema::Value::*;
95+
use graphql_tools::parser::schema::Value::*;
9696

9797
match self {
9898
Variable(_) | Int(_) | Float(_) | String(_) | Boolean(_) | Null | Enum(_) => {
@@ -151,7 +151,7 @@ impl ShapeHash for q::TypeCondition {
151151
#[cfg(test)]
152152
mod tests {
153153
use super::*;
154-
use graphql_parser::parse_query;
154+
use graphql_tools::parser::parse_query;
155155

156156
#[test]
157157
fn identical_and_different() {

graph/src/data/query/error.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use graphql_parser::Pos;
1+
use graphql_tools::parser::Pos;
22
use hex::FromHexError;
33
use serde::ser::*;
44
use std::collections::HashMap;

graph/src/data/query/query.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ impl Query {
147147
{
148148
(
149149
document
150-
.format(graphql_parser::Style::default().indent(0))
150+
.format(graphql_tools::parser::Style::default().indent(0))
151151
.replace('\n', " "),
152152
serde_json::to_string(&variables).unwrap_or_default(),
153153
)

graph/src/data/store/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ impl NullValue for Value {
329329

330330
impl Value {
331331
pub fn from_query_value(value: &r::Value, ty: &s::Type) -> Result<Value, QueryExecutionError> {
332-
use graphql_parser::schema::Type::{ListType, NamedType, NonNullType};
332+
use graphql_tools::parser::schema::Type::{ListType, NamedType, NonNullType};
333333

334334
Ok(match (value, ty) {
335335
// When dealing with non-null types, use the inner type to convert the value

graph/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,8 +177,8 @@ pub mod prelude {
177177
macro_rules! static_graphql {
178178
($m:ident, $m2:ident, {$($n:ident,)*}) => {
179179
pub mod $m {
180-
use graphql_parser::$m2 as $m;
181-
pub use graphql_parser::Pos;
180+
use graphql_tools::parser::$m2 as $m;
181+
pub use graphql_tools::parser::Pos;
182182
pub use $m::*;
183183
$(
184184
pub type $n = $m::$n<'static, String>;

0 commit comments

Comments
 (0)