codebolt 1.11.4 → 1.11.5

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.
Files changed (2) hide show
  1. package/dist/index.js +11 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -378638,8 +378638,8 @@ async function main() {
378638
378638
  userMessage: prompt,
378639
378639
  type: 'messageResponse',
378640
378640
  templateType: 'userChat',
378641
- selectedAgent: agentName !== 'codebolt-agent' ? { id: agentName, name: agentName } : { id: '', name: '' },
378642
- mentionedAgents: agentName !== 'codebolt-agent' ? [{ name: agentName }] : [],
378641
+ selectedAgent: { id: agentName, name: agentName },
378642
+ mentionedAgents: [{ name: agentName }],
378643
378643
  mentionedFiles: [],
378644
378644
  mentionedFolders: [],
378645
378645
  mentionedMultiFile: [],
@@ -446205,6 +446205,8 @@ class ChannelManager extends events_1.EventEmitter {
446205
446205
  /**
446206
446206
  * Initialize the channel manager for a project.
446207
446207
  * Disconnects any channels from a previous project before loading new ones.
446208
+ * Only eagerly connects adapters when auto-connect channels exist;
446209
+ * otherwise the store is ready and adapters are created on demand.
446208
446210
  */
446209
446211
  async initialize(projectPath) {
446210
446212
  // Disconnect adapters from a previous project before switching
@@ -446214,8 +446216,12 @@ class ChannelManager extends events_1.EventEmitter {
446214
446216
  }
446215
446217
  await this.store.initialize(projectPath);
446216
446218
  this.initialized = true;
446217
- // Auto-connect channels
446219
+ // Only connect adapters when channels are configured with autoConnect
446218
446220
  const autoChannels = this.store.getAutoConnect();
446221
+ if (autoChannels.length === 0) {
446222
+ appLogger_1.default.info('[ChannelManager] Initialized — no auto-connect channels, skipping adapter setup');
446223
+ return;
446224
+ }
446219
446225
  for (const config of autoChannels) {
446220
446226
  try {
446221
446227
  await this.connect(config.id);
@@ -607604,6 +607610,7 @@ const readFileSync = (filePath) => {
607604
607610
  catch (error) {
607605
607611
  if (error.code === 'ENOENT') {
607606
607612
  try {
607613
+ fs_extra_1.default.mkdirSync(path_1.default.dirname(filePath), { recursive: true });
607607
607614
  fs_extra_1.default.writeFileSync(filePath, '', 'utf8');
607608
607615
  console.log(`File not found. Created new file at ${filePath}`);
607609
607616
  return '{}';
@@ -607626,6 +607633,7 @@ const getDatabasePath = () => {
607626
607633
  exports.getDatabasePath = getDatabasePath;
607627
607634
  const writeFileSync = (filePath, data) => {
607628
607635
  try {
607636
+ fs_extra_1.default.mkdirSync(path_1.default.dirname(filePath), { recursive: true });
607629
607637
  fs_extra_1.default.writeFileSync(filePath, data, 'utf8');
607630
607638
  }
607631
607639
  catch (error) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codebolt",
3
- "version": "1.11.4",
3
+ "version": "1.11.5",
4
4
  "description": "CodeBolt headless server CLI",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",