@pareto4/pp-core 1.17.1 → 1.18.0

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 (86) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/README.md +5 -3
  3. package/agents/pp-code-fixer.md +0 -11
  4. package/agents/pp-code-reviewer.md +1 -78
  5. package/agents/pp-executor.md +9 -23
  6. package/agents/pp-planner.md +11 -11
  7. package/agents/pp-vault-reviewer.md +43 -189
  8. package/agents/pp-verifier.md +0 -6
  9. package/commands/pp-ns-manage.md +1 -1
  10. package/commands/pp-ns-review.md +1 -1
  11. package/commands/pp-vault-promote.md +7 -8
  12. package/commands/pp-vault-review.md +6 -7
  13. package/gemini-extension.json +1 -1
  14. package/package.json +3 -6
  15. package/pp-core/bin/lib/capability-registry.cjs +13 -355
  16. package/pp-core/bin/lib/capability-state.cjs +15 -79
  17. package/pp-core/bin/lib/capability-writer.cjs +2 -16
  18. package/pp-core/bin/lib/check-command-router.cjs +277 -2273
  19. package/pp-core/bin/lib/clusters.cjs +2 -2
  20. package/pp-core/bin/lib/compose-bindings.cjs +2 -2
  21. package/pp-core/bin/lib/config.cjs +3 -6
  22. package/pp-core/bin/lib/git-base-branch.cjs +10 -13
  23. package/pp-core/bin/lib/git-provider.cjs +5 -6
  24. package/pp-core/bin/lib/init-contract.cjs +7 -35
  25. package/pp-core/bin/lib/init-interactive.cjs +6 -20
  26. package/pp-core/bin/lib/io.cjs +2 -8
  27. package/pp-core/bin/lib/loop-resolver.cjs +8 -32
  28. package/pp-core/bin/lib/org-profile.cjs +16 -92
  29. package/pp-core/bin/lib/vault-command-router.cjs +174 -1206
  30. package/pp-core/bin/lib/vault-coordinates.cjs +3 -3
  31. package/pp-core/bin/lib/vault-index.cjs +27 -70
  32. package/pp-core/bin/lib/vault-seal.cjs +37 -122
  33. package/pp-core/bin/lib/vault-standards-promote.cjs +577 -0
  34. package/pp-core/bin/lib/vault-standards-review.cjs +293 -0
  35. package/pp-core/bin/lib/vault-standards.cjs +15 -16
  36. package/pp-core/bin/lib/vault-trace.cjs +40 -3016
  37. package/pp-core/bin/lib/vault-update.cjs +1 -26
  38. package/pp-core/bin/lib/vault.cjs +120 -314
  39. package/pp-core/bin/pp-tools.cjs +5 -32
  40. package/pp-core/references/autonomous-best-effort.md +1 -1
  41. package/pp-core/references/planner-vault-standards.md +16 -25
  42. package/pp-core/templates/README.md +1 -1
  43. package/pp-core/templates/VAULT-REVIEW.md +24 -170
  44. package/pp-core/workflows/add-tests.md +3 -3
  45. package/pp-core/workflows/audit-fix.md +3 -3
  46. package/pp-core/workflows/code-review-fix.md +3 -3
  47. package/pp-core/workflows/code-review.md +1 -57
  48. package/pp-core/workflows/debug.md +2 -2
  49. package/pp-core/workflows/discovery-sprint/prototype.md +2 -2
  50. package/pp-core/workflows/discovery-sprint/vault-context.md +4 -10
  51. package/pp-core/workflows/execute-phase/steps/check-query-gate.md +11 -13
  52. package/pp-core/workflows/execute-phase/steps/execute-pre-dispatch.md +5 -25
  53. package/pp-core/workflows/execute-phase/steps/vault-fetch.md +6 -6
  54. package/pp-core/workflows/execute-phase/steps/vault-load-gate.md +6 -109
  55. package/pp-core/workflows/execute-phase/steps/verify-post-gate.md +1 -17
  56. package/pp-core/workflows/execute-phase.md +2 -5
  57. package/pp-core/workflows/execute-plan.md +6 -8
  58. package/pp-core/workflows/help/modes/full.md +1 -1
  59. package/pp-core/workflows/quick.md +8 -8
  60. package/pp-core/workflows/validate-phase.md +3 -3
  61. package/pp-core/workflows/vault-review.md +64 -186
  62. package/pp-core/workflows/vault-write-back.md +73 -110
  63. package/pp-core/workflows/verify-work.md +1 -1
  64. package/scripts/gen-capability-registry.cjs +12 -93
  65. package/scripts/lint-test-file-count.allowlist.json +1 -19
  66. package/scripts/lint-test-file-count.cjs +5 -6
  67. package/scripts/prompt-injection-scan.sh +0 -3
  68. package/pp-core/bin/lib/practices-review-check.cjs +0 -944
  69. package/pp-core/bin/lib/vault-audit.cjs +0 -2594
  70. package/pp-core/bin/lib/vault-mode.cjs +0 -235
  71. package/pp-core/bin/lib/vault-practices.cjs +0 -2057
  72. package/pp-core/bin/lib/vault-review.cjs +0 -2102
  73. package/pp-core/bin/lib/vault-write-back.cjs +0 -905
  74. package/pp-core/references/planner-vault-practices.md +0 -95
  75. package/pp-core/references/practice-arithmetic-contract.md +0 -121
  76. package/pp-core/references/verifier-practice-verdicts.md +0 -263
  77. package/pp-core/templates/practices/README.md +0 -248
  78. package/pp-core/templates/practices/error-handling.md +0 -18
  79. package/pp-core/templates/practices/minimal-comments.md +0 -14
  80. package/pp-core/templates/practices/naming-convention.md +0 -18
  81. package/pp-core/templates/practices/practice-template.md +0 -23
  82. package/pp-core/workflows/execute-phase/steps/verifier-practice-payload.md +0 -165
  83. package/scripts/gen-practice-arithmetic-contract.cjs +0 -412
  84. package/scripts/practice-arithmetic-contract.allow.json +0 -35
  85. package/scripts/record-vault-mode-golden.cjs +0 -89
  86. package/scripts/vault-calibrate.cjs +0 -996
