Patch for Python 3 Support
by Ralph Bean
Hello all,
I created a patch to update python-bugzilla to work on both python 2
and python 3. The unit tests all pass under both py2.7 and py3.2.
I have tested the login and query commands by hand on py2.6, py2.7,
and py3.2.
http://threebean.org/patches/python-bugzilla-Python3-support.patch
The patch is against the master branch (7ca8a60). If I should
recreate it against another branch, please let me know.
I'm also willing to update and maintain a spec file supporting both
versions if and when that time comes.
Cheers-
-Ralph
10 years, 11 months
Small typo in imports
by Björn Wingman
I found a typo in the imports of __init__.py. I hope this patch format
comes across ok.
/Björn
--- new/__init__.py 2012-06-18 11:39:01.232060575 +0200
+++ __init__.py 2012-06-18 11:27:30.383710970 +0200
@@ -9,7 +9,7 @@
# option) any later version. See http://www.gnu.org/copyleft/gpl.html for
# the full text of the license.
-from bugzilla3 import Bugzilla3, Bugzilla32, Bugzilla34, Bugzilla3
+from bugzilla3 import Bugzilla3, Bugzilla32, Bugzilla34, Bugzilla36
from bugzilla4 import Bugzilla4
from rhbugzilla import RHBugzilla, RHBugzilla3, RHBugzilla4
from nvlbugzilla import NovellBugzilla
11 years, 8 months
creation date in query
by Vivek Ayer
Hi,
I like python-bugzilla and was wondering if there was a way to do
'Creation date: less than or equal to DATE'? Boolean charts perhaps?
If so, could someone illustrate? I'm on Bugzilla 4.2.1 with
python-bugzilla 0.7.0. According to python-bugzilla, apparently my
4.2.1 doesn't support Boolean charts. If not boolean charts, perhaps
this support could be added? Help appreciated.
Thanks,
Vivek
12 years
xmlrpc unsupported protocol error when running on my mac; only in certain cases
by Eric Sammons
I'm hoping someone here can help me out, I have a problem that I have not been able to resolve as I have eliminated and changed up scenarios and found that only in one case (thus far) do I get the error IOError Unsupported XML-RPC protocol.
I have written small snippets of code that use xmlrpclib, I have re-written these snippets to use python-bugzilla, and then I have even used bugzilla (the cli), and finally I even added a python-bugzilla call to a test scenario and used py.test. In _all_ cases the code runs just fine; however, in one scenario I receive the mentioned error. This scenario involves a pytest-plugin that I wrote - it works perfectly on Fedora.
Install https://github.com/eanxgeek/pytest_marker_bugzilla and use py.test to call it to execute a series of sample tests. On my Mac I get the XML-RPC error.
For more I have a question posted on stackoverflow.
http://stackoverflow.com/questions/11024425/pytest-plugin-using-xmlrpclib...
Appreciate any thoughts here as I mentioned I have tried several scenarios that all work on the very same Mac.
Thank you!
---
Eric L. Sammons, RHCE/RHCVA
Sr. Quality Engineer, Cloud Technologies
Sent by my android Transformer Prime
12 years
Known API usage of python-bugzilla
by Toshio Kuratomi
Greetings all, I had done some auditing to give to the RH bugzilla admins
and wwoods thoght it might be useful for creating tests that cover things
that are actively used. It's a list of what things we're running in Fedora
Infrastructure (and a few things we aren't but contributors use) and what
pieces of python-bugzilla API they use.
# Note that we'd like to use multicall for queries whenever possible but some
# uses of multicall via python-bugzilla appear to be broken
# https://bugzilla.redhat.com/show_bug.cgi?id=824241
# Note that we use python-bugzilla to access bugzilla for all but one of these scripts
# http://git.fedorahosted.org/git/?p=python-bugzilla.git;a=summary
FAS bugzilla sync
bugzilla.Bugzilla.updateperms()
# Remove user from fedorabugs group
# Add a user to the fedorabugs group
bugzilla.Bugzilla.getuser()
# Test that a user has a bugzilla account
PKGDB bugzilla sync
bugzilla.Bugzilla.getcomponentsdetails()
# Retrieve information about all the packages in a collection (Fedora, Fedora EPEL)
# Note: Non-bugzilla calls logic:
# Check for differences between what's i nthe pkgdb and what's in the
# components in bugzilla. [qacontact, initialowner, description,
# initialcclist]. Where a difference is found, set it on the package
bugzilla.Bugzilla.editcomponent()
# Save the data for packages we found above.
bugzilla.Bugzilla.addcomponent()
# Add new packages that didn't exist previously
bz-make-components (Ownership for docs, translations)
# **IMPORTANT** Everything else goes through python-bugzilla. This script
# makes xmlrpc calls on its own
# This could be ported to be more like the PKGDB bugzilla sync if needed
bugzilla.getProdCompDetails()
# To retrieve all components in the products [Fedora Documentation and Fedora Localization]
bugzilla.editComponent()
# To save the updated data for components that have had changes made
PKGDB:
bugzilla.Bugzilla.query()
# Retrieve all bugs about a certain package in Fedora or Fedora EPEL where the bug is not closed.
bugzilla.Bugzilla.getbugsimple()
# Retrieve information about the bugs -- we use product, version, bug_id, url, bug_status, short_desc
Bodhi:
bugzilla.Bugzilla.getbugid()
# Retrieve a bug to read its keywords, short_desc, product, parent, and title
bugzilla.Bugzilla._Bug.add_comment()}
# Add a comment to an existing bug
bugzilla.Bugzilla._Bug.close()
# Close a bug when an update is pushed to stable
bugzilla.Bugzilla._Bug.setstatus()
# Change the status of a bug when updates are submitted that address the bug
packages.fedoraproject.org:
bugzilla.Bugzilla.query()
bugzilla.Bugzilla.getbugs()
# Retrieve information for bugs on a package including statistics of how many
# recently closed bugs. Otherwise, similar to the pkgdb use
review-stats
# Caches review request bugs
bugzilla.Bugzilla.query()
bugzilla.Bugzilla.getbugsimple()
easyfix.fedoraproject.org
# Finds tickets on selected projects that have been marked with an EasyFix
# style keyword for new contributors to work on
bugzilla.Bugzilla.query()
fedora-active-user
# Gathers information to see if a contributor has gone AWOL
# Uses bugzilla to tell how active the user has been in answering bugzilla
# bugs.
bugzilla.getuser()
bugzilla.query()
bugzilla.getbugs()
fedora-create-review and fedora-review
# Aids in reviewing new packages
bugzilla.query()
bugzilla.getbugs()
bugzilla.createbug()
bugzilla.login()
cnucnu
# Tracks upstream package versions and opens or modifies a bug when an
# upstream update is newer than what's in rawhide
bugzilla._update_bugs()
bugzilla.createbug()
bugzilla._proxy.bugzilla.changeStatus()
bugzilla._proxy.bugzilla.updateKeywords()
bugzilla.query()
bugzilla.login()
Hope this is helpful
-Toshio
12 years
Test
by Cole Robinson
Just making sure this works
12 years