← Back to team overview

touch-packages team mailing list archive

[Bug 1181359] Re: Documents: Integers are getting corrupted

 

** Changed in: u1db-qt
       Status: Confirmed => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to qtbase-opensource-src in
Ubuntu.
https://bugs.launchpad.net/bugs/1181359

Title:
  Documents: Integers are getting corrupted

Status in U1DB Qt/ QML:
  Fix Released
Status in qtbase-opensource-src package in Ubuntu:
  Fix Released

Bug description:
  Hi,

  when saving a javascript object with an integer, the integer is not
  the same after retrieved from the db.

  Saving {test_id:2911298} will result in {test_id:2911300}.  I'm using
  0.1.4bzr89quantal0

  Example:

  import QtQuick 2.0
  import U1db 1.0 as U1db

  Item{
      id: u1dbBug

      U1db.Database {
              id: testDatabase
              path: "test-database"
      }

      function testFunction() {
          testDatabase.putDoc({test_id:2911298})
          var docs = testDatabase.listDocs();
          for(var x=0;x<docs.length;x++) {
              var doc = testDatabase.getDoc(docs[x]);
              console.log(doc.test_id)
          }
      }

  }

To manage notifications about this bug go to:
https://bugs.launchpad.net/u1db-qt/+bug/1181359/+subscriptions