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 semantic version type #199

Merged
merged 22 commits into from
Jul 25, 2024
Merged

Conversation

jbkroner
Copy link
Contributor

@jbkroner jbkroner commented Jul 22, 2024

Adding a semantic version type as requested in #2506 in the pydantic repo.

The implementation here is just the example from the python-semver docs + some additional tests.

When this PR gets a thumbs up I will update the docs in python-semver.

Any feedback appreciated, cheers.

edit: tracking on coverage and 3.8 compatibility issues, will try to get that covered early this week before marking as ready for review.

Selected Reviewer: @yezz123

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (e186814) to head (563284f).
Report is 38 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##              main      #199    +/-   ##
==========================================
  Coverage   100.00%   100.00%            
==========================================
  Files           11        17     +6     
  Lines          685       960   +275     
  Branches       169       232    +63     
==========================================
+ Hits           685       960   +275     

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

@jbkroner jbkroner marked this pull request as ready for review July 23, 2024 23:24
@jbkroner
Copy link
Contributor Author

please review

Copy link
Collaborator

@yezz123 yezz123 left a comment

Choose a reason for hiding this comment

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

Hey, @jbkroner can you please address these small enhancements, I would be happy to merge this PR after!

Thanks 👍🏻

tests/test_semver.py Outdated Show resolved Hide resolved
pydantic_extra_types/semver.py Outdated Show resolved Hide resolved
@jbkroner
Copy link
Contributor Author

@yezz123 fixes applied. apologies for the extra commits - didn't click that I could run the linter / pre-commit stuff locally (duh) following the instructions in the main pydantic repo.

@yezz123
Copy link
Collaborator

yezz123 commented Jul 25, 2024

@yezz123 fixes applied. apologies for the extra commits - didn't click that I could run the linter / pre-commit stuff locally (duh) following the instructions in the main pydantic repo.

No Problem now we have it ready we can merge it, Thanks for the great work @jbkroner 🚀

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.

2 participants