Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Search and all mappings options not working: error 500 #69

Open
britonb opened this issue Feb 19, 2020 · 1 comment
Open

Search and all mappings options not working: error 500 #69

britonb opened this issue Feb 19, 2020 · 1 comment

Comments

@britonb
Copy link

britonb commented Feb 19, 2020

Hi

Please find logs bellow.
Is this problem known?

Kind Regards
Nuno

::ffff:172.19.0.3 - - [2020-02-19 21:12:08] "POST /collection-counts HTTP/1.0" 500 445 0.001687
ERROR:web:Exception on /search_es [GET]
Traceback (most recent call last):
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 2446, in wsgi_app
response = self.full_dispatch_request()
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1951, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1820, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1949, in full_dispatch_request
rv = self.dispatch_request()
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1935, in dispatch_request
return self.view_functionsrule.endpoint
File "/data/web/views.py", line 505, in search_es
search_form = construct_search_form(es=True)
File "/data/web/views.py", line 815, in construct_search_form
search_form.oses.choices = [(pair, pair) for pair in fetch_os_releases()]
File "/data/web/views.py", line 829, in fetch_os_releases
return query_db(os_releases_query)
File "/data/web/views.py", line 1224, in query_db
client = ArangoClient(protocol='http', host='dbms')
TypeError: init() got an unexpected keyword argument 'protocol'

::ffff:172.19.0.3 - - [2020-02-19 21:12:18] "GET /search_es HTTP/1.0" 500 459 0.002182
::ffff:172.19.0.3 - - [2020-02-19 21:12:26] "GET /matchmaker HTTP/1.0" 200 15699 0.012075
::ffff:172.19.0.3 - - [2020-02-19 21:12:26] "GET /static/cui-1.2.2-official/fonts/CiscoSans/CiscoSansTTLightOblique.woff2 HTTP/1.0" 304 202 0.001336
::ffff:172.19.0.3 - - [2020-02-19 21:12:28] "GET /datapath/direct HTTP/1.0" 200 8412 0.001894
ERROR:web:Exception on /datapath/matches [GET]
Traceback (most recent call last):
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 2446, in wsgi_app
response = self.full_dispatch_request()
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1951, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1820, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1949, in full_dispatch_request
rv = self.dispatch_request()
File "/root/.local/share/virtualenvs/data-I7nS9QO2/lib/python3.8/site-packages/flask/app.py", line 1935, in dispatch_request
return self.view_functionsrule.endpoint
File "/data/web/views.py", line 36, in datapath_matches
dml_matches=fetch_all_matches()
File "/data/web/views.py", line 55, in fetch_all_matches
return query_db(all_matches_query)
File "/data/web/views.py", line 1224, in query_db
client = ArangoClient(protocol='http', host='dbms')
TypeError: init() got an unexpected keyword argument 'protocol'

@crisponions
Copy link

It seems a lot of upstream libraries have been changed since this was last updated. I had to add several packages to the pip file to get it to install.

I believe this error is related to a major change to version 5+ of the Arango client.

from arango import ArangoClient.

OLD

client = ArangoClient(protocol='http', host='localhost', port=8529)

NEW (single host)

client = ArangoClient(hosts='http://localhost:8529')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants