Skip to content

database migrations#457

Merged
ericbuckley merged 21 commits into
mainfrom
feature/450-migrations-take-2
Jul 8, 2025
Merged

database migrations#457
ericbuckley merged 21 commits into
mainfrom
feature/450-migrations-take-2

Conversation

@ericbuckley

@ericbuckley ericbuckley commented Jul 7, 2025

Copy link
Copy Markdown
Collaborator

Description

Add alembic to handle database migrations.

Related Issues

closes #450

Additional Notes

  • No alembic.ini file was added (this is typically the default), instead all the configuration logic was added to pyproject.toml. Minor changes were made to the production and development logging configuration to support emitting alembic messages.
  • The INITIALIZE_TABLES bool env variable was added so users can disable auto creation of database tables (the default is set to true).
  • The TracebackMiddleware class was added to properly log uncaught exception tracebacks before returning an "Internal Server Error" message to the user.
    <--------------------- REMOVE THE LINES BELOW BEFORE MERGING --------------------->

Checklist

Please review and complete the following checklist before submitting your pull request:

  • I have ensured that the pull request is of a manageable size, allowing it to be reviewed within a single session.
  • I have reviewed my changes to ensure they are clear, concise, and well-documented.
  • I have updated the documentation, if applicable.
  • I have added or updated test cases to cover my changes, if applicable.
  • I have minimized the number of reviewers to include only those essential for the review.

Checklist for Reviewers

Please review and complete the following checklist during the review process:

  • The code follows best practices and conventions.
  • The changes implement the desired functionality or fix the reported issue.
  • The tests cover the new changes and pass successfully.
  • Any potential edge cases or error scenarios have been considered.

@ericbuckley ericbuckley self-assigned this Jul 7, 2025
@ericbuckley ericbuckley added the qa Technical improvements to increase code quality label Jul 7, 2025
@codecov

codecov Bot commented Jul 7, 2025

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.45%. Comparing base (a4a3a91) to head (f1425a7).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #457      +/-   ##
==========================================
+ Coverage   98.44%   98.45%   +0.01%     
==========================================
  Files          41       41              
  Lines        2318     2337      +19     
==========================================
+ Hits         2282     2301      +19     
  Misses         36       36              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@ericbuckley ericbuckley marked this pull request as ready for review July 7, 2025 23:48

@m-goggins m-goggins left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looks good, thanks for the hard work on this! Our future selves will be thankful if we ever need it

Comment thread migrations/README.md Outdated
Comment thread migrations/README.md Outdated
ericbuckley and others added 2 commits July 8, 2025 16:52
Co-authored-by: Marcelle <53578688+m-goggins@users.noreply.github.com>
Co-authored-by: Marcelle <53578688+m-goggins@users.noreply.github.com>
@ericbuckley ericbuckley merged commit 5b7ee69 into main Jul 8, 2025
15 checks passed
@ericbuckley ericbuckley deleted the feature/450-migrations-take-2 branch July 8, 2025 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

qa Technical improvements to increase code quality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

database migrations

2 participants