1 test failing resulting in FTBFS

Bug #1267026 reported by Timo Jyrinki
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
unity-scopes-api
Fix Released
Critical
Michi Henning
unity-scopes-shell
Invalid
Critical
Michi Henning
unity-scopes-api (Ubuntu)
Fix Released
Undecided
Unassigned

Related branches

Revision history for this message
Michal Hruby (mhr3) wrote :

Affecting also unity-scopes-api as it seems to be a race coming from there.

What happens in this test is that we setup a custom registry with a single scope in its scope directory and call registry->list(). For some reason the registry sometimes returns 0 entries, although one scope should always be present.

A bit more info - this seems to happen only when armhf build is being slow, plus the failure is happening already in tests' setup function (the one that is run for each test) *but* it fails only on the first test - ie right after spawning the registry, further tests that are using the exact same test setup function do not fail on the same check.

From this it would appear that if list() is called too early, it might not have information about the local scopes yet, and therefore sends back an empty response to the client.

Changed in unity-scopes-api:
importance: Undecided → Critical
assignee: nobody → Michi Henning (michihenning)
Revision history for this message
Michal Hruby (mhr3) wrote :

Btw this seems to have been there for quite a while, the builds show the error since version 0.1.6+14.04.20131219.1, although not sooner (but don't take the date as something exact, it's the debian pkg version, but still might have been introduced by a change around that time). Otoh as a race it might have been there for a while and we were just lucky.

Revision history for this message
Michi Henning (michihenning) wrote :

I'm pretty sure that the MR I attached will fix this. This was a silly mistake: I added the registry object to the middleware too early, meaning that a request could be processed before the lookup table was fully populated.

Changed in unity-scopes-api:
status: New → In Progress
Changed in unity-scopes-shell:
status: New → In Progress
assignee: nobody → Michi Henning (michihenning)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :

Fix committed into lp:unity-scopes-api at revision 121, scheduled for release in unity-scopes-api, milestone Unknown

Changed in unity-scopes-api:
status: In Progress → Fix Committed
Michal Hruby (mhr3)
Changed in unity-scopes-shell:
status: In Progress → Invalid
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (4.7 KiB)

This bug was fixed in the package unity-scopes-api - 0.2.0+14.04.20140120-0ubuntu1

---------------
unity-scopes-api (0.2.0+14.04.20140120-0ubuntu1) trusty; urgency=low

  [ Michi Henning ]
  * Added ability for scope to push an exception (as an exception_ptr). On the client side,
    the exception is delivered as the what() string (if the exception is a std::exception) and
    as "unknown exception", otherwise.
  * Disabled running the tests in parallel for CI. They are not written
    to run concurrently because the different tests try to bind to the
    same network endpoints. This should almost certainly fix the failure
    reported here:
    https://launchpadlibrarian.net/159997415/buildlog_ubuntu-saucy-
    i386.unity-scopes-api_0.1.5-0~94~ubuntu13.10.1_FAILEDTOBUILD.txt.gz.
  * Got rid of chatter from helgrind. (Needs helgrind 3.9.0 or later--
    3.8.1 generates bogus errors.) Added public destroy() method so it
    is possible to shut down the reaper explicitly. Fixed race condition
    on setting the self_ weak_ptr.
  * Changed code to match macro change here:
    https://code.launchpad.net/~michihenning/unity-api/noncopyable-
    fix/+merge/200084 Also removed remaining remnants of deprecated
    NonCopyable class.
  * Added CMake option to build with -fsanitize=thread. Fixed a bunch of
    warnings when building with clang.
  * Fixed valgrind error in HttpClient_test.cpp: execv was using
    deallocated memory. Updated CTestCustom.cmake.in to correctly
    suppress the tests that should not be run under valgrind.
  * Fixed shutdown in ObjectAdapter and added proper exception handling
    if the broker thread or a worker thread encounters an exception.
  * Disabled code generation for stand-alone header compilation tests.
    This makes the tests run marginally faster.
  * Added locate() remote method to the Registry, for the scope
    activation logic.
  * Changed ScopeLoader to not run the scope in a separate thread. (This
    is done by scoperunner anyway.) This fixes the problem of an
    exception being thrown by start(), but the scoperunner not realizing
    this. (LP: #1262536)
  * Added suppressions file for thread sanitizer issues in zmq.
  * Fixed race on registry start-up: registry was answering incoming
    requests too early. Other minor cosmetic changes: replaced
    factory()->create() call with factory()->find() because RuntimeImpl
    already instantiates the middleware. Removed redundant #includes.
    (LP: #1267026)
  * Minor fix: got rid of unnecessary unique_ptr. No functional changes.
  * Added formatcode target to CMakeLists.txt. This runs all source and
    header files through a pretty-printer.
  * Updated code for API changes in latest Cap'n Proto. (LP: #1268538)
  * Added check to prevent two servers from binding to the same ipc
    endpoint. Added coverage test for double-bind. Removed attempts to
    deal with servant destructors that throw. It turns out that this
    doesn't work because the destructor is called in the context of the
    map destructor, which calls the shared_ptr destructors, so we end up
    in terminate(). I might theoretically be possible to do this with a
    custom deleter for the...

Read more...

Changed in unity-scopes-api (Ubuntu):
status: New → Fix Released
Michal Hruby (mhr3)
Changed in unity-scopes-api:
status: Fix Committed → 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.