Skip to content

v4.1.1 - Critical Bug Fixes

Choose a tag to compare

@piterkos piterkos released this 11 Oct 22:15
· 9 commits to master since this release

Critical Bug Fixes

This release fixes critical errors that prevented calendar entities from loading and caused crashes in lessons fetching.

Fixed Issues

Calendar Entities (TypeError)

  • Fixed TypeError: 'coroutine' object is not subscriptable in calendar.py
  • Changed event property from async to synchronous implementation
  • Added _create_calendar_event() method to each calendar entity subclass
  • Calendar entities now properly load without errors

Lessons Fetching (AttributeError)

  • Fixed AttributeError when accessing changes.type and changes.id
  • Changed from object notation to dict notation throughout changes handling
  • Fixed lesson.time.position to use time.get('position')
  • Now properly handles None and dict types for changes data

Installation

  1. Update via HACS (Redownload)
  2. Restart Home Assistant
  3. Calendar entities and lesson sensors should now work correctly

Technical Details

Files Modified:

  • calendar.py - Fixed async event property, added synchronous event handling
  • fetch_data.py - Fixed object notation in changes handling (lines 69-95)

Error Messages Resolved:

  • RuntimeWarning: coroutine LibrusLessonsCalendarEntity.async_get_events was never awaited
  • TypeError: coroutine object is not subscriptable
  • AttributeError: dict object has no attribute type
  • Error adding entity calendar.jan_kowalski_lessons_lessons

All calendar and lesson entities should now load properly!