Date & Time picker is not working on device.

Bug #1351024 reported by Mihir Soni on 2014-07-31
26
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Ubuntu Calendar App
Critical
Mihir Soni
Ubuntu UI Toolkit
Invalid
Critical
Zsombor Egri
qtubuntu (Ubuntu)
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) on 2014-07-31
Changed in ubuntu-calendar-app:
status: New → Triaged
importance: Undecided → High
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
Nicholas Skaggs (nskaggs) wrote :

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

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

Kunal Parmar (pkunal-parmar) wrote :

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

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
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.

Tim Peeters (tpeeters) wrote :

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

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
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) on 2014-08-06
Changed in ubuntu-ui-toolkit (Ubuntu):
assignee: Tim Peeters (tpeeters) → nobody
Zsombor Egri (zsombi) on 2014-08-06
Changed in ubuntu-ui-toolkit (Ubuntu):
assignee: nobody → Zsombor Egri (zsombi)
Zoltan Balogh (bzoltan) on 2014-08-06
no longer affects: ubuntu-ui-toolkit
affects: ubuntu-ui-toolkit (Ubuntu) → ubuntu-ui-toolkit
Zoltan Balogh (bzoltan) on 2014-08-06
Changed in ubuntu-ui-toolkit:
status: New → Confirmed
status: Confirmed → In Progress
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/

Zsombor Egri (zsombi) wrote :

DatePicker has AP tests. PickerPanel has no tests.

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

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

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

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.

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

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
Gerry Boland (gerboland) wrote :

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

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?

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
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) on 2014-08-08
Changed in qtubuntu:
status: Confirmed → In Progress
Changed in ubuntu-calendar-app:
status: Triaged → Invalid
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) on 2014-08-11
Changed in ubuntu-ui-toolkit:
status: In Progress → Invalid
kevin gunn (kgunn72) on 2014-09-02
Changed in qtubuntu:
status: In Progress → Fix Released
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.

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.

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) on 2014-09-12
Changed in ubuntu-calendar-app:
status: Invalid → Confirmed
assignee: nobody → Mihir Soni (mihirsoni)
milestone: none → rtm14
status: Confirmed → In Progress
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) on 2017-03-13
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  Edit
Everyone can see this information.

Other bug subscribers