Bug 470801

Summary: calendar/InfiniteList.qml:88: TypeError: Value is null and could not be converted to an object
Product: [Plasma] plasmashell Reporter: Nate Graham <nate>
Component: Digital Clock widgetAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: tantalising007
Priority: NOR Keywords: qt6
Version First Reported In: master   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Nate Graham 2023-06-08 19:04:07 UTC
Also for line 93.

Seen in journal logs for Plasmashell on Plasma 6 Wayland git master.

Relevant code in InfiniteList.qml does this:

        switch(infiniteList.viewType) {
            case InfiniteList.ViewType.DayView:
                infiniteList.itemAtIndex(0).gridModel = previousAlternativeBackend.item.daysModel;
                infiniteList.itemAtIndex(2).gridModel = nextAlternativeBackend.item.daysModel;
                break;

            case InfiniteList.ViewType.DecadeView:
                infiniteList.itemAtIndex(0).gridModel = previousYearModel.item;
                infiniteList.itemAtIndex(2).gridModel = nextYearModel.item;
                break;
        }

My guess is that itemAtIndex(0) is null at the moment it's called.
Comment 1 Nate Graham 2023-10-27 16:24:05 UTC
Fixed now.