Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/astral-sh/ruff
/ functions
Functions
31,766 in github.com/astral-sh/ruff
⨍
Functions
31,766
◇
Types & classes
7,128
↳
Endpoints
82
↓ 1 callers
Method
lex_interpolated_string_middle_or_end
Lex an f-string or t-string middle or end token.
crates/ruff_python_parser/src/lexer.rs:745
↓ 1 callers
Method
lex_interpolated_string_start
Lex a f-string or t-string start token if positioned at the start of an f-string or t-string.
crates/ruff_python_parser/src/lexer.rs:723
↓ 1 callers
Method
lex_ipython_escape_command
Lex a single IPython escape command.
crates/ruff_python_parser/src/lexer.rs:1118
↓ 1 callers
Method
lex_number
Numeric lexing. The feast can start!
crates/ruff_python_parser/src/lexer.rs:987
↓ 1 callers
Method
lex_number_radix
Lex a hex/octal/decimal/binary number without a decimal point.
crates/ruff_python_parser/src/lexer.rs:1004
↓ 1 callers
Method
lex_token
(&mut self)
crates/ruff_python_parser/src/lexer.rs:155
↓ 1 callers
Function
lexical_return_type
The return annotation in the function's lexical scope, before callable type variables are rescoped or the return type of an async function is wrapped.
crates/ty_python_semantic/src/types/signatures.rs:95
↓ 1 callers
Function
lib2to3_parse
Given a string with source, return the lib2to3 Node.
crates/ruff_python_formatter/resources/test/fixtures/black/cases/pattern_matching_generic.py:91
↓ 1 callers
Function
limited_parallelism
(coroutine: Awaitable[T])
python/ruff-ecosystem/ruff_ecosystem/main.py:56
↓ 1 callers
Method
line_belongs_to_section
( &self, line: ParsedLine<'_>, line_header: Option<Header>, starts_item_block:
crates/ty_ide/src/docstring/document/numpy.rs:312
↓ 1 callers
Method
line_end_exclusive
(&self, line: OneIndexed)
crates/ruff_source_file/src/lib.rs:71
↓ 1 callers
Method
line_index
Returns the row number for a given offset. ## Examples ``` # use ruff_text_size::TextSize; # use ruff_source_file::{LineIndex, OneIndexed, LineColum
crates/ruff_source_file/src/line_index.rs:249
↓ 1 callers
Method
line_len
Returns the length of the line in characters, respecting the given encoding
crates/ruff_source_file/src/line_index.rs:215
↓ 1 callers
Method
line_num
Override the output style for line numbers in the [`Snippet`][crate::Snippet] gutter
crates/ruff_annotate_snippets/src/renderer/mod.rs:240
↓ 1 callers
Method
line_number
(&self, char_index: TextSize)
crates/mdtest/src/parser.rs:1061
↓ 1 callers
Method
line_position
The position of the comment in the text.
crates/ruff_python_formatter/src/comments/visitor.rs:318
↓ 1 callers
Method
line_range
Computes the range of this `offset`s line ending before the newline character. The range starts at the beginning of the line and goes up to, but excl
crates/ruff_source_file/src/line_ranges.rs:122
↓ 1 callers
Function
line_starts_markdown_block_content
(line: &str, at_description_start: bool)
crates/ty_ide/src/docstring/markdown/structured.rs:338
↓ 1 callers
Function
line_too_long
E501
crates/ruff_linter/src/rules/pycodestyle/rules/line_too_long.rs:86
↓ 1 callers
Method
line_width
(&self)
crates/ruff_python_formatter/src/options.rs:244
↓ 1 callers
Function
link_rule_names
Replace `rule-name` with [`rule-name`](url) for any known rule names, turning them into inline links automatically.
crates/ruff_dev/src/generate_ty_rules.rs:190
↓ 1 callers
Method
lint
(&self, db: &dyn Db, diagnostics: &mut Vec<OptionDiagnostic>)
crates/ty_project/src/metadata/options.rs:1309
↓ 1 callers
Method
lint
(&self)
crates/ruff_server/src/session/settings.rs:151
↓ 1 callers
Method
lint_options
(&self, db: &dyn Db)
crates/ty_project/src/metadata.rs:533
↓ 1 callers
Method
lint_override
(&self, db: &dyn Db, diagnostics: &mut Vec<OptionDiagnostic>)
crates/ty_project/src/metadata/options.rs:1939
↓ 1 callers
Function
lint_path
Wraps [`lint_path`](crate::diagnostics::lint_path) in a [`catch_unwind`](std::panic::catch_unwind) and emits a diagnostic if the linting the file pani
crates/ruff/src/commands/check.rs:196
↓ 1 callers
Function
lint_stdin
Generate `Diagnostic`s from source code content derived from stdin.
crates/ruff/src/diagnostics.rs:383
↓ 1 callers
Function
linter
(format: HelpFormat)
crates/ruff/src/commands/linter.rs:30
↓ 1 callers
Function
list
()
crates/ruff_linter/resources/test/fixtures/flake8_comprehensions/C408.py:8
↓ 1 callers
Function
list_all_modules
( db: &'db dyn Db, resolver_environment: ResolverEnvironment<'db>, )
crates/ty_module_resolver/src/resolve/search.rs:43
↓ 1 callers
Function
list_assign_reversed
FURB187
crates/ruff_linter/src/rules/refurb/rules/list_reverse_copy.rs:70
↓ 1 callers
Function
list_snapshot_filter
( db: &'db TestDb, predicate: impl Fn(&Module<'db>) -> bool, )
crates/ty_module_resolver/src/list.rs:62
↓ 1 callers
Function
list_submodules_by_name
( db: &'db dyn Db, name: ModuleNameIngredient<'db>, )
crates/ty_module_resolver/src/resolve/search.rs:100
↓ 1 callers
Method
list_terminator
Returns the token that terminates a list of parameters.
crates/ruff_python_parser/src/parser/mod.rs:1057
↓ 1 callers
Method
list_terminator_kind
(self, p: &Parser)
crates/ruff_python_parser/src/parser/mod.rs:1293
↓ 1 callers
Function
literal_comparisons
E711, E712
crates/ruff_linter/src/rules/pycodestyle/rules/literal_comparisons.rs:207
↓ 1 callers
Function
literal_contains_string_only_escapes
(literal: &StringLiteral, locator: &Locator)
crates/ruff_linter/src/rules/pyupgrade/rules/unnecessary_encode_utf8.rs:306
↓ 1 callers
Function
literal_content_range
Determines the content range of a valid string or byte literal if it's non-empty.
crates/ty_ide/src/selection_range.rs:50
↓ 1 callers
Function
literal_dunder_all_assignment
Returns the elements of a list or tuple directly assigned to `__all__`.
crates/ty_python_core/src/static_dunder_all.rs:16
↓ 1 callers
Function
literal_equality_fallthrough_code
()
crates/ruff_benchmark/benches/ty.rs:2022
↓ 1 callers
Function
literal_iterable_length
The literal element count used when inferring expansions such as `(*{"key": 1},)`. An expansion within a set or dictionary, as in `{*items}` or `{**it
crates/ty_python_semantic/src/types/unpacker.rs:705
↓ 1 callers
Function
literal_iterable_truthiness
Returns the static truthiness of a literal iterable. Returns [`Truthiness::Unknown`] for other expressions and when starred elements or dictionary un
crates/ty_python_core/src/builder.rs:6236
↓ 1 callers
Function
literal_keyword
(call: ast.Call, name: str)
scripts/collect_ty_ecosystem_run_metadata.py:163
↓ 1 callers
Function
literal_membership
PLR6201
crates/ruff_linter/src/rules/pylint/rules/literal_membership.rs:53
↓ 1 callers
Function
literal_or_pattern_reachability_code
()
crates/ruff_benchmark/benches/ty.rs:2067
↓ 1 callers
Method
literal_signature
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/function.rs:1986
↓ 1 callers
Function
load_ast
(root: Path)
crates/ruff_python_ast/generate.py:87
↓ 1 callers
Method
load_from_tokens
(mut self, tokens: &Tokens, indexer: &Indexer)
crates/ruff_linter/src/suppression.rs:752
↓ 1 callers
Function
load_options
Load `Options` from a `pyproject.toml` or `ruff.toml` file.
crates/ruff_workspace/src/pyproject.rs:182
↓ 1 callers
Function
load_state
(path: Path)
scripts/pull_request_reviewers.py:107
↓ 1 callers
Function
loads
Parse TOML from a string.
crates/ruff_benchmark/resources/tomllib/_parser.py:69
↓ 1 callers
Method
local
(kind: ScopeKind<'a>, parent: ScopeId)
crates/ruff_python_semantic/src/scope.rs:60
↓ 1 callers
Method
local_binding
Returns the local Python binding through which this fixture is exposed.
crates/ty_python_semantic/src/types/dedicated/pytest/fixtures.rs:1029
↓ 1 callers
Method
local_function_bindings
Pairs source methods with the alternatives that remain in this member's exposed type. Keeping definitions separate lets callers apply exclusions with
crates/ty_python_semantic/src/types/list_members.rs:736
↓ 1 callers
Method
local_source
( self, place_expr: PlaceExprRef, )
crates/ty_python_semantic/src/place_load.rs:1207
↓ 1 callers
Function
locals_in_render_function
DJ003
crates/ruff_linter/src/rules/flake8_django/rules/locals_in_render_function.rs:49
↓ 1 callers
Function
log_exception_outside_except_handler
LOG004
crates/ruff_linter/src/rules/flake8_logging/rules/log_exception_outside_except_handler.rs:90
↓ 1 callers
Function
logging_call
PLE1205 PLE1206
crates/ruff_linter/src/rules/pylint/rules/logging.rs:99
↓ 1 callers
Function
logging_config_insecure_listen
S612
crates/ruff_linter/src/rules/flake8_bandit/rules/logging_config_insecure_listen.rs:40
↓ 1 callers
Function
logging_eager_conversion
RUF065
crates/ruff_linter/src/rules/ruff/rules/logging_eager_conversion.rs:111
↓ 1 callers
Function
logging_f_string
( checker: &Checker, msg: &Expr, f_string: &ast::ExprFString, arguments: &Arguments, msg_p
crates/ruff_linter/src/rules/flake8_logging_format/rules/logging_call.rs:18
↓ 1 callers
Function
long_sleep_not_forever
ASYNC116
crates/ruff_linter/src/rules/flake8_async/rules/long_sleep_not_forever.rs:65
↓ 1 callers
Method
lookup
Classifies an ASCII identifier whose first character has already been consumed. `rest` starts after `first` and may extend past the identifier; `len`
crates/ruff_python_parser/src/lexer.rs:1653
↓ 1 callers
Method
lookup_binding
Lookup a concrete binding in the current scope. If `symbol` resolves to an unmaterialized builtin, this creates its binding before returning the [`Bi
crates/ruff_python_semantic/src/model.rs:827
↓ 1 callers
Method
lookup_binding_in_scope
Lookup a concrete binding in a certain scope. If `symbol` resolves to an unmaterialized builtin, this creates its binding before returning the [`Bind
crates/ruff_python_semantic/src/model.rs:841
↓ 1 callers
Function
lookup_dunder
Look up a comparison method in the class's MRO, excluding `object`'s identity fallback.
crates/ty_python_semantic/src/types/equality.rs:2152
↓ 1 callers
Method
lookup_or_parse
( &self, annotation: &ast::ExprStringLiteral, source: &str, )
crates/ruff_linter/src/checkers/ast/mod.rs:3515
↓ 1 callers
Method
lookup_path
( &mut self, path: &NormalizedVendoredPath, )
crates/ruff_db/src/vendored.rs:377
↓ 1 callers
Function
loop_exits_early
Returns `true` if the given body contains a `break` statement.
crates/ruff_linter/src/rules/pylint/rules/useless_else_on_loop.rs:97
↓ 1 callers
Method
loop_header_fallback_type
Compute the type for reads such as `box.value` or `items[0]` in loop iterations after `box` or `items` has been assigned a new object. A check on `bo
crates/ty_python_semantic/src/types/infer/builder.rs:10793
↓ 1 callers
Function
loop_header_reachability_impl
( db: &'db dyn Db, definition: Definition<'db>, mut cycle_initial_cache: Option<&mut FxHashMap<Def
crates/ty_python_semantic/src/place.rs:1632
↓ 1 callers
Method
loop_header_rebinds_target
( &self, definition: Definition<'db>, visited: &mut FxHashSet<Definition<'db>>, )
crates/ty_python_semantic/src/types/narrow.rs:1885
↓ 1 callers
Function
loop_iterator_mutation
B909
crates/ruff_linter/src/rules/flake8_bugbear/rules/loop_iterator_mutation.rs:58
↓ 1 callers
Function
loop_variable_overrides_iterator
B020
crates/ruff_linter/src/rules/flake8_bugbear/rules/loop_variable_overrides_iterator.rs:55
↓ 1 callers
Function
loop_variables_are_used_outside_loop
( binding_names: &[&ExprName], loop_range: TextRange, semantic: &SemanticModel, scope_id: Scop
crates/ruff_linter/src/rules/refurb/rules/for_loop_writes.rs:230
↓ 1 callers
Function
lorem
lorem ipsum dolor sit amet consectetur adipiscing elit sed do eiusmod tempor incididunt ut labore et dolore magna aliqua
crates/ruff_linter/resources/test/fixtures/pydocstyle/D209_D400.py:1
↓ 1 callers
Function
lowercase_imported_as_non_lowercase
N812
crates/ruff_linter/src/rules/pep8_naming/rules/lowercase_imported_as_non_lowercase.rs:54
↓ 1 callers
Method
lowest_precedence
Returns the lowest precedence of any operator in this binary chain.
crates/ruff_python_formatter/src/expression/binary_like.rs:581
↓ 1 callers
Function
lru_cache_with_maxsize_none
UP033
crates/ruff_linter/src/rules/pyupgrade/rules/lru_cache_with_maxsize_none.rs:64
↓ 1 callers
Function
lru_cache_without_parameters
UP011
crates/ruff_linter/src/rules/pyupgrade/rules/lru_cache_without_parameters.rs:58
↓ 1 callers
Method
lsp_command
(self, project: Project, venv: Venv)
scripts/ty_benchmark/src/benchmark/tool.py:134
↓ 1 callers
Method
lsp_initialization_options
( self, project: Project, venv: Venv )
scripts/ty_benchmark/src/benchmark/tool.py:66
↓ 1 callers
Function
lsp_range_to_text_range
Helper function to convert an LSP Range to internal `TextRange`. This is used internally by the `RangeExt` trait and in special cases where `db` and `
crates/ty_server/src/document/range.rs:293
↓ 1 callers
Function
magic_value_comparison
PLR2004
crates/ruff_linter/src/rules/pylint/rules/magic_value_comparison.rs:130
↓ 1 callers
Function
main
( command: RuffCommand, baseline_executable: Path, comparison_executable: Path, targets: list[
python/ruff-ecosystem/ruff_ecosystem/main.py:32
↓ 1 callers
Function
main
()
python/py-fuzzer/fuzz.py:1085
↓ 1 callers
Function
main
(argv: list[str] | None = None)
scripts/publish-crates.py:186
↓ 1 callers
Function
main
()
scripts/setup_primer_project.py:125
↓ 1 callers
Function
main
()
scripts/check-scripts.py:87
↓ 1 callers
Function
main
()
scripts/memory_report.py:531
↓ 1 callers
Function
main
()
scripts/generate-crate-readmes.py:85
↓ 1 callers
Function
main
()
scripts/update_ambiguous_characters.py:105
↓ 1 callers
Function
main
()
scripts/bump-workspace-crate-versions.py:30
↓ 1 callers
Function
main
Check code snippets in docs are formatted by Ruff.
scripts/check_docs_formatted.py:295
↓ 1 callers
Function
main
()
scripts/conformance.py:1079
↓ 1 callers
Function
main
Generate an MkDocs-compatible `docs` and `mkdocs.yml`.
scripts/generate_mkdocs.py:185
↓ 1 callers
Function
main
()
scripts/build_ruff_pgo.py:134
↓ 1 callers
Function
main
()
scripts/check-cargo-bans.py:107
↓ 1 callers
Function
main
Generate boilerplate for a new rule.
scripts/add_rule.py:56
↓ 1 callers
Function
main
()
scripts/pull_request_labels_and_title.py:36
← previous
next →
11,401–11,500 of 31,766, ranked by callers