mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-05 01:50:27 +08:00
fix(multi-cli): populate multiCliPlan sessions in liteTaskDataStore
Fix task click handlers not working in multi-CLI planning detail page.
Root cause: liteTaskDataStore was not being populated with multiCliPlan
sessions during initialization, so task click handlers couldn't access
session data using currentSessionDetailKey.
Changes:
- navigation.js: Add code to populate multiCliPlan sessions in liteTaskDataStore
- notifications.js: Add code to populate multiCliPlan sessions when data refreshes
Now when task detail page loads, liteTaskDataStore contains the correct key
'multi-cli-${sessionId}' matching currentSessionDetailKey, allowing task
click handlers to find session data and open detail drawer.
Verified: Task clicks now properly open detail panel for all 7 tasks.
This commit is contained in:
60
ccw/src/utils/codexlens-path.ts
Normal file
60
ccw/src/utils/codexlens-path.ts
Normal file
@@ -0,0 +1,60 @@
|
||||
/**
|
||||
* CodexLens Path Utilities
|
||||
*
|
||||
* Provides centralized path resolution for CodexLens data directory,
|
||||
* respecting the CODEXLENS_DATA_DIR environment variable.
|
||||
*
|
||||
* Priority order (matching Python implementation):
|
||||
* 1. CODEXLENS_DATA_DIR environment variable
|
||||
* 2. Default: ~/.codexlens
|
||||
*/
|
||||
|
||||
import { join } from 'path';
|
||||
import { homedir } from 'os';
|
||||
|
||||
/**
|
||||
* Get the CodexLens data directory.
|
||||
* Respects CODEXLENS_DATA_DIR environment variable.
|
||||
*
|
||||
* @returns Path to CodexLens data directory
|
||||
*/
|
||||
export function getCodexLensDataDir(): string {
|
||||
const envOverride = process.env.CODEXLENS_DATA_DIR;
|
||||
if (envOverride) {
|
||||
return envOverride;
|
||||
}
|
||||
return join(homedir(), '.codexlens');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the CodexLens virtual environment path.
|
||||
*
|
||||
* @returns Path to CodexLens venv directory
|
||||
*/
|
||||
export function getCodexLensVenvDir(): string {
|
||||
return join(getCodexLensDataDir(), 'venv');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the Python executable path in the CodexLens venv.
|
||||
*
|
||||
* @returns Path to python executable
|
||||
*/
|
||||
export function getCodexLensPython(): string {
|
||||
const venvDir = getCodexLensVenvDir();
|
||||
return process.platform === 'win32'
|
||||
? join(venvDir, 'Scripts', 'python.exe')
|
||||
: join(venvDir, 'bin', 'python');
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the pip executable path in the CodexLens venv.
|
||||
*
|
||||
* @returns Path to pip executable
|
||||
*/
|
||||
export function getCodexLensPip(): string {
|
||||
const venvDir = getCodexLensVenvDir();
|
||||
return process.platform === 'win32'
|
||||
? join(venvDir, 'Scripts', 'pip.exe')
|
||||
: join(venvDir, 'bin', 'pip');
|
||||
}
|
||||
@@ -14,6 +14,7 @@ import { existsSync, mkdirSync } from 'fs';
|
||||
import { join, dirname } from 'path';
|
||||
import { homedir, platform, arch } from 'os';
|
||||
import { EXEC_TIMEOUTS } from './exec-constants.js';
|
||||
import { getCodexLensDataDir, getCodexLensVenvDir } from './codexlens-path.js';
|
||||
|
||||
/**
|
||||
* Configuration for UvManager
|
||||
@@ -767,9 +768,9 @@ export class UvManager {
|
||||
* @returns Configured UvManager instance
|
||||
*/
|
||||
export function createCodexLensUvManager(dataDir?: string): UvManager {
|
||||
const baseDir = dataDir ?? join(homedir(), '.codexlens');
|
||||
const baseDir = dataDir ?? getCodexLensDataDir();
|
||||
return new UvManager({
|
||||
venvPath: join(baseDir, 'venv'),
|
||||
venvPath: getCodexLensVenvDir(),
|
||||
pythonVersion: '>=3.10,<3.13', // onnxruntime compatibility
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user