[odb-users] query_one assertion fail since postgres update

Boris Kolpackov boris at codesynthesis.com
Tue Mar 1 10:27:53 EST 2016


Hi Michael,

Michael Martín Moro <sexymimi64 at gmail.com> writes:

> I'm running Archlinux here, and recently we've had an update of Postgresql
> (the current version is 9.5.1).
> There seems to be an issue with this new version and odb's `query_one`
> method. Everything else works fine, afaik, but each use of `query_one` in
> my application fails an assertion when I use 9.5.1 libs and database.
> 
> I can perhaps help in fixing this issue, but I have no idea if it's already
> been reported (Archlinux made the update a few days ago already).
> 
> The failing assertion is the following:
> 
> /usr/include/odb/result.txx:36: bool odb::result<T>::one(T&) [with T =
> User]: Assertion `++i == end ()' failed.

My initial thought was that there is something "new" in PG 9.5 (and/or
its libpq client library) that causes this. So I have installed 9.5.1 from
the PG's apt repository and ran the entire ODB test suite (which includes
tests for query_one(); see common/quiery/one). No problems.

The only other difference between our setups is that I am using the latest
development version of ODB. If you would like to rule this out, you can try
the pre-release:

http://codesynthesis.com/~boris/tmp/odb/pre-release/

Failed that, I will need a test case that reproduces the problem. For
reference, here are my versions of the client libraries:

libpq5    9.5.1-1.pgdg14.04+1
libpq-dev 9.5.1-1.pgdg14.04+1

Boris



More information about the odb-users mailing list