DocsErrors and AI

Fix proposals

From a triaged issue, Watchdock drafts the code change and, when you approve it, opens a pull request on a new branch. You review a patch instead of starting from a blank editor.

4 min readTeamNeeds GitHub
TeamFix proposals are on the Team plan and need GitHub connected to the issue's project.

Open Integrations › GitHub, connect the app, and link the project to its repo. Proposals are written against the file the stack trace points at, read from your repo's default branch.

2Propose a fix

Open an issue and press Propose a fix. Watchdock finds the file the top frame of the stack trace points at, reads the whole file rather than just the line, and drafts the smallest change that fixes the error. It works best on an issue that's already been triaged, but doesn't need it.

3Review it

Press Review fix. The drawer shows the diff, the file and an explanation of the change. Nothing has touched your repo yet. Read it the way you'd read any pull request.

  • Approve & open PR creates a branch from your default branch, commits the change there and opens a pull request with a written description. Your approval is recorded on the PR.
  • Reject discards it. You can propose a new fix at any time.

Watchdock never pushes to your default branch and never merges. Every change lands as a pull request your team reviews and merges like any other.

After you merge

Watchdock follows the pull request through GitHub:

  • Merged: the issue is resolved automatically, and a GitHub issue linked to it is closed.
  • Closed without merging: the proposal is marked closed and the issue stays open.

Both show up in the issue's activity and in Recent activity on the GitHub page.

Limits

  • Files over 800 lines aren't attempted. Very large files are where a generated patch is least trustworthy.
  • If a draft doesn't apply cleanly to the current file, it retries once before giving up.
  • A proposal still generating after 5 minutes has stalled. Propose a new fix instead of waiting.

Troubleshooting

The proposal failed with a GitHub error

Creating the branch, commit or pull request failed on GitHub's side. Check the GitHub app still has access to the repo, and that branch protection doesn't block it from reading the default branch.

It couldn't find the file

The path in the stack trace has to exist in the linked repo. Check the project is linked to the repo the code actually lives in. Errors raised inside a dependency have no file of yours to change.

It says there's no stack frame

The issue has no frame from your code to fix, like a message captured with capture_message. Fix proposals need an exception with a stack trace.

No fix was proposed

Check the file's size. Files over 800 lines are skipped by design.

The diff looks out of date

The draft is based on the file as it was when you proposed it. If the file has changed a lot since, propose a new fix rather than approving the old one.