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

Problem regenerating the graph #17

Open
dgarijo opened this issue Jul 5, 2021 · 0 comments
Open

Problem regenerating the graph #17

dgarijo opened this issue Jul 5, 2021 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@dgarijo
Copy link
Contributor

dgarijo commented Jul 5, 2021

After several hours retrieving information from Zenodo, I got the following error:

doing recursive search                                              [38/1907]
Traceback (most recent call last):                                           
  File "/usr/local/lib/python3.6/runpy.py", line 193, in _run_module_as_main 
    "__main__", mod_spec)                                                    
  File "/usr/local/lib/python3.6/runpy.py", line 85, in _run_code            
    exec(code, run_globals)                                                  
  File "/sosen/sosen/__main__.py", line 142, in <module>                     
    cli()                                                                    
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 829, in _
_call__                                                                      
    return self.main(*args, **kwargs)                                        
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 782, in m
ain                                                                          
    rv = self.invoke(ctx)                                                    
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1259, in 
invoke                                                                       
    return _process_result(sub_ctx.command.invoke(sub_ctx))                  
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 1066, in 
invoke                                                                       
    return ctx.invoke(self.callback, **ctx.params)                           
  File "/usr/local/lib/python3.6/site-packages/click/core.py", line 610, in i
nvoke                                                                        
    return callback(*args, **kwargs)                                         
  File "/sosen/sosen/__main__.py", line 66, in scrape                        
    run_scrape(**kwargs)                                                     
  File "/sosen/sosen/cli.py", line 46, in run_scrape                         
    for dict_obj in data_and_urls:
  File "/sosen/sosen/cli.py", line 41, in <genexpr>
    data_and_urls = (get_zenodo_data(query) for query in queries)
  File "/sosen/sosen/get_data.py", line 100, in get_zenodo_data
    children_data = get_zenodo_data(f"conceptrecid:\"{conceptrecid}\"", recur
sive=False)
  File "/sosen/sosen/get_data.py", line 55, in get_zenodo_data
    'Accept': "application/vnd.zenodo.v1+json"
  File "/sosen/sosen/get_data.py", line 11, in zenodo_get
    data = response.json()
return callback(*args, **kwargs)                                         
  File "/sosen/sosen/__main__.py", line 66, in scrape                        
    run_scrape(**kwargs)                                                     
  File "/sosen/sosen/cli.py", line 46, in run_scrape                         
    for dict_obj in data_and_urls:
  File "/sosen/sosen/cli.py", line 41, in <genexpr>
    data_and_urls = (get_zenodo_data(query) for query in queries)
  File "/sosen/sosen/get_data.py", line 100, in get_zenodo_data
    children_data = get_zenodo_data(f"conceptrecid:\"{conceptrecid}\"", recur
sive=False)
  File "/sosen/sosen/get_data.py", line 55, in get_zenodo_data
    'Accept': "application/vnd.zenodo.v1+json"
  File "/sosen/sosen/get_data.py", line 11, in zenodo_get
    data = response.json()
  File "/usr/local/lib/python3.6/site-packages/requests/models.py", line 898,
 in json
    return complexjson.loads(self.text, **kwargs)
  File "/usr/local/lib/python3.6/json/__init__.py", line 354, in loads
    return _default_decoder.decode(s)
  File "/usr/local/lib/python3.6/json/decoder.py", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/local/lib/python3.6/json/decoder.py", line 357, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

No new data were saved

Command run:

python -m sosen scrape --all -g graph_out_new.ttl -k keywords_out_new.ttl -t 0.85 -d somef_cache.json -c zenodo_cache.json
@dgarijo dgarijo added the bug Something isn't working label Jul 5, 2021
@dgarijo dgarijo added this to the v1.0.0 milestone Jul 7, 2021
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