Skip to content

Fix Biolink type lookup filters - #16

Merged
shuchenliu merged 1 commit into
mainfrom
fix/biolink-type-filter
Sep 11, 2026
Merged

shuchenliu merged 1 commit into
mainfrom
fix/biolink-type-filter

Conversation

@shuchenliu

@shuchenliu shuchenliu commented Sep 11, 2026 •

Copy link
Copy Markdown
Member
  • Accept both the repeatable biolink_type parameter and the biolink_types alias.
  • Remove the optional biolink: prefix correctly using removeprefix.
  • Add coverage for singular and plural parameters.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

The changes are focused, with only a non-blocking OpenAPI documentation nit remaining.

Pull request overview

Fixes Biolink type lookup filtering by supporting singular/plural query parameters and normalizing prefixes.

Changes:

  • Supports biolink_type and biolink_types.
  • Removes the optional biolink: prefix.
  • Adds coverage for both parameter forms.
File summaries
File Summary
test/test_lookup_query.py Adds singular and plural filter coverage.
src/nameres/handlers/lookup.py Updates alias handling and prefix normalization; OpenAPI documentation for the plural query alias remains a nit.
Review details

Suppressed comments (1)

src/nameres/handlers/lookup.py:268

  • This adds biolink_types as a public query alias, but the OpenAPI definitions for both /lookup query operations still advertise only biolink_type; the existing plural schema is a request-body property. Without updating the API specification, generated clients and Swagger users cannot discover or reliably use the alias. Please add the plural query parameter to the relevant OpenAPI operations as well.
        biolink_types = [*self.get_arguments("biolink_types"), *self.get_arguments("biolink_type")]
  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@shuchenliu
shuchenliu merged commit 74b6f7d into main Sep 11, 2026
1 check passed
@shuchenliu
shuchenliu deleted the fix/biolink-type-filter branch September 11, 2026 23:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants