Date & Time picker is not working on device.

Bug #1351024 reported by Mihir Soni
26
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Ubuntu Calendar App
Fix Released
Critical
Mihir Soni
Ubuntu UI Toolkit
Invalid
Critical
Zsombor Egri
qtubuntu (Ubuntu)
Fix Released
Critical
Gerry Boland

Bug Description

Steps to Reproduce :-

1) Open Calendar
2) Create new Event
3) Tap on Start date

Expected Result :-

It should open Date selector.

Actual Result :-

It is doing nothing

Related branches

David Planella (dpm)
Changed in ubuntu-calendar-app:
status: New → Triaged
importance: Undecided → High
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

I'd consider this pretty critical. Sadly due to https://code.launchpad.net/bugs/1328600 the test for this is disabled, which means we didn't get to see exactly when or why this stopped working.

Changed in ubuntu-calendar-app:
importance: High → Critical
tags: added: lt-blocker lt-category-visible lt-prio-high
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

Kunal, are you able to have a look at this?

Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

I see following erros when trying to launch time picker, there might be some API change that calendar might needs to adapt or there is some issue with timepicker.

file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Components/Pickers/PickerPanel.qml:203:13: QML DatePicker: Possible anchor loop detected on fill.
file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Components/Pickers/PickerPanel.qml:229: TypeError: Cannot read property 'height' of null
file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Components/Pickers/PickerPanel.qml:200: TypeError: Cannot read property of null
file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Components/Pickers/PickerPanel.qml:198: TypeError: Cannot read property of null
file:///usr/lib/arm-linux-gnueabihf/qt5/qml/Ubuntu/Components/Pickers/PickerPanel.qml:229: TypeError: Cannot read property 'height' of null

Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

looks like something is changed in TimePicker , as calendar code looks fine to me

Revision history for this message
Mihir Soni (mihirsoni) wrote :

We have used PanelPicker for selecting dateTime for an event where in recurrence we have used DatePicker component, i believe that works fine on device too.

Changed in ubuntu-ui-toolkit (Ubuntu):
importance: Undecided → Critical
assignee: nobody → Tim Peeters (tpeeters)
tags: added: rtm14
Revision history for this message
Tim Peeters (tpeeters) wrote :

In UITK, I don't see any changes to date or time picker since the Malta sprint in May, to fix a bug for the switch to Qt 5.3.

Revision history for this message
Tim Peeters (tpeeters) wrote :

^ that's r1080 on UITK staging, 27 May 2014.

Revision history for this message
Tim Peeters (tpeeters) wrote :

Do the date/time picker panels show up in front of everything, or could it be that it is behind the page, and the anchors of the page/mainview are incorrect (see this bug - https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1349366 )?

Changed in ubuntu-ui-toolkit:
assignee: nobody → Zsombor Egri (zsombi)
importance: Undecided → Critical
Revision history for this message
Mihir Soni (mihirsoni) wrote :

Yes, on desktop it shows on bottom edge and front of all other controls and it is not at all visible on device.

Tim Peeters (tpeeters)
Changed in ubuntu-ui-toolkit (Ubuntu):
assignee: Tim Peeters (tpeeters) → nobody
Zsombor Egri (zsombi)
Changed in ubuntu-ui-toolkit (Ubuntu):
assignee: nobody → Zsombor Egri (zsombi)
Zoltan Balogh (bzoltan)
no longer affects: ubuntu-ui-toolkit
affects: ubuntu-ui-toolkit (Ubuntu) → ubuntu-ui-toolkit
Zoltan Balogh (bzoltan)
Changed in ubuntu-ui-toolkit:
status: New → Confirmed
status: Confirmed → In Progress
Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

I'm concerned why this didn't show in the acceptance tests for this feature. Those continue to work and show passing on the dashboard. What is different about them? Can we ensure we have coverage for these pickers? Is the dashboard not showing things properly?

http://ci.ubuntu.com/smokeng/utopic/touch/mako/171:20140805:20140728.1/9484/ubuntuuitoolkit/

Revision history for this message
Zsombor Egri (zsombi) wrote :

DatePicker has AP tests. PickerPanel has no tests.

Revision history for this message
Pat McGowan (pat-mcgowan) wrote :

reverting the whole Qt Compositor landing from #158 to their #157 versions (including removal of those new packages and adding unity-mir back) fixes calendar
Perhaps related to MR https://code.launchpad.net/~andreas-pokorny/mir/fix-1346952-0.5/+merge/228098

Short term we will provide a C++ wrapper for the pickerpanel

Revision history for this message
Gerry Boland (gerboland) wrote :

Quick look appears to indicate that QuickUtils::rootItem returns null in the calendar, causing those QML errors. It should return the root QQuickItem for the view. Will dig tomorrow

Revision history for this message
Nicholas Skaggs (nskaggs) wrote :

Thanks zsombi. I filed a bug to track AP tests for PickerPanel. I would advocate writing tests to cover this before re-merging this code to protect against future regressions.

https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1354138

Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

A little more details in that the Mir landing in #158 was unrelated, it's the Qt Compositor landing (platform-api, unity8, and replacing qtubuntu/unity-mir with qtmir) that's responsible for the changed behavior.

Note that calendar date/time picker does not work perfectly on #157 either - you need to manually hide the keyboard to show the picker. But on #158 and onwards hiding the keyboard reveals only empty space.

Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

"Note that calendar date/time picker does not work perfectly on #157 either - you need to manually hide the keyboard to show the picker."

There is bug[1] on that already, but due to current issue, we are not able resolve it.

[1] https://bugs.launchpad.net/ubuntu-calendar-app/+bug/1338956

Revision history for this message
Gerry Boland (gerboland) wrote :

Looking further into the QuickUtils::rootItem problem, I've figured out that the culprit is a workaround I added to QtUbuntu to avoid https://bugs.launchpad.net/autopilot/+bug/1346633

The workaround sets the following in src/ubuntumirclient/window.h:
    bool isEmbedded(const QPlatformWindow *) const override { return true; }
so that Qt considers the application window an embedded window - i.e. that there is no window system managing it. Thus if Qt wants to find the absulote coordinates for a point inside the window, it will call the Window's mapToGlobal method instead of trying to query a window manager.

However this workaround means that QGuiApplication::topLevelWindows() returns zero, and thus breaks the QuickUtils::rootItem in the SDK.

Changed in qtubuntu:
status: New → Confirmed
Revision history for this message
Gerry Boland (gerboland) wrote :

For the record, I'm working on making a different workaround

Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

With the following:

lp:~timo-jyrinki/ubuntu-ui-toolkit/zsombis-pickerpanel-workaround-with-ftbfs-fixed
lp:~timo-jyrinki/ubuntu-calendar-app/use_pickerpanelworkaround_lp1351024

I still am not able to trigger the date/time picker visible in Calendar app. You should be able to try yourself with:
adb shell
apt-add-repository ppa:canonical-qt5-edgers/qt5-beta1
apt update
apt dist-upgrade
sed -i 's/PickerPanel/PickerPanelWorkaround/' /usr/share/click/preinstalled/com.ubuntu.calendar/current/NewEvent.qml

I'm getting ReferenceError: PickerPanelWorkaround is not defined, but maybe I don't know how it should be used?

Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

I can confirm that Gerry's qtubuntu branch fixes the issue (back to #157 status) for me.

To reproduce:
wget http://people.canonical.com/~tjyrinki/datepicker/qtubuntu-android_0.60+14.10.20140728+fix1351024-0ubuntu1_armhf.deb
dpkg -i qtubuntu-android_0.60+14.10.20140728+fix1351024-0ubuntu1_armhf.deb
reboot

Changed in qtubuntu:
assignee: nobody → Gerry Boland (gerboland)
importance: Undecided → Critical
Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

Now in landing PPA:

apt-add-repository ppa:ci-train-ppa-service/landing-015
apt update
apt install qtubuntu-android
reboot

Gerry Boland (gerboland)
Changed in qtubuntu:
status: Confirmed → In Progress
Changed in ubuntu-calendar-app:
status: Triaged → Invalid
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qtubuntu - 0.60+14.10.20140808.1-0ubuntu1

