PyTest plugin using xmlrpclib fails with IOError: "unsupported XML-RPC protocol" on Mac OS X

When running py.test using a plugin that loads xmlrpclib the test run fails with:

INTERNALERROR> Traceback (most recent call last): INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest-2.2.4-py2.7.egg/_pytest/", line 70, in wrap_session INTERNALERROR> config.pluginmanager.do_configure(config) INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest-2.2.4-py2.7.egg/_pytest/", line 267, in do_configure INTERNALERROR> config.hook.pytest_configure(config=self._config) INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest-2.2.4-py2.7.egg/_pytest/",line 421, in call INTERNALERROR> return self._docall(methods, kwargs) INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest-2.2.4-py2.7.egg/_pytest/",line 432, in _docall INTERNALERROR> res = mc.execute() INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest-2.2.4-py2.7.egg/_pytest/",line 350, in execute INTERNALERROR> res = method(**kwargs) INTERNALERROR> File "/Library/Python/2.7/site-packages/pytest_marker_bugzilla-0.01-py2.7.egg/",line 94, in pytest_configure INTERNALERROR> bz = bugzilla.Bugzilla(url=url) INTERNALERROR> File "build/bdist.macosx-10.7-intel/egg/bugzilla/", line 75, in init INTERNALERROR> c = getBugzillaClassForURL(kwargs['url']) INTERNALERROR> File "build/bdist.macosx-10.7-intel/egg/bugzilla/", line 26, in getBugzillaClassForURL INTERNALERROR> s = xmlrpclib.ServerProxy(url) INTERNALERROR> File "build/bdist.macosx-10.7-intel/egg/", line 1215, in init INTERNALERROR> raise IOError, "unsupported XML-RPC protocol" INTERNALERROR> > > IOError: unsupported XML-RPC protocol

I have verified that xmlrpclib will work with a simple test program, this program removes py.test from the picture.

#!/usr/bin/env python

import xmlrpclib
import bugzilla
import sys
for i in sys.path:
    print i

url = ''
u = ' '
p = ' '

    proxy = xmlrpclib.ServerProxy(url)
except(), e:
    print e
b = bugzilla.Bugzilla(url=url)
bug = b.getbugsimple('12345')
print bug

The program above when executed returns as expected. I am at a loss for what is going on here. I have even added print sys.path to both py.test and the test program above and found that the paths are identical with the exception of the execute directory, /Users/esammons for the and /usr/local/bin for py.test.

To further rule out issues I copied /usr/local/bin/py.test and /usr/local/bin/py.test-2.7 to my project root, same error occurred.



The issue was caused by the formatting of my values in my cfg file. I'm using ConfigParser to parse my config file; the cfg file has the following format.

key = value
key2 = value
key3 = value

The issue was caused by my wrapping the value in quotes ('value'). Specifically:


bugzilla_url = ''


bugzilla_url =

Need Your Help

Can you set EventArgs from ASP.NET controls? controls eventargs

I have a DropDownList whose SelectedIndexChanged event I set:

Delete Rows Containing 0 formatted as Currency

vba excel-vba excel-2010 excel

I am trying to delete all rows in Column E that contain 0. It is formatted as Currency and is giving me some issues.