DATA OPS

Snowflake Table Contract Drift to GitHub Migration PR

On a schedule, snapshots the live schema of tracked Snowflake tables, diffs it against the committed contract.

CategoryData Ops
Enginesim
Difficultyintermediate
Triggerschedule
Steps5
Setup~15 min

How it runs

The automated pipeline, trigger to output.

  • TriggerDaily schedule fires
  • ActionQuery Snowflake INFORMATION_SCHEMA for tracked tablesSnowflakeSnowflake
  • LogicDiff live schema vs committed contract; stop if no drift
  • ActionCommit regenerated contract to a new branchGitHubGitHub
  • OutputOpen GitHub PR with diff summary and table labelsGitHubGitHub

What it does

Keeps a versioned "contract" file for each tracked Snowflake table in your repo and continuously checks that the warehouse still matches it. When the live schema diverges (a column added, dropped, renamed, or retyped), it writes the updated contract and opens a GitHub pull request so the change goes through review instead of landing silently.

When to use it

Use it when analytics or product engineers can ALTER tables faster than your dbt models and downstream consumers can keep up. It turns invisible warehouse drift into a reviewable code change with a clear owner.

How it works

  1. 1A daily schedule fires the run.
  2. 2The workflow queries `INFORMATION_SCHEMA.COLUMNS` in Snowflake for every table on the watch list.
  3. 3It compares the live shape against the checked-in contract YAML and computes a structured diff.
  4. 4A logic step exits early if the diff is empty — no noise on clean days.
  5. 5When drift exists, it commits the regenerated contract to a new branch and opens a GitHub PR with the diff summarized in the body and the affected tables labeled.

Set it up

What you configure once, before turning it on.

  1. 1
    Connect SnowflakeWarehouses, queries, shares.
  2. 2
    Connect GitHubRepos, issues, pull requests, actions.
  3. 3
    Set each agent's modelWe leave models unset so you pick the tier — fast + cheap, or top-quality.
  4. 4
    Tune it to your dataEdit the prompts, filters, and field mappings so it matches how your team works.
  5. 5
    Test, then turn it onRun once against a sample, confirm the output, then enable the trigger.

Run this workflow in your colony.

14-day trial. No DevOps. No Sales call. Provisioned in under a minute.