---------------
qtubuntu (0.60+14.10.20140808.1-0ubuntu1) utopic; urgency=low

  [ Gerry Boland ]
  * Workaround for bug 1346633 broke QGuiApplication::topLevelWindows(),
    perform a different workaround. This workaround guesses the window
    geometry relative to the screen (mainly setting y=panelHeight),
    defining it using QPlatformWindow::setGeometry and then Qt uses it
    to calculate mapToGlobal internally (LP: #1351024, #1346633)
 -- Ubuntu daily release <email address hidden> Fri, 08 Aug 2014 14:10:40 +0000

Changed in qtubuntu (Ubuntu):
status: New → Fix Released
Zsombor Egri (zsombi)
Changed in ubuntu-ui-toolkit:
status: In Progress → Invalid
kevin gunn (kgunn72)
Changed in qtubuntu:
status: In Progress → Fix Released
Revision history for this message
Tomas Öqvist (tomoqv) wrote :

I believe this bug has to be reopened. I can't trigger the date or time picker anymore since one of the recent updates. I am now on devel-proposed #237 on a Nexus 4.

Revision history for this message
Zsombor Egri (zsombi) wrote :

From UITK side the only modification we did was to make the PickerPanel and UbuntuColors to be instantiated as proper QML singletons. The change has been tested on the device, and everything was working perfectly. However the Calendar app wasnát looking like now in 237, so either the Calendar app or QtUbuntu has something with the singleton.

Revision history for this message
Zsombor Egri (zsombi) wrote :
Download full text (4.9 KiB)

I rigged further, and seems we have a problem with Qt defining the singletons, or there is something in our backend which makes the PickerPanel singleton to be instantiable.
There was a change in UITK which brought the proper instantiation of QML singletons. This affected UbuntuColors and PickerPanel. UbuntuColors works well (you can see every app using it, components using it) but fro some reason when PickerPanel is about to be used, it said cannot find it. See logs below:

libust[21858/21860]: Error: Error opening shm /lttng-ust-wait-5 (in get_wait_shm() at lttng-ust-comm.c:886)
libust[21858/21860]: Error: Error opening shm /lttng-ust-wait-5 (in get_wait_shm() at lttng-ust-comm.c:886)
libust[21858/21861]: Error: Error opening shm /lttng-ust-wait-5-32011 (in get_wait_shm() at lttng-ust-comm.c:886)
libust[21858/21861]: Error: Error opening shm /lttng-ust-wait-5-32011 (in get_wait_shm() at lttng-ust-comm.c:886)

(process:21858): dconf-CRITICAL **: unable to create file '/run/user/32011/dconf/user': Permission denied. dconf will not work properly.

(process:21858): dconf-CRITICAL **: unable to create file '/run/user/32011/dconf/user': Permission denied. dconf will not work properly.

(process:21858): dconf-CRITICAL **: unable to create file '/run/user/32011/dconf/user': Permission denied. dconf will not work properly.
<Unknown File>: Invalid empty URL
UbuntuWindow - regular geometry
UbuntuWindow::handleSurfaceFocusChange(focused=true)
UbuntuWindow::handleSurfaceResize(width=768, height=1226)
QQmlComponent: Created graphical object was not placed in the graphics scene.
QQmlComponent: Created graphical object was not placed in the graphics scene.
QQmlComponent: Created graphical object was not placed in the graphics scene.
virtual QtOrganizer::QOrganizerCollection QOrganizerEDSEngine::defaultCollection(QtOrganizer::QOrganizerManager::Error*) Not implemented
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.calendar/0.4.441/NewEvent.qml:238: ReferenceError: PickerPanel is not defined
file:///usr/share/click/preinstalled/com.ubuntu.c...

Read more...

Mihir Soni (mihirsoni)
Changed in ubuntu-calendar-app:
status: Invalid → Confirmed
assignee: nobody → Mihir Soni (mihirsoni)
milestone: none → rtm14
status: Confirmed → In Progress
Revision history for this message
Nekhelesh Ramananthan (nik90) wrote :

We recently redesigned the new event page. It seems we missed an import statement there which caused the issue. We just fixed and pushed into trunk. Should land in a hot-fix update asap.

Changed in ubuntu-calendar-app:
status: In Progress → Fix Committed
Changed in ubuntu-calendar-app:
status: Fix Committed → Fix Released
Michał Sawicz (saviq)
Changed in qtubuntu (Ubuntu):
assignee: nobody → Gerry Boland (gerboland)
importance: Undecided → Critical
no longer affects: qtubuntu
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.