Skip to content

Conversation

yoff
Copy link
Contributor

@yoff yoff commented Mar 17, 2021

Adjustment of #5389

@RasmusWL RasmusWL added the no-change-note-required This PR does not need a change note label Mar 17, 2021
RasmusWL
RasmusWL previously approved these changes Mar 17, 2021
Copy link
Member

@RasmusWL RasmusWL left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@yoff yoff added the ready-for-doc-review This PR requires and is ready for review from the GitHub docs team. label Mar 17, 2021
@github-actions
Copy link
Contributor

Hello @github/docs-content-codeql - this PR is ready for docs review.

RasmusWL
RasmusWL previously approved these changes Mar 17, 2021
Copy link
Contributor

@shati-patel shati-patel left a comment

Choose a reason for hiding this comment

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

Thanks for writing this! I've left some minor editorial suggestions, but this looks like a useful addition to the docs overall 😊


select API::moduleImport("re")

➤ `See this in the query console on LGTM.com <https://lgtm.com/query/1876172022264324639/>`__.
Copy link
Contributor

Choose a reason for hiding this comment

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

I see that this example has no results. Is it worth finding projects with a result? (Perhaps not necessary, since the next example shows results!)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think perhaps the API node corresponding to the imported module does not have a location and therefor does not show up as a result. While moduleImport is not meant to be used on its own, I wonder if this behaviour should be considered a bug, since we might be tempted to detect if certain libraries are imported just by seeing if moduleImport gives results..

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Issue created.


➤ `See this in the query console on LGTM.com <https://lgtm.com/query/288293322319747121/>`__.

Note the use of the set literal ``["View", "MethodView"]`` to match both classes simultaneously.
Copy link
Contributor

Choose a reason for hiding this comment

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

Yay, this might be the first set literal example I've seen "in the wild" in the docs! 😉 (Apart from the reference)

Co-authored-by: Shati Patel <42641846+shati-patel@users.noreply.github.com>
@yoff yoff requested a review from shati-patel March 19, 2021 15:51
@yoff
Copy link
Contributor Author

yoff commented Mar 19, 2021

Issue for the non-result here.

@yoff yoff requested a review from RasmusWL March 19, 2021 21:00
@erik-krogh erik-krogh removed the request for review from RasmusWL March 19, 2021 21:09
@erik-krogh erik-krogh merged commit 07ca09e into github:main Mar 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation no-change-note-required This PR does not need a change note Python ready-for-doc-review This PR requires and is ready for review from the GitHub docs team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants