Skip to content

Conversation

@dalthviz
Copy link
Contributor

@dalthviz dalthviz commented Mar 27, 2020

With @ccordoba12 we noticed that hover requests were not working for np or NumPy ufuncs like np.sin since the validation of definitions with x.name == word fails. For example:

  • name -> numpy vs word -> np
  • name -> ufunc vs word -> sin)

This PR proposes to not do the validation mentioned in case only one definition is returned by Jedi, and take that unique definition to respond the hover request.

@dalthviz dalthviz force-pushed the numpy_hover branch 2 times, most recently from a326507 to 51fe88c Compare March 27, 2020 19:22
@gatesn gatesn merged commit 0591ade into palantir:develop Apr 3, 2020
sthagen added a commit to sthagen/palantir-python-language-server that referenced this pull request Apr 4, 2020
PR: Fix hover request for numpy alias (np) and ufuncs (palantir#768)
@ccordoba12 ccordoba12 changed the title PR: Fix hover request for numpy alias (np) and ufuncs Fix hover request for numpy alias (np) and ufuncs Apr 18, 2020
@ccordoba12 ccordoba12 added this to the 0.31.10 milestone Apr 18, 2020
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.

3 participants