[regression] Exception when running phablet-screenshot [std::exception::what: Attempt to set swap interval on screencast is invalid]

Bug #1425307 reported by Ricardo Salveti
30
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Mir
Confirmed
High
Unassigned
0.12
Won't Fix
High
Unassigned
0.13
Won't Fix
High
Unassigned
0.14
Won't Fix
High
Unassigned
mir (Ubuntu)
Confirmed
High
Unassigned
phablet-tools (Ubuntu)
New
Undecided
Unassigned

Bug Description

current build number: 110
device name: mako
channel: ubuntu-touch/vivid-proposed
last update: 2015-02-24 22:35:35
version version: 110
version ubuntu: 20150224
version device: 20150210
version custom: 20150224

rsalveti@evasys:~$ phablet-screenshot /tmp/foo.png
I: Dumping fb0 ...
[1424817826.846470] Loader: Loading modules from: /usr/lib/arm-linux-gnueabihf/mir/client-platform/
[1424817826.847569] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/mesa.so
[1424817826.848393] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/android.so
[1424817826.849583] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/dummy.so
[1424817826.944654] <ERROR> mircommon: Caught exception at Mir/EGL driver boundary (in setSwapInterval): /build/buildd/mir-0.11.0+15.04.20150209.1/src/client/buffer_stream.cpp(283): Throw in function virtual void mir::client::BufferStream::request_and_wait_for_configure(MirSurfaceAttrib, int)
Dynamic exception type: N5boost16exception_detail10clone_implINS0_19error_info_injectorISt11logic_errorEEEE
std::exception::what: Attempt to set swap interval on screencast is invalid

3004 KB/s (3932160 bytes in 1.278s)
I: Done

phablet-tools - 1.1+15.04.20150218-0ubuntu1

Related branches

Revision history for this message
Ricardo Salveti (rsalveti) wrote :

Seems it's not a fatal issue though, as the png was extracted correctly.

Revision history for this message
Ricardo Salveti (rsalveti) wrote :
Download full text (3.1 KiB)

(gdb) catch throw
Catchpoint 1 (throw)
(gdb) r -m /run/mir_socket -n1 -f /tmp/mir_screencast_768x1280.rgba
Starting program: /usr/bin/mirscreencast -m /run/mir_socket -n1 -f /tmp/mir_screencast_768x1280.rgba
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/arm-linux-gnueabihf/libthread_db.so.1".
[1424819317.052580] Loader: Loading modules from: /usr/lib/arm-linux-gnueabihf/mir/client-platform/
[1424819317.055296] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/mesa.so
[1424819317.067687] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/android.so
[1424819317.181522] Loader: Loading module: /usr/lib/arm-linux-gnueabihf/mir/client-platform/dummy.so
[New Thread 0xb63fb440 (LWP 5734)]
Catchpoint 1 (exception thrown), __cxxabiv1::__cxa_throw (obj=0x4a258, tinfo=0xb6fc56c4 <typeinfo for boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::logic_error> >>,
    dest=0xb6f97921 <boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::logic_error> >::~clone_impl()>) at ../../../../src/libstdc++-v3/libsupc++/eh_throw.cc:63
63 ../../../../src/libstdc++-v3/libsupc++/eh_throw.cc: No such file or directory.
(gdb) bt full
#0 __cxxabiv1::__cxa_throw (obj=0x4a258, tinfo=0xb6fc56c4 <typeinfo for boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::logic_error> >>,
    dest=0xb6f97921 <boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<std::logic_error> >::~clone_impl()>) at ../../../../src/libstdc++-v3/libsupc++/eh_throw.cc:63
        globals = <optimized out>
#1 0xb6f98228 in boost::throw_exception<boost::exception_detail::error_info_injector<std::logic_error> > (e=...) at /usr/include/boost/throw_exception.hpp:70
No locals.
#2 0xb6f982ce in boost::exception_detail::throw_exception_<std::logic_error> (x=...,
    current_function=0xb6fadef4 <mir::client::BufferStream::request_and_wait_for_configure(MirSurfaceAttrib, int)::__PRETTY_FUNCTION__> "virtual void mir::client::BufferStream::request_and_wait_for_configure(MirSurfaceAttrib, int)",
    file=0xb6fadfe4 "/build/buildd/mir-0.11.0+15.04.20150209.1/src/client/buffer_stream.cpp", line=line@entry=283) at /usr/include/boost/throw_exception.hpp:87
No locals.
#3 0xb6f97660 in mir::client::BufferStream::request_and_wait_for_configure (this=<optimized out>, attrib=mir_surface_attrib_swapinterval, value=1) at /build/buildd/mir-0.11.0+15.04.20150209.1/src/client/buffer_stream.cpp:283
        lock = {_M_device = 0xb5a00ac0, _M_owns = true}
        __PRETTY_FUNCTION__ = "virtual void mir::client::BufferStream::request_and_wait_for_configure(MirSurfaceAttrib, int)"
        setting = <incomplete type>
        result = <incomplete type>
#4 0xb6485690 in mir::graphics::android::MirNativeWindow::setSwapInterval (this=<optimized out>, interval=<optimized out>) at /build/buildd/mir-0.11.0+15.04.20150209.1/src/common/graphics/android/mir_native_window.cpp:158
        __FUNCTION__ = "setSwapInterval"
