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

🐛 InjectTool cannot submit data into EBI BioSamples #120

Open
bunop opened this issue Jun 8, 2023 · 0 comments
Open

🐛 InjectTool cannot submit data into EBI BioSamples #120

bunop opened this issue Jun 8, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@bunop
Copy link
Member

bunop commented Jun 8, 2023

Describe the bug
BioSample API submission system was changed and InjectTool cannot submit a sample into BioSamples

To Reproduce
Steps to reproduce the behavior:

  1. Load new data
  2. Validate new data (🐛 InjectTool cannot validate data using OLS #119 need to be solved)
  3. Submit data into BioSamples

Expected behavior
Valid data need to be submitted to BioSamples

Errors

  File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 706, in urlopen
    chunked=chunked,
  File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 382, in _make_request
    self._validate_conn(conn)
  File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
    conn.connect()
  File "/usr/local/lib/python3.6/site-packages/urllib3/connection.py", line 421, in connect
    tls_in_tls=tls_in_tls,
  File "/usr/local/lib/python3.6/site-packages/urllib3/util/ssl_.py", line 450, in ssl_wrap_socket
    sock, context, tls_in_tls, server_hostname=server_hostname
  File "/usr/local/lib/python3.6/site-packages/urllib3/util/ssl_.py", line 493, in _ssl_wrap_socket_impl
    return ssl_context.wrap_socket(sock, server_hostname=server_hostname)
  File "/usr/local/lib/python3.6/ssl.py", line 407, in wrap_socket
    _context=self, _session=session)
  File "/usr/local/lib/python3.6/ssl.py", line 817, in __init__
    self.do_handshake()
  File "/usr/local/lib/python3.6/ssl.py", line 1077, in do_handshake
    self._sslobj.do_handshake()
  File "/usr/local/lib/python3.6/ssl.py", line 689, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:852)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 449, in send
    timeout=timeout
  File "/usr/local/lib/python3.6/site-packages/urllib3/connectionpool.py", line 756, in urlopen
    method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2]
  File "/usr/local/lib/python3.6/site-packages/urllib3/util/retry.py", line 574, in increment
    raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='submission-test.ebi.ac.uk', port=443): Max retries exceeded with url: /api/ (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:852)'),))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/var/uwsgi/image/biosample/tasks/submission.py", line 309, in run
    submission_helper.read_token()
  File "/var/uwsgi/image/biosample/tasks/submission.py", line 141, in read_token
    self.root = pyUSIrest.usi.Root(auth=self.auth)
  File "/usr/local/lib/python3.6/site-packages/pyUSIrest/usi.py", line 46, in __init__
    self.get(self.api_root)
  File "/usr/local/lib/python3.6/site-packages/pyUSIrest/client.py", line 329, in get
    response = super().get(url)
  File "/usr/local/lib/python3.6/site-packages/pyUSIrest/client.py", line 163, in get
    response = self.session.get(url, headers=headers, params=params)
  File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 555, in get
    return self.request('GET', url, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 542, in request
    resp = self.send(prep, **send_kwargs)
  File "/usr/local/lib/python3.6/site-packages/requests/sessions.py", line 655, in send
    r = adapter.send(request, **kwargs)
  File "/usr/local/lib/python3.6/site-packages/requests/adapters.py", line 514, in send
    raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='submission-test.ebi.ac.uk', port=443): Max retries exceeded with url: /api/ (Caused by SSLError(SSLError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:852)'),))

Additional context
Submission API endpoint are changed and pyUSIrest, a dependency required to data submission, need to be upgraded. Submission need to be tested using testing and production BioSamples endpoints

@bunop bunop added the bug Something isn't working label Jun 8, 2023
@bunop bunop added this to the General Enhancement milestone Jun 8, 2023
@bunop bunop pinned this issue Jun 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant