Skip to content

Illegal openaire token results in failed search error #7

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

Open
willu47 opened this issue Aug 12, 2024 · 0 comments
Open

Illegal openaire token results in failed search error #7

willu47 opened this issue Aug 12, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@willu47
Copy link
Contributor

willu47 commented Aug 12, 2024

If the OpenAire token is illegal or incorrect, then this is not raised as an error. Instead, we get the following consequent errors:

$ research_index data/d2d.txt 
  0%|                                                                                                                                                | 0/4 [00:00<?, ?it/s]
Traceback (most recent call last):
  File "/home/pi/mambaforge/envs/research_index/bin/research_index", line 8, in <module>
    sys.exit(entry_point())
             ^^^^^^^^^^^^^
  File "/home/pi/repositories/research_index_backend/src/research_index_backend/create_graph_from_doi.py", line 324, in entry_point
    result = main(list_of_dois, graph)
             ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pi/repositories/research_index_backend/src/research_index_backend/create_graph_from_doi.py", line 257, in main
    metadata = get_output_metadata(session, valid_doi)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pi/repositories/research_index_backend/src/research_index_backend/create_graph_from_doi.py", line 97, in get_output_metadata
    response.raise_for_status()
  File "/home/pi/mambaforge/envs/research_index/lib/python3.12/site-packages/requests/models.py", line 1024, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 403 Client Error: Forbidden for url: https://api.openaire.eu/search/researchProducts?format=json&doi=10.33774/coe-2023-sqbfm-v5
@willu47 willu47 added the bug Something isn't working label Aug 12, 2024
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