Skip to content

error on using some special chars in password #24

Closed
@jacksitlab

Description

@jacksitlab

I get this error when trying to create an instance of the client

Traceback (most recent call last):
  File "/usr/lib/python3.8/http/client.py", line 868, in _get_hostport
    port = int(host[i+1:])
ValueError: invalid literal for int() with base 10: 'R'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "fillDokuWikiPage.py", line 72, in <module>
    run(args.config)
  File "fillDokuWikiPage.py", line 39, in run
    dokuwikiClient = RemoteDokuWikiClient('http://172.19.0.3',
  File "/home/jack/test/lib/dokuwiki/remoteDokuWikiClient.py", line 8, in __init__
    self.client = dokuwiki.DokuWiki(url, username, passwd)
  File "/home/jack/test/env/lib/python3.8/site-packages/dokuwiki.py", line 173, in __init__
    self.version
  File "/home/jack/test/env/lib/python3.8/site-packages/dokuwiki.py", line 211, in version
    return self.send('dokuwiki.getVersion')
  File "/home/jack/test/env/lib/python3.8/site-packages/dokuwiki.py", line 197, in send
    return method(*args)
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1109, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1450, in __request
    response = self.__transport.request(
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1153, in request
    return self.single_request(host, handler, request_body, verbose)
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1165, in single_request
    http_conn = self.send_request(host, handler, request_body, verbose)
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1266, in send_request
    connection = self.make_connection(host)
  File "/usr/lib/python3.8/xmlrpc/client.py", line 1243, in make_connection
    self._connection = host, http.client.HTTPConnection(chost)
  File "/usr/lib/python3.8/http/client.py", line 830, in __init__
    (self.host, self.port) = self._get_hostport(host, port)
  File "/usr/lib/python3.8/http/client.py", line 873, in _get_hostport
    raise InvalidURL("nonnumeric port: '%s'" % host[i+1:])
http.client.InvalidURL: nonnumeric port: 'R'

credentials are:

  • username: bot
  • password: R#IZM#@tf^93Vz3GKS§C

I reduced the problem to that, due the fact that if I remove '#' and '^' and '@' of the password and set this in the wiki it is working.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions