← Back to team overview

ubuntu-phone team mailing list archive

Re: Failing qt connections

 

On Wednesday 09 April 2014 00:21:45 Manuel de la Pena wrote:
> Hello,
> 
> In the ubuntu download manager we are using the new connection style syntax
> (http://qt-project.org/wiki/New_Signal_Slot_Syntax) so that if there are
> errors in the signal connections we will be notified at compile time.
> However, in recent versions of udm we have noticed that the udm tests that
> ensure that the qt signals are emitted correctly have started failing
> randomly in the build servers.

Yes, connections of signals/slots using C++11 constructs fail in powerpc 
machines (we had never them fail on arm, even though upstream Qt complains 
about arm too).

Here a patch we used for dee-qt
  https://code.launchpad.net/~cjwatson/dee-qt/powerpc-pie/+merge/211308

Here the upstream patch that went all ahead and disabled -Bsymbolic* on 
anything but x86 and x86-64
  https://codereview.qt-project.org/#change,81095

We may want to get to cherry-pick the last one and add it to our Qt sources.

Cheers,
  Albert

> 
> As it can be seen in the following build logs the compilation does finish
> with no errors but the tests raise errors at runtime (an assert was added
> for each of the connect calls in the project):
> 
> https://launchpadlibrarian.net/172280588/buildlog_ubuntu-trusty-powerpc.ubun
> tu-download-manager_0.3%2B14.04.20140408.1-0ubuntu1_FAILEDTOBUILD.txt.gz
> https://launchpadlibrarian.net/172280333/buildlog_ubuntu-trusty-arm64.ubunt
> u-download-manager_0.3%2B14.04.20140408.1-0ubuntu1_FAILEDTOBUILD.txt.gz
> https://launchpadlibrarian.net/172280872/buildlog_ubuntu-trusty-armhf.ubunt
> u-download-manager_0.3%2B14.04.20140408.1-0ubuntu1_FAILEDTOBUILD.txt.gz
> 
> Some of the errors between the diff archs are the same but this feels like
> a coincidence. The unity-scope-click package project has had the same issue
> and has solved it in the following way:
> 
> scope/click/download-manager.cpp (123)
> 
>  // NOTE: using SIGNAL/SLOT macros here because new-style
>     // connections are flaky on ARM.
>     c = connect(impl->systemDownloadManager.data(),
> SIGNAL(downloadCreated(Download*)),
>                 this, SLOT(handleDownloadCreated(Download*)));
> 
>     if (!c) {
>         qDebug() << "failed to connect to
> systemDownloadManager::downloadCreated";
> 
>     }
> 
> 
> It is very interesting that the tests have never (so far) failed in the
> other 2 architectures (i386, amd64). I'm raising this issue because it
> might be hitting us in some other projects. I have reported the following
> bug (https://bugs.launchpad.net/ubuntu-ui-toolkit/+bug/1304709) in (very
> probably) wrong project. I would really appreciate input form more
> intelligent developers :)
> 
> PS: At least I know that my crazy tests that ensure that all signals are
> raised correctly do make sense even when they stop me from landing udm at
> the moment.



References