From a5ad2cd03ce8ecd101f0c5b57fbf50fa99f98cbe Mon Sep 17 00:00:00 2001 From: Sunli Date: Fri, 12 Aug 2022 12:48:01 +0800 Subject: [PATCH] Update build.rs --- CHANGELOG.md | 4 ++++ parser/build.rs | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a07805ad..ee821ef3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +# [4.0.8] 2022-08-12 + +- Add tracing to dataloader methods when the tracing feature is enabled. [#996](https://github.com/async-graphql/async-graphql/pull/996) + # [4.0.7] 2022-08-09 - Limit parser recursion depth to `64`. diff --git a/parser/build.rs b/parser/build.rs index e9bdd8a2..1d580660 100644 --- a/parser/build.rs +++ b/parser/build.rs @@ -24,6 +24,9 @@ struct GraphQLParser; let tokens = pest_generator::derive_parser(input, false); let new = tokens.to_string(); let code = format!("{}\n{}", PREAMBLE, &new); - fs::write("./src/parse/generated.rs", code).unwrap(); + let current_code = fs::read_to_string("./src/parse/generated.rs").unwrap(); + if current_code != code { + fs::write("./src/parse/generated.rs", code).unwrap(); + } Ok(()) }