When I open http://localhost:9201/ and click "Connect" it gives a 500 "Internal Server" error in the JS Console.
The runserver logs show:
config settings.json not found, searched /etc/elastic-hq/settings.json,~/settings.json,elasticsearch-HQ/settings.json,elasticsearch-HQ/elastichq/settings.json,elasticsearch-HQ/elastichq/config/settings.json
loading config elasticsearch-HQ/elastichq/config/logger.json
2020-02-19 23:38:56,343 INFO engineio server.__init__:140 Server initialized for eventlet.
None
None
--- Logging error ---
Traceback (most recent call last):
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 58, in create_connection
verify_certs = string_to_bool(verify_certs)
File "elasticsearch-HQ/elastichq/common/utils.py", line 13, in string_to_bool
raise ValueError('invalid literal for boolean. Not a string.')
ValueError: invalid literal for boolean. Not a string.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 1034, in emit
msg = self.format(record)
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 880, in format
return fmt.format(record)
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 619, in format
record.message = record.getMessage()
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 380, in getMessage
msg = msg % self.args
TypeError: not all arguments converted during string formatting
Call stack:
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/greenthread.py", line 221, in main
result = function(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 818, in process_request
proto.__init__(conn_state, self)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 357, in __init__
self.handle()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 390, in handle
self.handle_one_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 466, in handle_one_request
self.handle_one_response()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 566, in handle_one_response
result = self.application(self.environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1997, in __call__
return self.wsgi_app(environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_socketio/__init__.py", line 43, in __call__
start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/engineio/middleware.py", line 67, in __call__
return self.wsgi_app(environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 480, in wrapper
resp = resource(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/views.py", line 84, in view
return self.dispatch_request(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 595, in dispatch_request
resp = meth(*args, **kwargs)
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 29, in _request_wrapper
return functor(*args, **kwargs)
File "elasticsearch-HQ/elastichq/api/clusters.py", line 129, in post
client_cert=client_cert)
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 173, in create_connection
LOG.error(message, ex)
Message: 'Unable to create connection to: http://localhost:9200'
Arguments: (ValueError('invalid literal for boolean. Not a string.'),)
--- Logging error ---
Traceback (most recent call last):
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 58, in create_connection
verify_certs = string_to_bool(verify_certs)
File "elasticsearch-HQ/elastichq/common/utils.py", line 13, in string_to_bool
raise ValueError('invalid literal for boolean. Not a string.')
ValueError: invalid literal for boolean. Not a string.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "miniconda3.7/lib/python3.7/logging/handlers.py", line 68, in emit
if self.shouldRollover(record):
File "miniconda3.7/lib/python3.7/logging/handlers.py", line 184, in shouldRollover
msg = "%s\n" % self.format(record)
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 880, in format
return fmt.format(record)
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 619, in format
record.message = record.getMessage()
File "miniconda3.7/lib/python3.7/logging/__init__.py", line 380, in getMessage
msg = msg % self.args
TypeError: not all arguments converted during string formatting
Call stack:
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/greenthread.py", line 221, in main
result = function(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 818, in process_request
proto.__init__(conn_state, self)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 357, in __init__
self.handle()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 390, in handle
self.handle_one_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 466, in handle_one_request
self.handle_one_response()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/eventlet/wsgi.py", line 566, in handle_one_response
result = self.application(self.environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1997, in __call__
return self.wsgi_app(environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_socketio/__init__.py", line 43, in __call__
start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/engineio/middleware.py", line 67, in __call__
return self.wsgi_app(environ, start_response)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 480, in wrapper
resp = resource(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/views.py", line 84, in view
return self.dispatch_request(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 595, in dispatch_request
resp = meth(*args, **kwargs)
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 29, in _request_wrapper
return functor(*args, **kwargs)
File "elasticsearch-HQ/elastichq/api/clusters.py", line 129, in post
client_cert=client_cert)
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 173, in create_connection
LOG.error(message, ex)
Message: 'Unable to create connection to: http://localhost:9200'
Arguments: (ValueError('invalid literal for boolean. Not a string.'),)
2020-02-19 23:39:01,018 ERROR elastichq exceptions._request_wrapper:37 Oops! Something bad happened.
Traceback (most recent call last):
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 29, in _request_wrapper
return functor(*args, **kwargs)
File "elasticsearch-HQ/elastichq/api/clusters.py", line 129, in post
client_cert=client_cert)
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 174, in create_connection
raise ex
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 58, in create_connection
verify_certs = string_to_bool(verify_certs)
File "elasticsearch-HQ/elastichq/common/utils.py", line 13, in string_to_bool
raise ValueError('invalid literal for boolean. Not a string.')
ValueError: invalid literal for boolean. Not a string.
[2020-02-19 23:39:01,022] ERROR in app: Exception on /api/clusters/_connect [POST]
Traceback (most recent call last):
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 29, in _request_wrapper
return functor(*args, **kwargs)
File "elasticsearch-HQ/elastichq/api/clusters.py", line 129, in post
client_cert=client_cert)
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 174, in create_connection
raise ex
File "elasticsearch-HQ/elastichq/service/ConnectionService.py", line 58, in create_connection
verify_certs = string_to_bool(verify_certs)
File "elasticsearch-HQ/elastichq/common/utils.py", line 13, in string_to_bool
raise ValueError('invalid literal for boolean. Not a string.')
ValueError: invalid literal for boolean. Not a string.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 480, in wrapper
resp = resource(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/views.py", line 84, in view
return self.dispatch_request(*args, **kwargs)
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask_restful/__init__.py", line 595, in dispatch_request
resp = meth(*args, **kwargs)
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 38, in _request_wrapper
return ApiException(message=exception_message, status_code=HTTP_Status.INTERNAL_SERVER_ERROR).to_response()
File "elasticsearch-HQ/elastichq/common/exceptions.py", line 62, in to_response
response = jsonify({"message": self.message, "status_code": self.status_code})
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/flask/json.py", line 298, in jsonify
if current_app.config['JSONIFY_PRETTYPRINT_REGULAR'] and not request.is_xhr:
File "elasticsearch-HQ/venv/lib/python3.7/site-packages/werkzeug/local.py", line 347, in __getattr__
return getattr(self._get_current_object(), name)
AttributeError: 'Request' object has no attribute 'is_xhr'
General information
Issue Description
I ran:
When I open http://localhost:9201/ and click "Connect" it gives a 500 "Internal Server" error in the JS Console. The runserver logs show: