crash QUbuntu: Could not create application instance

Bug #1297900 reported by Bill Filler
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Autopilot Qt Support
Invalid
Undecided
Unassigned
dialer-app
Fix Released
Undecided
Gustavo Pichorim Boiko
dialer-app (Ubuntu)
Fix Released
Undecided
Unassigned
qtubuntu (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

This crash is occuring when launching the dialer-app during the nightly smoke tests:
http://ci.ubuntu.com/smokeng/trusty/touch/mako/261:20140325.3:20140304/7375/dialer_app/

See the dialer-app.crash file from the above link.

#0 0xb63938e6 in ?? () from /lib/arm-linux-gnueabihf/libc.so.6
#1 0xb63a20fe in raise () from /lib/arm-linux-gnueabihf/libc.so.6
#2 0xb63a4956 in abort () from /lib/arm-linux-gnueabihf/libc.so.6
#3 0xb6c9daea in qt_message_fatal (context=..., message=...) at global/qlogging.cpp:979
#4 QMessageLogger::fatal (this=this@entry=0xbea2041c, msg=0xb4320168 "QUbuntu: Could not create application instance") at global/qlogging.cpp:384
#5 0xb431094c in QUbuntuIntegration::QUbuntuIntegration (this=0xb4707000, input_factory=0x1) at ../../../../../src/platforms/ubuntu/ubuntucommon/integration.cc:75
#6 0xb4311da2 in QUbuntuMirIntegration::QUbuntuMirIntegration (this=0x1d14eb8) at ../../../../../../src/platforms/ubuntu/ubuntumir/ubuntumircommon/integration.cc:39
#7 0xb430c086 in QUbuntuMirClientIntegrationPlugin::create (this=<optimized out>, system=..., paramList=...)
    at ../../../../../../src/platforms/ubuntu/ubuntumir/ubuntumirclient/main.cc:41
#8 0xb6a49910 in loadIntegration (argv=0xbea20774, argc=@0xbea205f4: 1, parameters=..., key=..., loader=0xb6c36b18 <_ZZN12_GLOBAL__N_112Q_QGS_loader13innerFunctionEvE6holder>)
    at kernel/qplatformintegrationfactory.cpp:64
#9 QPlatformIntegrationFactory::create (platform=..., paramList=..., argc=@0xbea205f4: 1, argv=argv@entry=0xbea20774, platformPluginPath=...)
    at kernel/qplatformintegrationfactory.cpp:81
#10 0xb6a501dc in init_platform (argv=0xbea20774, argc=@0xbea205f4: 1, platformThemeName=..., platformPluginPath=..., pluginArgument=...) at kernel/qguiapplication.cpp:897
#11 QGuiApplicationPrivate::createPlatformIntegration (this=<optimized out>) at kernel/qguiapplication.cpp:1039
#12 0xb6a5080a in QGuiApplicationPrivate::createEventDispatcher (this=<optimized out>) at kernel/qguiapplication.cpp:1054
#13 0xb6dcdeec in QCoreApplication::init (this=this@entry=0xbea205fc) at kernel/qcoreapplication.cpp:711
#14 0xb6dcdf6e in QCoreApplication::QCoreApplication (this=0xbea205fc, p=...) at kernel/qcoreapplication.cpp:638
#15 0xb6a51046 in QGuiApplication::QGuiApplication (this=0xbea205fc, argc=@0xbea205f4: 1, argv=0xbea20774, flags=328193) at kernel/qguiapplication.cpp:481
#16 0x0000ae46 in DialerApplication::DialerApplication (this=0xbea205fc, argc=<optimized out>, argv=<optimized out>)
    at /build/buildd/dialer-app-0.1+14.04.20140325/src/dialerapplication.cpp:60
#17 0x0000ac4a in main (argc=1, argv=0xbea20774) at /build/buildd/dialer-app-0.1+14.04.20140325/src/main.cpp:42

Related branches

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

From the unity8.log:

ApplicationManager REJECTED connection from app with pid 4983 as no desktop_file_hint specified

which is the primary cause for this crash. Why unity8/unity-mir is rejecting the connection would need to be determined - it may be a unity-mir bug, else the desktop_file_hint isn't being used correctly

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

or upstart-app-launch isn't notifying shell about the app launch in time

Changed in qtubuntu (Ubuntu):
assignee: nobody → rosa maria (rprosamaria383)
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in qtubuntu (Ubuntu):
status: New → Confirmed
Revision history for this message
Michael Zanetti (mzanetti) wrote :

Ok, its caused by dialer_app.tests.test_calls.TestCalls.test_incoming

What happens:
* autopilot starts the dialer-app (by system call "/usr/bin/dialer-app --desktop_file_hint=/usr/share/applications/dialer-app.desktop")
* autopilot triggers the incoming call notification and accepts the call
* this causes telephony-service to upstart-app-launch the following url: application:///dialer-app.desktop
* upstart-app-launch doesn't really know about the "manually" launched instance and tries to launch it a second time
* unity8 in turn does reject it because there is already one session for this app

this is not an issue if all instances are launched via upstart-app-launch (hence doesn't happen in real-world scenario)

So I guess the solution is to use upstart-app-launch in dialer-app's autopilot tests.

Changed in dialer-app:
assignee: nobody → Gustavo Pichorim Boiko (boiko)
Revision history for this message
Bill Filler (bfiller) wrote :

Makes sense. In fact shouldn't *all* autopilot tests launch apps through upstart-app-launch? It's not specific to dialer-app.

Changed in autopilot-qt:
assignee: nobody → Thomi Richards (thomir)
Michał Sawicz (saviq)
Changed in qtubuntu (Ubuntu):
assignee: rosa maria (rprosamaria383) → nobody
Revision history for this message
Thomi Richards (thomir-deactivatedaccount) wrote :

Hi,

Michael's analysis makes sense to me, *but*:

It's the test case that launches dialer-app, not autopilot itself.

The solutionn here is for test authors to call 'self.launch_upstart_application' to launch the apps - this uses upstart app launch, so should solve the problem.

I'm marking the autopilot-qt bug task as invalid, since this really doesn't have anything to do with this project.

Upstart-app-launch support is now in autopilot trunk. If the test cases use the 'launch_upstart_application' (http://unity.ubuntu.com/autopilot/api/testcase.html#autopilot.testcase.AutopilotTestCase.launch_upstart_application) and you still have problems, please open a bug against autopilot itself.

Cheers,

Changed in autopilot-qt:
status: New → Invalid
assignee: Thomi Richards (thomir) → nobody
Changed in dialer-app:
status: New → Confirmed
Changed in dialer-app:
status: Confirmed → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package dialer-app - 0.1+14.10.20140522-0ubuntu1

---------------
dialer-app (0.1+14.10.20140522-0ubuntu1) utopic; urgency=low

  [ Gustavo Pichorim Boiko ]
  * Use upstart to launch the application to run the tests. (LP:
    #1297900)
 -- Ubuntu daily release <email address hidden> Thu, 22 May 2014 15:45:00 +0000

Changed in dialer-app (Ubuntu):
status: New → Fix Released
Bill Filler (bfiller)
Changed in dialer-app:
status: In Progress → Fix Released
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.