@ai-dossier/sched 0.48.0 → 0.49.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.
- package/README.md +83 -6
- package/dist/anchor-close.d.ts +160 -0
- package/dist/anchor-close.d.ts.map +1 -1
- package/dist/anchor-close.js +319 -36
- package/dist/anchor-close.js.map +1 -1
- package/dist/batch-dispatch.d.ts.map +1 -1
- package/dist/batch-dispatch.js +67 -0
- package/dist/batch-dispatch.js.map +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +23 -5
- package/dist/index.js.map +1 -1
- package/dist/labels.d.ts +9 -0
- package/dist/labels.d.ts.map +1 -1
- package/dist/labels.js +10 -1
- package/dist/labels.js.map +1 -1
- package/dist/status.d.ts +111 -6
- package/dist/status.d.ts.map +1 -1
- package/dist/status.js +253 -4
- package/dist/status.js.map +1 -1
- package/dist/teardown.d.ts +9 -0
- package/dist/teardown.d.ts.map +1 -1
- package/dist/teardown.js +19 -10
- package/dist/teardown.js.map +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { ANCHOR_CLOSE_BATCH_STATUSES, type AnchorCloseOutcome, type AnchorMemberReport, type AnchorReportItem, type AnchorVerdict, anchorCloseMarker, anchorLedgerBlockers, type CommitInBase, classifyAnchor, closeAnchor, formatBatchStatus, type IssueCloseReader, type MembersVerdictOptions, membersShippedVerdict, type OpenAnchorVerdict, openAnchorBatches, renderAnchorCloseComment, shippingEvidence, sweepAnchors, } from './anchor-close';
|
|
1
|
+
export { ANCHOR_CLOSE_BATCH_STATUSES, type AnchorCloseOutcome, type AnchorMemberReport, type AnchorReportItem, type AnchorVerdict, anchorCloseMarker, anchorLedgerBlockers, batchAnchorStillOpen, type CommitInBase, classifyAnchor, classifyOrphanAnchor, closeAnchor, DEFAULT_ORPHAN_BASE_BRANCH, formatBatchStatus, type IssueCloseReader, type MembersVerdictOptions, membersShippedVerdict, type OpenAnchorIssue, type OpenAnchorLister, type OpenAnchorVerdict, ORPHAN_SWEEP_MAX_ANCHORS, ORPHAN_SWEEP_MAX_MEMBERS, type OrphanAnchorCandidate, type OrphanAnchorReportItem, type OrphanAnchorSweepResult, type OrphanAnchorVerdict, openAnchorBatches, orphanAnchorListArgs, parseOrphanAnchorBody, renderAnchorCloseComment, shippingEvidence, sweepAnchors, sweepOrphanAnchors, } from './anchor-close';
|
|
2
2
|
export { type AmbiguousTest, attributeByOverlap, type BoundaryCommit, type FailingTest, failingTest, hasEarnedFailureEvidence, hasFailingTestEvidence, isReadableVitestReport, type MemberFootprint, type MemberRange, memberOfCommit, memberRanges, type OverlapAttribution, offendersOf, parseBoundaryCommits, parseVitestJson, SAFE_REF_RE, SHA_RE, } from './attribution';
|
|
3
3
|
export { type BatchDispatchDeps, type BatchTickResult, type CapOutcome, memberBranchFor, resumeBlockedGate, runBatchTick, } from './batch-dispatch';
|
|
4
4
|
export { type BatchLogEntry, buildBatchRunLogEntries, dispatchPreambleCmd, listBatchDispatchLogs, modelFromCmd, parsePreambleLine, } from './batch-stats';
|
|
@@ -9,7 +9,7 @@ export { assertNoDependencyCycle, EnqueueError, type EnqueueInput, type EnqueueO
|
|
|
9
9
|
export { createExecRunFenceBinder, createExecRunFenceReleaser, createExecRunFencer, FENCE_TIMEOUT_MS, type FenceOutcome, parseFenceGeneration, type RunFenceBinder, type RunFenceReleaser, type RunFencer, takeoverLabelFor, } from './fence';
|
|
10
10
|
export { createExecGroundTruth, GIT_OID_RE, type GroundTruth, type GroundTruthMilestone, groundTruthExec, type IssueCloseTruth, isBatchPhaseDone, isBatchTailParked, isMemberBlocked, isMemberComplete, isParkedMilestone, issueCloseReader, isVerifiedComplete, labelNames, memberBlockedReason, type PrTruth, parseIssueCloseTruthJson, parseIssueLabelsJson, parseMilestoneJson, parseMilestoneListJson, parseOpenPrListJson, parsePrViewJson, parseRepoName, parseSetupInfo, prOfMilestone, REVIEW_PARTIAL_REASON, type SetupInfo, } from './groundtruth';
|
|
11
11
|
export { appendJsonl, batchOfUnit, issueOfUnit, JOURNAL_FILE, Journal, readJsonl, unitEvent, } from './journal';
|
|
12
|
-
export { DECISION_PENDING_LABEL, HARD_BLOCK_LABELS, hasLabel, labelOfBlockReason, pickHardBlockLabel, } from './labels';
|
|
12
|
+
export { BATCH_ANCHOR_LABEL, DECISION_PENDING_LABEL, HARD_BLOCK_LABELS, hasLabel, labelOfBlockReason, pickHardBlockLabel, } from './labels';
|
|
13
13
|
export { CorruptStateError, type EngineLease, type EngineLeaseAcquisition, type EngineLeaseHolder, type EngineLeaseStatus, LockTimeoutError, SchedStore, writeAtomic, } from './persist';
|
|
14
14
|
export { createExecFn, defaultExec, type ExecFn, resolveProjectRepo, resolveProjectSlug, sanitizeSlug, schedStateDir, } from './project';
|
|
15
15
|
export { batchRank, compareByPriority, DISPATCHABLE_ISSUE_STATUSES, entryRank, type PriorityRank, } from './readiness';
|
|
@@ -17,7 +17,7 @@ export { type AttributionInput, type AttributionOutcome, type BatchMilestone, ty
|
|
|
17
17
|
export { appendSchedRunLog, buildSchedRunLogEntry, type FenceAbortEvidence, finalizeRunLogEntry, parseFenceAbort, readDispatchLog, type SchedRunLogInput, schedRunsLogPath, schedTelemetryEnabled, usageParserFor, } from './run-log';
|
|
18
18
|
export { type Assignment, abandonBatch, abandonIssue, assignToIdleSlot, batchBlockers, computeAssignments, type DependencyBlocker, dependencyBlockers, freeCapacity, type RunnableUnit, reprioritizeBatch, reprioritizeIssue, requeueParkedMember, runnableUnits, setPaused, stopBatch, stopIssue, } from './scheduler';
|
|
19
19
|
export { allowedBatchTransitions, appendEvictions, batchMemberUnit, createBatch, createEmptyState, distinctEvictions, duplicateEvictionDetail, findBatch, findEntry, isPreservedMember, type MemberExitExtra, memberDispatchProfile, memberExitEvidence, PARKED_MEMBER_STATUSES, parkMember, patchBatch, patchSlot, recordedMemberBranch, requeueMember, slotsForBatch, TRANSITIONS, transitionBatch, transitionIssue, transitionSlot, validatedMembersOf, validateState, } from './state';
|
|
20
|
-
export { type BlockedItem, buildStatusReport, buildStatusWarnings, type ParkedItem, type ParkedMemberItem, STATUS_HEALTH_WARNING_AGE_MS, type StatusReport, type StatusWarning, type StatusWarningKind, } from './status';
|
|
21
|
-
export { isSafeWorktree, runTeardown, TEARDOWN_TIMEOUT_MS, type TeardownResult } from './teardown';
|
|
20
|
+
export { type BlockedItem, buildKeptWorktreeWarnings, buildStatusReport, buildStatusWarnings, defaultKeptWorktreeReader, KEPT_WORKTREE_PROBE_LIMIT, type KeptWorktreeCandidate, type KeptWorktreeReader, keptWorktreeCandidates, type ParkedItem, type ParkedMemberItem, STATUS_HEALTH_WARNING_AGE_MS, type StatusReport, type StatusWarning, type StatusWarningKind, } from './status';
|
|
21
|
+
export { defaultFsExists, type FsExists, isSafeWorktree, POOL_ARGS_PREFIX, POOL_BIN, poolEntryFor, runTeardown, TEARDOWN_TIMEOUT_MS, type TeardownResult, } from './teardown';
|
|
22
22
|
export { type AttributionMethod, BATCH_PHASES, type BatchEntry, type BatchPhase, type BatchStatus, type CapabilityGateResult, type CleanupStatus, CONFIG_SCHEMA_VERSION, type CycleMode, DEFAULT_BATCH_PRIORITY, DEFAULT_DISSOLVE_POLICY, DEFAULT_ISSUE_PRIORITY, DEFAULT_LABEL_POLL_INTERVAL_MS, DEFAULT_MAX_SLOTS, DEFAULT_PHASE_STALL_TIMEOUT_MS, DEFAULT_PR_POLL_INTERVAL_MS, DEFAULT_RECONCILE_INTERVAL_MS, DEFAULT_STALL_TIMEOUT_MS, DISSOLVE_EVICTION_FRACTION, type DispatchConfig, type DispatchProfile, type DissolvePolicy, EngineTooOldError, ESCALATION_CAP, type EvictionRecord, type FailureEvidence, FIX_ATTEMPT_TIER, type FixAttemptRecord, IllegalTransitionError, type IssueStatus, JOURNAL_DEDUP_REANNOUNCE_TICKS, type JournalEvent, type JournalEventName, LEGACY_CONFIG_SCHEMA_VERSIONS, LEGACY_SCHEMA_VERSIONS, LIVE_SLOT_STATUSES, MAX_FIX_ATTEMPTS_PER_MEMBER, MAX_FULL_REVIEW_MEMBERS, MAX_MAX_SLOTS, MAX_REBASE_ATTEMPTS, MEMBER_EXIT_KINDS, MEMBER_RUN_STATUSES, MERGED_BATCH_STATUSES, type MemberDispatchMode, type MemberExitKind, type MemberRun, type MemberRunStatus, MIN_MAX_SLOTS, type ModelTier, PHASES, type Phase, type QueueEntry, type ReviewLevel, SATISFIED_ISSUE_STATUSES, SCHEMA_VERSION, type SchedConfig, type SchedConfigFile, SchedNotFoundError, type SchedState, SLOT_ROLES, type SlotEntry, type SlotReleaseReason, type SlotRole, type SlotStatus, TERMINAL_BATCH_STATUSES, TERMINAL_ISSUE_STATUSES, TIER_LADDER, TIER_ORDER, type TierDispatchSpec, } from './types';
|
|
23
23
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,2BAA2B,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,iBAAiB,EACjB,oBAAoB,EACpB,KAAK,YAAY,EACjB,cAAc,EACd,WAAW,EACX,iBAAiB,EACjB,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,qBAAqB,EACrB,KAAK,iBAAiB,EACtB,iBAAiB,EACjB,wBAAwB,EACxB,gBAAgB,EAChB,YAAY,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,2BAA2B,EAC3B,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,iBAAiB,EACjB,oBAA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B,WAAW,EACX,UAAU,EACV,KAAK,gBAAgB,GACtB,MAAM,SAAS,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,22 +1,31 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
exports.
|
|
6
|
-
exports.
|
|
7
|
-
exports.
|
|
3
|
+
exports.createSpawnDeps = exports.buildTierCommand = exports.buildReportPrompt = exports.buildPrompt = exports.buildMemberPrompt = exports.buildFixPrompt = exports.buildCommandForModel = exports.buildBatchTailPrompt = exports.buildBatchReportPrompt = exports.buildAgentCommand = exports.runAttributionBisect = exports.parsePreambleLine = exports.modelFromCmd = exports.listBatchDispatchLogs = exports.dispatchPreambleCmd = exports.buildBatchRunLogEntries = exports.runBatchTick = exports.resumeBlockedGate = exports.memberBranchFor = exports.SHA_RE = exports.SAFE_REF_RE = exports.parseVitestJson = exports.parseBoundaryCommits = exports.offendersOf = exports.memberRanges = exports.memberOfCommit = exports.isReadableVitestReport = exports.hasFailingTestEvidence = exports.hasEarnedFailureEvidence = exports.failingTest = exports.attributeByOverlap = exports.sweepOrphanAnchors = exports.sweepAnchors = exports.shippingEvidence = exports.renderAnchorCloseComment = exports.parseOrphanAnchorBody = exports.orphanAnchorListArgs = exports.openAnchorBatches = exports.ORPHAN_SWEEP_MAX_MEMBERS = exports.ORPHAN_SWEEP_MAX_ANCHORS = exports.membersShippedVerdict = exports.formatBatchStatus = exports.DEFAULT_ORPHAN_BASE_BRANCH = exports.closeAnchor = exports.classifyOrphanAnchor = exports.classifyAnchor = exports.batchAnchorStillOpen = exports.anchorLedgerBlockers = exports.anchorCloseMarker = exports.ANCHOR_CLOSE_BATCH_STATUSES = void 0;
|
|
4
|
+
exports.createExecGroundTruth = exports.takeoverLabelFor = exports.parseFenceGeneration = exports.FENCE_TIMEOUT_MS = exports.createExecRunFencer = exports.createExecRunFenceReleaser = exports.createExecRunFenceBinder = exports.parseManifest = exports.labelBlockReason = exports.LABEL_BLOCK_REASON_PREFIX = exports.enqueueEntries = exports.EnqueueError = exports.assertNoDependencyCycle = exports.tick = exports.runLoop = exports.recordTickFailure = exports.unitLogName = exports.tierExecutors = exports.takeoverInstruction = exports.stallTimeoutForSlot = exports.stallTimeoutForPhase = exports.SUPERSESSION_CHECKPOINT_INSTRUCTION = exports.resolveTierSpawn = exports.resolveProfiledDispatch = exports.resolveDispatch = exports.reportTierFor = exports.procStartTime = exports.priorWorkInstruction = exports.OPENCODE_DISPATCH_COMMAND = exports.NO_BACKGROUND_EXIT_INSTRUCTION = exports.memberDispatchTier = exports.journalCmdModelFields = exports.HEADLESS_BACKGROUND_GUARD_SETTINGS = exports.HEADLESS_BACKGROUND_GUARD_HOOK_COMMAND = exports.fileSizeOrZero = exports.FULL_REVIEW_MEMBER_DIRECTIVE = exports.escalateTier = exports.dispatchSummary = exports.dispatchLogPath = exports.DispatchProfileError = exports.DISPATCH_PROFILE_RE = exports.DEFAULT_TIER_MODELS = exports.DEFAULT_REPORT_PROMPT_TEMPLATE = exports.DEFAULT_PROMPT_TEMPLATE = exports.DEFAULT_MEMBER_PROMPT_TEMPLATE = exports.DEFAULT_FIX_PROMPT_TEMPLATE = exports.DEFAULT_DISPATCH_COMMAND = exports.DEFAULT_DISALLOWED_TOOLS = exports.DEFAULT_BATCH_TAIL_PROMPT_TEMPLATE = exports.DEFAULT_BATCH_REPORT_PROMPT_TEMPLATE = void 0;
|
|
5
|
+
exports.beginFixAttempt = exports.beginAttribution = exports.entryRank = exports.DISPATCHABLE_ISSUE_STATUSES = exports.compareByPriority = exports.batchRank = exports.schedStateDir = exports.sanitizeSlug = exports.resolveProjectSlug = exports.resolveProjectRepo = exports.defaultExec = exports.createExecFn = exports.writeAtomic = exports.SchedStore = exports.LockTimeoutError = exports.CorruptStateError = exports.pickHardBlockLabel = exports.labelOfBlockReason = exports.hasLabel = exports.HARD_BLOCK_LABELS = exports.DECISION_PENDING_LABEL = exports.BATCH_ANCHOR_LABEL = exports.unitEvent = exports.readJsonl = exports.Journal = exports.JOURNAL_FILE = exports.issueOfUnit = exports.batchOfUnit = exports.appendJsonl = exports.REVIEW_PARTIAL_REASON = exports.prOfMilestone = exports.parseSetupInfo = exports.parseRepoName = exports.parsePrViewJson = exports.parseOpenPrListJson = exports.parseMilestoneListJson = exports.parseMilestoneJson = exports.parseIssueLabelsJson = exports.parseIssueCloseTruthJson = exports.memberBlockedReason = exports.labelNames = exports.isVerifiedComplete = exports.issueCloseReader = exports.isParkedMilestone = exports.isMemberComplete = exports.isMemberBlocked = exports.isBatchTailParked = exports.isBatchPhaseDone = exports.groundTruthExec = exports.GIT_OID_RE = void 0;
|
|
6
|
+
exports.slotsForBatch = exports.requeueMember = exports.recordedMemberBranch = exports.patchSlot = exports.patchBatch = exports.parkMember = exports.PARKED_MEMBER_STATUSES = exports.memberExitEvidence = exports.memberDispatchProfile = exports.isPreservedMember = exports.findEntry = exports.findBatch = exports.duplicateEvictionDetail = exports.distinctEvictions = exports.createEmptyState = exports.createBatch = exports.batchMemberUnit = exports.appendEvictions = exports.allowedBatchTransitions = exports.stopIssue = exports.stopBatch = exports.setPaused = exports.runnableUnits = exports.requeueParkedMember = exports.reprioritizeIssue = exports.reprioritizeBatch = exports.freeCapacity = exports.dependencyBlockers = exports.computeAssignments = exports.batchBlockers = exports.assignToIdleSlot = exports.abandonIssue = exports.abandonBatch = exports.usageParserFor = exports.schedTelemetryEnabled = exports.schedRunsLogPath = exports.readDispatchLog = exports.parseFenceAbort = exports.finalizeRunLogEntry = exports.buildSchedRunLogEntry = exports.appendSchedRunLog = exports.resolveFixAttempt = exports.handlePrConflict = exports.expandEvictionGroups = exports.evictMembers = exports.dissolveBatch = exports.DISSOLVE_REFUSED_PREFIX = exports.createExecMilestonePoster = exports.checkDissolveTrigger = exports.blockBatch = void 0;
|
|
7
|
+
exports.SATISFIED_ISSUE_STATUSES = exports.PHASES = exports.MIN_MAX_SLOTS = exports.MERGED_BATCH_STATUSES = exports.MEMBER_RUN_STATUSES = exports.MEMBER_EXIT_KINDS = exports.MAX_REBASE_ATTEMPTS = exports.MAX_MAX_SLOTS = exports.MAX_FULL_REVIEW_MEMBERS = exports.MAX_FIX_ATTEMPTS_PER_MEMBER = exports.LIVE_SLOT_STATUSES = exports.LEGACY_SCHEMA_VERSIONS = exports.LEGACY_CONFIG_SCHEMA_VERSIONS = exports.JOURNAL_DEDUP_REANNOUNCE_TICKS = exports.IllegalTransitionError = exports.FIX_ATTEMPT_TIER = exports.ESCALATION_CAP = exports.EngineTooOldError = exports.DISSOLVE_EVICTION_FRACTION = exports.DEFAULT_STALL_TIMEOUT_MS = exports.DEFAULT_RECONCILE_INTERVAL_MS = exports.DEFAULT_PR_POLL_INTERVAL_MS = exports.DEFAULT_PHASE_STALL_TIMEOUT_MS = exports.DEFAULT_MAX_SLOTS = exports.DEFAULT_LABEL_POLL_INTERVAL_MS = exports.DEFAULT_ISSUE_PRIORITY = exports.DEFAULT_DISSOLVE_POLICY = exports.DEFAULT_BATCH_PRIORITY = exports.CONFIG_SCHEMA_VERSION = exports.BATCH_PHASES = exports.TEARDOWN_TIMEOUT_MS = exports.runTeardown = exports.poolEntryFor = exports.POOL_BIN = exports.POOL_ARGS_PREFIX = exports.isSafeWorktree = exports.defaultFsExists = exports.STATUS_HEALTH_WARNING_AGE_MS = exports.keptWorktreeCandidates = exports.KEPT_WORKTREE_PROBE_LIMIT = exports.defaultKeptWorktreeReader = exports.buildStatusWarnings = exports.buildStatusReport = exports.buildKeptWorktreeWarnings = exports.validateState = exports.validatedMembersOf = exports.transitionSlot = exports.transitionIssue = exports.transitionBatch = exports.TRANSITIONS = void 0;
|
|
8
|
+
exports.TIER_ORDER = exports.TIER_LADDER = exports.TERMINAL_ISSUE_STATUSES = exports.TERMINAL_BATCH_STATUSES = exports.SLOT_ROLES = exports.SchedNotFoundError = exports.SCHEMA_VERSION = void 0;
|
|
8
9
|
var anchor_close_1 = require("./anchor-close");
|
|
9
10
|
Object.defineProperty(exports, "ANCHOR_CLOSE_BATCH_STATUSES", { enumerable: true, get: function () { return anchor_close_1.ANCHOR_CLOSE_BATCH_STATUSES; } });
|
|
10
11
|
Object.defineProperty(exports, "anchorCloseMarker", { enumerable: true, get: function () { return anchor_close_1.anchorCloseMarker; } });
|
|
11
12
|
Object.defineProperty(exports, "anchorLedgerBlockers", { enumerable: true, get: function () { return anchor_close_1.anchorLedgerBlockers; } });
|
|
13
|
+
Object.defineProperty(exports, "batchAnchorStillOpen", { enumerable: true, get: function () { return anchor_close_1.batchAnchorStillOpen; } });
|
|
12
14
|
Object.defineProperty(exports, "classifyAnchor", { enumerable: true, get: function () { return anchor_close_1.classifyAnchor; } });
|
|
15
|
+
Object.defineProperty(exports, "classifyOrphanAnchor", { enumerable: true, get: function () { return anchor_close_1.classifyOrphanAnchor; } });
|
|
13
16
|
Object.defineProperty(exports, "closeAnchor", { enumerable: true, get: function () { return anchor_close_1.closeAnchor; } });
|
|
17
|
+
Object.defineProperty(exports, "DEFAULT_ORPHAN_BASE_BRANCH", { enumerable: true, get: function () { return anchor_close_1.DEFAULT_ORPHAN_BASE_BRANCH; } });
|
|
14
18
|
Object.defineProperty(exports, "formatBatchStatus", { enumerable: true, get: function () { return anchor_close_1.formatBatchStatus; } });
|
|
15
19
|
Object.defineProperty(exports, "membersShippedVerdict", { enumerable: true, get: function () { return anchor_close_1.membersShippedVerdict; } });
|
|
20
|
+
Object.defineProperty(exports, "ORPHAN_SWEEP_MAX_ANCHORS", { enumerable: true, get: function () { return anchor_close_1.ORPHAN_SWEEP_MAX_ANCHORS; } });
|
|
21
|
+
Object.defineProperty(exports, "ORPHAN_SWEEP_MAX_MEMBERS", { enumerable: true, get: function () { return anchor_close_1.ORPHAN_SWEEP_MAX_MEMBERS; } });
|
|
16
22
|
Object.defineProperty(exports, "openAnchorBatches", { enumerable: true, get: function () { return anchor_close_1.openAnchorBatches; } });
|
|
23
|
+
Object.defineProperty(exports, "orphanAnchorListArgs", { enumerable: true, get: function () { return anchor_close_1.orphanAnchorListArgs; } });
|
|
24
|
+
Object.defineProperty(exports, "parseOrphanAnchorBody", { enumerable: true, get: function () { return anchor_close_1.parseOrphanAnchorBody; } });
|
|
17
25
|
Object.defineProperty(exports, "renderAnchorCloseComment", { enumerable: true, get: function () { return anchor_close_1.renderAnchorCloseComment; } });
|
|
18
26
|
Object.defineProperty(exports, "shippingEvidence", { enumerable: true, get: function () { return anchor_close_1.shippingEvidence; } });
|
|
19
27
|
Object.defineProperty(exports, "sweepAnchors", { enumerable: true, get: function () { return anchor_close_1.sweepAnchors; } });
|
|
28
|
+
Object.defineProperty(exports, "sweepOrphanAnchors", { enumerable: true, get: function () { return anchor_close_1.sweepOrphanAnchors; } });
|
|
20
29
|
var attribution_1 = require("./attribution");
|
|
21
30
|
Object.defineProperty(exports, "attributeByOverlap", { enumerable: true, get: function () { return attribution_1.attributeByOverlap; } });
|
|
22
31
|
Object.defineProperty(exports, "failingTest", { enumerable: true, get: function () { return attribution_1.failingTest; } });
|
|
@@ -140,6 +149,7 @@ Object.defineProperty(exports, "unitEvent", { enumerable: true, get: function ()
|
|
|
140
149
|
// since #544, but stay exported through `./enqueue` above — that is where
|
|
141
150
|
// they were first public, and re-exporting them twice would collide.
|
|
142
151
|
var labels_1 = require("./labels");
|
|
152
|
+
Object.defineProperty(exports, "BATCH_ANCHOR_LABEL", { enumerable: true, get: function () { return labels_1.BATCH_ANCHOR_LABEL; } });
|
|
143
153
|
Object.defineProperty(exports, "DECISION_PENDING_LABEL", { enumerable: true, get: function () { return labels_1.DECISION_PENDING_LABEL; } });
|
|
144
154
|
Object.defineProperty(exports, "HARD_BLOCK_LABELS", { enumerable: true, get: function () { return labels_1.HARD_BLOCK_LABELS; } });
|
|
145
155
|
Object.defineProperty(exports, "hasLabel", { enumerable: true, get: function () { return labels_1.hasLabel; } });
|
|
@@ -225,11 +235,19 @@ Object.defineProperty(exports, "transitionSlot", { enumerable: true, get: functi
|
|
|
225
235
|
Object.defineProperty(exports, "validatedMembersOf", { enumerable: true, get: function () { return state_1.validatedMembersOf; } });
|
|
226
236
|
Object.defineProperty(exports, "validateState", { enumerable: true, get: function () { return state_1.validateState; } });
|
|
227
237
|
var status_1 = require("./status");
|
|
238
|
+
Object.defineProperty(exports, "buildKeptWorktreeWarnings", { enumerable: true, get: function () { return status_1.buildKeptWorktreeWarnings; } });
|
|
228
239
|
Object.defineProperty(exports, "buildStatusReport", { enumerable: true, get: function () { return status_1.buildStatusReport; } });
|
|
229
240
|
Object.defineProperty(exports, "buildStatusWarnings", { enumerable: true, get: function () { return status_1.buildStatusWarnings; } });
|
|
241
|
+
Object.defineProperty(exports, "defaultKeptWorktreeReader", { enumerable: true, get: function () { return status_1.defaultKeptWorktreeReader; } });
|
|
242
|
+
Object.defineProperty(exports, "KEPT_WORKTREE_PROBE_LIMIT", { enumerable: true, get: function () { return status_1.KEPT_WORKTREE_PROBE_LIMIT; } });
|
|
243
|
+
Object.defineProperty(exports, "keptWorktreeCandidates", { enumerable: true, get: function () { return status_1.keptWorktreeCandidates; } });
|
|
230
244
|
Object.defineProperty(exports, "STATUS_HEALTH_WARNING_AGE_MS", { enumerable: true, get: function () { return status_1.STATUS_HEALTH_WARNING_AGE_MS; } });
|
|
231
245
|
var teardown_1 = require("./teardown");
|
|
246
|
+
Object.defineProperty(exports, "defaultFsExists", { enumerable: true, get: function () { return teardown_1.defaultFsExists; } });
|
|
232
247
|
Object.defineProperty(exports, "isSafeWorktree", { enumerable: true, get: function () { return teardown_1.isSafeWorktree; } });
|
|
248
|
+
Object.defineProperty(exports, "POOL_ARGS_PREFIX", { enumerable: true, get: function () { return teardown_1.POOL_ARGS_PREFIX; } });
|
|
249
|
+
Object.defineProperty(exports, "POOL_BIN", { enumerable: true, get: function () { return teardown_1.POOL_BIN; } });
|
|
250
|
+
Object.defineProperty(exports, "poolEntryFor", { enumerable: true, get: function () { return teardown_1.poolEntryFor; } });
|
|
233
251
|
Object.defineProperty(exports, "runTeardown", { enumerable: true, get: function () { return teardown_1.runTeardown; } });
|
|
234
252
|
Object.defineProperty(exports, "TEARDOWN_TIMEOUT_MS", { enumerable: true, get: function () { return teardown_1.TEARDOWN_TIMEOUT_MS; } });
|
|
235
253
|
var types_1 = require("./types");
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;AAAA,+CAkCwB;AAjCtB,2HAAA,2BAA2B,OAAA;AAK3B,iHAAA,iBAAiB,OAAA;AACjB,oHAAA,oBAAoB,OAAA;AACpB,oHAAA,oBAAoB,OAAA;AAEpB,8GAAA,cAAc,OAAA;AACd,oHAAA,oBAAoB,OAAA;AACpB,2GAAA,WAAW,OAAA;AACX,0HAAA,0BAA0B,OAAA;AAC1B,iHAAA,iBAAiB,OAAA;AAGjB,qHAAA,qBAAqB,OAAA;AAIrB,wHAAA,wBAAwB,OAAA;AACxB,wHAAA,wBAAwB,OAAA;AAKxB,iHAAA,iBAAiB,OAAA;AACjB,oHAAA,oBAAoB,OAAA;AACpB,qHAAA,qBAAqB,OAAA;AACrB,wHAAA,wBAAwB,OAAA;AACxB,gHAAA,gBAAgB,OAAA;AAChB,4GAAA,YAAY,OAAA;AACZ,kHAAA,kBAAkB,OAAA;AAEpB,6CAmBuB;AAjBrB,iHAAA,kBAAkB,OAAA;AAGlB,0GAAA,WAAW,OAAA;AACX,uHAAA,wBAAwB,OAAA;AACxB,qHAAA,sBAAsB,OAAA;AACtB,qHAAA,sBAAsB,OAAA;AAGtB,6GAAA,cAAc,OAAA;AACd,2GAAA,YAAY,OAAA;AAEZ,0GAAA,WAAW,OAAA;AACX,mHAAA,oBAAoB,OAAA;AACpB,8GAAA,eAAe,OAAA;AACf,0GAAA,WAAW,OAAA;AACX,qGAAA,MAAM,OAAA;A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+FAAA,MAAM,OAAA;AAIN,iHAAA,wBAAwB,OAAA;AACxB,uGAAA,cAAc,OAAA;AAGd,2GAAA,kBAAkB,OAAA;AAElB,mGAAA,UAAU,OAAA;AAKV,gHAAA,uBAAuB,OAAA;AACvB,gHAAA,uBAAuB,OAAA;AACvB,oGAAA,WAAW,OAAA;AACX,mGAAA,UAAU,OAAA"}
|
package/dist/labels.d.ts
CHANGED
|
@@ -37,6 +37,15 @@
|
|
|
37
37
|
* not the `IssueStatus` value of the same name (`types.ts`).
|
|
38
38
|
*/
|
|
39
39
|
export declare const DECISION_PENDING_LABEL = "decision-pending";
|
|
40
|
+
/**
|
|
41
|
+
* The label a batch ANCHOR issue carries (`cli/src/batch-compose.ts`'s Step 6
|
|
42
|
+
* anchor-creation, per `examples/git/batch-issues-preparation.ds.md`) —
|
|
43
|
+
* distinct from every per-issue hard-block label above, since an anchor is
|
|
44
|
+
* never itself dispatched. Canonical here (#790) so the #790 orphan sweep's
|
|
45
|
+
* `gh issue list --label batch-epic` (`cli/src/commands/sched.ts`) and
|
|
46
|
+
* `batch-compose.ts`'s own `BATCH_ANCHOR_LABEL` cannot silently drift apart.
|
|
47
|
+
*/
|
|
48
|
+
export declare const BATCH_ANCHOR_LABEL = "batch-epic";
|
|
40
49
|
export declare const HARD_BLOCK_LABELS: readonly ["decision-pending", "needs-clarification", "epic", "decomposed"];
|
|
41
50
|
/** Whether `labels` carries `name`, case-insensitively — how every label screen here compares. */
|
|
42
51
|
export declare function hasLabel(labels: readonly string[], name: string): boolean;
|
package/dist/labels.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"labels.d.ts","sourceRoot":"","sources":["../src/labels.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH;;;;;;;;;;;;;;;GAeG;AACH;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAEzD,eAAO,MAAM,iBAAiB,4EAKpB,CAAC;AAEX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ANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
* (`gh issue view --json labels`), the same discipline `enqueue.ts` follows.
|
|
18
18
|
*/
|
|
19
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
|
-
exports.LABEL_BLOCK_REASON_PREFIX = exports.HARD_BLOCK_LABELS = exports.DECISION_PENDING_LABEL = void 0;
|
|
20
|
+
exports.LABEL_BLOCK_REASON_PREFIX = exports.HARD_BLOCK_LABELS = exports.BATCH_ANCHOR_LABEL = exports.DECISION_PENDING_LABEL = void 0;
|
|
21
21
|
exports.hasLabel = hasLabel;
|
|
22
22
|
exports.pickHardBlockLabel = pickHardBlockLabel;
|
|
23
23
|
exports.labelBlockReason = labelBlockReason;
|
|
@@ -44,6 +44,15 @@ exports.labelOfBlockReason = labelOfBlockReason;
|
|
|
44
44
|
* not the `IssueStatus` value of the same name (`types.ts`).
|
|
45
45
|
*/
|
|
46
46
|
exports.DECISION_PENDING_LABEL = 'decision-pending';
|
|
47
|
+
/**
|
|
48
|
+
* The label a batch ANCHOR issue carries (`cli/src/batch-compose.ts`'s Step 6
|
|
49
|
+
* anchor-creation, per `examples/git/batch-issues-preparation.ds.md`) —
|
|
50
|
+
* distinct from every per-issue hard-block label above, since an anchor is
|
|
51
|
+
* never itself dispatched. Canonical here (#790) so the #790 orphan sweep's
|
|
52
|
+
* `gh issue list --label batch-epic` (`cli/src/commands/sched.ts`) and
|
|
53
|
+
* `batch-compose.ts`'s own `BATCH_ANCHOR_LABEL` cannot silently drift apart.
|
|
54
|
+
*/
|
|
55
|
+
exports.BATCH_ANCHOR_LABEL = 'batch-epic';
|
|
47
56
|
exports.HARD_BLOCK_LABELS = [
|
|
48
57
|
exports.DECISION_PENDING_LABEL,
|
|
49
58
|
'needs-clarification',
|
package/dist/labels.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"labels.js","sourceRoot":"","sources":["../src/labels.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;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,UAAU,CAAC,iCAAyB,CAAC;QAAE,OAAO,IAAI,CAAC;IAClF,MAAM,IAAI,GAAG,MAAM,CAAC,KAAK,CAAC,iCAAyB,CAAC,MAAM,CAAC,CAAC;IAC5D,OAAO,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC;AACvC,CAAC"}
|
package/dist/status.d.ts
CHANGED
|
@@ -5,9 +5,11 @@
|
|
|
5
5
|
* `renderTable`) — the package deliberately has no dependency on CLI
|
|
6
6
|
* utilities.
|
|
7
7
|
*/
|
|
8
|
-
import { type AnchorReportItem, type CommitInBase, type IssueCloseReader } from './anchor-close';
|
|
8
|
+
import { type AnchorReportItem, type CommitInBase, type IssueCloseReader, type OpenAnchorLister, type OrphanAnchorReportItem } from './anchor-close';
|
|
9
9
|
import { type TierExecutor } from './dispatch';
|
|
10
10
|
import type { EngineLeaseStatus } from './persist';
|
|
11
|
+
import type { ExecFn } from './project';
|
|
12
|
+
import { type FsExists } from './teardown';
|
|
11
13
|
import type { BatchEntry, DispatchProfileSource, MemberExitKind, ModelTier, QueueEntry, SchedConfig, SchedState, SlotEntry } from './types';
|
|
12
14
|
/** An entry that cannot progress, with the human reason. */
|
|
13
15
|
export interface BlockedItem {
|
|
@@ -52,8 +54,8 @@ export interface ParkedMemberItem {
|
|
|
52
54
|
* working" — it is state nobody came back to.
|
|
53
55
|
*/
|
|
54
56
|
export declare const STATUS_HEALTH_WARNING_AGE_MS: number;
|
|
55
|
-
/** The kinds of health warning `sched status` raises (#776). */
|
|
56
|
-
export type StatusWarningKind = 'long-pause' | 'stale-engine-lease' | 'stuck-slot' | 'stale-closed';
|
|
57
|
+
/** The kinds of health warning `sched status` raises (#776, plus #791's `kept-worktree`). */
|
|
58
|
+
export type StatusWarningKind = 'long-pause' | 'stale-engine-lease' | 'stuck-slot' | 'stale-closed' | 'kept-worktree';
|
|
57
59
|
/**
|
|
58
60
|
* A condition an operator must act on (#776): the 2026-09-24 incident was a
|
|
59
61
|
* scheduler paused for days, a dead engine lease, and a slot `recovering` an
|
|
@@ -69,6 +71,8 @@ export interface StatusWarning {
|
|
|
69
71
|
issue?: number;
|
|
70
72
|
/** The slot the warning is about, when it is about one. */
|
|
71
73
|
slot?: number;
|
|
74
|
+
/** The batch the warning is about, when it is about one (#791: batch ids are strings, unlike `issue`/`slot`). */
|
|
75
|
+
batch?: string;
|
|
72
76
|
}
|
|
73
77
|
/** Machine-readable status report (`sched status --json`). */
|
|
74
78
|
export interface StatusReport {
|
|
@@ -138,7 +142,10 @@ export interface StatusReport {
|
|
|
138
142
|
blocked: BlockedItem[];
|
|
139
143
|
failed: QueueEntry[];
|
|
140
144
|
stopped: QueueEntry[];
|
|
141
|
-
/**
|
|
145
|
+
/**
|
|
146
|
+
* Health warnings (#776), plus #791's `kept-worktree` when a reader was
|
|
147
|
+
* supplied — empty when nothing needs an operator.
|
|
148
|
+
*/
|
|
142
149
|
warnings: StatusWarning[];
|
|
143
150
|
/**
|
|
144
151
|
* #768 anchor sweep (report-only, `sched status --anchors`): every
|
|
@@ -148,17 +155,115 @@ export interface StatusReport {
|
|
|
148
155
|
* network call unless asked; nothing is guessed from the ledger alone).
|
|
149
156
|
*/
|
|
150
157
|
anchors: AnchorReportItem[] | null;
|
|
158
|
+
/**
|
|
159
|
+
* #790 orphan anchor sweep (report-only, same `sched status --anchors`
|
|
160
|
+
* opt-in): every open `batch-epic` anchor whose batch is no longer in
|
|
161
|
+
* `state.batches` at all — invisible to `anchors` above, which only walks
|
|
162
|
+
* the ledger. `null` under three conditions, deliberately never rendered
|
|
163
|
+
* as an empty-but-clean result: no sweep asked for; the orphan lister was
|
|
164
|
+
* not supplied even though the ledger sweep was (an older caller, or a
|
|
165
|
+
* repo the orphan lister could not verify); or the lister ran but the
|
|
166
|
+
* GitHub list call itself FAILED — distinguished from `[]` (asked for,
|
|
167
|
+
* genuinely found none) the same way `anchors` distinguishes "not asked"
|
|
168
|
+
* from "asked, clean".
|
|
169
|
+
*/
|
|
170
|
+
orphan_anchors: OrphanAnchorReportItem[] | null;
|
|
171
|
+
/**
|
|
172
|
+
* True when {@link orphan_anchors} left real orphan candidates unprobed
|
|
173
|
+
* because {@link ORPHAN_SWEEP_MAX_ANCHORS} was hit — ledger-tracked
|
|
174
|
+
* anchors are excluded before the cap, so this can fire only when MORE
|
|
175
|
+
* than the cap's worth of genuine orphans exist in one repo. `false` when
|
|
176
|
+
* `orphan_anchors` is `null` (nothing was classified either way) or the
|
|
177
|
+
* sweep classified every candidate.
|
|
178
|
+
*/
|
|
179
|
+
orphan_anchors_truncated: boolean;
|
|
151
180
|
}
|
|
152
181
|
/**
|
|
153
182
|
* #776: the health warnings — pure over state + lease + clock, so every
|
|
154
183
|
* warning is unit-testable without a live engine.
|
|
155
184
|
*/
|
|
156
185
|
export declare function buildStatusWarnings(state: SchedState, engineLease: EngineLeaseStatus | null, now: Date): StatusWarning[];
|
|
186
|
+
/** One `done` batch's kept worktree (#791) — either the shared batch worktree or the current member's own. */
|
|
187
|
+
export interface KeptWorktreeCandidate {
|
|
188
|
+
batch: string;
|
|
189
|
+
/** Which `BatchEntry` field this candidate came from — `worktree` (shared) or `member_worktree` (current member, #677). */
|
|
190
|
+
field: 'worktree' | 'member_worktree';
|
|
191
|
+
path: string;
|
|
192
|
+
poolClaimed: boolean;
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* Every `done` batch whose `worktree` or `member_worktree` is still set in
|
|
196
|
+
* the ledger (#791) — pure over state, exactly like `buildStatusWarnings`.
|
|
197
|
+
* A candidate is skipped when its path is ALSO held by a non-`done` (still
|
|
198
|
+
* in-flight) batch: a pool worktree the operator already returned can be
|
|
199
|
+
* re-claimed by a fresh batch before the done batch's own ledger field is
|
|
200
|
+
* cleared, and warning about a path a live batch is actively using is worse
|
|
201
|
+
* than not warning at all — it tells the operator to remove/return a
|
|
202
|
+
* worktree that is in use. Naturally bounded beyond that: only `done`
|
|
203
|
+
* batches are considered, and in practice very few ever carry a kept
|
|
204
|
+
* worktree (only the `members-closed` reconcile path leaves one).
|
|
205
|
+
*/
|
|
206
|
+
export declare function keptWorktreeCandidates(state: SchedState): KeptWorktreeCandidate[];
|
|
207
|
+
/**
|
|
208
|
+
* Local, read-only facts about a kept worktree (#791) — injectable so tests
|
|
209
|
+
* never touch a real filesystem or spawn a real `git`. The default
|
|
210
|
+
* implementation ({@link defaultKeptWorktreeReader}) is the only place that
|
|
211
|
+
* runs a real command, and it runs at most three, all read-only: `git
|
|
212
|
+
* rev-parse --show-toplevel` (containment check), `git --no-optional-locks
|
|
213
|
+
* status --porcelain`, and `git log HEAD --not --remotes`. Nothing in this
|
|
214
|
+
* package ever builds a `git worktree remove` / `worktree-pool return` argv
|
|
215
|
+
* from this reader — the remedy text is a string for a human to run by hand.
|
|
216
|
+
*/
|
|
217
|
+
export interface KeptWorktreeReader {
|
|
218
|
+
/** Whether `path` still exists on disk. */
|
|
219
|
+
exists: (path: string) => boolean;
|
|
220
|
+
/**
|
|
221
|
+
* Whether `path` (an existing worktree) has uncommitted changes or
|
|
222
|
+
* commits not on any remote branch. `true` = dirty/unpushed (unsafe to
|
|
223
|
+
* remove), `false` = clean and fully pushed (safe to remove), `null` =
|
|
224
|
+
* the check could not be trusted — the git probe itself failed (path not
|
|
225
|
+
* a repo, git missing, timeout), OR `path` is no longer its own worktree
|
|
226
|
+
* root (pruned, or reused by something else — see `defaultKeptWorktreeReader`)
|
|
227
|
+
* — reported as `unknown`, never guessed.
|
|
228
|
+
*/
|
|
229
|
+
hasLocalWork: (path: string) => boolean | null;
|
|
230
|
+
}
|
|
231
|
+
/**
|
|
232
|
+
* The real {@link KeptWorktreeReader}: `exec`/`fsExists` follow the same
|
|
233
|
+
* injectable conventions as the rest of the package (`project.ts`'s
|
|
234
|
+
* `ExecFn`, `teardown.ts`'s `FsExists`) so the CLI wires in a real,
|
|
235
|
+
* bounded-timeout `git`/`fs` and every test wires in a spy instead.
|
|
236
|
+
*/
|
|
237
|
+
export declare function defaultKeptWorktreeReader(exec: ExecFn, fsExists?: FsExists): KeptWorktreeReader;
|
|
238
|
+
/** Per-run cap on how many kept-worktree candidates get probed with real git calls (#791 supportability review finding 7) — `sched status` must stay fast even with many leftovers. */
|
|
239
|
+
export declare const KEPT_WORKTREE_PROBE_LIMIT = 10;
|
|
240
|
+
/**
|
|
241
|
+
* Turn kept-worktree candidates into `StatusWarning`s (#791) — pure given
|
|
242
|
+
* the reader, exactly like `buildStatusWarnings` is pure given the state
|
|
243
|
+
* and lease. A reader call that throws is caught defensively (a hostile or
|
|
244
|
+
* buggy injected reader must never crash `sched status`) and routed to the
|
|
245
|
+
* SAME "could not be checked" outcome as a reader returning `null` — a
|
|
246
|
+
* thrown `exists()` must never read as "gone", which would tell an operator
|
|
247
|
+
* there is nothing left to do when the truth is simply unknown (#791
|
|
248
|
+
* maintainability review finding 3).
|
|
249
|
+
*/
|
|
250
|
+
export declare function buildKeptWorktreeWarnings(candidates: KeptWorktreeCandidate[], reader: KeptWorktreeReader): StatusWarning[];
|
|
157
251
|
export declare function buildStatusReport(state: SchedState, config: SchedConfig, project: string, engineLease?: EngineLeaseStatus | null, now?: Date,
|
|
158
|
-
/**
|
|
252
|
+
/**
|
|
253
|
+
* #768/#790: the opt-in anchor sweep's GitHub/git readers; omitted →
|
|
254
|
+
* `anchors: null` and `orphan_anchors: null`. `orphanList` is optional
|
|
255
|
+
* within this — a caller that supplies `read`/`repo` but no `orphanList`
|
|
256
|
+
* (an unverified repo, or one that has not adopted #790 yet) still gets
|
|
257
|
+
* the ledger sweep, just no orphan sweep (`orphan_anchors: null`).
|
|
258
|
+
*/
|
|
159
259
|
anchorSweep?: {
|
|
160
260
|
read: IssueCloseReader;
|
|
161
261
|
repo?: string;
|
|
162
262
|
commitInBase?: CommitInBase;
|
|
163
|
-
|
|
263
|
+
orphanList?: OpenAnchorLister;
|
|
264
|
+
/** #790: the base branch an orphan's own `base_branch:` metadata must match to ever be `orphan-closable-candidate` — passed to `sweepOrphanAnchors`; defaults to `DEFAULT_ORPHAN_BASE_BRANCH` ('main') when omitted. */
|
|
265
|
+
expectedBaseBranch?: string;
|
|
266
|
+
},
|
|
267
|
+
/** #791: the opt-in kept-worktree reader; omitted → no `kept-worktree` warnings (zero behavior change for every existing caller). */
|
|
268
|
+
worktreeReader?: KeptWorktreeReader): StatusReport;
|
|
164
269
|
//# sourceMappingURL=status.d.ts.map
|
package/dist/status.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../src/status.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;
|
|
1
|
+
{"version":3,"file":"status.d.ts","sourceRoot":"","sources":["../src/status.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAG5B,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAGL,KAAK,YAAY,EAElB,MAAM,YAAY,CAAC;AAEpB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AASxC,OAAO,EAAmB,KAAK,QAAQ,EAA8B,MAAM,YAAY,CAAC;AACxF,OAAO,KAAK,EACV,UAAU,EACV,qBAAqB,EACrB,cAAc,EACd,SAAS,EACT,UAAU,EACV,WAAW,EACX,UAAU,EACV,SAAS,EACV,MAAM,SAAS,CAAC;AAGjB,4DAA4D;AAC5D,MAAM,WAAW,WAAW;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,kDAAkD;AAClD,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,MAAM,CAAC;IACd,EAAE,EAAE,MAAM,CAAC;IACX,iDAAiD;I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