@probelabs/probe-chat 0.6.0-rc103 → 0.6.0-rc104

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/package.json +1 -1
  2. package/probeTool.js +5 -9
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@probelabs/probe-chat",
3
- "version": "0.6.0-rc103",
3
+ "version": "0.6.0-rc104",
4
4
  "description": "CLI and web interface for Probe code search (formerly @probelabs/probe-web and @probelabs/probe-chat)",
5
5
  "main": "index.js",
6
6
  "type": "module",
package/probeTool.js CHANGED
@@ -534,15 +534,11 @@ const baseSearchFilesTool = {
534
534
  await fsPromises.access(searchDir);
535
535
  } catch (err) {
536
536
  console.error(`Directory does not exist: ${searchDir}`);
537
- return {
538
- success: true,
539
- directory: targetDir,
540
- pattern: pattern,
541
- recursive: recursive,
542
- files: [],
543
- count: 0,
544
- timestamp: new Date().toISOString()
545
- };
537
+ console.error(`Falling back to search in parent directory: ${targetDir}`);
538
+ // Fall back to searching in the parent directory instead of failing
539
+ searchDir = targetDir;
540
+ // Adjust the pattern to include the subdirectory in the search
541
+ filePattern = pattern; // Use the original pattern for glob matching
546
542
  }
547
543
 
548
544
  // Read directory contents