From 3235f7793c295f2e5cdd61e312ee765798f7ba10 Mon Sep 17 00:00:00 2001 From: Fabio Gartenmann <137318798+artiphishle@users.noreply.github.com> Date: Thu, 8 Oct 2026 21:08:23 +0200 Subject: [PATCH] fix(release): sync self-release parity probe --- .github/workflows/release.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index caa8c5b0..db0e32ea 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -271,15 +271,19 @@ jobs: process.stdout.write(output.length === 0 ? '' : `${output.join('\n')}\n`); NODE - PACKAGE_NAME="$package_name" node - <<'NODE' - const { createRequire } = require('node:module'); - const { readFileSync } = require('node:fs'); - const { join } = require('node:path'); - const { pathToFileURL } = require('node:url'); + PACKAGE_NAME="$package_name" node --input-type=module - <<'NODE' + import { readFileSync } from 'node:fs'; + import { createRequire } from 'node:module'; + import { join } from 'node:path'; + import { pathToFileURL } from 'node:url'; const name = process.env.PACKAGE_NAME; const packageDir = join(process.cwd(), 'node_modules', ...name.split('/')); const manifest = JSON.parse(readFileSync(join(packageDir, 'package.json'), 'utf8')); - if (!manifest.ankh || typeof manifest.ankh !== 'object') process.exit(0); + if ( + !manifest.ankh || + typeof manifest.ankh !== 'object' || + !Object.hasOwn(manifest.ankh, 'capabilities') + ) process.exit(0); const requireFromPackage = createRequire(join(packageDir, 'package.json')); const contractsPath = requireFromPackage.resolve('@ankhorage/contracts/capabilities'); const { areCapabilitiesEqual, isCapability, normalizeCapability } = await import(pathToFileURL(contractsPath).href);