Skip to content

socket timeout exception handler: TypeError: not enough arguments for format string #70

Closed
@mutang

Description

@mutang

conn.optimize()
File "C:\tools\Python27\lib\site-packages\pysolr.py", line 825, in optimize
return self._update(msg, waitFlush=waitFlush, waitSearcher=waitSearcher)
File "C:\tools\Python27\lib\site-packages\pysolr.py", line 359, in _update
return self._send_request('post', path, message, {'Content-type': 'text/xml; charset=utf-8'})
File "C:\tools\Python27\lib\site-packages\pysolr.py", line 278, in _send_request
raise SolrError(error_message % [url, self.timeout])
TypeError: not enough arguments for format string

bug fix: pysolr.py line: 278 should change to:
patch here:
-raise SolrError(error_message % [url, self.timeout])
+raise SolrError(error_message % (url, self.timeout))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions