bugzero 0.0.11 → 0.0.12

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > bugzero@0.0.11 build D:\WD projects\OpsPilot\packages\cli
2
+ > bugzero@0.0.12 build D:\WD projects\OpsPilot\packages\cli
3
3
  > tsup src/index.ts --format cjs --dts
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -7,8 +7,8 @@
7
7
  CLI tsup v8.5.1
8
8
  CLI Target: es2022
9
9
  CJS Build start
10
- CJS dist\index.js 49.36 KB
11
- CJS ⚡️ Build success in 76ms
10
+ CJS dist\index.js 49.97 KB
11
+ CJS ⚡️ Build success in 105ms
12
12
  DTS Build start
13
- DTS ⚡️ Build success in 1162ms
13
+ DTS ⚡️ Build success in 1226ms
14
14
  DTS dist\index.d.ts 20.00 B
package/dist/index.js CHANGED
@@ -906,12 +906,28 @@ var require_dist6 = __commonJS({
906
906
  const result = (0, import_patcher.applyPatch)(absolutePath, search, replace);
907
907
  if (!result.success) {
908
908
  console.error(`[BugZero] Patch failed: ${result.error}`);
909
+ const updatedLogs = `${state.logs}
910
+
911
+ \u26A0\uFE0F [BugZero System Warning] Your previous patch suggestion for "${filePath}" failed with the following error:
912
+ - ${result.error}
913
+
914
+ Please check if the file path is correct relative to the project root and make sure you target the correct file that contains the build error.`;
915
+ return {
916
+ logs: updatedLogs
917
+ };
909
918
  } else {
910
919
  console.log(`[BugZero] Backup saved to: ${result.backupPath}`);
911
920
  }
912
921
  return {};
913
922
  }
914
923
  async function verifyNode(state) {
924
+ if (state.logs.includes("[BugZero System Warning]")) {
925
+ console.log("[BugZero] Skipping validation pipeline because the patch failed to apply.");
926
+ return {
927
+ success: false,
928
+ logs: state.logs
929
+ };
930
+ }
915
931
  console.log("[BugZero] Re-running validation pipeline to verify fix\u2026");
916
932
  const result = await (0, import_analyzers.runValidationPipeline)(state.cwd);
917
933
  if (result.success) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "bugzero",
3
- "version": "0.0.11",
3
+ "version": "0.0.12",
4
4
  "bin": {
5
5
  "bugzero": "dist/index.js"
6
6
  },