Integrations
Pull requests
GAOS touches pull requests in three ways: it opens a draft fix for an easy defect, it reviews the ones Brain Town reports, and the QA tool opens one on the automation repository after a person approves a generated spec. The Pull requests page in the back office lists all of them, per product, with their state, their branch and base, the task each belongs to and, for the QA tool, a link to the job. It reads; it never merges, marks ready or closes anything (D-092).
Where each kind comes from
| Kind | Source | Its task |
|---|---|---|
| Auto-fix | The draft pull request GAOS opened for a defect (the fix record, Defect auto-fix). | The fix card. |
| Review | A pull request Brain Town reported on a repository the product follows (Pull-request agents). A row is written when GAOS plans the cards, and once at the first start for pull requests already open. | The reviewer card. |
| QA tool | The pull request a QA job opened, reported by the QA tool in the job’s status. Only a repository listed in the product’s automationRepos makes a row. | The e2e card. |
The page
- Per product, newest first, at most 200 rows. Tabs: Open (open and draft), Merged, Closed, All. Filters: product and kind.
- A row shows the pull request (a link to GitHub), its kind and state, the title,
branch → base(“unknown” until GAOS has read it), the task (a button that opens the task’s detail sheet, with its status), the defect or the QA case and, when the QA tool sent a link on its own host, a link to the job, and the age. - The drawer adds the related tasks, the branch and base, the task code, and the pull requests it replaced or was replaced by. It makes no GitHub call; opening and closing it swaps only the drawer, and the list stays as it is.
- Kept fresh by the poller, not by the page: every 5 minutes for the first 7 days, hourly after, up to 90 days for a review or QA row. A row says “not followed since” once it is no longer read, and “no longer followed” when the product stopped following the repository. The page itself refreshes every 30 seconds without touching GitHub.
- A GitHub failure shows a banner and leaves the rows as they were.
The card cap
Above the list, The card cap shows each product’s open pull-request cards against
GAOS_PR_MAX_OPEN, with the room left or, when pull requests wait, how many and how long the oldest has
waited. A row the cap refused carries the chip waiting for room; GAOS plans it, oldest first, as soon as
cards finish (When the card cap is full, D-120).
For a product listed in GAOS_PR_TEMPLATE_PRODUCTS, a row also shows the bundle it belongs to and,
when GAOS sent the missing-code alert, the chip no task code (Bundles
from the PR template). A member of a bundle that is not planned yet is kept past the 30-day prune. When the
product is bound to a task tracker, the code is also checked against the tracker’s tasks, and a code the tracker does not know
records the alert unknown-task-code (Task tracker).
An auto-fix admin sees Re-sync on a row that still shows no task code, in the row and in its drawer. It reads that one pull request from the forge now and records the task code its body names; for a merged, closed or 90-day-old pull request only the code is recorded, not its state or links. At most ten re-syncs a minute (D-124).
Both alerts reach only a row GAOS has seen with its template from its first look
(BR-64). That first look is the pr.opened event when it plans a card;
when the event plans none — the daily review cap, a skip, a duplicate, the card cap — it is the first poll, which reads
the template before it records the check. A pull request opened while the cap is full is therefore still
checked and still alerted.
Merge write-back
Since v0.89.0 (D-132, BR-63), when a review pull request
that names a task merges, GAOS moves the task’s release status in the bound task
tracker to merged and tells the author. It applies to a product bound to a tracker and listed in
GAOS_PR_TEMPLATE_PRODUCTS, and to GitHub pull requests only.
- Marked at the merge. The poll that sees a review row move from open to merged, or an admin’s re-sync of a row the poller still reads, marks it pending and freezes the task code its body names at that moment, in the same write. A later edit of the body, or a re-sync, never moves that frozen code. A body whose code changed at that very read is refused: the author is told the code changed when the pull request merged, and nothing is recorded. Rows merged before v0.89.0, rows closed unmerged and GitLab rows are never marked.
- Waits for the siblings. The pending rows of one task wait until no other pull request naming the
same task (by code or by its
task:bundle) is open or draft within the poll window. A task is written once, after its last open pull request merges or closes, for as long as that takes. - One call per wait. At the end of each poll pass, GAOS checks the code and the author with a fresh
GetTask, then makes oneRecordMergefor the newest merged row (the carrier), naming its author’s tracker person. The other rows of the wait are grouped and silent. At most five tracker calls a pass; a wait that was tried and is still pending waits five minutes. - Told to the author only. The notice, kind
pr:merged, goes to the carrier’s author: to their contact when they have one and it is a person (a contact that is a group, or empty, keeps it in the bell); with no contact, to their number in the tracker; otherwise to the bell only. It never goes to a group, and it is not a choice on the Contacts page (What is never sent). Every notice is also kept on the Notifications page, without the task link. - Given up after a day. A wait still pending 24 hours after it became ready (the tracker
unavailable, paused, or not yet implementing the method) is skipped, and the author is told GAOS could not
record it. When the cause is one no developer can fix — the tracker does not implement or grant
RecordMerge(nomerge), or refused the credential — the notice stays in the bell.
| Outcome | When | The author gets |
|---|---|---|
| recorded | The tracker set the release status to merged. | PR <pr>, linked to task <code> (<task link>), has been merged; its deployment status is now MERGED |
| already | The task was already at merged or later. | The same, ending its deployment status is already <label> |
| confirm | The task is still in development: the tracker issued a confirmation. | A one-time link (below) |
| refused | The tracker refused; the author has no tracker account or is not assigned; the code changed at the merge; the link could not be sent; or the author rejected. | … has been merged; its deployment status was not changed: <reason> (nothing after a reject) |
| unknown | The tracker does not know the code as a task of the bound product. | The same, with “the task tracker does not know task <code>”, unless the author was already alerted while the pull request was open |
| expired | Nobody answered the link within 24 hours. | The same, with “nobody confirmed within 24 hours” |
| skipped | Still pending 24 hours after the wait became ready. | The same, with “GAOS could not record it within 24 hours” (bell only for nomerge or a refused credential) |
| grouped, off, unchecked | Covered by another row of the wait or by a live link; no usable binding; an answer GAOS cannot read. | Nothing |
The task link in the parenthesis is shown only when it lies under the connection’s web base, and the
tracker’s title, reason and label are kept to one line with every address defanged.
The confirmation link
When the task is still in development, the tracker answers with a one-use nonce and GAOS sends the author, on their
own number in the tracker and nowhere else, a link <GAOS_PUBLIC_URL>/m#<token> on the second line
of the message. The token is 256 random bits; it sits in the URL’s fragment, which a browser never sends to a
server; GAOS stores only its SHA-256. It is used once and expires 24 hours after it is sent; there is at most one
live link per task and person (BR-76). The bell says a link was sent,
without it.
- The page needs no sign-in. It shows the pull request, the task, who is confirming, and two buttons. Opening it changes nothing. Accept asks the tracker to mark the task development-done on the author’s behalf, then merged; the author gets a confirmation on their own number, with “If this was not you, ask your task controller to undo it in the task tracker”. Reject changes nothing in the tracker and ends the link.
- Before an accept GAOS checks again that the binding is unchanged, that the tracker is reachable and that the author is still assigned; otherwise the accept is refused. A tracker that does not answer releases the link for another try after a minute.
- No link is sent, and the author is told why, when
GAOS_PUBLIC_URLis not https, WhatsApp does not serve the product, the author has no WhatsApp number in the tracker, the tracker issued no nonce or does not accept confirmations from GAOS, or the gateway is reached over plain HTTP at a public address — unless the operator setGAOS_WA_CONFIRM_LINK_OVER_HTTP=1(The settings), which sends the link across the network in clear. - The routes
GET /m,POST /m/lookandPOST /m/actare public, refuse another origin, take a body of at most 1 KiB, answer 30 requests a minute per source, and are never cached, indexed or sent with a referrer.
Holding the link is enough to make the one accept: a forwarded or intercepted link acts for its assignee. The tracker’s history marks every such write as made through GAOS by an unauthenticated link holder, and the real person is told on their own number.
On the Integrations view
The task tracker’s connection row reads merge write-back: <state> while GAOS holds its calls:
nomerge (the method is not implemented or granted; retried hourly), asked to stop,
credential refused, unavailable, or confirmations not granted (no link is sent for an
hour). A malformed web file is named on the same row (The
Integrations block).
The settings
Both are fields of POST /products/{id}/autofix, for the accounts on the auto-fix admin list. The post replaces the whole configuration, so a field left out is cleared.
| Field | Meaning |
|---|---|
automationRepos | The repositories (owner/repo, at most 4) where the QA tool opens its pull requests. They are deliberately not the product’s own repositories: a repository there would put the QA tool’s generated pull requests into the review flow. |
allowedBases | The branches (at most 8) a fix pull request may later be moved to. Empty means none. |
Every change of these is recorded in the AutoFixConfigured event with the account’s alias.
Change the base branch
For a draft GAOS opened, the drawer has a Retarget block for the accounts on the auto-fix admin list. GAOS does not edit the pull request. It raises the defect’s generation and plans a related fix task against the chosen base; the AI redoes the fix on that base’s code and a new draft pull request opens against it.
| What happens | Detail |
|---|---|
| Choosing a base | Only the product’s allowedBases, minus the current base; the route checks that the branch exists on GitHub, once, when you press the button. |
| The task | An ordinary fix task of the next generation, titled “(retarget to …)”, with the account, the rule and the reason in its event. It spends the product’s daily fix cap and waits its turn like any fix. |
| The AI | It gets the source of the new base and the previous fix as untrusted data, and the usual limits apply (three files, 40 and 120 lines, allowed paths, the CI check against the new base). |
| The result | A new draft pull request on a branch ending in the generation, linked both ways, with a comment on each; one WhatsApp line marked retarget. |
| The old pull request | Closed by GAOS once the new one is recorded, its branch kept, with a comment that says so (D-108). If GitHub refuses the close, it stays open, the Auto-fix page lists it as a duplicate, and the next restart tries again. Closing or merging it never moves the defect after the new one exists; a merge while the retarget is still pending lands the fix and blocks the retarget task. |
| Limits | At most three retargets of a defect; one at a time; a base removed from allowedBases is refused from then on, even for a task someone unblocks. |
allowedBasesStep 5 runs only after the new pull request is recorded, so a failure never leaves the defect with none open. The full data flow, with the duplicate close, is on Defect auto-fix.
When the button is off, the drawer says why and how to turn it on (not an admin, not a GAOS branch, closed, base not yet known, already retargeted, a task already working, three retargets, no other allowed base).
What it never does
- Merge, mark ready or approve a pull request, or change the base of one it already opened: a retarget opens a new draft instead. It closes only its own drafts that a retarget replaced or an auto-fix admin closed as a duplicate (D-108).
- Read a repository the product does not follow, or build a link from a URL someone else supplied: GitHub links come from the validated owner, repository and number, and the QA link only from the one host GAOS is configured to trust.
- Show GitHub’s text as markup: titles, authors and branch names are plain text, and a title that matches a secret detector is withheld.