Skip to content

[Bug]: Creating a GitHub issue silently loses requested labels and assignees #37983

Closed as not planned

Description

@StiensWout

Before submitting

  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.

Area

Not sure

Steps to reproduce

  1. Start T3 Code. In Settings, under Source control and issues, sign in to GitHub as an account that can open issues on a public repository but has neither write nor triage access to it. That repository already has a label, and it has a person who can be assigned to its issues.
  2. Add a checkout of that repository as a project.
  3. Start a new thread in that project.
  4. Ask the agent to file an issue, and to set that existing label and that assignee.
  5. Open the issue the thread says it filed, on the project's Issues screen.

Expected behavior

The thread reports that GitHub did not apply the requested label or assignee.

Actual behavior

The thread says the issue was filed and shows no warning. The issue has neither the requested label nor the assignee.

Impact

Major degradation or frequent failure. Users filing issues through agents without repository metadata permissions can silently lose the requested triage information on every creation.

Version or commit

main at 0ff1495c05. The cause is at packages/source-control-github/src/server/GitHubIssueTracker.ts:318.

Environment

Linux x64, the repository's own tests.

Logs or stack traces

expected { Object (success) } to match object
Automated repro

Fails in 2 of 2 runs on main: apply the patch with git apply, then run the command.

diff --git a/packages/source-control-github/src/server/GitHubIssueTracker.test.ts b/packages/source-control-github/src/server/GitHubIssueTracker.test.ts
--- a/packages/source-control-github/src/server/GitHubIssueTracker.test.ts
+++ b/packages/source-control-github/src/server/GitHubIssueTracker.test.ts
@@ -385,6 +385,43 @@
     }),
   );
 
+  it.effect("reports when GitHub creates an issue but drops requested metadata", () =>
+    Effect.gen(function* () {
+      const http = HttpClient.make((request) =>
+        Effect.succeed(
+          HttpClientResponse.fromWeb(
+            request,
+            new Response(
+              JSON.stringify({
+                number: 43,
+                html_url: "https://github.com/acme/web/issues/43",
+                labels: [],
+                assignees: [],
+              }),
+              { status: 201, headers: { "content-type": "application/json" } },
+            ),
+          ),
+        ),
+      );
+      const api = yield* GitHubIssueTracker.make.pipe(Effect.provide(transport(http)));
+      const result = yield* api
+        .create({
+          cwd: "/w",
+          host: "github.com",
+          scope: "acme/web",
+          title: "Missing metadata",
+          body: "Repro attached.",
+          labels: ["bug"],
+          assignees: ["octocat"],
+        })
+        .pipe(Effect.result);
+      expect(result).toMatchObject({
+        _tag: "Failure",
+        failure: { operation: "create", reason: "failed" },
+      });
+    }),
+  );
+
   it.effect("asks search for the labels, assignee and order a listing names", () =>
     Effect.gen(function* () {
       const seen: unknown[] = [];
cd packages/source-control-github && pnpm exec vp test run --config ../../vite.config.ts --dir . src/server/GitHubIssueTracker.test.ts -t 'reports when GitHub creates'

Workaround

No response

Activity

  1. added
    vouch:trusted
    on Nov 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    vouch:trusted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions