Skip to content

Add migration checksum validation for sequential migrations #6

@CaliLuke

Description

@CaliLuke

Store a SHA256 checksum of each migration's up/down TypeQL when recording it as applied. On subsequent runs, validate that previously-applied migrations haven't been tampered with.

Add a Checksum field to SeqMigrationRecord, compute it in Record(), and verify in Applied(). Raise SeqMigrationError on mismatch.

Files: gotype/seq_migrate_state.go, gotype/seq_migrate.go, gotype/seq_migrate_test.go

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions