@ikunin/sprintpilot 2.3.3 → 2.3.4
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.
|
@@ -260,12 +260,28 @@ function buildEdges(strategies, nodes, depsDoc, { includeCrossEpic = false } = {
|
|
|
260
260
|
out.push([a, b]);
|
|
261
261
|
}
|
|
262
262
|
};
|
|
263
|
+
// Track whether explicit produced any edges in this build — if it did,
|
|
264
|
+
// ordering is suppressed for the same nodeset to avoid the back-edge
|
|
265
|
+
// cycle bug: when an explicit dep points "backwards" against story
|
|
266
|
+
// order (e.g. 6-1 depends on 6-3 — explicit emits 6-3 → 6-1), the
|
|
267
|
+
// linear ordering chain (6-1 → 6-2 → 6-3) closes a fake cycle that
|
|
268
|
+
// the user never declared. Explicit deps express the user's intent
|
|
269
|
+
// in full; ordering is only a fallback when none are provided.
|
|
270
|
+
let explicitProducedEdges = false;
|
|
263
271
|
for (const strat of strategies) {
|
|
264
272
|
if (strat === 'explicit') {
|
|
265
|
-
|
|
266
|
-
|
|
273
|
+
const explicit = edgesFromExplicit(depsDoc, nodes);
|
|
274
|
+
pushEdges(explicit);
|
|
275
|
+
if (explicit.length > 0) explicitProducedEdges = true;
|
|
276
|
+
if (includeCrossEpic) {
|
|
277
|
+
const cross = edgesFromCrossEpic(depsDoc, nodes);
|
|
278
|
+
pushEdges(cross);
|
|
279
|
+
if (cross.length > 0) explicitProducedEdges = true;
|
|
280
|
+
}
|
|
267
281
|
} else if (strat === 'ordering') {
|
|
268
|
-
|
|
282
|
+
if (!explicitProducedEdges) {
|
|
283
|
+
pushEdges(edgesFromOrdering(nodes));
|
|
284
|
+
}
|
|
269
285
|
} else if (strat === 'files') {
|
|
270
286
|
// files strategy opt-in, not implemented yet — a future
|
|
271
287
|
// sprintpilot-infer-dependencies skill populates the explicit sidecar.
|
package/package.json
CHANGED