After installing PatZilla in development mode on a fresh Ubuntu 18.10 box, customers are reporting a problem to us. While PatZilla starts fine and is apparently configured properly, it bails out when actually accessing the OPS services with this exception:
2019-01-31 18:11:00,896 INFO [patzilla.access.epo.ops.client ][waitress] OpsOAuthClientFactory.create_session: identifier=system, client_id=<redacted>
2019-01-31 18:11:00,898 INFO [patzilla.navigator.services.ops ][waitress] query raw: pn=EP666666
2019-01-31 18:11:00,898 INFO [patzilla.util.expression ][waitress] Parsing search expression "pn=EP666666" with syntax "cql" and grammar "default"
2019-01-31 18:11:01,168 INFO [patzilla.navigator.services.ops ][waitress] query cql: pn=EP0666666
2019-01-31 18:11:01,177 DEBUG [patzilla.access.epo.ops.api ][waitress] OPS request with client-id <redacted>
2019-01-31 18:11:01,453 DEBUG [patzilla.util.web.identity.store ][waitress] Measure transfer: userid=389e0df4-a846-440d-a445-a2c873871fca, upstream=ops, volume=86
2019-01-31 18:11:01,462 ERROR [patzilla.access.epo.ops.client ][waitress] OpsOAuth2Session HTTPError: 401 Client Error: Unauthorized for url: https://ops.epo.org/3.2/auth/accesstoken. client_id=<redacted>
2019-01-31 18:11:01,463 WARNING [patzilla.access.epo.ops.client ][waitress] Invalidating token and closing connection for client_id=<redacted>
2019-01-31 18:11:01,478 CRITICAL [patzilla.navigator.services ][waitress] ops-search error: query="pn=EP0666666", reason=pyramid.httpexceptions.HTTPBadGateway: Could not connect to OPS servers.
response:
None
exception:
Traceback (most recent call last):
File "/home/develop/patselect-dev/ip-navigator/patzilla/navigator/services/ops.py", line 105, in ops_published_data_search_handler
result = ops_published_data_search(constituents, search.expression, range)
File "/home/develop/patselect-dev/ip-navigator/.venv27/local/lib/python2.7/site-packages/beaker/cache.py", line 599, in cached
return cache[0].get_value(cache_key, createfunc=go)
File "/home/develop/patselect-dev/ip-navigator/.venv27/local/lib/python2.7/site-packages/beaker/cache.py", line 322, in get
return self._get_value(key, **kw).get_value()
File "/home/develop/patselect-dev/ip-navigator/.venv27/local/lib/python2.7/site-packages/beaker/container.py", line 378, in get_value
v = self.createfunc()
File "/home/develop/patselect-dev/ip-navigator/.venv27/local/lib/python2.7/site-packages/beaker/cache.py", line 597, in go
return func(*args, **kwargs)
File "/home/develop/patselect-dev/ip-navigator/patzilla/access/epo/ops/api.py", line 208, in ops_published_data_search
return ops_published_data_search_real(constituents, query, range)
File "/home/develop/patselect-dev/ip-navigator/patzilla/access/epo/ops/api.py", line 223, in ops_published_data_search_real
response = client.get(url, headers={'Accept': 'application/json'}, params={'q': query, 'Range': range})
File "/home/develop/patselect-dev/ip-navigator/.venv27/local/lib/python2.7/site-packages/requests/sessions.py", line 521, in get
return self.request('GET', url, **kwargs)
File "/home/develop/patselect-dev/ip-navigator/patzilla/access/epo/ops/client.py", line 192, in request
raise error
HTTPBadGateway: Could not connect to OPS servers.
2019-01-31 18:11:01,481 INFO [patzilla.navigator.services.ops ][waitress] query finished
We have been able to confirm this problem.