Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/astral-sh/ruff
/ functions
Functions
28,410 in github.com/astral-sh/ruff
⨍
Functions
28,410
◇
Types & classes
6,658
↳
Endpoints
82
↓ 20 callers
Method
trailing
(&self, node: T)
crates/ruff_python_formatter/src/comments/mod.rs:310
↓ 20 callers
Method
try_upcast_to_callable
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/callable.rs:43
↓ 20 callers
Method
with_file
( mut self, path: &'a (impl AsRef<SystemPath> + ?Sized), content: &'a str,
crates/ty_python_semantic/src/db.rs:220
↓ 19 callers
Method
ancestor_ids
Returns an iterator over all [`NodeId`] ancestors, starting from the given [`NodeId`].
crates/ruff_python_semantic/src/nodes.rs:63
↓ 19 callers
Method
apply_specialization
( self, db: &'db dyn Db, f: impl FnOnce(GenericContext<'db>) -> Specialization<'db>,
crates/ty_python_semantic/src/types/class/static_literal.rs:499
↓ 19 callers
Method
as_function
(&self)
crates/ty_python_core/src/scope.rs:415
↓ 19 callers
Method
as_str
(&self)
crates/ruff_db/src/diagnostic/mod.rs:972
↓ 19 callers
Method
as_str
(self)
crates/ruff_linter/src/rules/pyupgrade/rules/pep695/private_type_parameter.rs:81
↓ 19 callers
Method
bump
Consumes the next character
crates/ruff_python_trivia/src/cursor.rs:82
↓ 19 callers
Method
close
Closes the virtual file.
crates/ruff_db/src/files.rs:636
↓ 19 callers
Function
create_dir
Helper function to create a directory and all parent directories
crates/ruff_linter/src/rules/isort/categorize.rs:462
↓ 19 callers
Method
current_statements
Returns an [`Iterator`] over the current statement hierarchy, from the current [`Stmt`] through to any parents.
crates/ruff_python_semantic/src/model.rs:1466
↓ 19 callers
Method
end_of_scope_symbol_bindings
( &self, symbol: ScopedSymbolId, )
crates/ty_python_core/src/use_def.rs:989
↓ 19 callers
Method
file_name
(&self)
crates/ty_project/src/watch.rs:73
↓ 19 callers
Method
finish
(self)
crates/ruff_python_formatter/src/comments/visitor.rs:613
↓ 19 callers
Method
following_node
Returns the node following the comment. The direct child node (ignoring lists) of the [`enclosing_node`](DecoratedComment::enclosing_node) that follo
crates/ruff_python_formatter/src/comments/visitor.rs:313
↓ 19 callers
Function
indentation_at_offset
Extract the leading indentation from a line.
crates/ruff_python_trivia/src/whitespace.rs:49
↓ 19 callers
Method
is_ascii
Returns `true` if the text only consists of ASCII characters
crates/ruff_source_file/src/line_index.rs:227
↓ 19 callers
Method
is_empty
(&self, snapshot: &ScratchSnapshot)
crates/ruff_python_parser/src/parser/scratch_buffer.rs:29
↓ 19 callers
Function
is_identifier
Returns `true` if a string is a valid Python identifier (e.g., variable name).
crates/ruff_python_stdlib/src/identifiers.rs:7
↓ 19 callers
Method
is_language_services_disabled
(&self)
crates/ty_server/src/session/settings.rs:43
↓ 19 callers
Function
is_overload
Returns `true` if a function definition is an `@overload`.
crates/ruff_python_semantic/src/analyze/visibility.rs:30
↓ 19 callers
Method
is_string_literal_expr
(&self)
crates/ruff_python_ast/src/generated.rs:2318
↓ 19 callers
Method
matches
Returns `true` if the given name matches any of the ignored patterns.
crates/ruff_linter/src/rules/pep8_naming/settings.rs:140
↓ 19 callers
Method
next
(&mut self)
crates/ruff_db/src/system/path.rs:979
↓ 19 callers
Method
nominal_class
If this type is a class instance, returns its class.
crates/ty_python_semantic/src/types.rs:1488
↓ 19 callers
Method
parse
Parses the content and returns its AST
crates/ruff_wasm/src/lib.rs:506
↓ 19 callers
Function
parse_suite
(source: &str)
crates/ruff_linter/src/rules/pylint/helpers.rs:402
↓ 19 callers
Method
pop
(&mut self)
crates/ty_python_semantic/src/types/constraints.rs:7348
↓ 19 callers
Function
predicate
(index: usize)
crates/ty_python_core/src/narrowing_constraints.rs:425
↓ 19 callers
Method
primary
Add a primary annotation with a message. If the message is empty, then an annotation without any message be created. See the docs on `TestEnvironmen
crates/ruff_db/src/diagnostic/render.rs:2761
↓ 19 callers
Function
process
(__debug__)
crates/ruff_linter/resources/test/fixtures/semantic_errors/write_to_debug.py:3
↓ 19 callers
Method
qualified_name
Returns the [`QualifiedName`] of the imported name (e.g., given `from foo import bar as baz`, returns `["foo", "bar"]`).
crates/ruff_python_semantic/src/imports.rs:60
↓ 19 callers
Method
range
Returns the [`TextRange`] for the diagnostic.
crates/ruff_db/src/diagnostic/mod.rs:523
↓ 19 callers
Function
render_docstring
(raw: &str)
crates/ty_ide/src/docstring/markdown/structured/rst.rs:834
↓ 19 callers
Method
seen_typing
(&self)
crates/ruff_python_semantic/src/model.rs:1716
↓ 19 callers
Method
source
(&self)
crates/ruff_linter/src/rules/pep8_naming/settings.rs:63
↓ 19 callers
Method
stmt
Generate source code from a [`Stmt`].
crates/ruff_python_codegen/src/generator.rs:140
↓ 19 callers
Method
suffix_elements
(&self)
crates/ty_python_semantic/src/types/tuple.rs:1091
↓ 19 callers
Method
tokens
Returns all the tokens for the parsed output.
crates/ruff_python_parser/src/lib.rs:401
↓ 19 callers
Function
trailing
()
crates/ruff_python_formatter/src/comments/map.rs:643
↓ 19 callers
Function
walk_stmt
(visitor: &mut V, stmt: &'a Stmt)
crates/ruff_python_ast/src/visitor.rs:135
↓ 19 callers
Method
workspace_settings
Returns the client settings for the workspace that this document belongs to.
crates/ty_server/src/session.rs:1390
↓ 18 callers
Method
add_positive_in_place
(&mut self, ty: Type<'db>)
crates/ty_python_semantic/src/types/set_theoretic/builder.rs:1236
↓ 18 callers
Method
append
(self)
crates/ruff_python_formatter/resources/test/fixtures/black/cases/preview_long_strings__regression.py:109
↓ 18 callers
Method
binding_id
Returns the [`BindingId`] if this symbol resolves to a concrete binding.
crates/ruff_python_semantic/src/model.rs:44
↓ 18 callers
Method
build
(self)
crates/ty_python_semantic/src/db.rs:229
↓ 18 callers
Method
bytes
Returns an iterator over the bytes of the concatenated bytestring.
crates/ruff_python_ast/src/nodes.rs:1886
↓ 18 callers
Method
class
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/instance.rs:238
↓ 18 callers
Method
collect_publish_diagnostic_notifications
( &mut self, count: usize, )
crates/ty_server/tests/e2e/main.rs:555
↓ 18 callers
Method
contents
Return the underlying source code.
crates/ruff_linter/src/locator.rs:117
↓ 18 callers
Method
definition
(&self, id: ScopedDefinitionId)
crates/ty_python_core/src/use_def.rs:957
↓ 18 callers
Method
enter_node
(&mut self, node: T)
crates/ruff_python_ast_integration_tests/tests/visitor.rs:205
↓ 18 callers
Method
exit_node
(&mut self)
crates/ruff_python_ast_integration_tests/tests/visitor.rs:213
↓ 18 callers
Method
explicit_extra_items
Returns extra items only when they were explicitly declared. An implicitly open `TypedDict` returns `None` here because its hidden items are not dire
crates/ty_python_semantic/src/types/typed_dict.rs:95
↓ 18 callers
Method
file
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/ide_support.rs:2070
↓ 18 callers
Function
file_to_module
(db: &dyn Db, file: File)
crates/ty_module_resolver/src/resolve.rs:294
↓ 18 callers
Method
files
Returns the files belonging to this project.
crates/ty_project/src/lib.rs:613
↓ 18 callers
Method
finish
(&mut self)
crates/ruff_db/src/display.rs:49
↓ 18 callers
Method
finish
(self)
crates/ruff_linter/src/rules/pydoclint/rules/check_docstring.rs:915
↓ 18 callers
Method
generic_context
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/static_literal.rs:343
↓ 18 callers
Method
has_leading
(&self, node: T)
crates/ruff_python_formatter/src/comments/mod.rs:272
↓ 18 callers
Method
inference_flags
(&self)
crates/ty_python_semantic/src/types/infer/builder.rs:11238
↓ 18 callers
Method
insert
(mut self, insert: impl Into<CompactString>)
crates/ty_ide/src/completion.rs:535
↓ 18 callers
Method
interior_node_data
(&self, node: NodeId)
crates/ty_python_semantic/src/types/constraints.rs:1378
↓ 18 callers
Method
into_iter
(self)
crates/ty_site_packages/src/lib.rs:255
↓ 18 callers
Method
is_always_false
(self)
crates/ty_python_core/src/lib.rs:949
↓ 18 callers
Method
is_empty
(&self)
crates/ruff_annotate_snippets/src/snippet.rs:95
↓ 18 callers
Method
is_file
(self)
crates/ruff_db/src/system.rs:320
↓ 18 callers
Method
is_ipynb
(self)
crates/ruff_python_ast/src/lib.rs:153
↓ 18 callers
Method
is_same_typevar_as
Returns whether two bound typevars represent the same occurrence, regardless of e.g. differences in their bounds or constraints due to materialization
crates/ty_python_semantic/src/types/typevar.rs:1051
↓ 18 callers
Method
is_triple_quoted
Returns `true` if the current f-string is a triple-quoted f-string.
crates/ruff_python_parser/src/lexer/interpolated_string.rs:75
↓ 18 callers
Method
iter_all_elements
(&self)
crates/ty_python_semantic/src/types/tuple.rs:821
↓ 18 callers
Method
len
(&self)
crates/ruff_db/src/parsed.rs:477
↓ 18 callers
Method
line
Set the default line number to display
crates/ruff_annotate_snippets/src/snippet.rs:558
↓ 18 callers
Method
name
(self, db: &'db dyn Db, module: &'ast ParsedModuleRef)
crates/ty_python_core/src/scope.rs:59
↓ 18 callers
Method
node_index
Returns the anchor node index for this scope, or `None` for the module scope. This is used to compute relative node indices for expressions within th
crates/ty_python_core/src/scope.rs:441
↓ 18 callers
Method
open
(self, server: &mut TestServer)
crates/ty_server/tests/e2e/notebook.rs:629
↓ 18 callers
Method
or
(self, other: Self)
crates/ty_python_core/src/lib.rs:976
↓ 18 callers
Method
p
(&mut self, s: &str)
crates/ruff_python_codegen/src/generator.rs:171
↓ 18 callers
Method
path
Returns the relative path as specified by the user.
crates/ty_project/src/metadata/value.rs:53
↓ 18 callers
Method
report_diagnostic
( &self, context: &CallDiagnosticContext<'_, '_, 'db, '_>, node: ast::AnyNodeRef,
crates/ty_python_semantic/src/types/call/bind.rs:7898
↓ 18 callers
Method
return_type
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/call.rs:283
↓ 18 callers
Method
system
(&self)
crates/ruff_db/src/system/test.rs:91
↓ 18 callers
Method
try_call_dunder
Look up a dunder method on the meta-type of `self` and call it. Returns an `Err` if the dunder method can't be called, or the given arguments are not
crates/ty_python_semantic/src/types.rs:5548
↓ 18 callers
Method
ty
(self)
crates/ty_python_semantic/src/types/protocol_class.rs:1093
↓ 18 callers
Method
vendored
(&self)
crates/ty_module_resolver/src/resolve.rs:1751
↓ 17 callers
Method
add_negative
(mut self, ty: Type<'db>)
crates/ty_python_semantic/src/types/set_theoretic/builder.rs:1295
↓ 17 callers
Method
as_str
(self)
crates/ty_module_resolver/src/module.rs:363
↓ 17 callers
Method
as_str
(&self)
crates/ruff_linter/src/rules/ruff/rules/unused_noqa.rs:21
↓ 17 callers
Method
char_column
Set the default column to display <div class="warning"> `char_column` is only be respected if [`Origin::line`] is also set. </div>
crates/ruff_annotate_snippets/src/snippet.rs:570
↓ 17 callers
Function
check_os_pathlib_single_arg_calls
We check functions that take only 1 argument, this does not apply to functions with `dir_fd` argument, because `dir_fd` is not supported by pathlib,
crates/ruff_linter/src/rules/flake8_use_pathlib/helpers.rs:53
↓ 17 callers
Method
child_scopes
Returns an iterator over the direct child scopes of `scope`.
crates/ty_python_core/src/lib.rs:562
↓ 17 callers
Method
default_specialization
Returns the default specialization for this class. For static classes, this applies default type arguments. For dynamic classes, this returns a non-g
crates/ty_python_semantic/src/types/class.rs:635
↓ 17 callers
Function
delete_stmt
Return the [`Edit`] to use when deleting a [`Stmt`]. In some cases, this is as simple as deleting the [`TextRange`] of the [`Stmt`] itself. However,
crates/ruff_linter/src/fix/edits.rs:39
↓ 17 callers
Method
display
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/display.rs:603
↓ 17 callers
Method
element_type
(self, _db: &'db dyn Db)
crates/ty_python_semantic/src/types/tuple.rs:774
↓ 17 callers
Method
extension
(&self)
crates/ty_module_resolver/src/path.rs:838
↓ 17 callers
Method
finish
(self)
crates/ty_python_core/src/place.rs:419
↓ 17 callers
Method
first_public_binding
(&self, symbol: ScopedSymbolId)
crates/ty_python_core/src/lib.rs:1087
← previous
next →
701–800 of 28,410, ranked by callers