@@ -15,9 +15,7 @@
15
15
  * Two steps, so the confirmation is explicit and works the same for a person
16
16
  * and for an agent shell: without `--yes` it only reports the plan
17
17
  * (current → target) and writes nothing; with `--yes` it writes
18
- * `client.vaultRef`, fetches the vault at the new version, and reports any
19
- * practice whose `schemaVersion` is newer than this pp-core supports (the
20
- * vault version a project picks implies a minimum pp-core, never the reverse).
18
+ * `client.vaultRef` and fetches the vault at the new version.
21
19
  * It never commits: the command it prints is the operator's to run.
22
20
  *
23
21
  * ADR-457 build-at-publish: this TypeScript file is the SOURCE OF TRUTH. It
@@ -48,8 +46,6 @@ const { redactCloneTarget } = vaultModule;
48
46
  /** How many tags a report lists — enough to pick from, bounded for a long history. */
49
47
  exports.AVAILABLE_TAGS_CAP = 10;
50
48
  const BINDINGS_FILE = '.platform-bindings.json';
51
- /** Matches the degrade warning `parsePracticeFile` emits for a newer schemaVersion. */
52
- const NEWER_SCHEMA_WARNING_RE = /schemaVersion \d+ is newer than this pp-core supports/;
53
49
  // ─── Helpers ─────────────────────────────────────────────────────────────────
54
50
  function isObject(v) {
55
51
  return v !== null && typeof v === 'object' && !Array.isArray(v);
@@ -92,17 +88,6 @@ function runFetch(root, opts) {
92
88
  warnings,
93
89
  };
94
90
  }
95
- function findNewerSchemaPractices(root, opts) {
96
- // eslint-disable-next-line @typescript-eslint/no-require-imports
97
- const discover = opts._discover ?? require('./vault-practices.cjs').discoverPracticeFiles;
98
- const discovery = discover(root);
99
- const ids = [];
100
- for (const entry of discovery.degraded ?? []) {
101
- if (entry.warnings.some((w) => NEWER_SCHEMA_WARNING_RE.test(w)) && !ids.includes(entry.id))
102
- ids.push(entry.id);
103
- }
104
- return ids;
105
- }
106
91
  // ─── vaultUpdate ─────────────────────────────────────────────────────────────
107
92
  /**
108
93
  * Plan — and with `apply` perform — a move of the project's client vault to
@@ -126,7 +111,6 @@ function vaultUpdate(cwd, opts = {}) {
126
111
  latest: null,
127
112
  available: [],
128
113
  fetch: null,
129
- newerSchemaPractices: [],
130
114
  nextStep: null,
131
115
  };
132
116
  const fail = (reason, message) => ({
@@ -213,12 +197,6 @@ function vaultUpdate(cwd, opts = {}) {
213
197
  catch {
214
198
  applied.fetch = { source: 'error', ref: null, warnings: ['The vault could not be fetched at the new version — run "pp-tools vault fetch" to retry.'] };
215
199
  }
216
- try {
217
- applied.newerSchemaPractices = findNewerSchemaPractices(root, opts);
218
- }
219
- catch {
220
- applied.newerSchemaPractices = [];
221
- }
222
200
  return applied;
223
201
  }
224
202
  /** Plain-text rendering of a `vaultUpdate` result for the non-`--raw` CLI path. */
@@ -232,9 +210,6 @@ function renderVaultUpdate(r) {
232
210
  for (const w of r.fetch.warnings)
233
211
  lines.push(w);
234
212
  }
235
- if (r.newerSchemaPractices.length > 0) {
236
- lines.push(`${r.newerSchemaPractices.length} practice(s) in this vault version were written for a newer pp-core and apply only in degraded form: ${r.newerSchemaPractices.join(', ')}. Update pp-core to apply them fully.`);
237
- }
238
213
  if (r.nextStep) {
239
214
  lines.push(r.applied ? `Commit the change: ${r.nextStep}` : `To apply: ${r.nextStep}`);
240
215
  }