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

Validate use of std::forward when passing callback to transactions

    XMLWordPrintable

Details

    • Task
    • Resolution: Unresolved
    • Minor
    • 4.1.x
    • None
    • None
    • None
    • 1

    Description

      The transactions lib utilizes couchbase::core::utils::movable_function for the callback passed into the couchbase::transaction::run methods. This change appears to result in a crash for the async transactions (acouchbase) in Python. The crash is due to the PyObject* callback and errback passed into the lambda used for the transactions callback are null when the lambda (i.e. callback) is executed.

      Passing in the callback with std::forward helps to mitigate the crash, but it should be better understood if this is the appropriate path forward. So, creating this ticket to log the effort to better understand what is happening and if the current use of std::forward is the best approach.

      Transactions references:

      Python references:
      transaction's callback lambda

      Attachments

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

        Activity

          People

            jared.casey Jared Casey
            jared.casey Jared Casey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty