Skip to content

🎬 Open-source, self-hosted AI agent that runs a YouTube channel end to end: researches topics, writes scripts, generates narration, visuals and video, optimizes SEO, and publishes after your approval, then learns from analytics. Works with Gemini, OpenAI, OpenRouter, DeepSeek and more.

Report the real version in the startup banner

darkzOGxc7c2553c9fbe
diff --git a/index.js b/index.js
index 8aafc12..0c80dce 100644
--- a/index.js
+++ b/index.js
@@ -13,6 +13,7 @@ const { ProductionManagementAgent } = require('./agents/production-management-ag
const { PublishingSchedulingAgent } = require('./agents/publishing-scheduling-agent');
const { AnalyticsOptimizationAgent } = require('./agents/analytics-optimization-agent');
const { DailyAutomation } = require('./schedules/daily-automation');
+const { version } = require('./package.json');
const chalk = require('chalk');
class YouTubeAutomationAgent {
@@ -27,7 +28,7 @@ class YouTubeAutomationAgent {
async initialize() {
try {
- console.log(chalk.cyan.bold('\n🎬 YouTube Automation Agent v2.0'));
+ console.log(chalk.cyan.bold(`\n🎬 YouTube Automation Agent v${version}`));
console.log(chalk.gray('─'.repeat(50)));
// Initialize database
diff --git a/test.js b/test.js
index ab7515f..bf81706 100644
--- a/test.js
+++ b/test.js
@@ -613,6 +613,27 @@ class SystemTest {
// Check if main index file exists
await fs.access('./index.js');
+ // The startup banner must report the real version. It was hardcoded to "v2.0"
+ // through v2.4.0, so bug reports pasted a version that was four releases stale.
+ const indexSource = await fs.readFile('index.js', 'utf8');
+ const hardcodedBanner = indexSource.match(/YouTube Automation Agent v[\d.]/);
+ if (hardcodedBanner) {
+ throw new Error(
+ `Startup banner hardcodes a version ("${hardcodedBanner[0]}") — interpolate package.json's version instead`
+ );
+ }
+ if (!indexSource.includes('YouTube Automation Agent v${version}')) {
+ throw new Error('Startup banner does not report the package.json version');
+ }
+
+ // package.json and package-lock.json drifted apart before v2.4.1; keep them aligned
+ const lockJson = JSON.parse(await fs.readFile('package-lock.json', 'utf8'));
+ if (lockJson.version !== packageJson.version) {
+ throw new Error(
+ `package-lock.json version (${lockJson.version}) does not match package.json (${packageJson.version})`
+ );
+ }
+
this.logger.info('Configuration test completed successfully');
}
}