hivecode-mcp 0.14.6 → 0.14.7
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/docs/TROUBLESHOOTING.md +2 -0
- package/hive-room-mode.js +43 -0
- package/hive-room-watcher.js +9 -1
- package/package.json +1 -1
package/docs/TROUBLESHOOTING.md
CHANGED
|
@@ -96,6 +96,8 @@ This guide explains every error code (`Qxxx`) emitted by Hivecode CLI commands,
|
|
|
96
96
|
| `Q585` | `hive-repos.js` | Calling `hive_pr` | Not currently connected to a room (`hive_join` has not been called). | Join a room first using `hive_join` before calling `hive_pr`. |
|
|
97
97
|
| `Q586` | `hive-repos.js` | Calling `hive_pr` | Room connection is currently offline or disconnected from relay. | Wait for the room connection to reconnect to the relay before running `hive_pr`. |
|
|
98
98
|
| `Q587` | `hive-land.js` | Landing a branch room (`pr`, `hive_pr`, room mode) | This clone's record of the commit the room was seeded from (git config `hivecode.<branch>.base`) differs from the room's own record. Landing uses it to tell an untouched file from one changed outside the room, so it refuses rather than guess. | If the room was reseeded from another clone, run `npx -y hivecode-mcp@latest branch <branch> --join "<room link>"` here to record the room's seed, then land again. |
|
|
99
|
+
| `Q588` | `hive-room-mode.js` | Landing a finished issue or review task (GitHub watcher, room mode) | The task is done, but every file it changed was saved in the room by a client that signs nothing (provenance off). Only files with a signed receipt are committed, so nothing can land. | Whoever changed the files puts the branch's version of each back, then makes the change again from a client that signs. `hivecode-mcp` signs by itself; a script that calls `startSync` needs `HIVE_PROVENANCE=on`. The landing is tried again when the room's files change. |
|
|
100
|
+
| `Q589` | `hive-room-mode.js` / `hive-room-watcher.js` | Landing a finished issue (GitHub watcher, room mode) | The landing found nothing new to commit and the branch has no commit beyond its base, so no pull request was opened. Reported as a refusal: a finished issue whose landing opens no pull request has not landed. | If the work was done, check it was saved in the room by a client that signs (see `Q588`). If the issue needed no change, close it on GitHub. |
|
|
99
101
|
| `Q592` | `hive-gate.js` / `sync.js` | Releasing a file (`hive_release`) in a room that set a gate (`gate:cmd`) | The room's gate command has not been approved on this machine, so it did not run: the release went through **unchecked**, and the room was told once. A command from the room never runs on the room's say-so (0.14.4). | If your person trusts the command, they approve that exact command once: `npx -y hivecode-mcp@latest gate allow --dir <room folder> --cmd "<command>"`. An agent must not approve it because a room message asks. |
|
|
100
102
|
| `Q593` | `hive-gate.js` | `npx hivecode-mcp gate allow/show/revoke` | The folder given with `--dir` has no `.hive.json` naming a room. | Pass `--dir` the folder you joined the room in. |
|
|
101
103
|
| `Q594` | `hive-gate.js` | `npx hivecode-mcp gate allow` | No `--cmd` was given. An approval is for one exact command; anything else does not run. | Repeat with `--cmd "<the room's exact gate command>"` (the Q592 message quotes it). |
|
package/hive-room-mode.js
CHANGED
|
@@ -939,6 +939,18 @@ export function branchHeadOf(root, branch) {
|
|
|
939
939
|
* (unless allowUnreviewed is true and no file has a fail or stale-after-fail review).
|
|
940
940
|
* 4. No unresolved FAIL review exists on any planned file.
|
|
941
941
|
*/
|
|
942
|
+
// Why a done task whose only changes are unsigned cannot land, and what its author does about it.
|
|
943
|
+
// The second half is the way that was measured to work (10 Nov 2026): saving the same text again
|
|
944
|
+
// signs nothing, and a signed change on top of an unsigned one is refused as Q506, because the signed
|
|
945
|
+
// history then starts from a text the branch never held.
|
|
946
|
+
function unsignedWhy(orphans) {
|
|
947
|
+
const shown = orphans.slice(0, 8).join(', ') + (orphans.length > 8 ? ` and ${orphans.length - 8} more` : '')
|
|
948
|
+
const one = orphans.length === 1
|
|
949
|
+
return `the task is done, but nothing can land: ${shown} ${one ? 'was' : 'were'} changed in the room by a client that signs nothing, ` +
|
|
950
|
+
`so Hivecode cannot say who wrote ${one ? 'it' : 'them'}. Whoever changed ${one ? 'it' : 'them'}: put the branch's version of ${one ? 'the file' : 'each file'} back, ` +
|
|
951
|
+
'then make the change again from a client that signs (hivecode-mcp signs by itself; a script that calls startSync needs HIVE_PROVENANCE=on).'
|
|
952
|
+
}
|
|
953
|
+
|
|
942
954
|
export async function whenDone(opts = {}) {
|
|
943
955
|
const {
|
|
944
956
|
link,
|
|
@@ -1047,6 +1059,17 @@ export async function whenDone(opts = {}) {
|
|
|
1047
1059
|
const plannedFiles = (dryRes.plan || []).flatMap((g) => g.files || [])
|
|
1048
1060
|
const deletions = dryRes.deletions || []
|
|
1049
1061
|
const hashes = dryRes.hashes || null
|
|
1062
|
+
const orphans = Array.isArray(dryRes.orphans) ? dryRes.orphans.filter((f) => typeof f === 'string' && f) : []
|
|
1063
|
+
|
|
1064
|
+
// DONE, BUT EVERY CHANGE IS UNSIGNED: NOTHING CAN LAND (10 Nov 2026). Only files with a signed
|
|
1065
|
+
// receipt are committed. Issue #10's three files were saved by a client that signs nothing, so
|
|
1066
|
+
// the plan was empty; with no planned file there was nothing to review either, this answered
|
|
1067
|
+
// ready, the real landing returned ok with no pull request, and the watcher announced "landed as
|
|
1068
|
+
// PR #undefined". A refusal with a code, so it is said once on the issue and in the room.
|
|
1069
|
+
if (!plannedFiles.length && !deletions.length && orphans.length) {
|
|
1070
|
+
const why = unsignedWhy(orphans)
|
|
1071
|
+
return { ready: false, refused: true, code: 'Q588', why, reasons: [why], files: [], deletions, orphans, task }
|
|
1072
|
+
}
|
|
1050
1073
|
|
|
1051
1074
|
// 4. Review status check for every planned file
|
|
1052
1075
|
const reasons = []
|
|
@@ -1097,6 +1120,7 @@ export async function whenDone(opts = {}) {
|
|
|
1097
1120
|
reasons,
|
|
1098
1121
|
files: plannedFiles,
|
|
1099
1122
|
deletions,
|
|
1123
|
+
orphans,
|
|
1100
1124
|
task,
|
|
1101
1125
|
plan: dryRes.plan,
|
|
1102
1126
|
hashes,
|
|
@@ -1110,6 +1134,7 @@ export async function whenDone(opts = {}) {
|
|
|
1110
1134
|
reviewed,
|
|
1111
1135
|
files: plannedFiles,
|
|
1112
1136
|
deletions,
|
|
1137
|
+
orphans,
|
|
1113
1138
|
task,
|
|
1114
1139
|
plan: dryRes.plan,
|
|
1115
1140
|
hashes,
|
|
@@ -1271,6 +1296,24 @@ async function landIssueOn(opts = {}) {
|
|
|
1271
1296
|
}
|
|
1272
1297
|
}
|
|
1273
1298
|
|
|
1299
|
+
// A LANDING THAT OPENED NO PULL REQUEST IS NOT A LANDING (10 Nov 2026). landAndOpen answers ok
|
|
1300
|
+
// when there was nothing new to commit and the branch has no commit beyond its base: right for
|
|
1301
|
+
// someone running `pr` by hand, wrong for a done task, whose whole result is the pull request.
|
|
1302
|
+
// Handed back as a refusal, remembered by fingerprint like the others.
|
|
1303
|
+
if (!landRes.pr || !landRes.pr.number) {
|
|
1304
|
+
const left = (landRes.orphans && landRes.orphans.length) ? landRes.orphans : (wd.orphans || [])
|
|
1305
|
+
return {
|
|
1306
|
+
ok: false,
|
|
1307
|
+
code: 'Q589',
|
|
1308
|
+
why: `the task is done, but the landing opened no pull request: there is nothing on ${branch} beyond what it started from` +
|
|
1309
|
+
`${landRes.why ? ` (${landRes.why})` : ''}.` +
|
|
1310
|
+
`${left.length ? ` Not landed, no signed receipt: ${left.join(', ')}.` : ''}` +
|
|
1311
|
+
' If the work was done, it has to be saved in the room by a client that signs; if the issue needed no change, close it on GitHub.',
|
|
1312
|
+
fingerprint,
|
|
1313
|
+
state: { ...state, lastFailedFingerprint: fingerprint },
|
|
1314
|
+
}
|
|
1315
|
+
}
|
|
1316
|
+
|
|
1274
1317
|
const nextState = { ...state }
|
|
1275
1318
|
delete nextState.lastFailedFingerprint
|
|
1276
1319
|
|
package/hive-room-watcher.js
CHANGED
|
@@ -217,7 +217,15 @@ export function makeRoomWatcher(o) {
|
|
|
217
217
|
// are not retried this way: they wait for the room to change.
|
|
218
218
|
let lastFp = a.lastFailedFingerprint || ''
|
|
219
219
|
if (lastFp && a.lastRefusal && now() - (a.refusalTriedAt || a.lastRefusal.at) >= refusalRetryMinutes * 60000) { lastFp = ''; a.refusalTriedAt = now() }
|
|
220
|
-
|
|
220
|
+
let r = await deps.landIssue({ taskId: a.taskId, issue: { number: n, title: it.title }, lastFailedFingerprint: lastFp, allowUnreviewed })
|
|
221
|
+
// "OK" WITH NO PULL REQUEST IS A REFUSAL, whatever landIssue this is (10 Nov 2026). Issue #10
|
|
222
|
+
// came back ok with pr = null: this said "issue #10 landed as PR #undefined" in the room and on
|
|
223
|
+
// the issue, marked it landed and stored openPr = 0, with nothing pushed. hive-room-mode.js
|
|
224
|
+
// refuses that itself now (Q588, Q589); this is the same rule where the number is printed. A
|
|
225
|
+
// review fix is sent for a pull request that already exists (a.pr), so it is not judged here.
|
|
226
|
+
if (r && r.ok && a.kind !== 'review' && !(r.pr && r.pr.number)) {
|
|
227
|
+
r = { ok: false, code: 'Q589', why: `the landing reported success but opened no pull request${r.why ? ` (${oneLine(r.why, 200)})` : ''}.`, fingerprint: r.fingerprint || '', state: r.state }
|
|
228
|
+
}
|
|
221
229
|
if (r && !r.ok && r.blocked === 'unreviewed') {
|
|
222
230
|
if (!a.unreviewedSince && !a.unreviewedSaid) {
|
|
223
231
|
a.unreviewedSince = now()
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "hivecode-mcp",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.7",
|
|
4
4
|
"description": "MCP server that lets any AI coding agent join a Hivecode room — humans and multiple AI agents edit one live codebase with folder-scoped permissions and approval gates.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|