From 7ef800e8401a4e3fda4e8d1208b940ad6743449e Mon Sep 17 00:00:00 2001 From: Tom Hastjarjanto Date: Sun, 14 Sep 2025 07:58:30 +0200 Subject: [PATCH] fix: ensure file is written in temp dir (#6753) --- .changeset/happy-wasps-vanish.md | 5 +++++ packages/libraries/router/src/registry.rs | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 .changeset/happy-wasps-vanish.md diff --git a/.changeset/happy-wasps-vanish.md b/.changeset/happy-wasps-vanish.md new file mode 100644 index 000000000..ac31e38ab --- /dev/null +++ b/.changeset/happy-wasps-vanish.md @@ -0,0 +1,5 @@ +--- +'hive-apollo-router-plugin': patch +--- + +fix tmp dir filename diff --git a/packages/libraries/router/src/registry.rs b/packages/libraries/router/src/registry.rs index 0f806f727..c3fbb7b67 100644 --- a/packages/libraries/router/src/registry.rs +++ b/packages/libraries/router/src/registry.rs @@ -124,7 +124,7 @@ impl HiveRegistry { // It also enables hot-reloading to makes sure Apollo Router watches the file. let file_name = config.schema_file_path.unwrap_or( env::temp_dir() - .with_file_name("supergraph-schema.graphql") + .join("supergraph-schema.graphql") .to_string_lossy() .to_string(), );