diff --git a/CHANGELOG.md b/CHANGELOG.md index d2e97dd6..c6f8cac1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,11 @@ 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). +## [2.10.2] - 2026-05-22 + +### Fixed +- **Open Core Build Fallback**: Updated the `build:resolve` script to gracefully fallback to Open Core licensing types when the proprietary `@core` module is unavailable, resolving CI build failures in public GitHub Actions environments. + ## [2.10.0] - 2026-05-11 ### Added diff --git a/package.json b/package.json index 0c68de25..9ac22918 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "tempo-monorepo", - "version": "2.10.1", + "version": "2.10.2", "private": true, "description": "Magma Computing Monorepo", "repository": { diff --git a/packages/library/package.json b/packages/library/package.json index 73a2b455..a1942c93 100644 --- a/packages/library/package.json +++ b/packages/library/package.json @@ -1,6 +1,6 @@ { "name": "@magmacomputing/library", - "version": "2.10.1", + "version": "2.10.2", "description": "Shared utility library for Tempo", "author": "Magma Computing Solutions", "license": "MIT", diff --git a/packages/tempo/bin/resolve-types.ts b/packages/tempo/bin/resolve-types.ts index 7a18f09c..dd98ef21 100644 --- a/packages/tempo/bin/resolve-types.ts +++ b/packages/tempo/bin/resolve-types.ts @@ -17,11 +17,7 @@ const LIB_DEST_DIR = path.resolve(DIST_DIR, 'lib'); const __dirname = path.dirname(fileURLToPath(import.meta.url)); const LIC_SRC_DIR = process.env.LIC_SRC_DIR || path.resolve(__dirname, '../../../../tempo-plugin/internal/@core/dist'); -if (!fs.existsSync(LIC_SRC_DIR)) { - console.error(`\n⚠️ ERROR: External license directory not found: ${LIC_SRC_DIR}`); - console.error(`⚠️ Cannot build premium module without proprietary @core types.\n`); - process.exit(1); -} +const isPremiumAvailable = fs.existsSync(LIC_SRC_DIR); const LIC_DEST_DIR = path.resolve(DIST_DIR, 'lic'); @@ -48,10 +44,19 @@ usedModules.forEach(mod => { // 4. Copy licensing core types if (!fs.existsSync(LIC_DEST_DIR)) fs.mkdirSync(LIC_DEST_DIR, { recursive: true }); -const licFiles = fs.readdirSync(LIC_SRC_DIR).filter(f => f.endsWith('.d.ts')); -licFiles.forEach(file => { - fs.copyFileSync(path.join(LIC_SRC_DIR, file), path.join(LIC_DEST_DIR, file)); -}); + +if (isPremiumAvailable) { + const licFiles = fs.readdirSync(LIC_SRC_DIR).filter(f => f.endsWith('.d.ts')); + licFiles.forEach(file => { + fs.copyFileSync(path.join(LIC_SRC_DIR, file), path.join(LIC_DEST_DIR, file)); + }); +} else { + console.log('ℹ️ Premium licensing not found. Falling back to Open Core types.'); + const defaultLicType = path.resolve(DIST_DIR, 'support/support.license.d.ts'); + if (fs.existsSync(defaultLicType)) { + fs.copyFileSync(defaultLicType, path.join(LIC_DEST_DIR, 'index.d.ts')); + } +} // 5. Walk through all .d.ts files in dist/ to rewrite aliases function walk(dir: string) { diff --git a/packages/tempo/package.json b/packages/tempo/package.json index 8534ac8c..88ae8b90 100644 --- a/packages/tempo/package.json +++ b/packages/tempo/package.json @@ -1,6 +1,6 @@ { "name": "@magmacomputing/tempo", - "version": "2.10.1", + "version": "2.10.2", "description": "The Tempo core library", "author": "Magma Computing Solutions", "license": "MIT", @@ -227,7 +227,7 @@ }, "devDependencies": { "@js-temporal/polyfill": "^0.5.1", - "@magmacomputing/library": "2.10.1", + "@magmacomputing/library": "2.10.2", "@rollup/plugin-alias": "^6.0.0", "esbuild": "^0.25.12", "javascript-obfuscator": "^5.4.2",