Skip to content

feat: Add identity Mixin for Primary Keys #473

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

Merged
merged 4 commits into from
May 8, 2025
Merged

feat: Add identity Mixin for Primary Keys #473

merged 4 commits into from
May 8, 2025

Conversation

cofin
Copy link
Member

@cofin cofin commented May 6, 2025

The sequences based BigInt key offers the most compatibility, but many would prefer to use the Identity column when the database supports it.

This changes implements a basic Identity primary key mixin

@codecov-commenter
Copy link

codecov-commenter commented May 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 88.48%. Comparing base (e626875) to head (db1a2a3).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #473      +/-   ##
==========================================
+ Coverage   88.47%   88.48%   +0.01%     
==========================================
  Files          84       84              
  Lines        5476     5481       +5     
  Branches      678      678              
==========================================
+ Hits         4845     4850       +5     
  Misses        424      424              
  Partials      207      207              

☔ 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.

@cofin cofin force-pushed the big-int-identity branch from 350bc90 to db1a2a3 Compare May 8, 2025 01:30
@cofin cofin merged commit 8d4b59a into main May 8, 2025
15 checks passed
@cofin cofin deleted the big-int-identity branch May 8, 2025 01:30
Copy link

github-actions bot commented May 8, 2025

Documentation preview will be available shortly at https://litestar-org.github.io/advanced-alchemy-docs-preview/473

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: BigIntPrimaryKey does not generate IDENTITY column in PostgreSQL using create_all() with orm_registry
2 participants