@miraland-labs/conduit-bridge 0.16.37 → 0.16.40

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.
Files changed (2) hide show
  1. package/dist/driver.js +12 -2
  2. package/package.json +1 -1
package/dist/driver.js CHANGED
@@ -1071,6 +1071,15 @@ export function antigravityPermissionProjection(executionClass, grants, options
1071
1071
  * — Claude Code merely skips one — and a run that had already committed died opening its own PR URL
1072
1072
  * with `read_url`, which no assignment without external_network may hold.
1073
1073
  */
1074
+ /**
1075
+ * agy's shell tool starts in agy's own scratch directory, not in the workspace it was given. Left
1076
+ * unanchored, an agent went looking for the repository on disk, found an older checkout first, and
1077
+ * committed a correct file into a stale worktree there. The prompt therefore names the worktree and
1078
+ * makes every command run inside it.
1079
+ */
1080
+ export function antigravityWorkspaceRule(workspace) {
1081
+ return `Working directory: ${workspace}. This is the checked-out attempt worktree; run every command with this as its Cwd, and read and write files only under it. Do not search the file system for other checkouts of the repository, and do not use any other directory.`;
1082
+ }
1074
1083
  export const antigravityPromptRule = "Antigravity: do not use read_url, browser, or web tools unless this assignment lists external_network; do not open the pull request URL after creating it — report the URL from the `gh pr create` output. A denied tool ends the whole run, so use only the tools this assignment allows.";
1075
1084
  export function antigravityRunArgs(input, mode, timeoutMs) {
1076
1085
  const args = ["--mode", mode];
@@ -1095,7 +1104,8 @@ export function antigravityRunArgs(input, mode, timeoutMs) {
1095
1104
  export function parseAntigravityModelList(stdout) {
1096
1105
  const models = new Set();
1097
1106
  for (const line of stdout.split("\n")) {
1098
- const match = /^\s*([A-Za-z0-9][A-Za-z0-9._/-]*)\s{2,}\S/.exec(line);
1107
+ // A terminal shows the two columns padded with spaces; a pipe gets one tab between them.
1108
+ const match = /^\s*([A-Za-z0-9][A-Za-z0-9._/-]*)(?:\t+| {2,})\S/.exec(line);
1099
1109
  if (match)
1100
1110
  models.add(match[1]);
1101
1111
  }
@@ -1239,7 +1249,7 @@ export const antigravityDriver = {
1239
1249
  const timeoutMs = agentTurnTimeoutMs(input);
1240
1250
  let executed;
1241
1251
  try {
1242
- executed = await withAntigravityPermissions(input.workspace, allow, () => execute(input.executable ?? "agy", antigravityRunArgs({ prompt: `${input.prompt}\n\n${antigravityPromptRule}`, grants: input.grants, resumeSessionId: input.resumeSessionId, model: input.model }, mode, timeoutMs), input.workspace, timeoutMs, undefined, "local"));
1252
+ executed = await withAntigravityPermissions(input.workspace, allow, () => execute(input.executable ?? "agy", antigravityRunArgs({ prompt: `${antigravityWorkspaceRule(input.workspace)}\n\n${input.prompt}\n\n${antigravityPromptRule}`, grants: input.grants, resumeSessionId: input.resumeSessionId, model: input.model }, mode, timeoutMs), input.workspace, timeoutMs, undefined, "local"));
1243
1253
  }
1244
1254
  catch (error) {
1245
1255
  return { status: "failed", resultText: null, sessionId: null, error: error instanceof Error ? error.message : String(error) };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@miraland-labs/conduit-bridge",
3
- "version": "0.16.37",
3
+ "version": "0.16.40",
4
4
  "description": "Conduit Bridge CLI \u2014 join, connect, disconnect, multi-driver lanes, and run Claude Code / Codex / Cursor / OpenCode / Pi / Kiro / Antigravity / Grok Build agents for a Conduit organization",
5
5
  "type": "module",
6
6
  "bin": {