Skip to content

Fix StrEnum usage for Python 3.10 compatibility#1056

Merged
edwinyyyu merged 1 commit into
MemMachine:mainfrom
edwinyyyu:claude/fix-strenum-python310-HYpnk
Feb 5, 2026
Merged

Fix StrEnum usage for Python 3.10 compatibility#1056
edwinyyyu merged 1 commit into
MemMachine:mainfrom
edwinyyyu:claude/fix-strenum-python310-HYpnk

Conversation

@edwinyyyu

@edwinyyyu edwinyyyu commented Feb 5, 2026

Copy link
Copy Markdown
Contributor

This should be a temporary fix until #1052 is done.

Note: Written by Claude Code on the web with this prompt:

The client is meant to support Python 3.10. StrEnum was introduced in 3.11. Please change StrEnum inheritances to str, Enum.

The repo uses uv and ruff.
Downgrade ruff to ~=0.14 instead of 0.15 so that it does not complain about using str, Enum instead of StrEnum.

Description generated by Claude Code:

Replace StrEnum (Python 3.11+) with str, Enum in ResourceStatus and SupportedDB so the shared code works on Python 3.10. Downgrade ruff from ~=0.15 to ~=0.14 to avoid UP042 flagging the str, Enum pattern.

https://claude.ai/code/session_01BY2h2Mejn1FaechszWRtkC

Replace `StrEnum` (Python 3.11+) with `str, Enum` in ResourceStatus and
SupportedDB so the shared code works on Python 3.10. Downgrade ruff from
~=0.15 to ~=0.14 to avoid UP042 flagging the `str, Enum` pattern.

https://claude.ai/code/session_01BY2h2Mejn1FaechszWRtkC

@o-love o-love left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Approve while waiting for proper fix in #1052

@edwinyyyu edwinyyyu merged commit b4ffdd0 into MemMachine:main Feb 5, 2026
41 checks passed
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.

[Bug]: Test python client package imports with python 3.10 always fail

4 participants