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

Pass object explicitly to save_objects method #47

Merged
merged 1 commit into from
Oct 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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