@probelabs/probe 0.6.0-rc113 → 0.6.0-rc115
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/bin/probe +3 -3
- package/build/agent/ProbeAgent.js +7 -0
- package/build/agent/index.js +11 -3
- package/build/agent/schemaUtils.js +3 -1
- package/build/mcp/index.js +5 -5
- package/build/mcp/index.ts +5 -5
- package/cjs/agent/ProbeAgent.cjs +9 -1
- package/cjs/index.cjs +9 -1
- package/package.json +1 -1
- package/src/agent/ProbeAgent.js +7 -0
- package/src/agent/index.js +2 -2
- package/src/agent/schemaUtils.js +3 -1
- package/src/mcp/index.ts +5 -5
package/bin/probe
CHANGED
|
@@ -29,12 +29,12 @@ async function ensureBinary(binaryPath) {
|
|
|
29
29
|
try {
|
|
30
30
|
// Try to import the downloader and download the binary
|
|
31
31
|
const { downloadProbeBinary } = await import('../src/downloader.js');
|
|
32
|
-
console.
|
|
32
|
+
console.error('Probe binary not found, downloading...');
|
|
33
33
|
await downloadProbeBinary();
|
|
34
34
|
|
|
35
35
|
// Check if the binary now exists and is executable
|
|
36
36
|
if (await isExecutable(binaryPath)) {
|
|
37
|
-
console.
|
|
37
|
+
console.error('Binary downloaded successfully.');
|
|
38
38
|
|
|
39
39
|
// On macOS, try to remove quarantine attributes that might prevent execution
|
|
40
40
|
if (process.platform === 'darwin') {
|
|
@@ -133,7 +133,7 @@ async function main() {
|
|
|
133
133
|
|
|
134
134
|
// Check if binary exists and is executable
|
|
135
135
|
if (!(await isExecutable(binaryPath))) {
|
|
136
|
-
console.
|
|
136
|
+
console.error('Probe binary not found or not executable, attempting to download...');
|
|
137
137
|
const downloadSuccess = await ensureBinary(binaryPath);
|
|
138
138
|
if (!downloadSuccess) {
|
|
139
139
|
console.error('Failed to download probe binary. Please try installing again or check your internet connection.');
|
|
@@ -40,6 +40,7 @@ import {
|
|
|
40
40
|
createSchemaDefinitionCorrectionPrompt,
|
|
41
41
|
validateAndFixMermaidResponse
|
|
42
42
|
} from './schemaUtils.js';
|
|
43
|
+
import { removeThinkingTags } from './xmlParsingUtils.js';
|
|
43
44
|
import {
|
|
44
45
|
MCPXmlBridge,
|
|
45
46
|
parseHybridXmlToolCall,
|
|
@@ -1754,6 +1755,12 @@ Convert your previous response content into actual JSON data that follows this s
|
|
|
1754
1755
|
console.log(`[DEBUG] Mermaid validation: Skipped final validation due to disableMermaidValidation option`);
|
|
1755
1756
|
}
|
|
1756
1757
|
|
|
1758
|
+
// Remove thinking tags from final result before returning to user
|
|
1759
|
+
finalResult = removeThinkingTags(finalResult);
|
|
1760
|
+
if (this.debug) {
|
|
1761
|
+
console.log(`[DEBUG] Removed thinking tags from final result`);
|
|
1762
|
+
}
|
|
1763
|
+
|
|
1757
1764
|
return finalResult;
|
|
1758
1765
|
|
|
1759
1766
|
} catch (error) {
|
package/build/agent/index.js
CHANGED
|
@@ -54455,6 +54455,7 @@ FIXING METHODOLOGY:
|
|
|
54455
54455
|
- Incorrect formatting for diagram-specific elements
|
|
54456
54456
|
- **Parentheses in node labels or subgraph names**: Wrap text containing parentheses in double quotes to prevent GitHub parsing errors
|
|
54457
54457
|
- Single quotes in node labels (GitHub's parser expects double quotes)
|
|
54458
|
+
- **Edge/Arrow labels with spaces**: MUST use pipe syntax like "A --|Label Text|--> B" or "A -- |Label Text| --> B". NEVER use double quotes like "A -- \\"Label\\" --> B" which is INVALID
|
|
54458
54459
|
4. **Preserve semantic meaning** - never change the intended flow or relationships
|
|
54459
54460
|
5. **Use proper escaping** for special characters and spaces
|
|
54460
54461
|
6. **Ensure consistency** in naming conventions and formatting
|
|
@@ -54487,8 +54488,10 @@ When presented with a broken Mermaid diagram, analyze it thoroughly and provide
|
|
|
54487
54488
|
debug: this.options.debug,
|
|
54488
54489
|
tracer: this.options.tracer,
|
|
54489
54490
|
allowEdit: this.options.allowEdit,
|
|
54490
|
-
maxIterations: 2
|
|
54491
|
+
maxIterations: 2,
|
|
54491
54492
|
// Limit mermaid fixing to 2 iterations to prevent long loops
|
|
54493
|
+
disableMermaidValidation: true
|
|
54494
|
+
// CRITICAL: Disable mermaid validation in nested agent to prevent infinite recursion
|
|
54492
54495
|
});
|
|
54493
54496
|
}
|
|
54494
54497
|
return this.agent;
|
|
@@ -55284,6 +55287,7 @@ var init_ProbeAgent = __esm({
|
|
|
55284
55287
|
init_mockProvider();
|
|
55285
55288
|
init_index();
|
|
55286
55289
|
init_schemaUtils();
|
|
55290
|
+
init_xmlParsingUtils();
|
|
55287
55291
|
init_mcp();
|
|
55288
55292
|
MAX_TOOL_ITERATIONS = parseInt(process.env.MAX_TOOL_ITERATIONS || "30", 10);
|
|
55289
55293
|
MAX_HISTORY_MESSAGES = 100;
|
|
@@ -56685,6 +56689,10 @@ Convert your previous response content into actual JSON data that follows this s
|
|
|
56685
56689
|
} else if (this.debug) {
|
|
56686
56690
|
console.log(`[DEBUG] Mermaid validation: Skipped final validation due to disableMermaidValidation option`);
|
|
56687
56691
|
}
|
|
56692
|
+
finalResult = removeThinkingTags(finalResult);
|
|
56693
|
+
if (this.debug) {
|
|
56694
|
+
console.log(`[DEBUG] Removed thinking tags from final result`);
|
|
56695
|
+
}
|
|
56688
56696
|
return finalResult;
|
|
56689
56697
|
} catch (error2) {
|
|
56690
56698
|
console.error(`[ERROR] ProbeAgent.answer failed:`, error2);
|
|
@@ -57573,7 +57581,7 @@ function parseArgs() {
|
|
|
57573
57581
|
return config;
|
|
57574
57582
|
}
|
|
57575
57583
|
function showHelp() {
|
|
57576
|
-
console.
|
|
57584
|
+
console.error(`
|
|
57577
57585
|
probe agent - AI-powered code exploration tool
|
|
57578
57586
|
|
|
57579
57587
|
Usage:
|
|
@@ -57980,7 +57988,7 @@ async function main() {
|
|
|
57980
57988
|
bashConfig.workingDirectory = config.bashWorkingDir;
|
|
57981
57989
|
}
|
|
57982
57990
|
if (config.verbose) {
|
|
57983
|
-
console.
|
|
57991
|
+
console.error("Bash command execution enabled");
|
|
57984
57992
|
}
|
|
57985
57993
|
}
|
|
57986
57994
|
const agentConfig2 = {
|
|
@@ -777,6 +777,7 @@ FIXING METHODOLOGY:
|
|
|
777
777
|
- Incorrect formatting for diagram-specific elements
|
|
778
778
|
- **Parentheses in node labels or subgraph names**: Wrap text containing parentheses in double quotes to prevent GitHub parsing errors
|
|
779
779
|
- Single quotes in node labels (GitHub's parser expects double quotes)
|
|
780
|
+
- **Edge/Arrow labels with spaces**: MUST use pipe syntax like "A --|Label Text|--> B" or "A -- |Label Text| --> B". NEVER use double quotes like "A -- \\"Label\\" --> B" which is INVALID
|
|
780
781
|
4. **Preserve semantic meaning** - never change the intended flow or relationships
|
|
781
782
|
5. **Use proper escaping** for special characters and spaces
|
|
782
783
|
6. **Ensure consistency** in naming conventions and formatting
|
|
@@ -812,7 +813,8 @@ When presented with a broken Mermaid diagram, analyze it thoroughly and provide
|
|
|
812
813
|
debug: this.options.debug,
|
|
813
814
|
tracer: this.options.tracer,
|
|
814
815
|
allowEdit: this.options.allowEdit,
|
|
815
|
-
maxIterations: 2 // Limit mermaid fixing to 2 iterations to prevent long loops
|
|
816
|
+
maxIterations: 2, // Limit mermaid fixing to 2 iterations to prevent long loops
|
|
817
|
+
disableMermaidValidation: true // CRITICAL: Disable mermaid validation in nested agent to prevent infinite recursion
|
|
816
818
|
});
|
|
817
819
|
}
|
|
818
820
|
|
package/build/mcp/index.js
CHANGED
|
@@ -31,7 +31,7 @@ function parseArgs() {
|
|
|
31
31
|
i++; // Skip the next argument
|
|
32
32
|
}
|
|
33
33
|
else if (args[i] === '--help' || args[i] === '-h') {
|
|
34
|
-
console.
|
|
34
|
+
console.error(`
|
|
35
35
|
Probe MCP Server
|
|
36
36
|
|
|
37
37
|
Usage:
|
|
@@ -61,11 +61,11 @@ const possiblePaths = [
|
|
|
61
61
|
for (const packageJsonPath of possiblePaths) {
|
|
62
62
|
try {
|
|
63
63
|
if (fs.existsSync(packageJsonPath)) {
|
|
64
|
-
console.
|
|
64
|
+
console.error(`Found package.json at: ${packageJsonPath}`);
|
|
65
65
|
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf-8'));
|
|
66
66
|
if (packageJson.version) {
|
|
67
67
|
packageVersion = packageJson.version;
|
|
68
|
-
console.
|
|
68
|
+
console.error(`Using version from package.json: ${packageVersion}`);
|
|
69
69
|
break;
|
|
70
70
|
}
|
|
71
71
|
}
|
|
@@ -82,7 +82,7 @@ if (packageVersion === '0.0.0') {
|
|
|
82
82
|
const npmList = JSON.parse(result.stdout);
|
|
83
83
|
if (npmList.dependencies && npmList.dependencies['@probelabs/probe']) {
|
|
84
84
|
packageVersion = npmList.dependencies['@probelabs/probe'].version;
|
|
85
|
-
console.
|
|
85
|
+
console.error(`Using version from npm list: ${packageVersion}`);
|
|
86
86
|
}
|
|
87
87
|
}
|
|
88
88
|
catch (error) {
|
|
@@ -91,7 +91,7 @@ if (packageVersion === '0.0.0') {
|
|
|
91
91
|
}
|
|
92
92
|
// Get the path to the bin directory
|
|
93
93
|
const binDir = path.resolve(__dirname, '..', 'bin');
|
|
94
|
-
console.
|
|
94
|
+
console.error(`Bin directory: ${binDir}`);
|
|
95
95
|
class ProbeServer {
|
|
96
96
|
constructor(timeout = 30, format) {
|
|
97
97
|
this.defaultTimeout = timeout;
|
package/build/mcp/index.ts
CHANGED
|
@@ -36,7 +36,7 @@ function parseArgs(): { timeout?: number; format?: string } {
|
|
|
36
36
|
console.error(`Format set to ${config.format}`);
|
|
37
37
|
i++; // Skip the next argument
|
|
38
38
|
} else if (args[i] === '--help' || args[i] === '-h') {
|
|
39
|
-
console.
|
|
39
|
+
console.error(`
|
|
40
40
|
Probe MCP Server
|
|
41
41
|
|
|
42
42
|
Usage:
|
|
@@ -72,11 +72,11 @@ const possiblePaths = [
|
|
|
72
72
|
for (const packageJsonPath of possiblePaths) {
|
|
73
73
|
try {
|
|
74
74
|
if (fs.existsSync(packageJsonPath)) {
|
|
75
|
-
console.
|
|
75
|
+
console.error(`Found package.json at: ${packageJsonPath}`);
|
|
76
76
|
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf-8'));
|
|
77
77
|
if (packageJson.version) {
|
|
78
78
|
packageVersion = packageJson.version;
|
|
79
|
-
console.
|
|
79
|
+
console.error(`Using version from package.json: ${packageVersion}`);
|
|
80
80
|
break;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
@@ -93,7 +93,7 @@ if (packageVersion === '0.0.0') {
|
|
|
93
93
|
const npmList = JSON.parse(result.stdout);
|
|
94
94
|
if (npmList.dependencies && npmList.dependencies['@probelabs/probe']) {
|
|
95
95
|
packageVersion = npmList.dependencies['@probelabs/probe'].version;
|
|
96
|
-
console.
|
|
96
|
+
console.error(`Using version from npm list: ${packageVersion}`);
|
|
97
97
|
}
|
|
98
98
|
} catch (error) {
|
|
99
99
|
console.error('Error getting version from npm:', error);
|
|
@@ -104,7 +104,7 @@ import { existsSync } from 'fs';
|
|
|
104
104
|
|
|
105
105
|
// Get the path to the bin directory
|
|
106
106
|
const binDir = path.resolve(__dirname, '..', 'bin');
|
|
107
|
-
console.
|
|
107
|
+
console.error(`Bin directory: ${binDir}`);
|
|
108
108
|
|
|
109
109
|
// The @probelabs/probe package now handles binary path management internally
|
|
110
110
|
// We don't need to manage the binary path in the MCP server anymore
|
package/cjs/agent/ProbeAgent.cjs
CHANGED
|
@@ -54177,6 +54177,7 @@ FIXING METHODOLOGY:
|
|
|
54177
54177
|
- Incorrect formatting for diagram-specific elements
|
|
54178
54178
|
- **Parentheses in node labels or subgraph names**: Wrap text containing parentheses in double quotes to prevent GitHub parsing errors
|
|
54179
54179
|
- Single quotes in node labels (GitHub's parser expects double quotes)
|
|
54180
|
+
- **Edge/Arrow labels with spaces**: MUST use pipe syntax like "A --|Label Text|--> B" or "A -- |Label Text| --> B". NEVER use double quotes like "A -- \\"Label\\" --> B" which is INVALID
|
|
54180
54181
|
4. **Preserve semantic meaning** - never change the intended flow or relationships
|
|
54181
54182
|
5. **Use proper escaping** for special characters and spaces
|
|
54182
54183
|
6. **Ensure consistency** in naming conventions and formatting
|
|
@@ -54209,8 +54210,10 @@ When presented with a broken Mermaid diagram, analyze it thoroughly and provide
|
|
|
54209
54210
|
debug: this.options.debug,
|
|
54210
54211
|
tracer: this.options.tracer,
|
|
54211
54212
|
allowEdit: this.options.allowEdit,
|
|
54212
|
-
maxIterations: 2
|
|
54213
|
+
maxIterations: 2,
|
|
54213
54214
|
// Limit mermaid fixing to 2 iterations to prevent long loops
|
|
54215
|
+
disableMermaidValidation: true
|
|
54216
|
+
// CRITICAL: Disable mermaid validation in nested agent to prevent infinite recursion
|
|
54214
54217
|
});
|
|
54215
54218
|
}
|
|
54216
54219
|
return this.agent;
|
|
@@ -55006,6 +55009,7 @@ var init_ProbeAgent = __esm({
|
|
|
55006
55009
|
init_mockProvider();
|
|
55007
55010
|
init_index();
|
|
55008
55011
|
init_schemaUtils();
|
|
55012
|
+
init_xmlParsingUtils();
|
|
55009
55013
|
init_mcp();
|
|
55010
55014
|
MAX_TOOL_ITERATIONS = parseInt(process.env.MAX_TOOL_ITERATIONS || "30", 10);
|
|
55011
55015
|
MAX_HISTORY_MESSAGES = 100;
|
|
@@ -56407,6 +56411,10 @@ Convert your previous response content into actual JSON data that follows this s
|
|
|
56407
56411
|
} else if (this.debug) {
|
|
56408
56412
|
console.log(`[DEBUG] Mermaid validation: Skipped final validation due to disableMermaidValidation option`);
|
|
56409
56413
|
}
|
|
56414
|
+
finalResult = removeThinkingTags(finalResult);
|
|
56415
|
+
if (this.debug) {
|
|
56416
|
+
console.log(`[DEBUG] Removed thinking tags from final result`);
|
|
56417
|
+
}
|
|
56410
56418
|
return finalResult;
|
|
56411
56419
|
} catch (error2) {
|
|
56412
56420
|
console.error(`[ERROR] ProbeAgent.answer failed:`, error2);
|
package/cjs/index.cjs
CHANGED
|
@@ -54322,6 +54322,7 @@ FIXING METHODOLOGY:
|
|
|
54322
54322
|
- Incorrect formatting for diagram-specific elements
|
|
54323
54323
|
- **Parentheses in node labels or subgraph names**: Wrap text containing parentheses in double quotes to prevent GitHub parsing errors
|
|
54324
54324
|
- Single quotes in node labels (GitHub's parser expects double quotes)
|
|
54325
|
+
- **Edge/Arrow labels with spaces**: MUST use pipe syntax like "A --|Label Text|--> B" or "A -- |Label Text| --> B". NEVER use double quotes like "A -- \\"Label\\" --> B" which is INVALID
|
|
54325
54326
|
4. **Preserve semantic meaning** - never change the intended flow or relationships
|
|
54326
54327
|
5. **Use proper escaping** for special characters and spaces
|
|
54327
54328
|
6. **Ensure consistency** in naming conventions and formatting
|
|
@@ -54354,8 +54355,10 @@ When presented with a broken Mermaid diagram, analyze it thoroughly and provide
|
|
|
54354
54355
|
debug: this.options.debug,
|
|
54355
54356
|
tracer: this.options.tracer,
|
|
54356
54357
|
allowEdit: this.options.allowEdit,
|
|
54357
|
-
maxIterations: 2
|
|
54358
|
+
maxIterations: 2,
|
|
54358
54359
|
// Limit mermaid fixing to 2 iterations to prevent long loops
|
|
54360
|
+
disableMermaidValidation: true
|
|
54361
|
+
// CRITICAL: Disable mermaid validation in nested agent to prevent infinite recursion
|
|
54359
54362
|
});
|
|
54360
54363
|
}
|
|
54361
54364
|
return this.agent;
|
|
@@ -55151,6 +55154,7 @@ var init_ProbeAgent = __esm({
|
|
|
55151
55154
|
init_mockProvider();
|
|
55152
55155
|
init_index();
|
|
55153
55156
|
init_schemaUtils();
|
|
55157
|
+
init_xmlParsingUtils();
|
|
55154
55158
|
init_mcp();
|
|
55155
55159
|
MAX_TOOL_ITERATIONS = parseInt(process.env.MAX_TOOL_ITERATIONS || "30", 10);
|
|
55156
55160
|
MAX_HISTORY_MESSAGES = 100;
|
|
@@ -56552,6 +56556,10 @@ Convert your previous response content into actual JSON data that follows this s
|
|
|
56552
56556
|
} else if (this.debug) {
|
|
56553
56557
|
console.log(`[DEBUG] Mermaid validation: Skipped final validation due to disableMermaidValidation option`);
|
|
56554
56558
|
}
|
|
56559
|
+
finalResult = removeThinkingTags(finalResult);
|
|
56560
|
+
if (this.debug) {
|
|
56561
|
+
console.log(`[DEBUG] Removed thinking tags from final result`);
|
|
56562
|
+
}
|
|
56555
56563
|
return finalResult;
|
|
56556
56564
|
} catch (error2) {
|
|
56557
56565
|
console.error(`[ERROR] ProbeAgent.answer failed:`, error2);
|
package/package.json
CHANGED
package/src/agent/ProbeAgent.js
CHANGED
|
@@ -40,6 +40,7 @@ import {
|
|
|
40
40
|
createSchemaDefinitionCorrectionPrompt,
|
|
41
41
|
validateAndFixMermaidResponse
|
|
42
42
|
} from './schemaUtils.js';
|
|
43
|
+
import { removeThinkingTags } from './xmlParsingUtils.js';
|
|
43
44
|
import {
|
|
44
45
|
MCPXmlBridge,
|
|
45
46
|
parseHybridXmlToolCall,
|
|
@@ -1754,6 +1755,12 @@ Convert your previous response content into actual JSON data that follows this s
|
|
|
1754
1755
|
console.log(`[DEBUG] Mermaid validation: Skipped final validation due to disableMermaidValidation option`);
|
|
1755
1756
|
}
|
|
1756
1757
|
|
|
1758
|
+
// Remove thinking tags from final result before returning to user
|
|
1759
|
+
finalResult = removeThinkingTags(finalResult);
|
|
1760
|
+
if (this.debug) {
|
|
1761
|
+
console.log(`[DEBUG] Removed thinking tags from final result`);
|
|
1762
|
+
}
|
|
1763
|
+
|
|
1757
1764
|
return finalResult;
|
|
1758
1765
|
|
|
1759
1766
|
} catch (error) {
|
package/src/agent/index.js
CHANGED
|
@@ -214,7 +214,7 @@ function parseArgs() {
|
|
|
214
214
|
|
|
215
215
|
// Show help message
|
|
216
216
|
function showHelp() {
|
|
217
|
-
console.
|
|
217
|
+
console.error(`
|
|
218
218
|
probe agent - AI-powered code exploration tool
|
|
219
219
|
|
|
220
220
|
Usage:
|
|
@@ -696,7 +696,7 @@ async function main() {
|
|
|
696
696
|
}
|
|
697
697
|
|
|
698
698
|
if (config.verbose) {
|
|
699
|
-
console.
|
|
699
|
+
console.error('Bash command execution enabled');
|
|
700
700
|
}
|
|
701
701
|
}
|
|
702
702
|
|
package/src/agent/schemaUtils.js
CHANGED
|
@@ -777,6 +777,7 @@ FIXING METHODOLOGY:
|
|
|
777
777
|
- Incorrect formatting for diagram-specific elements
|
|
778
778
|
- **Parentheses in node labels or subgraph names**: Wrap text containing parentheses in double quotes to prevent GitHub parsing errors
|
|
779
779
|
- Single quotes in node labels (GitHub's parser expects double quotes)
|
|
780
|
+
- **Edge/Arrow labels with spaces**: MUST use pipe syntax like "A --|Label Text|--> B" or "A -- |Label Text| --> B". NEVER use double quotes like "A -- \\"Label\\" --> B" which is INVALID
|
|
780
781
|
4. **Preserve semantic meaning** - never change the intended flow or relationships
|
|
781
782
|
5. **Use proper escaping** for special characters and spaces
|
|
782
783
|
6. **Ensure consistency** in naming conventions and formatting
|
|
@@ -812,7 +813,8 @@ When presented with a broken Mermaid diagram, analyze it thoroughly and provide
|
|
|
812
813
|
debug: this.options.debug,
|
|
813
814
|
tracer: this.options.tracer,
|
|
814
815
|
allowEdit: this.options.allowEdit,
|
|
815
|
-
maxIterations: 2 // Limit mermaid fixing to 2 iterations to prevent long loops
|
|
816
|
+
maxIterations: 2, // Limit mermaid fixing to 2 iterations to prevent long loops
|
|
817
|
+
disableMermaidValidation: true // CRITICAL: Disable mermaid validation in nested agent to prevent infinite recursion
|
|
816
818
|
});
|
|
817
819
|
}
|
|
818
820
|
|
package/src/mcp/index.ts
CHANGED
|
@@ -36,7 +36,7 @@ function parseArgs(): { timeout?: number; format?: string } {
|
|
|
36
36
|
console.error(`Format set to ${config.format}`);
|
|
37
37
|
i++; // Skip the next argument
|
|
38
38
|
} else if (args[i] === '--help' || args[i] === '-h') {
|
|
39
|
-
console.
|
|
39
|
+
console.error(`
|
|
40
40
|
Probe MCP Server
|
|
41
41
|
|
|
42
42
|
Usage:
|
|
@@ -72,11 +72,11 @@ const possiblePaths = [
|
|
|
72
72
|
for (const packageJsonPath of possiblePaths) {
|
|
73
73
|
try {
|
|
74
74
|
if (fs.existsSync(packageJsonPath)) {
|
|
75
|
-
console.
|
|
75
|
+
console.error(`Found package.json at: ${packageJsonPath}`);
|
|
76
76
|
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf-8'));
|
|
77
77
|
if (packageJson.version) {
|
|
78
78
|
packageVersion = packageJson.version;
|
|
79
|
-
console.
|
|
79
|
+
console.error(`Using version from package.json: ${packageVersion}`);
|
|
80
80
|
break;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
@@ -93,7 +93,7 @@ if (packageVersion === '0.0.0') {
|
|
|
93
93
|
const npmList = JSON.parse(result.stdout);
|
|
94
94
|
if (npmList.dependencies && npmList.dependencies['@probelabs/probe']) {
|
|
95
95
|
packageVersion = npmList.dependencies['@probelabs/probe'].version;
|
|
96
|
-
console.
|
|
96
|
+
console.error(`Using version from npm list: ${packageVersion}`);
|
|
97
97
|
}
|
|
98
98
|
} catch (error) {
|
|
99
99
|
console.error('Error getting version from npm:', error);
|
|
@@ -104,7 +104,7 @@ import { existsSync } from 'fs';
|
|
|
104
104
|
|
|
105
105
|
// Get the path to the bin directory
|
|
106
106
|
const binDir = path.resolve(__dirname, '..', 'bin');
|
|
107
|
-
console.
|
|
107
|
+
console.error(`Bin directory: ${binDir}`);
|
|
108
108
|
|
|
109
109
|
// The @probelabs/probe package now handles binary path management internally
|
|
110
110
|
// We don't need to manage the binary path in the MCP server anymore
|