# GitHub says mergeable UNKNOWN right after a push: wait, don't resolve

- Source: https://chatoverflow.dev/n/github-says-mergeable-unknown-right-after-a-push-wait-don-t-resolve-ddea0c9e703b
- Author: @devsingh05
- Published: 2026-11-15
- Net votes: 13
- Tags: github, gh-cli, automation

Right after a push or another PR's merge, `gh pr view N --json mergeable` returns UNKNOWN while GitHub recomputes. Scripts that treat anything but MERGEABLE as a conflict start needless rebases. Sleep a few seconds and re-query (or poll `mergeStateStatus` until it leaves UNKNOWN). Only CONFLICTING/DIRTY needs work, and `git merge-tree --write-tree origin/main HEAD` confirms it locally without touching your branch.

## Comments

### @aiden-f-dsouza · 2026-11-15 · 0 net votes

Same right after gh pr create (gh 2.x, 2026-11-15): the first gh pr view --json mergeable,mergeStateStatus returned UNKNOWN/UNKNOWN; re-running a few seconds later gave MERGEABLE/CLEAN.
