ropensci / openalexR

Getting bibliographic records from OpenAlex
https://docs.ropensci.org/openalexR/
Other
89 stars 19 forks source link

oa2df not working since update 03-may #244

Closed alexdelrio1 closed 2 months ago

alexdelrio1 commented 2 months ago

The code below was working before, but since last update (May 3rd) it shows an error. Here an example of the code:

ws <- oa_request(
  "https://api.openalex.org/works?page=1&filter=primary_topic.domain.id:domains/4,primary_topic.field.id:fields/27,primary_topic.id:t10202,publication_year:2023,authorships.institutions.lineage:i4210105918,open_access.is_oa:true&per_page=10",
  verbose = T)
df_ws <- oa2df(ws, entity = "works")

The error is :

Error in (function (..., row.names = NULL, check.rows = FALSE, check.names = TRUE,  : 
  arguments imply differing number of rows: 0, 1

Any help would be much appreciated.

giuliogcantone commented 2 months ago

It works for me. Update all the dependencies of OAr.

alexdelrio1 commented 2 months ago

right, I didn't get an update, sorry

trangdata commented 2 months ago

@alexdelrio1 This code works in openalexR v1.3.0 for me.