Skip to content

Conversation

@kshitijgetsac
Copy link
Contributor

@kshitijgetsac kshitijgetsac commented Nov 16, 2025

Summary

Fixes #1581
Adds configuration option to control whether hover tooltips display "Go to definition" links.

Following pattern from #1421.

Configuration

{
  "python.analysis.showHoverGoToLinks": false
}

Default: true (backward compatible)

Changes

  • workspace.rs: Add config field to LspAnalysisConfig
  • server.rs: Read config and pass to hover implementation
  • hover.rs: Conditionally show links based on config
  • playground.rs: Pass default value (true)
  • hover.rs (test): Update test

5 files changed, +18 insertions, -4 deletions

Testing

✅ Tested with config enabled/disabled
✅ Backward compatible (defaults to true)
✅ All existing tests pass

@meta-cla meta-cla bot added the cla signed label Nov 16, 2025
@kshitijgetsac
Copy link
Contributor Author

@yangdanny97 @kinto0 this is the pr for issue 1581

@yangdanny97 yangdanny97 requested a review from kinto0 November 17, 2025 02:23
@kinto0 kinto0 changed the title added the requested hover functionality Add configuration to control existence of "go to <type>" on hover Nov 17, 2025
Copy link
Contributor

@kinto0 kinto0 left a comment

Choose a reason for hiding this comment

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

Looks great! thanks for working on this. a few suggestions:

  • looks like CI is red for formatting, could you run the formatter?
  • would you be able to update ide.mdx and lsp/readme.md with a description of the new setting?
  • would you be able to add this config value to lsp/package.json so clients like vscode show it in the vscode settings?

@kshitijgetsac
Copy link
Contributor Author

kshitijgetsac commented Nov 18, 2025

thanks @kinto0 for the feedback I have made the required changes could you please review it and let me know if anything else needs to be done

…ake flag visible in vs code and did formatting
@meta-codesync
Copy link

meta-codesync bot commented Nov 18, 2025

@kinto0 has imported this pull request. If you are a Meta employee, you can view this in D87336223.

Copy link
Contributor

@yangdanny97 yangdanny97 left a comment

Choose a reason for hiding this comment

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

Review automatically exported from Phabricator review in Meta.

@meta-codesync
Copy link

meta-codesync bot commented Nov 18, 2025

@kinto0 merged this pull request in ed570ab.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add configuration to disable "Go to <type>" on hover

4 participants