@yemi33/minions 0.1.305 → 0.1.307
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/CHANGELOG.md +5 -1
- package/dashboard.js +4 -3
- package/engine/lifecycle.js +14 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## 0.1.
|
|
3
|
+
## 0.1.307 (2026-04-03)
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
- guard projects[0] fallbacks in lifecycle.js
|
|
7
|
+
- Add null guards to dashboard.js request handlers
|
|
4
8
|
|
|
5
9
|
### Fixes
|
|
6
10
|
- normalize acceptanceCriteria to array (string from doc-chat crashed tick)
|
package/dashboard.js
CHANGED
|
@@ -845,9 +845,9 @@ const server = http.createServer(async (req, res) => {
|
|
|
845
845
|
|
|
846
846
|
// Check if verify was created
|
|
847
847
|
const project = PROJECTS.find(p => {
|
|
848
|
-
const plan =
|
|
849
|
-
return p.name?.toLowerCase() === (plan.project || '').toLowerCase();
|
|
850
|
-
}) || PROJECTS[0];
|
|
848
|
+
const plan = safeJson(activePath) || safeJson(prdPath);
|
|
849
|
+
return plan && p.name?.toLowerCase() === (plan.project || '').toLowerCase();
|
|
850
|
+
}) || PROJECTS[0] || null;
|
|
851
851
|
if (project) {
|
|
852
852
|
const wiPath = shared.projectWorkItemsPath(project);
|
|
853
853
|
const items = JSON.parse(safeRead(wiPath) || '[]');
|
|
@@ -1037,6 +1037,7 @@ const server = http.createServer(async (req, res) => {
|
|
|
1037
1037
|
if (body.project) {
|
|
1038
1038
|
// Write to project-specific queue
|
|
1039
1039
|
const targetProject = PROJECTS.find(p => p.name === body.project) || PROJECTS[0];
|
|
1040
|
+
if (!targetProject) return jsonReply(res, 400, { error: 'No projects configured' });
|
|
1040
1041
|
wiPath = shared.projectWorkItemsPath(targetProject);
|
|
1041
1042
|
} else {
|
|
1042
1043
|
// Write to central queue — agent decides which project
|
package/engine/lifecycle.js
CHANGED
|
@@ -154,7 +154,11 @@ function checkPlanCompletion(meta, config) {
|
|
|
154
154
|
// Resolve the primary project for writing new work items (PR, verify)
|
|
155
155
|
const projectName = plan.project;
|
|
156
156
|
const primaryProject = projectName
|
|
157
|
-
? projects.find(p => p.name?.toLowerCase() === projectName?.toLowerCase()) : projects[0];
|
|
157
|
+
? projects.find(p => p.name?.toLowerCase() === projectName?.toLowerCase()) : (projects[0] || null);
|
|
158
|
+
if (!primaryProject) {
|
|
159
|
+
log('warn', `checkPlanCompletion: no project available (projects array ${projects.length === 0 ? 'empty' : 'no match for ' + projectName}) — skipping PR/verify creation for ${planFile}`);
|
|
160
|
+
return;
|
|
161
|
+
}
|
|
158
162
|
const wiPath = primaryProject ? shared.projectWorkItemsPath(primaryProject) : null;
|
|
159
163
|
const workItems = wiPath ? (safeJson(wiPath) || []) : [];
|
|
160
164
|
|
|
@@ -424,6 +428,10 @@ function chainPlanToPrd(dispatchItem, meta, config) {
|
|
|
424
428
|
|
|
425
429
|
const projectName = meta?.item?.project || meta?.project?.name;
|
|
426
430
|
const projects = shared.getProjects(config);
|
|
431
|
+
if (projects.length === 0) {
|
|
432
|
+
log('error', 'Plan chaining: no projects configured — cannot chain plan to PRD');
|
|
433
|
+
return;
|
|
434
|
+
}
|
|
427
435
|
const targetProject = projectName
|
|
428
436
|
? projects.find(p => p.name === projectName) || projects[0]
|
|
429
437
|
: projects[0];
|
|
@@ -584,7 +592,11 @@ function syncPrsFromOutput(output, agentId, meta, config) {
|
|
|
584
592
|
if (prMatches.size === 0) return 0;
|
|
585
593
|
|
|
586
594
|
const projects = shared.getProjects(config);
|
|
587
|
-
|
|
595
|
+
if (projects.length === 0 && !meta?.project?.name) {
|
|
596
|
+
log('warn', `syncPrsFromOutput: no projects configured and no project in meta — cannot sync PRs`);
|
|
597
|
+
return 0;
|
|
598
|
+
}
|
|
599
|
+
const defaultProject = (meta?.project?.name && projects.find(p => p.name === meta.project.name)) || (projects[0] || null);
|
|
588
600
|
const useCentral = !defaultProject;
|
|
589
601
|
|
|
590
602
|
// Match each PR to its correct project by finding which repo URL appears near the PR number in output
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yemi33/minions",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.307",
|
|
4
4
|
"description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
|
|
5
5
|
"bin": {
|
|
6
6
|
"minions": "bin/minions.js"
|