X Tutup
Skip to content

Let search inside work if availability is down#11521

Merged
mekarpeles merged 4 commits intointernetarchive:masterfrom
cdrini:fix/search-inside-no-availability
Dec 29, 2025
Merged

Let search inside work if availability is down#11521
mekarpeles merged 4 commits intointernetarchive:masterfrom
cdrini:fix/search-inside-no-availability

Conversation

@cdrini
Copy link
Collaborator

@cdrini cdrini commented Nov 27, 2025

Closes #11519 . Note it fixes it so that the page isn't empty, but the borrow buttons again say "Locate" instead of the correct availability if the availability service is erroring.

Technical

Testing

Tested on testing and confirmed it still works, but testing isn't exhibiting the bug described in the issue. Going to patch deploy to see if it fixes it there.

Screenshot

Stakeholders

@cdrini cdrini added the Patch Deployed This PR has been deployed to production independently, outside of the regular deploy cycle. label Nov 27, 2025
@cdrini cdrini marked this pull request as ready for review November 27, 2025 17:46
Copilot AI review requested due to automatic review settings November 27, 2025 17:46
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request addresses issue #11519 by allowing the search inside functionality to continue working even when the availability service is down. Previously, when get_availability returned an error, the function would return empty search results. Now, it continues with an empty availability dictionary and fetches editions directly from the database.

Key changes:

  • Modified error handling to set availability = {} instead of returning empty hits when availability service fails
  • Changed edition lookup from using availability data to directly querying by ocaid
  • Simplified edition processing to use .get() for safe access to availability data

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mekarpeles mekarpeles self-assigned this Dec 1, 2025
@mekarpeles mekarpeles force-pushed the fix/search-inside-no-availability branch 2 times, most recently from c9ce8c7 to e78b465 Compare December 25, 2025 14:31
@mekarpeles
Copy link
Member

@cdrini lgtm -- I added web and tried to resolve the merge conflict -- can you double check and (if it looks right to you) merge at your discretion?

@mekarpeles mekarpeles added the Priority: 1 Do this week, receiving emails, time sensitive, . [managed] label Dec 25, 2025
@mekarpeles mekarpeles merged commit dc07890 into internetarchive:master Dec 29, 2025
4 checks passed
mystic-06 pushed a commit to mystic-06/openlibrary that referenced this pull request Jan 11, 2026
…e-no-availability

Let search inside work if availability is down
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Patch Deployed This PR has been deployed to production independently, outside of the regular deploy cycle. Priority: 1 Do this week, receiving emails, time sensitive, . [managed]

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Search inside feature seems to be broken in recent release

3 participants

X Tutup