natureco-cli 2.3.1 → 2.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "natureco-cli",
3
- "version": "2.3.1",
3
+ "version": "2.3.2",
4
4
  "description": "NatureCo AI Bot Terminal Interface",
5
5
  "main": "bin/natureco.js",
6
6
  "bin": {
@@ -211,7 +211,7 @@ body::before{
211
211
  <div class="header-bot-name" id="header-bot-name">Nature Bot</div>
212
212
  <div class="header-bot-model" id="header-bot-model">NatureCo</div>
213
213
  </div>
214
- <div class="version-badge" id="version-badge">v2.3.1</div>
214
+ <div class="version-badge" id="version-badge">v2.3.2</div>
215
215
  </div>
216
216
  <div class="messages" id="messages"></div>
217
217
  <div class="input-area">
@@ -341,7 +341,7 @@ function dashboard(action) {
341
341
  apiKey: cfg.apiKey,
342
342
  defaultBot: cfg.defaultBot,
343
343
  defaultBotId: cfg.defaultBotId,
344
- version: 'v2.3.1',
344
+ version: 'v2.3.2',
345
345
  bots: cfg.bots || [],
346
346
  telegramToken: cfg.telegramToken || null,
347
347
  whatsappConnected: cfg.whatsappConnected || false,
@@ -24,25 +24,17 @@ function loadBaileys() {
24
24
  }
25
25
  }
26
26
 
27
- // Log helper
27
+ // Log helper - only writes to console in worker, file writing handled by stdio redirect
28
28
  function log(module, message, color = 'white') {
29
29
  const timestamp = new Date().toISOString().replace('T', ' ').substring(0, 19);
30
30
  const logLine = `[${timestamp}] [${module}] ${message}`;
31
31
 
32
- // Console output with color
32
+ // Console output with color (will be redirected to file by parent process)
33
33
  const colorFn = chalk[color] || chalk.white;
34
34
  console.log(colorFn(logLine));
35
35
 
36
- // File output (no color)
37
- try {
38
- const dir = path.dirname(LOG_FILE);
39
- if (!fs.existsSync(dir)) {
40
- fs.mkdirSync(dir, { recursive: true });
41
- }
42
- fs.appendFileSync(LOG_FILE, logLine + '\n', 'utf-8');
43
- } catch (err) {
44
- // Ignore file write errors
45
- }
36
+ // Note: File writing removed - parent process redirects stdout/stderr to log file
37
+ // This prevents duplicate log entries
46
38
  }
47
39
 
48
40
  // Number matching helper - compare last 10 digits only
@@ -136,7 +128,7 @@ async function startGateway() {
136
128
 
137
129
  async function runGatewayWorker() {
138
130
  // This runs in the background
139
- log('gateway', 'Starting NatureCo Gateway v2.3.1...', 'green');
131
+ log('gateway', 'Starting NatureCo Gateway v2.3.2...', 'green');
140
132
 
141
133
  // Load config
142
134
  const { getConfig } = require('../utils/config');