You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Give the template distinctive headings, such as ## Context and ## Verification.
Enable Settings → Source Control → Follow change request templates.
Create a pull request or merge request through T3 Code’s Git actions.
Expected behavior
When enabled, the setting discovers the hosting provider’s repository template and uses it to generate the description.
Actual behavior
Template discovery is explicitly restricted to GitHub. GitLab and Azure DevOps templates are not passed to the description generator, regardless of the setting.
GitManager.ts:2023 checks provider.kind === "github" before calling detectPrTemplate. The detector in PrTemplateDetection.ts only includes GitHub-compatible paths.
Decision: Accept Classification: Bug Severity: Minor (P3) Confidence: High Repro: Source-confirmed. Reporter steps are sufficient; no extra environment details are required. Area:apps/server (Git stacked actions + PR/MR description generation)
Summary
Confirmed. Settings → Source Control → Follow change request templates is on by default and advertised as host-agnostic (“Use the repository's template for change request descriptions when available”), but PR/MR body generation only loads a template when the remote is GitHub. GitLab and Azure DevOps repos skip discovery entirely, so generated descriptions fall back to the generic ## Summary / ## Testing prompt instead of the repo template.
This is not a duplicate of a still-open issue. It is leftover GitHub-only scope from #4204 / #264.
Diagnosis
Two independent gates, both still present on current main:
Provider gate in runPrStep. Template detection runs only when settings.style.followChangeRequestTemplates && provider.kind === "github". Any other host (gitlab, azure-devops, also Forgejo/Gitea/Bitbucket) passes changeRequestTemplate: undefined into generatePrContent.
GitHub-only path list in the detector. Even if the kind check were removed, detectPrTemplate only looks at GitHub-compatible files/directories. It does not include the paths the reporter named:
GitLab: .gitlab/merge_request_templates/Default.md (and the rest of .gitlab/merge_request_templates/*.md)
description="Use the repository's template for change request descriptions when available."
When no template is passed, generation uses the generic body rules in TextGenerationPrompts.ts. followChangeRequestTemplates defaults to true, so GitLab/Azure users hit this without changing settings.
PR #4204 implemented this as “Detect GitHub pull request templates” and closed #264. The setting and source-control docs later grew to cover GitLab and Azure DevOps, but discovery did not.
Reproduction assessment
Reporter steps match the code path. No log/screenshot is needed.
Repo on GitLab or Azure DevOps with a distinctive template at the host’s documented path.
Expected: template headings appear in the generated description.
Actual: detector never runs (non-GitHub), and GitLab/ADO paths are not in TEMPLATE_PATHS / TEMPLATE_DIRECTORIES.
Tests only cover GitHub paths (PrTemplateDetection.test.ts) and a GitHub pr create flow. There is no GitLab/Azure case that asserts a template is passed through.
No open issue about GitLab/Azure DevOps change-request templates.
Same provider gate also blocks Forgejo, Gitea, and Bitbucket. Out of scope for this report, but a fix should not special-case only GitLab + Azure if those hosts already have documented template paths.
Recommended next step
Accept and implement in apps/server:
Stop gating detectPrTemplate on provider.kind === "github". Keep the followChangeRequestTemplates setting as the only user switch.
Extend TEMPLATE_PATHS / TEMPLATE_DIRECTORIES with host paths, at least:
.gitlab/merge_request_templates (prefer Default.md when several files exist; today’s “ambiguous directory → none” rule would otherwise ignore a valid GitLab default)
.azuredevops/pull_request_template.md
Add detector tests for those paths and a GitManager test that a non-GitHub provider still receives changeRequestTemplate.
Optional docs tweak in docs/user/source-control.md under “Create a pull request” so the supported template locations are explicit.
Workaround
Unchanged from the report: after T3 generates the description, paste or edit in the host template by hand.
I've prepared a fix in #12392 that adds GitLab (.gitlab/merge_request_templates/Default.md) and Azure DevOps (.azuredevops/pull_request_template.md) change request template detection — let me know if you'd like any changes.
Adds .gitlab/merge_request_templates/Default.md (+ directory) and .azuredevops template paths to PrTemplateDetection, and enables followChangeRequestTemplates for gitlab and azure-devops in GitManager. Small fix, 3 files, 12 insertions. Happy to adjust scope.
I'd like to take this. I'll follow the direction in the maintainer triage above and open a focused PR with before/after evidence, noting the model and harness used.
PR is up: #18209. It adds the GitLab and Azure DevOps template readers following the triage. Forgejo, Gitea, Bitbucket and Azure branch-specific templates are out of scope there.
Activity
juliusmarminge commentedon Sep 17, 2026
Triage
Decision: Accept
Classification: Bug
Severity: Minor (P3)
Confidence: High
Repro: Source-confirmed. Reporter steps are sufficient; no extra environment details are required.
Area:
apps/server(Git stacked actions + PR/MR description generation)Summary
Confirmed. Settings → Source Control → Follow change request templates is on by default and advertised as host-agnostic (“Use the repository's template for change request descriptions when available”), but PR/MR body generation only loads a template when the remote is GitHub. GitLab and Azure DevOps repos skip discovery entirely, so generated descriptions fall back to the generic
## Summary/## Testingprompt instead of the repo template.This is not a duplicate of a still-open issue. It is leftover GitHub-only scope from #4204 / #264.
Diagnosis
Two independent gates, both still present on current
main:runPrStep. Template detection runs only whensettings.style.followChangeRequestTemplates && provider.kind === "github". Any other host (gitlab,azure-devops, also Forgejo/Gitea/Bitbucket) passeschangeRequestTemplate: undefinedintogeneratePrContent.GitHub-only path list in the detector. Even if the kind check were removed,
detectPrTemplateonly looks at GitHub-compatible files/directories. It does not include the paths the reporter named:.gitlab/merge_request_templates/Default.md(and the rest of.gitlab/merge_request_templates/*.md).azuredevops/pull_request_template.mdUser-facing copy does not mention a GitHub limit:
When no template is passed, generation uses the generic body rules in
TextGenerationPrompts.ts.followChangeRequestTemplatesdefaults totrue, so GitLab/Azure users hit this without changing settings.PR #4204 implemented this as “Detect GitHub pull request templates” and closed #264. The setting and source-control docs later grew to cover GitLab and Azure DevOps, but discovery did not.
Reproduction assessment
Reporter steps match the code path. No log/screenshot is needed.
Expected: template headings appear in the generated description.
Actual: detector never runs (non-GitHub), and GitLab/ADO paths are not in
TEMPLATE_PATHS/TEMPLATE_DIRECTORIES.Tests only cover GitHub paths (
PrTemplateDetection.test.ts) and a GitHubpr createflow. There is no GitLab/Azure case that asserts a template is passed through.Related issues
.github/pull_request_template.mdonly.Same provider gate also blocks Forgejo, Gitea, and Bitbucket. Out of scope for this report, but a fix should not special-case only GitLab + Azure if those hosts already have documented template paths.
Recommended next step
Accept and implement in
apps/server:detectPrTemplateonprovider.kind === "github". Keep thefollowChangeRequestTemplatessetting as the only user switch.TEMPLATE_PATHS/TEMPLATE_DIRECTORIESwith host paths, at least:.gitlab/merge_request_templates(preferDefault.mdwhen several files exist; today’s “ambiguous directory → none” rule would otherwise ignore a valid GitLab default).azuredevops/pull_request_template.mdchangeRequestTemplate.docs/user/source-control.mdunder “Create a pull request” so the supported template locations are explicit.Workaround
Unchanged from the report: after T3 generates the description, paste or edit in the host template by hand.
scs0209 commentedon Sep 18, 2026
I've prepared a fix in #12392 that adds GitLab (
.gitlab/merge_request_templates/Default.md) and Azure DevOps (.azuredevops/pull_request_template.md) change request template detection — let me know if you'd like any changes.SachinD6 commentedon Sep 23, 2026
Proposal ready in my fork for #12330:
Adds .gitlab/merge_request_templates/Default.md (+ directory) and .azuredevops template paths to PrTemplateDetection, and enables followChangeRequestTemplates for gitlab and azure-devops in GitManager. Small fix, 3 files, 12 insertions. Happy to adjust scope.
fixfon commentedon Oct 11, 2026
I'd like to take this. I'll follow the direction in the maintainer triage above and open a focused PR with before/after evidence, noting the model and harness used.
fixfon commentedon Oct 11, 2026
PR is up: #18209. It adds the GitLab and Azure DevOps template readers following the triage. Forgejo, Gitea, Bitbucket and Azure branch-specific templates are out of scope there.