MCPcopy Create free account
hub / github.com/getsentry/sentry / source_of

Method source_of

tools/flake8_plugin.py:659–665  ·  view source on GitHub ↗

"query string" / "request body" for an input source, else None.

(self, node: ast.expr)

Source from the content-addressed store, hash-verified

657 return self._is(node, frozenset(("data",)), self.body_locals)
658
659 def source_of(self, node: ast.expr) -> str | None:
660 """ "query string" / "request body" for an input source, else None."""
661 if self.is_query(node):
662 return "query string"
663 if self.is_body(node):
664 return "request body"
665 return None
666
667 def record_read(self, key: ast.expr, source: str, line: int, col: int) -> None:
668 if isinstance(key, ast.Constant) and isinstance(key.value, str):

Callers 2

visit_SubscriptMethod · 0.80
_record_input_callMethod · 0.80

Calls 2

is_queryMethod · 0.95
is_bodyMethod · 0.95

Tested by

no test coverage detected