fix(theme): import Schema helpers from theme package for openapi-docs v5#513
Merged
steve-calvert-glean merged 1 commit intomainfrom Apr 27, 2026
Merged
Conversation
After bumping to docusaurus-plugin-openapi-docs@5.0.1 and docusaurus-theme-openapi-docs@5.0.1, getQualifierMessage was removed from the plugin's lib/markdown/schema and now lives only in the theme package. The swizzled Schema component still imported from the old plugin path, so the symbol silently became undefined and any page whose schema hit the call path crashed with "TypeError: getQualifierMessage is not a function" (e.g. /api/indexing-api/bulk-index-employees). Update the import to pull both helpers from the theme package where they now live. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
travis-hoover-glean
approved these changes
Apr 27, 2026
chris-freeman-glean
approved these changes
Apr 27, 2026
aditya-scio
approved these changes
Apr 27, 2026
rwjblue-glean
approved these changes
Apr 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/api/indexing-api/bulk-index-employeeswas crashing on production withTypeError: (0, em.getQualifierMessage) is not a function.docusaurus-plugin-openapi-docsremovedgetQualifierMessagefromlib/markdown/schema; it now lives only indocusaurus-theme-openapi-docs/lib/markdown/schema. Our swizzledsrc/theme/Schema/index.tsxstill imported from the old plugin path, so the symbol silently resolved toundefinedand any schema whose render path hit the call (e.g. theallOf/object shape in bulk-index-employees) crashed. Simpler schemas like/index-employeedidn't trip the code path, which is why only some pages broke.Test plan
pnpm buildsucceedspnpm exec docusaurus serve—/api/indexing-api/bulk-index-employeesrenders schema, params, and response sections with nogetQualifierMessageerror in the console/api/indexing-api/index-employeestill renders (no regression on the previously-working pages)Follow-up (not in this PR)
Reaching into
/lib/of an upstream package is the pattern that broke here. Worth a separate hardening pass to either inline the two small helpers into a local util or refresh the swizzle against v5 upstream and keep the Glean customizations as a thinner wrapper.🤖 Generated with Claude Code