Merge lp://staging/~thisfred/u1db/fix-local-gen-before-sync into lp://staging/u1db

Proposed by Eric Casteleijn
Status: Merged
Approved by: Eric Casteleijn
Approved revision: 384
Merged at revision: 381
Proposed branch: lp://staging/~thisfred/u1db/fix-local-gen-before-sync
Merge into: lp://staging/u1db
Diff against target: 123 lines (+28/-12)
6 files modified
include/u1db/u1db.h (+6/-2)
include/u1db/u1db_internal.h (+5/-0)
src/u1db.c (+2/-6)
u1db/tests/c_backend_wrapper.pyx (+4/-2)
u1db/tests/test_c_backend.py (+6/-1)
u1db/tests/test_sync.py (+5/-1)
To merge this branch: bzr merge lp://staging/~thisfred/u1db/fix-local-gen-before-sync
Reviewer Review Type Date Requested Status
John A Meinel (community) Approve
Review via email: mp+119705@code.staging.launchpad.net

Commit message

Fixed local_gen to be an OUT parameter only, and return it from sync()

Description of the change

Fixed local_gen to be an OUT parameter only, and return it from sync()

To post a comment you must log in.
Revision history for this message
John A Meinel (jameinel) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 8/15/2012 2:42 PM, Eric Casteleijn wrote:
> Eric Casteleijn has proposed merging
> lp:~thisfred/u1db/fix-local-gen-before-sync into lp:u1db.
>
> Requested reviews: Ubuntu One hackers (ubuntuone-hackers)
>
> For more details, see:
> https://code.launchpad.net/~thisfred/u1db/fix-local-gen-before-sync/+merge/119705
>
> Fixed local_gen to be an OUT parameter only, and return it from
> sync()
>

     // fprintf(stderr, "Starting\n");
