Comment 1 for bug 231875

Revision history for this message
Markus Korn (thekorn) wrote :

I'm going to merge the changes into the .main branch as soon I've done some more testings. Let me just give you an overviewon how this will work:

================

In [16]: from launchpadbugs.connector import ConnectBug

In [17]: B = ConnectBug()

In [18]: B.authentication = "/home/markus/.gnome2/epiphany/mozilla/epiphany/cookies.sqlite"

In [19]: dups1 = B.check_duplicate({"name": "buglog-data"}, "check this for duplicate", "This is an example bugreport to show the features of the new check_duplicate-functionality", tags=["foo"])

In [20]: dups1
Out[20]: [<BugInfo 234363>, <BugInfo 120593>]

In [21]: dups1.submit()
Out[21]: <Bug 234366>

In [22]: _.status
Out[22]: 'New'

In [23]: dups2 = B.check_duplicate({"name": "buglog-data"}, "check this for duplicate", "This is an example bugre
port to show the features of the new check_duplicate-functionality", tags=["foo"])

In [24]: dups2.subscribe(234363)

================

Please note:
  * dups.submit() and dups.subscribe(<bugnr>) always returns an LPBugs-object
  * Bug.check_duplicate(<args>) returns a list, members are instances of LPBugInfo
  * dups.subscribe(<bugnr>) seems to be broken in some cases, I've to fix it before merging the changes into the main brach.

Markus