Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-644

setCookie & deleteCookie functions missing from QWebEngineCookieStore

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Reported
    • Priority: P2: Important
    • Resolution: Unresolved
    • Affects Version/s: 5.9
    • Fix Version/s: None
    • Component/s: PySide
    • Labels:

      Description

      I built the current PySide2 5.9 branch (5.9.0a1 - built on Windows 10 via https://codereview.qt-project.org/pyside/pyside-setup) on 20 April 2018.

      I created a cookieStore for my profile:
      self.cookieStore = self.profile.cookieStore()

      And, then tried to add a cookie to it, for example:
      self.cookieStore.setCookie(someCookie, QtCore.QUrl(someUrl))

      But, for some reason my installation is missing the setCookie function:
      AttributeError: 'PySide2.QtWebEngineCore.QWebEngineCookieStore' object has no attribute 'setCookie'

      Looking at the mjb_rejected_function.log file in ./pyside2/pyside-setup/pyside3_build/py3.6-qt5.9.3-32bit-release/pyside2/PySide2/QtWebEngineCore/ generated at the time of the build, I notice:
       - void QWebEngineCookieStore::setCookie(QNetworkCookie const&,QUrl const&): unmatched type 'QNetworkCookie const&' in parameter #1 "cookie"

      Although this long log also lists functions such as:
       - void QWebEngineCookieStore::cookieAdded(QNetworkCookie const&): unmatched type 'QNetworkCookie const&' in parameter #1 "cookie"

      that are listed when I call:
      dir(PySide2.QtWebEngineCore.QWebEngineCookieStore)

      ['__class__', '__delattr__', '__dict__', '__dir__', '__doc__', '__eq__', '__format__', '__ge__', '__getattribute__', '__gt__', '__hash__', '__init__', '__init_subclass__', '__le__', '__lt__', '__ne__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', '__subclasshook__', 'blockSignals', 'childEvent', 'children', 'connect', 'connectNotify', 'cookieAdded', 'cookieRemoved', 'customEvent', 'deleteAllCookies', 'deleteLater', 'deleteSessionCookies', 'destroyed', 'disconnect', 'disconnectNotify', 'dumpObjectInfo', 'dumpObjectTree', 'dynamicPropertyNames', 'emit', 'event', 'eventFilter', 'findChild', 'findChildren', 'inherits', 'installEventFilter', 'isSignalConnected', 'isWidgetType', 'isWindowType', 'killTimer', 'loadAllCookies', 'metaObject', 'moveToThread', 'objectName', 'objectNameChanged', 'parent', 'property', 'receivers', 'registerUserData', 'removeEventFilter', 'sender', 'senderSignalIndex', 'setObjectName', 'setParent', 'setProperty', 'signalsBlocked', 'startTimer', 'staticMetaObject', 'thread', 'timerEvent', 'tr']

      A comparison with https://doc.qt.io/qt-5/qwebenginecookiestore-members.html also reveals that the deleteCookie function is also missing.

      I'm afraid I'm not experienced enough to know if this is a general bug, or just related to my installation.

      Thanks.

        Attachments

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

          Activity

            People

            • Assignee:
              ctismer Christian Tismer
              Reporter:
              esuyb Angus Melville
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Gerrit Reviews

                There are no open Gerrit changes