Skip to content

Conversation

@ilovelinux
Copy link
Contributor

This PR:

  • Add support for StrEnum and IntEnum
  • Uses specialized enum class by default if they are supported by the target Python version
  • Add --[no-]use-specialized-enum CLI parameter and configuration value to enable/disable the feature

Warning

Since this feature is opt-out, this PR introduces a breaking change!

Users can still opt-out:

  • Using --no-use-specialized-enum CLI flag
  • Setting use_specialized_enum = false in the configuration

Closes #1313

@codspeed-hq
Copy link

codspeed-hq bot commented Oct 11, 2025

CodSpeed Performance Report

Merging #2512 will not alter performance

Comparing ilovelinux:feat/ilovelinux-1313-add-support-for-specialized-enums (8108c19) with main (9d83669)

Summary

✅ 32 untouched

@codecov
Copy link

codecov bot commented Oct 11, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 97.68%. Comparing base (9d83669) to head (8108c19).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2512      +/-   ##
==========================================
+ Coverage   97.66%   97.68%   +0.01%     
==========================================
  Files          68       68              
  Lines        8180     8246      +66     
  Branches      856      858       +2     
==========================================
+ Hits         7989     8055      +66     
  Misses        145      145              
  Partials       46       46              
Flag Coverage Δ
unittests 97.68% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for base class for enums

1 participant