You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/codeql/codeql-language-guides/using-api-graphs-in-python.rst
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,9 +31,9 @@ following snippet demonstrates.
31
31
32
32
➤ `See this in the query console on LGTM.com <https://lgtm.com/query/1876172022264324639/>`__.
33
33
34
-
This query only selects the API graph node corresponding to the ``re`` module. To find
35
-
where this module is referenced, you can use the ``getAUse`` method. The following query selects
36
-
all references to the ``re`` module in the current database.
34
+
This query selects the API graph node corresponding to the ``re`` module. This node represents the fact that the ``re`` module has been imported rather than a specific location in the program where the import happens. Therefore, there will be at most one result per project, and it will not have a useful location, so you'll have to click `Show 1 non-source result` in order to see it.
35
+
36
+
To find where the ``re`` module is referenced in the program, you can use the ``getAUse`` method. The following query selects all references to the ``re`` module in the current database.
37
37
38
38
.. code-block:: ql
39
39
@@ -102,7 +102,7 @@ where the return value of ``re.compile`` is used:
102
102
Note that this includes all uses of the result of ``re.compile``, including those reachable via
103
103
local flow. To get just the *calls* to ``re.compile``, you can use ``getAnImmediateUse`` instead of
104
104
``getAUse``. As this is a common occurrence, you can use ``getACall`` instead of
105
-
``getReturn`` followed by ``getAnImmediateUse``.
105
+
``getReturn`` followed by ``getAnImmediateUse``.
106
106
107
107
➤ `See this in the query console on LGTM.com <https://lgtm.com/query/8143347716552092926/>`__.
108
108
@@ -131,7 +131,7 @@ all subclasses of ``View``, you must explicitly include the subclasses of ``Meth
0 commit comments