@unbrained/pm-cli 2026.10.20 → 2026.10.21
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/.claude-plugin/marketplace.json +1 -1
- package/CHANGELOG.md +25 -0
- package/dist/cli/error-guidance.d.ts +8 -0
- package/dist/cli/error-guidance.js +2 -2
- package/dist/cli/main.js +1 -1
- package/dist/cli/register-list-query.js +2 -2
- package/dist/cli/register-operations.js +1 -1
- package/dist/cli-bundle/bundle-manifest.json +1 -1
- package/dist/cli-bundle/chunks/{chunk-QMZ73FCW.js → chunk-2B5HAZFK.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-4D25HF3V.js +2 -0
- package/dist/cli-bundle/chunks/{chunk-QETMESEB.js → chunk-4OYU5OXQ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-YTHI5DTH.js → chunk-5PZ7JNMI.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-TZU6U5ZE.js → chunk-C6SAXKBO.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-DIKQ2AL5.js +2 -0
- package/dist/cli-bundle/chunks/chunk-DIR3YEFD.js +2 -0
- package/dist/cli-bundle/chunks/{chunk-KU4Q3MSI.js → chunk-DJQVNDXO.js} +3 -3
- package/dist/cli-bundle/chunks/chunk-DR6DUBTU.js +30 -0
- package/dist/cli-bundle/chunks/{chunk-YT2Z3JPC.js → chunk-EMGMLKRV.js} +47 -47
- package/dist/cli-bundle/chunks/{chunk-YECCKB4E.js → chunk-GWIGZDRS.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-IB7UB5TE.js +2 -0
- package/dist/cli-bundle/chunks/{chunk-PNPE2OVJ.js → chunk-KBSVPUFD.js} +46 -45
- package/dist/cli-bundle/chunks/{chunk-7ZOIZ2AZ.js → chunk-MOC5BJHW.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-MZZIAC6S.js +20 -0
- package/dist/cli-bundle/chunks/{chunk-LS55VKRK.js → chunk-NNB65OOO.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-YW6SIKYP.js → chunk-QPV6UD55.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-GHJOMRSF.js → chunk-TMXWWOPJ.js} +2 -2
- package/dist/cli-bundle/chunks/{chunk-VLJLWZBO.js → chunk-V3XONSVC.js} +2 -2
- package/dist/cli-bundle/chunks/chunk-V5GJTXYW.js +126 -0
- package/dist/cli-bundle/chunks/{chunk-ZA3XXHEE.js → chunk-ZNKFMIVA.js} +2 -2
- package/dist/cli-bundle/chunks/{indexed-receipt-blobs-U7VGKIYC.js → indexed-receipt-blobs-65XXSPPR.js} +2 -2
- package/dist/cli-bundle/chunks/mutation-admission-FNWOVJLN.js +2 -0
- package/dist/cli-bundle/chunks/{register-list-query-NNDV6F6I.js → register-list-query-6PT5Y2EZ.js} +5 -5
- package/dist/cli-bundle/chunks/{register-mutation-3GCBSNQS.js → register-mutation-TAIQV46L.js} +4 -4
- package/dist/cli-bundle/chunks/register-operations-ONIRO22G.js +2 -0
- package/dist/cli-bundle/chunks/register-setup-OQMUZBJV.js +2 -0
- package/dist/cli-bundle/chunks/{settlement-hook-CLRGA6O7.js → settlement-hook-UVFYSBMU.js} +2 -2
- package/dist/cli-bundle/chunks/stage-FCPVFO3B.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-32ZKLRWM.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-HUZAXSIJ.js → chunk-3LWH2RJC.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-ZGEK57KD.js → chunk-44353U27.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-4HJVAUFX.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-VLSER3XW.js → chunk-5IMM7GOF.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-J6EYUGAR.js → chunk-6QSZHRM7.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-F7FD25TG.js → chunk-7UD7XTOE.js} +10 -10
- package/dist/cli-bundle/focused-chunks/{chunk-KKRFSI2N.js → chunk-CUWNNU4N.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-E2S42XCT.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-GHQVM6K6.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-GRSQGMRR.js +2 -0
- package/dist/cli-bundle/focused-chunks/{chunk-NI6NS44Q.js → chunk-HNCMYF2W.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-37SU7BZI.js → chunk-IAGFXKMZ.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-JI3RXXRN.js +78 -0
- package/dist/cli-bundle/focused-chunks/chunk-JMZPZQHR.js +26 -0
- package/dist/cli-bundle/focused-chunks/{chunk-E4II2D2B.js → chunk-KVYUQS6Y.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-O3M6YWVL.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-P5D7MHDS.js +20 -0
- package/dist/cli-bundle/focused-chunks/chunk-PDOWLRHC.js +8 -0
- package/dist/cli-bundle/focused-chunks/chunk-SVOOGGAK.js +2 -0
- package/dist/cli-bundle/focused-chunks/chunk-T27TLSEU.js +65 -0
- package/dist/cli-bundle/focused-chunks/{chunk-LJPUJ2KK.js → chunk-VD64TPXI.js} +2 -2
- package/dist/cli-bundle/focused-chunks/{chunk-GYHZ7W6O.js → chunk-VE6MTRH5.js} +2 -2
- package/dist/cli-bundle/focused-chunks/chunk-XE7P7N5X.js +8 -0
- package/dist/cli-bundle/focused-chunks/chunk-YIWDX6KO.js +91 -0
- package/dist/cli-bundle/focused-chunks/{indexed-receipt-blobs-H2G6CCGO.js → indexed-receipt-blobs-CRP6HAZY.js} +2 -2
- package/dist/cli-bundle/focused-chunks/mutation-admission-KM57KDDF.js +2 -0
- package/dist/cli-bundle/focused-chunks/{settlement-hook-5SNBBT7C.js → settlement-hook-MNCHFCAX.js} +2 -2
- package/dist/cli-bundle/focused-chunks/stage-UJYGWNZ7.js +2 -0
- package/dist/cli-bundle/main.js +21 -21
- package/dist/cli-bundle/sdk-authoring.js +1 -1
- package/dist/cli-bundle/sdk-contracts.js +1 -1
- package/dist/cli-bundle/sdk-core.js +23 -23
- package/dist/cli-bundle/sdk-governance.js +1 -1
- package/dist/cli-bundle/sdk-graph.js +1 -1
- package/dist/cli-bundle/sdk-merge.js +58 -57
- package/dist/cli-bundle/sdk-query.js +1 -1
- package/dist/cli-bundle/sdk-runtime.js +1 -1
- package/dist/cli-bundle/sdk-testing.js +1 -1
- package/dist/cli-bundle/sdk.js +2 -2
- package/dist/core/item/actionability.js +1 -1
- package/dist/core/lock/lock-gc.d.ts +12 -5
- package/dist/core/lock/lock-gc.js +1 -1
- package/dist/core/lock/lock-owner.d.ts +33 -0
- package/dist/core/lock/lock-owner.js +2 -0
- package/dist/core/lock/lock.d.ts +11 -22
- package/dist/core/lock/lock.js +4 -3
- package/dist/core/output/output.js +3 -3
- package/dist/core/shared/errors.d.ts +2 -0
- package/dist/core/shared/errors.js +1 -1
- package/dist/sdk/cli-contracts/runtime-contracts.js +1 -1
- package/dist/sdk/dependencies.js +1 -1
- package/dist/sdk/extension-command-context.js +2 -2
- package/dist/sdk/generated/generated-error-code-catalog-part-1.js +1 -1
- package/dist/sdk/governance/assurance-action.js +1 -1
- package/dist/sdk/governance/assurance.js +1 -1
- package/dist/sdk/governance/health.js +2 -2
- package/dist/sdk/output/list-envelope.js +1 -1
- package/dist/sdk/pagination.d.ts +3 -3
- package/dist/sdk/pagination.js +1 -1
- package/dist/sdk/public-surface.json +1 -1
- package/dist/sdk/query/context.js +2 -2
- package/dist/sdk/query/list.d.ts +2 -0
- package/dist/sdk/query/list.js +1 -1
- package/dist/sdk/query/projection-contracts.d.ts +1 -1
- package/dist/sdk/query/projection-contracts.js +1 -1
- package/dist/sdk/relationship-context.js +1 -1
- package/dist/sdk/runtime/mutation-admission.d.ts +2 -0
- package/dist/sdk/runtime/mutation-admission.js +2 -0
- package/dist/sdk/runtime-input.d.ts +2 -0
- package/dist/sdk/runtime-input.js +1 -1
- package/dist/sdk/runtime.js +1 -1
- package/dist/sdk/test/execution.d.ts +1 -0
- package/dist/sdk/test/execution.js +2 -2
- package/docs/AGENT_RUNTIME_PRIMITIVES.md +9 -0
- package/docs/ASSURANCE.md +17 -2
- package/docs/COMMANDS.md +17 -3
- package/docs/CONFIGURATION.md +29 -0
- package/docs/CONTEXT_RELEVANCE.md +15 -0
- package/docs/DEVELOPMENT_DEPENDENCY_SECURITY.md +26 -3
- package/docs/SDK.md +67 -0
- package/docs/TESTING.md +18 -0
- package/docs/agent-task-token-baseline.json +1 -1
- package/marketplace.json +1 -1
- package/package.json +1 -1
- package/packages/pm-beads/package.json +1 -1
- package/packages/pm-calendar/package.json +1 -1
- package/packages/pm-command-kit/package.json +1 -1
- package/packages/pm-digital-twin/package.json +1 -1
- package/packages/pm-governance-audit/package.json +1 -1
- package/packages/pm-guide-shell/package.json +1 -1
- package/packages/pm-kanban/package.json +1 -1
- package/packages/pm-lifecycle-hooks/package.json +1 -1
- package/packages/pm-linked-test-adapters/package.json +1 -1
- package/packages/pm-search-advanced/package.json +1 -1
- package/packages/pm-templates/package.json +1 -1
- package/packages/pm-todos/package.json +1 -1
- package/packages/pm-vcs/package.json +1 -1
- package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
- package/plugins/pm-claude/package.json +1 -1
- package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
- package/plugins/pm-codex/package.json +1 -1
- package/plugins/pm-codex/plugin.json +1 -1
- package/runtime-dependencies.json +1 -1
- package/dist/cli-bundle/chunks/chunk-2GGGOD7P.js +0 -30
- package/dist/cli-bundle/chunks/chunk-7NHA5K77.js +0 -126
- package/dist/cli-bundle/chunks/chunk-PTL3TBT6.js +0 -20
- package/dist/cli-bundle/chunks/chunk-QQYCB2LO.js +0 -2
- package/dist/cli-bundle/chunks/register-operations-YKDGNKUL.js +0 -2
- package/dist/cli-bundle/chunks/register-setup-AOUZQQWB.js +0 -2
- package/dist/cli-bundle/chunks/stage-6QXYRMSU.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-6IU7BESB.js +0 -65
- package/dist/cli-bundle/focused-chunks/chunk-AS3MOBO3.js +0 -25
- package/dist/cli-bundle/focused-chunks/chunk-AW35RDKA.js +0 -78
- package/dist/cli-bundle/focused-chunks/chunk-H5Q2HUU6.js +0 -8
- package/dist/cli-bundle/focused-chunks/chunk-JEXZEIAX.js +0 -91
- package/dist/cli-bundle/focused-chunks/chunk-KDGUIIRU.js +0 -20
- package/dist/cli-bundle/focused-chunks/chunk-MQ42BFGX.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-VAYS754X.js +0 -2
- package/dist/cli-bundle/focused-chunks/chunk-VS6VTWTZ.js +0 -8
- package/dist/cli-bundle/focused-chunks/stage-EMTISXR7.js +0 -2
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="826dab45-600c-58df-a150-eacecfb6ef95")}catch{}})();var b=["commands","renderers","hooks","schema","importers","search","parser","preflight","services"],F=2,v=Object.freeze({migration:"schema",validation:"schema"}),M=Object.freeze({version:2,capabilities:[...b],legacy_aliases:{...v}}),P=["off","warn","enforce"],U=["off","warn","enforce"],Y=["none","restricted","strict"],q=["block","warn"],W=["commands.override","commands.handler","hooks.beforecommand","hooks.beforemutation","hooks.aftercommand","hooks.onwrite","hooks.onread","hooks.onindex","schema.flags","schema.itemfields","schema.itemtypes","schema.relationshipkinds","schema.migrations","schema.profiles","parser.override","preflight.override","services.override","renderers.override","importers.importer","importers.exporter","search.provider","search.vectorstore","services.assuranceprovider"],X=["output_format","error_format","help_format","lock_acquire","lock_release","history_append","item_store_write","item_store_delete","context_relevance","command_result"];function m(){return{mode:"off",trust_mode:"off",require_provenance:!1,trusted_extensions:[],default_sandbox_profile:"none",allowed_extensions:[],blocked_extensions:[],allowed_capabilities:[],blocked_capabilities:[],allowed_surfaces:[],blocked_surfaces:[],allowed_commands:[],blocked_commands:[],allowed_actions:[],blocked_actions:[],allowed_services:[],blocked_services:[],extension_overrides:[]}}(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3d6df465-e82e-57d8-a687-6c2e720c99c1")}catch{}})();var E=["goal","objective","value","impact","outcome","why_now","parent","reviewer","risk","confidence","sprint","release","blocked_by","blocked_reason","unblock_note","reporter","severity","environment","repro_steps","resolution","expected_result","actual_result"],T=["id","title","description","type","pm_format_version","source_type","type_options","status","priority","tags","created_at","updated_at","deadline","reminders","events","closed_at","completed_at","assignee","claim_principal","source_owner","author","estimated_minutes","acceptance_criteria","design","external_ref","definition_of_ready","order",...E,"affected_version","fixed_version","component","regression","customer_impact","dependencies","comments","notes","learnings","files","tests","test_runs","docs","close_reason","duplicate_of","plan_mode","plan_scope","plan_harness","plan_resume_context","plan_validation","plan_decisions","plan_discoveries","plan_steps"],k=T;(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="9a92abe3-1900-5a69-a35d-6aa592c83da0")}catch{}})();var I=Object.freeze([{id:"draft",roles:["draft"]},{id:"open",roles:["active","default_open"]},{id:"in_progress",aliases:["in-progress"],roles:["active"]},{id:"blocked",roles:["blocked"]},{id:"closed",roles:["terminal","terminal_done","default_close"]},{id:"canceled",aliases:["cancelled"],roles:["terminal","terminal_canceled","default_cancel"]}]),O=Object.freeze({draft_status:"draft",open_status:"open",in_progress_status:"in_progress",blocked_status:"blocked",close_status:"closed",canceled_status:"canceled"}),z=".agents/pm",$="settings.json",V="Closed at creation via pm create",N=["","epics","features","tasks","chores","issues","schema","history","search","extensions","locks"],A=["decisions","events","reminders","milestones","meetings","plans"],J=[...N,...A],Q={Epic:"epics",Feature:"features",Task:"tasks",Chore:"chores",Issue:"issues",Decision:"decisions",Event:"events",Reminder:"reminders",Milestone:"milestones",Meeting:"meetings",Plan:"plans"},D={minimal:{ownership_enforcement:"none",create_mode_default:"progressive",close_validation_default:"off",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"core",force_required_for_stale_lock:!1,duplicate_detection_mode:"off",duplicate_detection_threshold:.8,duplicate_detection_limit:3},default:{ownership_enforcement:"warn",create_mode_default:"progressive",close_validation_default:"warn",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"core",force_required_for_stale_lock:!0,duplicate_detection_mode:"strict",duplicate_detection_threshold:.8,duplicate_detection_limit:3},strict:{ownership_enforcement:"strict",create_mode_default:"strict",close_validation_default:"strict",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"strict",force_required_for_stale_lock:!0,duplicate_detection_mode:"strict",duplicate_detection_threshold:.8,duplicate_detection_limit:3}},S=["no active blocker","ready for planned execution sequencing","work completed","work is closed"],f={blocked_reason:["no active blocker because work is closed","work is closed"],resolution:["closed with implementation evidence","closed with verification evidence","work completed and recorded","work is closed"],actual_result:["closed and recorded","work completed","work completed and recorded"]};function h(e){return e?[...e]:void 0}var Z={version:1,id_prefix:"pm-",ids:{token_length:4},author_default:"",agent_identity:{probes_enabled:!0,identity_vocabulary:{version:1,aliases:{}},harness_signals:[]},mutation_guard:{require_attributed_author:!1,secret_guard:"advise",stale_in_progress_hours:72},item_format:"toon",locks:{ttl_seconds:1800,wait_ms:3e3},checkpoints:{retention_days:14},output:{default_format:"toon"},ux:{deprecation_hints:!0},history:{missing_stream:"auto_create",compact_policy:{enabled:!1,max_entries:500,trigger:"health_warn"}},validation:{sprint_release_format:"warn",parent_reference:"warn",metadata_profile:"core",metadata_required_fields:[],lifecycle_stale_blocker_reason_patterns:[...S],lifecycle_closure_like_blocked_reason_patterns:[...f.blocked_reason],lifecycle_closure_like_resolution_patterns:[...f.resolution],lifecycle_closure_like_actual_result_patterns:[...f.actual_result],estimate_defaults_by_type:{}},governance:{preset:"minimal",...D.minimal},workflow:{definition_of_done:[]},testing:{record_results_to_items:!1,allow_untrusted_linked_tests:!1},telemetry:{enabled:!0,first_run_prompt_completed:!1,capture_level:"redacted",endpoint:"https://pm-cli.unbrained.dev/v1/events",installation_id:"",retention_days:365},agent_guidance:{prompt_completed:!1,declined:!1,declined_at:"",template_version:1,last_checked_files:[]},item_types:{definitions:[]},schema:{version:1,files:{types:"schema/types.json",statuses:"schema/statuses.json",fields:"schema/fields.json",workflows:"schema/workflows.json"},statuses:I.map(e=>({...e,aliases:h(e.aliases),roles:h(e.roles)})),fields:[],workflow:{...O},unknown_field_policy:"allow"},extensions:{enabled:[],disabled:[],policy:m()},search:{score_threshold:0,hybrid_semantic_weight:.7,max_results:50,embedding_model:"",embedding_batch_size:32,embedding_timeout_ms:3e4,scanner_max_batch_retries:3,provider:"",default_mode:"auto",mutation_refresh_policy:"semantic_configured",query_expansion:{enabled:!1,provider:""},rerank:{enabled:!1,model:"",top_k:20}},providers:{openai:{base_url:"",api_key:"",model:""},ollama:{base_url:"",model:""}},context:{default_depth:"brief",activity_limit:10,stale_threshold_days:7,sections:{hierarchy:!0,activity:!0,progress:!0,recently_created:!0,unparented:!0,blockers:!0,files:!0,workload:!0,staleness:!0,tests:!0}},vector_store:{adapter:"",collection_name:"pm_items",qdrant:{url:"",api_key:""},lancedb:{path:""}}},H={metadata:{},body:""},w={SUCCESS:0,GENERIC_FAILURE:1,USAGE:2,NOT_FOUND:3,CONFLICT:4,DEPENDENCY_FAILED:5,NO_EFFECT:6,PARTIAL_EFFECT:7},R=Object.freeze({unknown_command:"usage",unknown_option:"usage",missing_required_option:"usage",missing_required_argument:"usage",invalid_command_usage:"usage",linked_test_value_not_quoted:"usage",invalid_argument_value:"validation",health_findings:"validation",validation_findings:"validation",close_through_update:"validation",no_update_fields:"validation",unsupported_update_option:"validation",tracker_not_initialized:"validation",item_not_found:"validation",ownership_conflict:"conflict",lock_conflict:"conflict",terminal_state_conflict:"conflict",dependency_failed:"runtime",init_gitignore_unwritable:"runtime",merge_git_config_unwritable:"runtime",command_failed:"runtime",unknown_error:"runtime"});function ee(e){let t=(e??"").trim().toLowerCase();if(t.length===0)return"unknown";let o=R[t];return typeof o=="string"?o:t.includes("conflict")||t.includes("locked")?"conflict":t.startsWith("unknown_")||t.startsWith("missing_required_")?"usage":t.startsWith("invalid_")||t.endsWith("_not_found")||t.includes("validation")?"validation":t.endsWith("_error")||t.endsWith("_failed")?"runtime":"unknown"}(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="1e7d4217-da18-5bfc-a00b-67bba61f57c2")}catch{}})();var u=class extends Error{exitCode;code;context;constructor(t,o,i={}){super(t),this.name="PmCliError",this.exitCode=o,this.context=i,this.code=i.code}};import*as r from"node:fs/promises";import{constants as p}from"node:fs";import c from"node:path";import C from"node:crypto";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3792f1fd-ed9d-5252-887d-e4517a55fb9c")}catch{}})();var L=[10,25,50,100];async function y(e){await r.mkdir(e,{recursive:!0})}async function le(e){try{return await r.access(e),!0}catch{return!1}}function g(e){return x(e)||l(e,"ENOTDIR")}function x(e){return l(e,"ENOENT")}async function ce(e){try{return await r.readFile(e,"utf8")}catch(t){if(g(t))return null;throw t}}async function de(e,t){let o=await r.open(e,p.O_RDONLY|p.O_NOFOLLOW|p.O_NONBLOCK);try{if(!(await o.stat()).isFile())throw t;return await o.readFile("utf8")}finally{await o.close()}}function _e(e){let t=e?.replaceAll(c.sep,"/"),o=t!==void 0&&!c.posix.isAbsolute(t)&&!c.win32.isAbsolute(t)&&!t.split("/").includes(".."),i=o?t.split("/")[0]:void 0,s={"settings.json":"settings",runtime:"runtime",schema:"schema",history:"history",transactions:"transactions"},n=i===void 0?"tracker_storage":Object.hasOwn(s,i)?s[i]:"tracker_storage",d=o&&t.length>0&&t.length<=160&&t.split("/").every(a=>a!=="."&&/^[a-zA-Z0-9_.-]+$/u.test(a)),_=d?t:`${n} (entry name redacted)`;return new u(`Transaction preview requires regular files and directories. Inspect ${_} relative to the selected tracker root.`,w.USAGE,{code:"transaction_preview_non_regular_file",preview_storage:{storage_area:n,...d?{relative_entry:t}:{},entry_redacted:!d},required:"regular files and directories within the configured tracker storage",why:"Preview does not follow linked entries or read special files.",nextSteps:[`Inspect ${_} within the selected tracker for links, directories used as files, or special files; do not follow link targets.`,"Restore the intended regular files and directories, then retry the original dry-run command."]})}async function ue(e,t,o={}){let i=c.dirname(e);o.createParentDirectories!==!1&&await y(i);let s=c.join(i,`.${c.basename(e)}.${process.pid}.${Date.now()}.${C.randomBytes(4).toString("hex")}.tmp`);await r.writeFile(s,t,"utf8");try{await r.rename(s,e)}catch(n){if(process.platform==="win32"&&(l(n,"EPERM")||l(n,"EBUSY"))){let d=n;for(let _ of L){await new Promise(a=>setTimeout(a,_));try{await r.rename(s,e);return}catch(a){if(d=a,!l(a,"EPERM")&&!l(a,"EBUSY"))break}}try{await r.unlink(s)}catch{}throw d}if(l(n,"EXDEV")){try{await r.copyFile(s,e)}finally{try{await r.unlink(s)}catch{}}return}try{await r.unlink(s)}catch{}throw n}}async function fe(e,t){let o=c.dirname(e);await y(o);let i=await r.open(e,"a");try{await i.writeFile(`${t}
|
|
1
|
+
(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="826dab45-600c-58df-a150-eacecfb6ef95")}catch{}})();var b=["commands","renderers","hooks","schema","importers","search","parser","preflight","services"],F=2,v=Object.freeze({migration:"schema",validation:"schema"}),M=Object.freeze({version:2,capabilities:[...b],legacy_aliases:{...v}}),P=["off","warn","enforce"],U=["off","warn","enforce"],Y=["none","restricted","strict"],q=["block","warn"],W=["commands.override","commands.handler","hooks.beforecommand","hooks.beforemutation","hooks.aftercommand","hooks.onwrite","hooks.onread","hooks.onindex","schema.flags","schema.itemfields","schema.itemtypes","schema.relationshipkinds","schema.migrations","schema.profiles","parser.override","preflight.override","services.override","renderers.override","importers.importer","importers.exporter","search.provider","search.vectorstore","services.assuranceprovider"],X=["output_format","error_format","help_format","lock_acquire","lock_release","history_append","item_store_write","item_store_delete","context_relevance","command_result"];function m(){return{mode:"off",trust_mode:"off",require_provenance:!1,trusted_extensions:[],default_sandbox_profile:"none",allowed_extensions:[],blocked_extensions:[],allowed_capabilities:[],blocked_capabilities:[],allowed_surfaces:[],blocked_surfaces:[],allowed_commands:[],blocked_commands:[],allowed_actions:[],blocked_actions:[],allowed_services:[],blocked_services:[],extension_overrides:[]}}(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3d6df465-e82e-57d8-a687-6c2e720c99c1")}catch{}})();var E=["goal","objective","value","impact","outcome","why_now","parent","reviewer","risk","confidence","sprint","release","blocked_by","blocked_reason","unblock_note","reporter","severity","environment","repro_steps","resolution","expected_result","actual_result"],T=["id","title","description","type","pm_format_version","source_type","type_options","status","priority","tags","created_at","updated_at","deadline","reminders","events","closed_at","completed_at","assignee","claim_principal","source_owner","author","estimated_minutes","acceptance_criteria","design","external_ref","definition_of_ready","order",...E,"affected_version","fixed_version","component","regression","customer_impact","dependencies","comments","notes","learnings","files","tests","test_runs","docs","close_reason","duplicate_of","plan_mode","plan_scope","plan_harness","plan_resume_context","plan_validation","plan_decisions","plan_discoveries","plan_steps"],k=T;(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="9a92abe3-1900-5a69-a35d-6aa592c83da0")}catch{}})();var I=Object.freeze([{id:"draft",roles:["draft"]},{id:"open",roles:["active","default_open"]},{id:"in_progress",aliases:["in-progress"],roles:["active"]},{id:"blocked",roles:["blocked"]},{id:"closed",roles:["terminal","terminal_done","default_close"]},{id:"canceled",aliases:["cancelled"],roles:["terminal","terminal_canceled","default_cancel"]}]),O=Object.freeze({draft_status:"draft",open_status:"open",in_progress_status:"in_progress",blocked_status:"blocked",close_status:"closed",canceled_status:"canceled"}),z=".agents/pm",$="settings.json",V="Closed at creation via pm create",N=["","epics","features","tasks","chores","issues","schema","history","search","extensions","locks"],A=["decisions","events","reminders","milestones","meetings","plans"],J=[...N,...A],Q={Epic:"epics",Feature:"features",Task:"tasks",Chore:"chores",Issue:"issues",Decision:"decisions",Event:"events",Reminder:"reminders",Milestone:"milestones",Meeting:"meetings",Plan:"plans"},D={minimal:{ownership_enforcement:"none",create_mode_default:"progressive",close_validation_default:"off",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"core",force_required_for_stale_lock:!1,duplicate_detection_mode:"off",duplicate_detection_threshold:.8,duplicate_detection_limit:3},default:{ownership_enforcement:"warn",create_mode_default:"progressive",close_validation_default:"warn",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"core",force_required_for_stale_lock:!0,duplicate_detection_mode:"strict",duplicate_detection_threshold:.8,duplicate_detection_limit:3},strict:{ownership_enforcement:"strict",create_mode_default:"strict",close_validation_default:"strict",require_close_reason:!0,parent_reference:"strict_error",metadata_profile:"strict",force_required_for_stale_lock:!0,duplicate_detection_mode:"strict",duplicate_detection_threshold:.8,duplicate_detection_limit:3}},S=["no active blocker","ready for planned execution sequencing","work completed","work is closed"],f={blocked_reason:["no active blocker because work is closed","work is closed"],resolution:["closed with implementation evidence","closed with verification evidence","work completed and recorded","work is closed"],actual_result:["closed and recorded","work completed","work completed and recorded"]};function h(e){return e?[...e]:void 0}var Z={version:1,id_prefix:"pm-",ids:{token_length:4},author_default:"",agent_identity:{probes_enabled:!0,identity_vocabulary:{version:1,aliases:{}},harness_signals:[]},mutation_guard:{require_attributed_author:!1,secret_guard:"advise",stale_in_progress_hours:72},item_format:"toon",locks:{ttl_seconds:1800,wait_ms:3e3},checkpoints:{retention_days:14},output:{default_format:"toon"},ux:{deprecation_hints:!0},history:{missing_stream:"auto_create",compact_policy:{enabled:!1,max_entries:500,trigger:"health_warn"}},validation:{sprint_release_format:"warn",parent_reference:"warn",metadata_profile:"core",metadata_required_fields:[],lifecycle_stale_blocker_reason_patterns:[...S],lifecycle_closure_like_blocked_reason_patterns:[...f.blocked_reason],lifecycle_closure_like_resolution_patterns:[...f.resolution],lifecycle_closure_like_actual_result_patterns:[...f.actual_result],estimate_defaults_by_type:{}},governance:{preset:"minimal",...D.minimal},workflow:{definition_of_done:[]},testing:{record_results_to_items:!1,allow_untrusted_linked_tests:!1},telemetry:{enabled:!0,first_run_prompt_completed:!1,capture_level:"redacted",endpoint:"https://pm-cli.unbrained.dev/v1/events",installation_id:"",retention_days:365},agent_guidance:{prompt_completed:!1,declined:!1,declined_at:"",template_version:1,last_checked_files:[]},item_types:{definitions:[]},schema:{version:1,files:{types:"schema/types.json",statuses:"schema/statuses.json",fields:"schema/fields.json",workflows:"schema/workflows.json"},statuses:I.map(e=>({...e,aliases:h(e.aliases),roles:h(e.roles)})),fields:[],workflow:{...O},unknown_field_policy:"allow"},extensions:{enabled:[],disabled:[],policy:m()},search:{score_threshold:0,hybrid_semantic_weight:.7,max_results:50,embedding_model:"",embedding_batch_size:32,embedding_timeout_ms:3e4,scanner_max_batch_retries:3,provider:"",default_mode:"auto",mutation_refresh_policy:"semantic_configured",query_expansion:{enabled:!1,provider:""},rerank:{enabled:!1,model:"",top_k:20}},providers:{openai:{base_url:"",api_key:"",model:""},ollama:{base_url:"",model:""}},context:{default_depth:"brief",activity_limit:10,stale_threshold_days:7,sections:{hierarchy:!0,activity:!0,progress:!0,recently_created:!0,unparented:!0,blockers:!0,files:!0,workload:!0,staleness:!0,tests:!0}},vector_store:{adapter:"",collection_name:"pm_items",qdrant:{url:"",api_key:""},lancedb:{path:""}}},H={metadata:{},body:""},w={SUCCESS:0,GENERIC_FAILURE:1,USAGE:2,NOT_FOUND:3,CONFLICT:4,DEPENDENCY_FAILED:5,NO_EFFECT:6,PARTIAL_EFFECT:7},R=Object.freeze({unknown_command:"usage",unknown_option:"usage",missing_required_option:"usage",missing_required_argument:"usage",invalid_command_usage:"usage",linked_test_value_not_quoted:"usage",invalid_argument_value:"validation",health_findings:"validation",validation_findings:"validation",close_through_update:"validation",no_update_fields:"validation",unsupported_update_option:"validation",tracker_not_initialized:"validation",item_not_found:"validation",ownership_conflict:"conflict",lock_conflict:"conflict",terminal_state_conflict:"conflict",dependency_failed:"runtime",init_gitignore_unwritable:"runtime",merge_git_config_unwritable:"runtime",command_failed:"runtime",unknown_error:"runtime"});function ee(e){let t=(e??"").trim().toLowerCase();if(t.length===0)return"unknown";let o=R[t];return typeof o=="string"?o:t.includes("conflict")||t.includes("locked")?"conflict":t.startsWith("unknown_")||t.startsWith("missing_required_")?"usage":t.startsWith("invalid_")||t.endsWith("_not_found")||t.includes("validation")?"validation":t.endsWith("_error")||t.endsWith("_failed")?"runtime":"unknown"}(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3399082a-aeaf-5235-9524-d0e86253ee95")}catch{}})();var u=class extends Error{exitCode;code;context;constructor(t,o,i={}){super(t),this.name="PmCliError",this.exitCode=o,this.context=i,this.code=i.code}};import*as r from"node:fs/promises";import{constants as p}from"node:fs";import c from"node:path";import C from"node:crypto";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="3792f1fd-ed9d-5252-887d-e4517a55fb9c")}catch{}})();var L=[10,25,50,100];async function y(e){await r.mkdir(e,{recursive:!0})}async function le(e){try{return await r.access(e),!0}catch{return!1}}function g(e){return x(e)||l(e,"ENOTDIR")}function x(e){return l(e,"ENOENT")}async function ce(e){try{return await r.readFile(e,"utf8")}catch(t){if(g(t))return null;throw t}}async function de(e,t){let o=await r.open(e,p.O_RDONLY|p.O_NOFOLLOW|p.O_NONBLOCK);try{if(!(await o.stat()).isFile())throw t;return await o.readFile("utf8")}finally{await o.close()}}function _e(e){let t=e?.replaceAll(c.sep,"/"),o=t!==void 0&&!c.posix.isAbsolute(t)&&!c.win32.isAbsolute(t)&&!t.split("/").includes(".."),i=o?t.split("/")[0]:void 0,s={"settings.json":"settings",runtime:"runtime",schema:"schema",history:"history",transactions:"transactions"},n=i===void 0?"tracker_storage":Object.hasOwn(s,i)?s[i]:"tracker_storage",d=o&&t.length>0&&t.length<=160&&t.split("/").every(a=>a!=="."&&/^[a-zA-Z0-9_.-]+$/u.test(a)),_=d?t:`${n} (entry name redacted)`;return new u(`Transaction preview requires regular files and directories. Inspect ${_} relative to the selected tracker root.`,w.USAGE,{code:"transaction_preview_non_regular_file",preview_storage:{storage_area:n,...d?{relative_entry:t}:{},entry_redacted:!d},required:"regular files and directories within the configured tracker storage",why:"Preview does not follow linked entries or read special files.",nextSteps:[`Inspect ${_} within the selected tracker for links, directories used as files, or special files; do not follow link targets.`,"Restore the intended regular files and directories, then retry the original dry-run command."]})}async function ue(e,t,o={}){let i=c.dirname(e);o.createParentDirectories!==!1&&await y(i);let s=c.join(i,`.${c.basename(e)}.${process.pid}.${Date.now()}.${C.randomBytes(4).toString("hex")}.tmp`);await r.writeFile(s,t,"utf8");try{await r.rename(s,e)}catch(n){if(process.platform==="win32"&&(l(n,"EPERM")||l(n,"EBUSY"))){let d=n;for(let _ of L){await new Promise(a=>setTimeout(a,_));try{await r.rename(s,e);return}catch(a){if(d=a,!l(a,"EPERM")&&!l(a,"EBUSY"))break}}try{await r.unlink(s)}catch{}throw d}if(l(n,"EXDEV")){try{await r.copyFile(s,e)}finally{try{await r.unlink(s)}catch{}}return}try{await r.unlink(s)}catch{}throw n}}async function fe(e,t){let o=c.dirname(e);await y(o);let i=await r.open(e,"a");try{await i.writeFile(`${t}
|
|
2
2
|
`,"utf8")}finally{await i.close()}}async function pe(e){try{await r.unlink(e)}catch(t){if(!g(t))throw t}}function l(e,t){return typeof e=="object"&&e!==null&&"code"in e&&e.code===t}export{b as a,F as b,v as c,M as d,P as e,U as f,Y as g,q as h,W as i,X as j,m as k,E as l,k as m,I as n,O as o,z as p,$ as q,V as r,N as s,J as t,Q as u,D as v,S as w,f as x,Z as y,H as z,w as A,ee as B,u as C,y as D,le as E,g as F,x as G,ce as H,de as I,_e as J,ue as K,fe as L,pe as M};
|
|
3
|
-
//# sourceMappingURL=chunk-
|
|
3
|
+
//# sourceMappingURL=chunk-GWIGZDRS.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},r=new e.Error().stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="5c8194ff-d877-51b8-bd54-d206f85a979c")}catch{}})();
|
|
2
|
+
//# sourceMappingURL=chunk-IB7UB5TE.js.map
|