GitHub Issues

The ticket system: where your tickets live, with their labels, their comments, and which one waits on another.

What the factory uses it for

A ticket is an issue. Refinement writes the spec into its body, a session comments on it as it works, and the pull request that resolves it closes it when it merges.

You need

A GitHub repository with Issues turned on: on GitHub, Settings, General, Features, check "Issues".

Set it up

factory init needs nothing more for tickets. It reads issues through the GitHub CLI you signed in with (Set up a repository).

Optionally, a factory field can live in a field of the ticket rather than in its description. A factory field is a section refinement writes, such as the Spec or the Decisions, and tickets.fields says which ticket field holds each. Here a ticket field is an issue field, shown beside the issue. You create it in your account's or your organization's settings, under Issue fields. Create it before you run factory init, which offers only the fields that exist (Your tickets already have fields). Without one, each factory field stays in the description.

What setup adds

The labels the factory uses. Setup makes policy-override when you turn on an approval policy, and the factory makes each of the others the first time it needs it, such as factory on each ticket it works on and spec on a change your users will see. Labels, statuses, and checks lists them, and tickets.labels renames them.

Tokens and secrets

None of its own: on your machine the factory reaches issues with the same sign-in it uses for the repository, and in the cloud with the same token or App as the rest of the run (GitHub).

What the factory can and cannot do there

  • It records that one ticket waits on another as a "blocked by" relationship, which shows in each issue's sidebar (Write a ticket).
  • It closes a ticket through its pull request, whose body starts with the line factory ticket link 12 prints, such as Closes #12.
  • It works only on issues with its label (Write a ticket).
  • A ticket's key is its issue number, such as 12, which is what the factory ticket commands take as N.
  • What it records on a ticket is a comment on the issue: the note the poller leaves before it starts a build, saying a build is starting, and what a session records for the board sync, such as claiming the ticket or what it cost (The fields the sync writes).
  • Its labels are the repository's, serving its issues and its pull requests alike, so a name under tickets.labels can't match one under code-host.labels.

Limits that come from GitHub

A pull request closes an issue only in the repository it merges into, so a ticket across repositories closes when the last of its pull requests merges (A ticket across repositories).

An issue field shows its text as typed, without Markdown formatting, so a factory field written into one, such as a Spec, reads as written: a list keeps its numbers and dashes, and a table shows its | marks.

When something goes wrong

A ticket that does not close when its pull request merges: check that factory pr closes 15 prints the ticket's number. If it prints nothing, the pull request's first line does not link it.

By hand

To rename a label that tickets already carry, open the repository's Issues, then Labels, and choose Edit on the label. Give it the name you wrote under tickets.labels. That moves every ticket that has it.

Edit this page on GitHub