Skip to content

Commit

Permalink
Merge pull request #47 from astropy/algolia_3
Browse files Browse the repository at this point in the history
Pass `object` explicitly to `save_objects` method
  • Loading branch information
jeffjennings authored Oct 30, 2024
2 parents a805b10 + 66eaff4 commit d7c861f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion astropylibrarian/workflows/indexjupyterbookpage.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ async def index_jupyterbook_page(
logger.debug(
"Indexing %d records for Jupyter Book page at %s", len(records), url
)
response = await algolia_index.save_objects(records)
response = await algolia_index.save_objects(records=records)
logger.debug("Algolia save_objects: %s", response.raw_responses)

object_ids = [r["objectID"] for r in records]
Expand Down
2 changes: 1 addition & 1 deletion astropylibrarian/workflows/indextutorial.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ async def index_tutorial(

saved_object_ids: List[str] = []
try:
response = await algolia_index.save_objects(records)
response = await algolia_index.save_objects(objects=records)
except RequestException as e:
logger.error(
"Error saving objects for tutorial %s:\n%s",
Expand Down

0 comments on commit d7c861f

Please sign in to comment.