#5 0xb68be7f6 in ?? ()
No symbol table info available.
Backtrace stopped: previous frame identical to this frame (c...

Read more...

Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: Exception when running phablet-screenshot (mako/vivid 110) [std::exception::what: Attempt to set swap interval on screencast is invalid]

I think Mir's at fault here.

It's unreasonable to expect a client or shell to know it's being screencast and avoid setting swap interval. Mir should handle (or ignore) this transparently.

summary: Exception when running phablet-screenshot (mako/vivid 110)
+ [std::exception::what: Attempt to set swap interval on screencast is
+ invalid]
tags: added: screencast
Changed in mir:
importance: Undecided → Medium
Changed in mir (Ubuntu):
importance: Undecided → Medium
Changed in mir:
status: New → Triaged
Changed in mir (Ubuntu):
status: New → Triaged
Revision history for this message
Daniel van Vugt (vanvugt) wrote : Re: [regression] Exception when running phablet-screenshot (mako/vivid 110) [std::exception::what: Attempt to set swap interval on screencast is invalid]

Found the problem came from:

------------------------------------------------------------
revno: 2261 [merge]
author: Robert Carr <email address hidden>
committer: Tarmac
branch nick: development-branch
timestamp: Mon 2015-01-26 21:29:52 +0000
message:
  Factor a common buffer stream implementation out of MirScreencast and MirSurface.

  Approved by PS Jenkins bot, Alberto Aguirre, Chris Halse Rogers, Alexandros Frantzis.
------------------------------------------------------------

summary: - Exception when running phablet-screenshot (mako/vivid 110)
+ [regression] Exception when running phablet-screenshot (mako/vivid 110)
[std::exception::what: Attempt to set swap interval on screencast is
invalid]
tags: added: regression
Revision history for this message
Cemil Azizoglu (cemil-azizoglu) wrote :

Some comms in the chat... recording here... Upping the priority accordingly, and assigning to racarr.

:<ERROR> mircommon: Caught exception at Mir/EGL driver boundary (in setSwapInterval): /build/buildd/mir-0.12.0+15.04.20150228/src/client/buffer_stream.cpp(283): Throw in function virtual void mir::client::BufferStream::request_and_wait_for_configure(MirSurfaceAttrib, int)
 Dynamic exception type: N5boost16exception_detail10clone_implINS0_19error_info_injectorISt11logic_errorEEEE
 std::exception::what: Attempt to set swap interval on screencast is invalid
 ^^ https://jenkins.qa.ubuntu.com/job/generic-deb-autopilot-runner-vivid-mako/1520/consoleText

<kalikiana> AlbertA: so it's being worked on? there's some 20 failures I can attribute to that atm in ui toolkit staging

Changed in mir:
importance: Medium → High
assignee: nobody → Robert Carr (robertcarr)
Revision history for this message
Robert Carr (robertcarr) wrote :

Should be fixed in r2307

revno: 2307 [merge]
author: Robert Carr <email address hidden>
committer: Tarmac
branch nick: development-branch
timestamp: Tue 2015-02-10 01:21:53 +0000
message:
  Catch exceptions at android driver boundary.

  Approved by PS Jenkins bot, Kevin DuBois.

Changed in mir:
status: Triaged → Fix Committed
Changed in mir (Ubuntu):
status: Triaged → Fix Released
Changed in mir (Ubuntu):
status: Fix Released → Confirmed
Changed in mir:
milestone: none → 0.13.0
Changed in mir (Ubuntu):
status: Confirmed → Triaged
importance: Medium → High
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Actually Robert slipped his proposed fix just in time into the 0.11.0 release. And the 0.12 branch inherits from that...

------------------------------------------------------------
revno: 2287
tags: v0.11.0
committer: Robert Carr <email address hidden>
branch nick: 0.11
timestamp: Mon 2015-02-09 13:07:25 -0800
message:
  Cherrypick lp:~mir-team/mir/catch-exceptions-at-android-driver-boundary
------------------------------------------------------------

Sadly, this bug was reported against the same release it's meant to be fixed in. Although it's hard to tell what came first because the pre-release with the bug and the apparent fix both occurred on the same day.

It's not yet clear if the bug is fixed in any branch yet.

Changed in mir:
status: Fix Committed → Incomplete
no longer affects: mir/0.12
Changed in mir:
milestone: 0.13.0 → 0.11.0
Changed in mir (Ubuntu):
status: Triaged → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

If it is fixed, then it was fix released in 0.11.0

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

OK, just assuming it was indeed fixed unless proven otherwise.

Changed in mir:
status: Incomplete → Fix Released
Changed in mir (Ubuntu):
status: Incomplete → Fix Released
Changed in mir:
status: Fix Released → Confirmed
milestone: 0.11.0 → 0.13.0
Revision history for this message
Alberto Aguirre (albaguirre) wrote :

I still see this exception when testing in the BQ phone using mir-0.12.1+15.04.20150324 (image #172 from vivid-proposed channel)

http://pastebin.ubuntu.com/10725542/

Changed in mir:
assignee: Robert Carr (robertcarr) → nobody
Revision history for this message
kevin gunn (kgunn72) wrote :

i'm seeing this on vivid-proposed on arale

Changed in mir (Ubuntu):
status: Fix Released → Confirmed
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Confirmed the bug is in 0.12 also by duplicate bug 1447366.

Changed in mir:
milestone: 0.13.0 → 0.14.0
summary: - [regression] Exception when running phablet-screenshot (mako/vivid 110)
+ [regression] Exception when running phablet-screenshot
[std::exception::what: Attempt to set swap interval on screencast is
invalid]
Revision history for this message
Robert Carr (robertcarr) wrote :

It's just a log now right?

tags: added: bufferstream-regression
Changed in mir:
assignee: Robert Carr (robertcarr) → nobody
Changed in mir:
milestone: 0.13.1 → 0.16.0
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I'd like to see this fixed, but we have no definite plans to aim for a particular milestone.

Changed in mir:
milestone: 0.16.0 → none
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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