Uploaded image for project: 'Couchbase Python Client Library'
  1. Couchbase Python Client Library
  2. PYCBC-818

Collection.exists always returning true

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.0.0-beta.3
    • 3.0.0-rc
    • None
    • None
    • 1
    • SDK9: Coll/Txn/Doc chipping

    Description

      I believe that this used to work, but some recent LCB change (that fixed it's lcb behavior) has broken this.   Should be something in the bindings I missed, and not difficult to fix.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          david.kelly David Kelly added a comment -

          Turns out when I did it correctly (using lcb_respexists_is_found) I discovered lcb will return true for documents that have been removed (presumably eventually they get reaped out of existence, and then it returns false). In fact a completely random key that definitely didn't ever exist does return false.  So – I slightly re-implemented this to use is_found, but the actual issue still exists. This will be fixed when CCBC-1187 is fixed.

          david.kelly David Kelly added a comment - Turns out when I did it correctly (using lcb_respexists_is_found ) I discovered lcb will return true for documents that have been removed (presumably eventually they get reaped out of existence, and then it returns false). In fact a completely random key that definitely didn't ever exist does return false.  So – I slightly re-implemented this to use is_found, but the actual issue still exists. This will be fixed when CCBC-1187 is fixed.
          david.kelly David Kelly added a comment -

          I could skip the test that fails.... But instead lets have a test that passes by using a random key (say a random UUID).  Then another test that explicitly demonstrates this issue, which I skip until this is fixed.

          david.kelly David Kelly added a comment - I could skip the test that fails.... But instead lets have a test that passes by using a random key (say a random UUID).  Then another test that explicitly demonstrates this issue, which I skip until this is fixed.
          david.kelly David Kelly added a comment -

          We can un-skip the verification test when LCB fix is in

          david.kelly David Kelly added a comment - We can un-skip the verification test when LCB fix is in

          People

            david.kelly David Kelly
            david.kelly David Kelly
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty