Skip to content

fix: fall back to a local StrEnum on Python < 3.11 - #101

Open
tedil wants to merge 2 commits into
mainfrom
fix/strenum-fallback
Open

tedil wants to merge 2 commits into
mainfrom
fix/strenum-fallback

Conversation

@tedil

@tedil tedil commented Oct 23, 2026

Copy link
Copy Markdown

io.py imported enum.StrEnum, which only exists on Python 3.11+, although the package declares >=3.8. Snakemake imports this module in script jobs running under the job's conda env interpreter, so older envs failed with an ImportError. On Python < 3.11, io.py now defines a minimal StrEnum(str, Enum) with the same str() behavior.

Fixes #99.

I used AI assistance for code generation, tests, and research.

@coderabbitai

coderabbitai Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 6a9dd893-839e-491c-bd3c-39db66863f91
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@tedil
tedil marked this pull request as ready for review October 23, 2026 11:19
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.

io.py needs python 3.11 for StrEnum, which breaks older envs

1 participant