Chutney won't run because some print() statements are borken
The above is a description of an error in a Python program. Here is
the original traceback:
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 1180, in <module>
sys.exit(main())
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 1174, in main
result = runConfigFile(args['action'], f)
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 1151, in runConfigFile
return getattr(network, verb)()
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 841, in configure
b.preConfig(network)
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 320, in preConfig
self._genAuthorityKey()
File "/home/isis/code/torproject/chutney/lib/chutney/TorNet.py", line 387, in _genAuthorityKey
"path, or put the binary into $PATH.") % tor_gencert
TypeError: unsupported operand type(s) for %: 'NoneType' and 'str'
Umm… the %
operator goes inside the print()
function call. Otherwise, you're attempting to do a format string operation on the return value of the print()
function (which is None
).