Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/sorting/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
无法连接到我的openfire服务器:python_Python_Openfire - Fatal编程技术网

无法连接到我的openfire服务器:python

无法连接到我的openfire服务器:python,python,openfire,Python,Openfire,我已经在我的fedora 20机器上安装了openfire服务器,我正在尝试连接并插入一个具有以下内容的新用户 from openfire import UserService api = UserService("192.xxx.x.xxx:9090/", "SecretKey") 我得到以下错误 Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/

我已经在我的fedora 20机器上安装了openfire服务器,我正在尝试连接并插入一个具有以下内容的新用户

from openfire import UserService
api = UserService("192.xxx.x.xxx:9090/", "SecretKey")
我得到以下错误

Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python2.7/site-packages/python_openfire-0.2.3_beta-py2.7.egg/openfire/user_service.py", line 60, in add_user
'groups': groups_str,
File "/usr/lib/python2.7/site-packages/python_openfire-0.2.3_beta-py2.7.egg/openfire/base.py", line 34, in _submit_request
raise HTTPException(e.reason)
openfire.exception.HTTPException: unknown url type: 192.xxx.x.xxx
回溯(最近一次呼叫最后一次):
文件“”,第1行,在
文件“/usr/lib/python2.7/site packages/python\u openfire-0.2.3\u beta-py2.7.egg/openfire/user\u service.py”,第60行,添加用户
“组”:组,
文件“/usr/lib/python2.7/site packages/python\u openfire-0.2.3\u beta-py2.7.egg/openfire/base.py”,第34行,在提交请求中
引发HTTPException(例如,原因)
openfire.exception.HTTPException:未知url类型:192.xxx.x.xxx
我已从以下url获取参考:


任何帮助都将不胜感激

尝试使用协议预先设置URL。例如HTTP:

api = UserService("http://192.xxx.x.xxx:9090/", "SecretKey")

显然,您还需要使用有效的IP地址或主机名,而不是“192.xxx.x.xxx”。

是的,它已连接,但出现以下错误
openfire.exception.HTTPException:HTTP服务器返回重定向错误,这将导致无限循环。最后一条30倍的错误消息是:已找到