diff --git a/package.json b/package.json index 7f572a7..861550b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "ignite", - "version": "0.7.1", + "version": "0.7.2", "private": true, "description": "Secure JS/TS code execution in Docker with sandboxing for AI agents, untrusted code, and microservices", "workspaces": [ diff --git a/packages/cli/package.json b/packages/cli/package.json index b7fdfb6..780da9b 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@ignite/cli", - "version": "0.7.1", + "version": "0.7.2", "type": "module", "bin": { "ignite": "./dist/index.js" diff --git a/packages/cli/src/commands/run.ts b/packages/cli/src/commands/run.ts index cf658e9..1b4be2c 100644 --- a/packages/cli/src/commands/run.ts +++ b/packages/cli/src/commands/run.ts @@ -61,8 +61,12 @@ export async function runCommand(servicePath: string, options: RunOptions): Prom if (options.auditOutput && audit) { const outputPath = resolve(process.cwd(), options.auditOutput); - await writeFile(outputPath, JSON.stringify(audit, null, 2)); - logger.success(`Audit saved to ${outputPath}`); + try { + await writeFile(outputPath, JSON.stringify(audit, null, 2)); + logger.success(`Audit saved to ${outputPath}`); + } catch (err) { + logger.error(`Failed to write audit to ${outputPath}: ${(err as Error).message}`); + } } if (options.json) { diff --git a/packages/cli/src/index.ts b/packages/cli/src/index.ts index f1708fe..7b3bfdc 100644 --- a/packages/cli/src/index.ts +++ b/packages/cli/src/index.ts @@ -13,7 +13,7 @@ const program = new Command(); program .name('ignite') .description('Secure sandbox for AI-generated code, untrusted scripts, and JS/TS execution') - .version('0.7.1'); + .version('0.7.2'); program .command('init ') diff --git a/packages/core/package.json b/packages/core/package.json index 1755694..42b02d5 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -1,6 +1,6 @@ { "name": "@ignite/core", - "version": "0.7.1", + "version": "0.7.2", "type": "module", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/core/src/service/load-service.ts b/packages/core/src/service/load-service.ts index 4829f8b..0f95250 100644 --- a/packages/core/src/service/load-service.ts +++ b/packages/core/src/service/load-service.ts @@ -141,6 +141,15 @@ function validateServiceConfig(config: unknown): ServiceValidation { infoCount: 'positive', }); + const dependencyConfig = pf['dependencies'] as Record | undefined; + const warnCount = dependencyConfig?.['warnCount']; + const infoCount = dependencyConfig?.['infoCount']; + if (typeof warnCount === 'number' && typeof infoCount === 'number') { + if (infoCount >= warnCount) { + errors.push('preflight.dependencies.infoCount must be less than preflight.dependencies.warnCount'); + } + } + validatePreflightSection(pf['image'], 'preflight.image', errors, { warnMb: 'positive', failMb: 'positive', diff --git a/packages/http/package.json b/packages/http/package.json index 876d882..66f728f 100644 --- a/packages/http/package.json +++ b/packages/http/package.json @@ -1,6 +1,6 @@ { "name": "@ignite/http", - "version": "0.7.1", + "version": "0.7.2", "type": "module", "main": "./dist/index.js", "types": "./dist/index.d.ts", diff --git a/packages/shared/package.json b/packages/shared/package.json index 240c468..526af52 100644 --- a/packages/shared/package.json +++ b/packages/shared/package.json @@ -1,6 +1,6 @@ { "name": "@ignite/shared", - "version": "0.7.1", + "version": "0.7.2", "type": "module", "main": "./dist/index.js", "types": "./dist/index.d.ts",