Skip to content

v0.5.5 - Reflex Type Compatibility Fix

Choose a tag to compare

@izzoa izzoa released this 12 Mar 23:05
· 41 commits to master since this release

Fixed

Docker Startup Crash (UntypedVarError)

  • Reflex rejected Dict[str, Any] typed state vars in rx.foreach calls, causing the Docker image to crash at startup
  • All state dict values now converted to dict[str, str] via _str_dict() helper across LibraryState, GeneratorState, HistoryState, and TaggingState

Optional Type Deprecation Warnings

  • Optional[int] year filter state vars triggered Reflex deprecation warnings when None was passed to UI components
  • Changed to str = "" with explicit int() conversion at DB query boundaries

has_embedding Badge

  • After string coercion, "0" was truthy and incorrectly showed a green "Yes" badge in the library track table
  • Now uses explicit == "1" comparison

Files Changed

  • src/plexmix/ui/states/library_state.py — state var types + _str_dict conversion
  • src/plexmix/ui/states/generator_state.py — state var types + _str_dict conversion
  • src/plexmix/ui/states/history_state.py — state var types + _str_dict conversion
  • src/plexmix/ui/states/tagging_state.py — state var types + _str_dict conversion
  • src/plexmix/ui/components/track_table.py — type hints + has_embedding fix
  • src/plexmix/ui/pages/history.py — parameter type update
  • tests/ui/test_states.py — all assertions updated for string types

Testing

All 315 tests passing ✅