Conversation
The get_doc_resource tool matched only bare docs slugs, so a slug copied from list_docs_resources (a full URL, a docs/ prefix, or a trailing .md) or any template or recipe page came back as not found. Normalize the slug and route template, recipe, and solution pages through a shared renderDetailMarkdown helper, now used by the MCP route, the markdown API route, and the static-artifact build script. Reported through DevHub agent feedback. Co-authored-by: Isaac <no-reply@databricks.com>
Collaborator
|
Tony's agent: I reproduced an issue with the section overview URLs returned by Calling Calling it with Individual detail URLs, such as The parser only recognizes |
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.
Overview
Fix slug resolution in the DevHub docs MCP server.
get_doc_resourcematched only bare docs slugs, so a slug copied fromlist_docs_resources(a full URL, adocs/prefix, or a trailing.md) and any template or recipe page returned not found. This normalizes the slug and routes template, recipe, and solution pages through a sharedrenderDetailMarkdownhelper, now used by the MCP route, the/api/markdownroute, and the static-artifact build script, so all three return identical markdown.Reported through DevHub agent feedback.
Verified end to end over HTTP against a local server: index-style slugs and template/recipe pages resolve, and path traversal is still rejected.
This pull request and its description were written by Isaac.