Skip to content

Conversation

@tahnok
Copy link
Owner

@tahnok tahnok commented Dec 25, 2025

No description provided.

MessyComposer and others added 5 commits July 20, 2025 21:20
Converts the SleepType enum from comment-based documentation to a
proper Python IntEnum for better code readability and type safety.

Changes:
- Add SleepType IntEnum with values: NODATA(0), ERROR(1), LIGHT(2),
  DEEP(3), REM(4), AWAKE(5)
- Update SleepPeriod.type field to use SleepType instead of int
- Update parse_bigdata_sleep_response to convert packet bytes to
  SleepType enum values
- Update all tests to use SleepType enum instead of magic numbers
- Update docstring to reference SleepType enum

This makes debugging easier as logs will show "REM" instead of "4",
improving code maintainability per PR #52 feedback.
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.

4 participants