Cannot login to Bugzilla from PyBugz

匆匆过客 提交于 2019-12-25 06:55:46

问题


I am having trouble authenticating my bugzilla user from pybugz.

PyBugz v0.9.3
Bugzilla v4.4.6

I'm using this older version of pybugz because I believe I need it for gitzilla.

Anonymous login to bugzilla has been allowed by setting the option requirelogin = off.

I can successfully retrieve a bug anonymously with this command
bugz -b http://bugs.domain.org.au --skip-auth get 1

but when I attempt to authenticate with this
bugz -b http://bugs.domain.org.au -u me@bugs.domain.org.au -p mypassword get 1

I receive this message

* Using http://bugs.domain.org.au
* Getting bug 1 ..  
! Error: Failed to login

The username and password in the console command above are the same that I use to login to bugzilla from a web browser.

The contents of ~/.bugzrc are:

[bugs]  
base: http://bugs.domain.org.au/xmlrpc.cgi  
user: me@domain.org.au  
password: mypassword  
httpuser: me  
httppassword: mypassword  
logfile: /var/log/pybugz.log  
loglevel: debug  
forget: True  
columns: 80  
encoding: utf-8  
quiet: False

Same thing happens using the config file:
bugz --connection bugs --skip-auth get 1 works
bugz --connection bugs get 1 does not work
Nothing is written to the log file. The log file permissions are myuser:root 666.


回答1:


Actually there are lot of issues when we try to integrate Pybugz 0.9.3 and Bugzilla 4.4 and above. This link says that the issue has been fixed with the latest version of Pybugz.

So, try installing the latest version of Pybugz, possibly 0.11.1 with Python version 3.x and then integrate it with your version of Bugzilla.

If it doesn't work then you need to downgrade your version of Bugzilla and it is quite easy to integrate it with Pybugz 0.9.3.




回答2:


Bugzilla changed their authentication mechanism in v4.4.3.
Pybugz added support for the new authentication but also dropped support for python 2.

Since Gitzilla requires pybugs I had to port gitzilla to python 3 and then add the token support.

You can clone it here: https://github.com/gtait/gitzilla
Tested and working with Bugzilla 4.4.6 and 4.2.11 using pybugz 0.11.1 on python3.



来源:https://stackoverflow.com/questions/27349600/cannot-login-to-bugzilla-from-pybugz

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!