From 7c5511c9e34a92d28d86d66f0f7f658a9ad43881 Mon Sep 17 00:00:00 2001 From: Bruno Menezes Date: Wed, 27 May 2026 10:50:48 +0100 Subject: [PATCH] refactor(devnet): Run dependencies task sequentially and set task runner to exit on error. * Dependencies task download and extract artifacts information. The change prevents race-condition errors that cause EEXIST and ENOENT errors. * Set task runner to exit on error. That change is targeting the release CI action to avoid publishing a package with missing data. --- .changeset/sweet-items-film.md | 5 +++++ packages/devnet/build.ts | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changeset/sweet-items-film.md diff --git a/.changeset/sweet-items-film.md b/.changeset/sweet-items-film.md new file mode 100644 index 00000000..721da8bc --- /dev/null +++ b/.changeset/sweet-items-film.md @@ -0,0 +1,5 @@ +--- +"@cartesi/devnet": patch +--- + +Download artifacts dependencies sequentially to avoid race-condition errors when creating directories and files, which can result in EEXIST followed by ENOENT errors. Also, explicitly configure the task runner to exit on error, so it doesn't publish a package with missing required information. diff --git a/packages/devnet/build.ts b/packages/devnet/build.ts index 2289f3bb..0b5da822 100644 --- a/packages/devnet/build.ts +++ b/packages/devnet/build.ts @@ -189,7 +189,7 @@ const build = async () => { { title: "Download dependencies", task: async (_, task) => - task.newListr(dependencies, { concurrent: true }), + task.newListr(dependencies, { concurrent: false }), }, { title: "Starting anvil...", @@ -261,7 +261,7 @@ const build = async () => { }, }, ], - { exitOnError: false }, + { exitOnError: true }, ); await tasks.run({