Value type enums are not exposed to QML with Qt5.5

Bug #1532135 reported by Olivier Tilloy on 2016-01-08
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Oxide
Critical
Chris Coulson
1.11
Critical
Chris Coulson
1.12
Critical
Chris Coulson
oxide-qt (Ubuntu)
Critical
Olivier Tilloy

Bug Description

When launching webbrowser-app in a clean and up-to-date xenial desktop VM, I’m seeing the following messages in the console:

file:///usr/lib/x86_64-linux-gnu/qt5/qml/Ubuntu/Web/UbuntuWebView02.qml:142: TypeError: Cannot read property 'TypeFailed' of undefined
file:///usr/lib/x86_64-linux-gnu/qt5/qml/Ubuntu/Web/UbuntuWebView02.qml:141: TypeError: Cannot read property 'TypeStopped' of undefined
file:///usr/lib/x86_64-linux-gnu/qt5/qml/Ubuntu/Web/UbuntuWebView02.qml:140: TypeError: Cannot read property 'TypeSucceeded' of undefined
file:///usr/share/webbrowser-app/webbrowser/Browser.qml:1196: TypeError: Cannot read property 'TypeCommitted' of undefined
file:///usr/share/webbrowser-app/ChromeController.qml:78: TypeError: Cannot read property 'TypeStarted' of undefined

(I’m seeing multiple instances of each message)

oxide version 1.11.3-0ubuntu3 is installed

Olivier Tilloy (osomon) wrote :

Note that the browser seems to otherwise work well, but as expected because of these errors the history database is not being populated.

Changed in webbrowser-app (Ubuntu):
importance: Undecided → Critical
assignee: nobody → Olivier Tilloy (osomon)
Olivier Tilloy (osomon) wrote :

I’m not seeing that error with the same version of oxide (1.11.3-0ubuntu0.15.10.1) on wily.

Olivier Tilloy (osomon) wrote :

It appears that types that inherit QQmlValueType are not exposed any longer with Qt 5.5.
This can be observed with this simple piece of QML code:

  import QtQuick 2.4
  import com.canonical.Oxide 1.11 as Oxide
  Item {
    Component.onCompleted: {
      console.log(Oxide.SecurityStatus) // is a QObject, prints "[object Object]"
      console.log(Oxide.SecurityStatus.SecurityLevelError) // prints "4"
      console.log(Oxide.LoadEvent) // is a QQmlValueType, prints "undefined"
      console.log(Oxide.SslCertificate) // is a QQmlValueType, prints "undefined"
    }
  }

affects: webbrowser-app (Ubuntu) → oxide-qt (Ubuntu)
summary: - [desktop] On xenial, multiple TypeError messages when starting browser
+ On xenial, types that inherit QQmlValueType are not exposed

Duplicate of bug #1488364 ?

summary: - On xenial, types that inherit QQmlValueType are not exposed
+ Types that inherit QQmlValueType are not exposed
summary: - Types that inherit QQmlValueType are not exposed
+ Types that inherit QQmlValueType are not exposed to QML

It's not a duplicate - this is a separate issue. I've updated the title accordingly

summary: - Types that inherit QQmlValueType are not exposed to QML
+ Value type enums are not exposed to QML
Changed in oxide:
milestone: none → branch-1.13
assignee: nobody → Chris Coulson (chrisccoulson)
importance: Undecided → Critical
status: New → Triaged
summary: - Value type enums are not exposed to QML
+ Value type enums are not exposed to QML with Qt5.5
Chris Coulson (chrisccoulson) wrote :

Basically, we need some calls to qmlRegisterValueTypeEnums in OxideQmlPlugin::registerTypes

Chris Coulson (chrisccoulson) wrote :

This is fixed with http://bazaar.launchpad.net/~oxide-developers/oxide/oxide.trunk/revision/1306. I've done a build against the xenial stack and ran the full set of unit tests - they all pass with the exception of the tests in tst_SslCertificate.qml that rely on SslCertificate.issuer (due to bug 1488364)

Changed in oxide:
status: Triaged → Fix Released
Chris Coulson (chrisccoulson) wrote :

Might do a xenial only 1.11.5 for this

Changed in oxide-qt (Ubuntu):
status: New → Triaged
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package oxide-qt - 1.11.5-0ubuntu1

---------------
oxide-qt (1.11.5-0ubuntu1) xenial; urgency=medium

  * Update to v1.11.5
    - Fix LP: #1532135 - Ensure enums for value types are actually exposed to
      QML when building with Qt5.5

 -- Chris Coulson <email address hidden> Mon, 11 Jan 2016 17:11:11 +0000

Changed in oxide-qt (Ubuntu):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers