Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add PGCMP Workflow #698

Merged
merged 3 commits into from
Mar 4, 2023
Merged

Add PGCMP Workflow #698

merged 3 commits into from
Mar 4, 2023

Conversation

Mythicaeda
Copy link
Contributor

Description

Added a workflow to:

  1. Build the version of the DB from 1.0.1 (the base version for migrations), migrate it to current, then dump it
  2. Build the version of the DB on the current branch, then dump it
  3. Use pgcmp to compare the dumps for equality
  4. Upload the results of pgcmp should at least one comparison fail.

Verification

Successful running on this branch should indicate if it's working.

Future work

Potentially refine the script to only look at the changes between develop and the migration defined in the PR.

@Mythicaeda Mythicaeda added the ci Changes to our CI configuration files and scripts label Mar 1, 2023
@Mythicaeda Mythicaeda requested a review from mattdailis March 1, 2023 01:41
@Mythicaeda Mythicaeda self-assigned this Mar 1, 2023
@Mythicaeda Mythicaeda requested a review from a team as a code owner March 1, 2023 01:41
@Mythicaeda Mythicaeda requested a review from cohansen March 1, 2023 01:41
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 01:41 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda requested a review from skovati March 1, 2023 01:42
Copy link
Contributor

@cohansen cohansen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me, I ran locally and Aerie ran successfully.

It looks like there's some failed checks though, and 1 remove before merge.

.github/workflows/pgcmp.yml Outdated Show resolved Hide resolved
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 16:25 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 16:29 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from ad93742 to cc8af12 Compare March 1, 2023 16:34
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 16:34 — with GitHub Actions Inactive
@Mythicaeda
Copy link
Contributor Author

Looks fine to me, I ran locally and Aerie ran successfully.
You ran the workflow locally or you deployed Aerie from this branch successfully? Double-checking because this PR is adding a workflow to Aerie, not modifying any existing Aerie code

@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from cc8af12 to 7f3e48f Compare March 1, 2023 16:38
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 16:39 — with GitHub Actions Inactive
@cohansen
Copy link
Contributor

cohansen commented Mar 1, 2023

Looks fine to me, I ran locally and Aerie ran successfully.
You ran the workflow locally or you deployed Aerie from this branch successfully? Double-checking because this PR is adding a workflow to Aerie, not modifying any existing Aerie code

Ah, I misunderstood your instructions. I ran Aerie locally which I guess doesn't test this workflow. My comment above was because I saw some of the checks had failed against this branch.

@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 1, 2023 17:31 — with GitHub Actions Inactive
@Mythicaeda
Copy link
Contributor Author

Ah, I misunderstood your instructions. I ran Aerie locally which I guess doesn't test this workflow. My comment above was because I saw some of the checks had failed against this branch.

Yeah, that failing check is actually the one being added

@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 19:20 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from 3f2d6dd to 7d50ed7 Compare March 3, 2023 19:37
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 19:37 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 19:37 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 19:37 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:19 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:19 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:19 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from 198bc36 to a16c840 Compare March 3, 2023 20:30
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:30 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:30 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:30 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from a16c840 to 96e916a Compare March 3, 2023 20:47
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:47 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:47 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 20:47 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from 96e916a to 1da5f9c Compare March 3, 2023 21:02
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 21:02 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 21:02 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 3, 2023 21:02 — with GitHub Actions Inactive
Copy link
Contributor

@cohansen cohansen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great and the checks passed! 🎉

* Check both up and down migrations for equality
* Add explanations for unrevertable migrations schema
@Mythicaeda Mythicaeda force-pushed the feat/pgcmp-workflow branch from 1da5f9c to 16f2bf4 Compare March 4, 2023 00:14
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 4, 2023 00:14 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 4, 2023 00:14 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda temporarily deployed to e2e-test March 4, 2023 00:14 — with GitHub Actions Inactive
@Mythicaeda Mythicaeda merged commit bce7525 into develop Mar 4, 2023
@Mythicaeda Mythicaeda deleted the feat/pgcmp-workflow branch March 4, 2023 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci Changes to our CI configuration files and scripts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use pgcmp to compare migrations
2 participants