- - if (db == NULL || target == NULL || local_gen_before_sync == NULL) {
+ if (db == NULL || target == NULL) {
         // fprintf(stderr, "DB, target, or local are NULL\n");

You should probably still check that "local_gen == NULL" here, so that
we generate an INVALID_PARAMETER error if it is not supplied. Or are
you intentionally making it optional? If so, you should update the
docstring to indicate that.

The rest looks good.

 merge: approve

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAlArrJsACgkQJdeBCYSNAAPoygCgnAVKFl2EoKukAwlohz/DRhsd
5bsAn3vlT/AqJR4S5yfIIlgC9tQDedtt
=dSwQ
-----END PGP SIGNATURE-----

review: Approve
Revision history for this message
Ubuntu One Auto Pilot (otto-pilot) wrote :
Download full text (7.3 KiB)

The attempt to merge lp:~thisfred/u1db/fix-local-gen-before-sync into lp:u1db failed. Below is the output from the failed tests.

-- The C compiler identification is GNU 4.7.1
-- The CXX compiler identification is GNU 4.7.1
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found Cython: /usr/bin/cython
-- Found CURL: /usr/lib/x86_64-linux-gnu/libcurl.so (found version "7.26.0")
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26")
-- checking for module 'oauth'
-- found oauth, version 0.9.7
-- Found OAuth: /usr/lib/x86_64-linux-gnu/liboauth.so
-- checking for module 'json'
-- found json, version 0.9
-- Found JSON: /usr/lib/x86_64-linux-gnu/libjson.so
-- checking for module 'sqlite3'
-- found sqlite3, version 3.7.13
-- Found Sqlite3: /usr/lib/x86_64-linux-gnu/libsqlite3.so
-- Configuring done
-- Generating done
-- Build files have been written to: /mnt/tarmac/cache/u1db/trunk
[ 11%] Generating u1db_schema.c
Scanning dependencies of target u1db
[ 22%] Building C object src/CMakeFiles/u1db.dir/mkstemp_compat.c.o
[ 33%] Building C object src/CMakeFiles/u1db.dir/u1db.c.o
[ 44%] Building C object src/CMakeFiles/u1db.dir/u1db_http_sync_target.c.o
[ 55%] Building C object src/CMakeFiles/u1db.dir/u1db_query.c.o
[ 66%] Building C object src/CMakeFiles/u1db.dir/u1db_sync_target.c.o
[ 77%] Building C object src/CMakeFiles/u1db.dir/u1db_uuid.c.o
[ 88%] Building C object src/CMakeFiles/u1db.dir/u1db_vectorclock.c.o
[100%] Building C object src/CMakeFiles/u1db.dir/u1db_schema.c.o
Linking C static library libu1db.a
[100%] Built target u1db
Scanning dependencies of target ReplicatePythonSourceTree
[100%] Built target ReplicatePythonSourceTree
Scanning dependencies of target build-debug
running build_ext
cythoning u1db/tests/c_backend_wrapper.pyx to u1db/tests/c_backend_wrapper.c
building 'u1db.tests.c_backend_wrapper' extension
creating build
creating build/temp.linux-x86_64-2.7-pydebug
creating build/temp.linux-x86_64-2.7-pydebug/u1db
creating build/temp.linux-x86_64-2.7-pydebug/u1db/tests
gcc -pthread -fno-strict-aliasing -g -O0 -Wall -Wstrict-prototypes -fPIC -Iinclude -I/mnt/tarmac/cache/u1db/trunk/include -I/usr/include/python2.7_d -c u1db/tests/c_backend_wrapper.c -o build/temp.linux-x86_64-2.7-pydebug/u1db/tests/c_backend_wrapper.o
gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro build/temp.linux-x86_64-2.7-pydebug/u1db/tests/c_backend_wrapper.o -Lsrc -lu1db -lsqlite3 -loauth -lcurl -ljson -o /mnt/tarmac/cache/u1db/trunk/u1db/tests/c_backend_wrapper_d.so
[100%] Built target build-debug
Scanning dependencies of target check-valgrind
Tests running...
======================================================================
FAIL: u1db.tests.test_sync.DatabaseSyncTests.test_sync_tracks_db_generation_of_other(c,csync)
----------------------------------------------------------------------
Tr...

Read more...

Revision history for this message
Ubuntu One Auto Pilot (otto-pilot) wrote :
Download full text (7.3 KiB)

The attempt to merge lp:~thisfred/u1db/fix-local-gen-before-sync into lp:u1db failed. Below is the output from the failed tests.

-- The C compiler identification is GNU 4.7.1
-- The CXX compiler identification is GNU 4.7.1
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found Cython: /usr/bin/cython
-- Found CURL: /usr/lib/x86_64-linux-gnu/libcurl.so (found version "7.26.0")
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26")
-- checking for module 'oauth'
-- found oauth, version 0.9.7
-- Found OAuth: /usr/lib/x86_64-linux-gnu/liboauth.so
-- checking for module 'json'
-- found json, version 0.9
-- Found JSON: /usr/lib/x86_64-linux-gnu/libjson.so
-- checking for module 'sqlite3'
-- found sqlite3, version 3.7.13
-- Found Sqlite3: /usr/lib/x86_64-linux-gnu/libsqlite3.so
-- Configuring done
-- Generating done
-- Build files have been written to: /mnt/tarmac/cache/u1db/trunk
Scanning dependencies of target ReplicatePythonSourceTree
[ 0%] Built target ReplicatePythonSourceTree
[ 11%] Generating u1db_schema.c
Scanning dependencies of target u1db
[ 22%] Building C object src/CMakeFiles/u1db.dir/mkstemp_compat.c.o
[ 33%] Building C object src/CMakeFiles/u1db.dir/u1db.c.o
[ 44%] Building C object src/CMakeFiles/u1db.dir/u1db_http_sync_target.c.o
[ 55%] Building C object src/CMakeFiles/u1db.dir/u1db_query.c.o
[ 66%] Building C object src/CMakeFiles/u1db.dir/u1db_sync_target.c.o
[ 77%] Building C object src/CMakeFiles/u1db.dir/u1db_uuid.c.o
[ 88%] Building C object src/CMakeFiles/u1db.dir/u1db_vectorclock.c.o
[100%] Building C object src/CMakeFiles/u1db.dir/u1db_schema.c.o
Linking C static library libu1db.a
[100%] Built target u1db
Scanning dependencies of target build-debug
running build_ext
cythoning u1db/tests/c_backend_wrapper.pyx to u1db/tests/c_backend_wrapper.c
building 'u1db.tests.c_backend_wrapper' extension
creating build
creating build/temp.linux-x86_64-2.7-pydebug
creating build/temp.linux-x86_64-2.7-pydebug/u1db
creating build/temp.linux-x86_64-2.7-pydebug/u1db/tests
gcc -pthread -fno-strict-aliasing -g -O0 -Wall -Wstrict-prototypes -fPIC -Iinclude -I/mnt/tarmac/cache/u1db/trunk/include -I/usr/include/python2.7_d -c u1db/tests/c_backend_wrapper.c -o build/temp.linux-x86_64-2.7-pydebug/u1db/tests/c_backend_wrapper.o
gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-Bsymbolic-functions -Wl,-z,relro build/temp.linux-x86_64-2.7-pydebug/u1db/tests/c_backend_wrapper.o -Lsrc -lu1db -lsqlite3 -loauth -lcurl -ljson -o /mnt/tarmac/cache/u1db/trunk/u1db/tests/c_backend_wrapper_d.so
[100%] Built target build-debug
Scanning dependencies of target check-valgrind
Tests running...
======================================================================
FAIL: u1db.tests.test_sync.DatabaseSyncTests.test_sync_tracks_db_generation_of_other(c,csync)
----------------------------------------------------------------------
Tr...

Read more...

384. By Eric Casteleijn

init another int

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches