MCPcopy Create free account

hub / github.com/astral-sh/ruff / functions

Functions31,562 in github.com/astral-sh/ruff

↓ 6 callersMethoddefinition
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/cyclic.rs:287
↓ 6 callersMethoddefinition_span
Returns a [`Span`] pointing to the definition of this class. For static classes, this is the class header (name and arguments). For dynamic classes,
crates/ty_python_semantic/src/types/class.rs:2562
↓ 6 callersFunctiondefinitions_for_name
Returns definitions for IDE navigation, expanding numeric annotations to their accepted classes.
crates/ty_python_semantic/src/types/ide_support.rs:83
↓ 6 callersMethoddeprecated_functions
Returns the deprecated functions invoked by each union alternative, including downstream constructor methods. An intersection only reports deprecation
crates/ty_python_semantic/src/types/call/bind.rs:977
↓ 6 callersFunctiondeserialize
(deserializer: D)
crates/ty_project/src/uv/metadata/string_interner.rs:37
↓ 6 callersMethoddid_change_watched_file
Sends a `workspace/didChangeWatchedFiles` notification for one path.
crates/ty_server/tests/e2e/main.rs:955
↓ 6 callersMethoddispose
()
playground/ty/src/Editor/Editor.tsx:556
↓ 6 callersMethodeat_if
Eats the next character if `predicate` returns `true`.
crates/ruff_python_trivia/src/cursor.rs:152
↓ 6 callersMethodemit
(&mut self, text: &dyn Debug)
crates/ruff_python_ast_integration_tests/tests/source_order.rs:176
↓ 6 callersFunctionempty
()
crates/ty_python_core/src/lib.rs:1305
↓ 6 callersMethodentries
Adds the contents of an iterator of entries to the join output.
crates/ruff_formatter/src/builders.rs:2491
↓ 6 callersFunctionenumerate_argument_types
( arguments: &'a CallArguments<'a, 'db>, )
crates/ty_python_semantic/src/types/call/bind.rs:5877
↓ 6 callersMethodenv_remove
Removes an environment variable from the command.
crates/ruff_db/src/system/command.rs:61
↓ 6 callersMethodescape_for_display
(mut self)
crates/ruff_python_literal/src/escape.rs:84
↓ 6 callersMethodevaluate
( &self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, id: ScopedPredicateId
crates/ty_python_semantic/src/reachability.rs:851
↓ 6 callersMethodevaluate_expr_compare_op
( &self, lhs_ty: Type<'db>, rhs_ty: Type<'db>, op: ast::CmpOp, is_posi
crates/ty_python_semantic/src/types/narrow.rs:3917
↓ 6 callersFunctionevaluate_reachability_with_cache
Evaluates a reachability constraint, optionally using an inference-local cache.
crates/ty_python_semantic/src/reachability.rs:2263
↓ 6 callersFunctionexact
( db: &'db TestDb, builder: &'c ConstraintSetBuilder<'db>, typevar: BoundTypeVarInstance<'db>,
crates/ty_python_semantic/src/types/constraints/projection/tests.rs:39
↓ 6 callersFunctionexpect_formatted
(result: FormatResult)
crates/ruff_server/src/format.rs:389
↓ 6 callersMethodexpect_union
(self)
crates/ty_python_semantic/src/types.rs:3280
↓ 6 callersMethodexplicit_bases
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/enum_literal.rs:162
↓ 6 callersMethodextend_cycle_recovery
(&mut self, other: Option<Type<'db>>)
crates/ty_python_semantic/src/types/infer/builder.rs:621
↓ 6 callersMethodextend_definition
( &mut self, definition: Definition<'db>, inference: &DefinitionInference<'db>, )
crates/ty_python_semantic/src/types/infer/builder.rs:640
↓ 6 callersMethodextend_expression_types
Replacing an expression's type also replaces any truthiness override. A newly inferred comparison may no longer need an override, so extending the spa
crates/ty_python_semantic/src/types/infer/builder.rs:787
↓ 6 callersFunctionextract_result_ids_from_response
(response: &WorkspaceDiagnosticReport)
crates/ty_server/tests/e2e/pull_diagnostics.rs:1600
↓ 6 callersMethodfile_expression_type
Get the type of an expression from any scope in the same file. If the expression is in the current scope, and we are inferring the entire scope, just
crates/ty_python_semantic/src/types/infer/builder.rs:1138
↓ 6 callersFunctionfile_to_uri
Returns a [`Uri`] for the given [`File`].
crates/ty_server/src/system.rs:26
↓ 6 callersFunctionfind_best_suggestion
( options: O, typo: &str, hide_underscored_suggestions: HideUnderscoredSuggestions, )
crates/ty_python_semantic/src/diagnostic/levenshtein.rs:27
↓ 6 callersMethodfirst_help_text
Returns the message of the first sub-diagnostic with a `Help` severity. Note that this is used as the fix title/suggestion for some of Ruff's output
crates/ruff_db/src/diagnostic/mod.rs:483
↓ 6 callersFunctionfix_all
Applies all fixes for the given fix mode. `check_file` is a separate parameter so that tests can easily mock out a file's diagnostics.
crates/ty_python_semantic/src/fixes.rs:80
↓ 6 callersFunctionfixture_exposures_for_definition
Returns the available pytest fixture exposures contributed by `definition`. A decorated function contributes an exposure directly: ```python # fixtu
crates/ty_python_semantic/src/types/dedicated/pytest/fixtures.rs:285
↓ 6 callersMethodflow_snapshot
(&self)
crates/ty_python_core/src/builder.rs:1329
↓ 6 callersFunctionfoo
()
crates/ruff_linter/resources/test/fixtures/flake8_pytest_style/PT031.py:37
↓ 6 callersFunctionfull
()
crates/ty_python_semantic/src/types/signatures.rs:6876
↓ 6 callersMethodfuture_annotations_or_stub
(&self)
crates/ruff_linter/src/checkers/ast/mod.rs:911
↓ 6 callersMethodget
Get a resolved glob.
crates/ruff/src/commands/analyze_graph.rs:297
↓ 6 callersMethodget
(&self, directive: MdtestDirective)
crates/mdtest/src/parser.rs:1104
↓ 6 callersMethodget_default
Returns the most appropriate type of this argument when there is no specific declared type.
crates/ty_python_semantic/src/types/call/arguments.rs:459
↓ 6 callersMethodhas
Returns `true` if this set has an option that resolves to `name`. The name can be separated by `.` to find a nested option. ## Examples ### Test fo
crates/ruff_options_metadata/src/lib.rs:199
↓ 6 callersMethodhas_aliases
Returns `true` if any direct element of this union is a type alias.
crates/ty_python_semantic/src/types/set_theoretic.rs:213
↓ 6 callersMethodhas_cyclic_mro
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class_base.rs:474
↓ 6 callersMethodhas_dangling
Returns `true` if node has any [dangling comments](self#dangling-comments).
crates/ruff_python_formatter/src/comments/mod.rs:308
↓ 6 callersMethodhas_generated_slots
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/slots.rs:266
↓ 6 callersMethodhas_implicit_receiver
Returns true if this overload has an implicit `self` or `cls` receiver parameter.
crates/ty_python_semantic/src/types/function.rs:382
↓ 6 callersMethodhas_known_fields
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/named_tuple.rs:485
↓ 6 callersMethodhas_provisional_marker
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, )
crates/ty_python_semantic/src/types/typevar.rs:149
↓ 6 callersMethodhas_relation_to
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, target: Type<'db>,
crates/ty_python_semantic/src/types/relation.rs:871
↓ 6 callersMethodhas_relation_to_with_typevar_evaluation
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, target: Type<'db>,
crates/ty_python_semantic/src/types/relation.rs:893
↓ 6 callersMethodhas_unspecialized_type_var
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, )
crates/ty_python_semantic/src/types/typevar.rs:137
↓ 6 callersMethodheader_span
Returns a [`Span`] pointing to the definition of this class. For static classes, this is the class header (name and arguments). For dynamic classes,
crates/ty_python_semantic/src/types/class.rs:981
↓ 6 callersMethodhover
(&self)
crates/ty_ide/src/hover.rs:7510
↓ 6 callersFunctionimported_symbol
Infers the public type of an imported symbol. If `requires_explicit_reexport` is [`None`], it will be inferred from the file's source type. For stub
crates/ty_python_semantic/src/place.rs:535
↓ 6 callersMethodin_boolean_test
Return `true` if the model is in boolean test.
crates/ruff_python_semantic/src/model.rs:2251
↓ 6 callersMethodin_init_module
Returns whether the file under analysis is an `__init__.py` file.
crates/ruff_linter/src/checkers/ast/mod.rs:553
↓ 6 callersMethodin_pep_257_docstring
Return `true` if the model is in a docstring as described in [PEP 257]. [PEP 257]: https://peps.python.org/pep-0257/#what-is-a-docstring
crates/ruff_python_semantic/src/model.rs:2274
↓ 6 callersMethodin_runtime_evaluated_annotation
Return `true` if the context is in a runtime-evaluated type annotation.
crates/ruff_python_semantic/src/model.rs:2101
↓ 6 callersMethodinfer_optional_expression
( &mut self, expression: Option<&ast::Expr>, tcx: TypeContext<'db>, )
crates/ty_python_semantic/src/types/infer/builder.rs:6661
↓ 6 callersFunctioninfer_unpack_types
(db: &'db dyn Db, unpack: Unpack<'db>)
crates/ty_python_semantic/src/types/infer.rs:895
↓ 6 callersMethodinsert
Insert a resolved glob.
crates/ruff/src/commands/analyze_graph.rs:292
↓ 6 callersMethodinsert
Insert the type of this argument when inferred with the provided type context.
crates/ty_python_semantic/src/types/call/arguments.rs:492
↓ 6 callersMethodintern_bindings
(&mut self, bindings: &Bindings)
crates/ty_python_core/src/use_def.rs:376
↓ 6 callersMethodinterpolations
Returns an iterator over all the [`InterpolatedElement`] nodes contained in this f-string.
crates/ruff_python_ast/src/nodes.rs:1414
↓ 6 callersMethodinto_code
Access the resulting code, consuming the result
crates/ruff_formatter/src/lib.rs:419
↓ 6 callersMethodinto_diagnostic
Convert this program-settings diagnostic into a diagnostic that can be stored on a project.
crates/ty_project/src/metadata/options.rs:723
↓ 6 callersMethodinto_diagnostic_message
(self)
crates/ruff_db/src/diagnostic/mod.rs:1664
↓ 6 callersMethodinto_edit
(self)
crates/ruff_linter/src/noqa.rs:1084
↓ 6 callersMethodinto_settings
( self, )
crates/ruff_workspace/src/options.rs:1189
↓ 6 callersMethodis_alias
Return `true` if this [`Binding`] represents an aliased symbol (e.g., `app` in `from fastapi import FastAPI as app`).
crates/ruff_python_semantic/src/binding.rs:76
↓ 6 callersMethodis_always_raise
Returns `true` if the [`Terminal`] behavior is `Raise` or `RaiseNotImplemented`.
crates/ruff_python_semantic/src/analyze/terminal.rs:44
↓ 6 callersMethodis_attribute_expr
(&self)
crates/ruff_python_ast/src/generated.rs:2540
↓ 6 callersFunctionis_cased_lowercase
Return `true` if a string is _cased_ as lowercase. A string is cased as lowercase if it contains at least one lowercase character and no uppercase ch
crates/ruff_python_stdlib/src/str.rs:96
↓ 6 callersMethodis_closed
(self)
crates/ty_python_semantic/src/types/typed_dict.rs:125
↓ 6 callersFunctionis_const_false
Return `true` if an [`Expr`] is a literal `False`.
crates/ruff_python_ast/src/helpers.rs:846
↓ 6 callersMethodis_data_descriptor
Returns whether this type is a data descriptor, i.e. defines `__set__` or `__delete__`. If this type is a union, requires all elements of union to be
crates/ty_python_semantic/src/types.rs:5547
↓ 6 callersMethodis_dataclass_like
Returns `true` if this class is a dataclass-like class. This covers `@dataclass`-decorated classes, as well as classes created via `dataclass_transfo
crates/ty_python_semantic/src/types/class/static_literal.rs:259
↓ 6 callersMethodis_empty
(&self)
crates/ty_project/src/files.rs:207
↓ 6 callersMethodis_empty
Whether there are no modules or stub override names to visit during recursive enumeration.
crates/ty_module_resolver/src/resolve/search.rs:459
↓ 6 callersMethodis_empty
(&self)
crates/ruff_python_parser/tests/generate_inline_tests.rs:46
↓ 6 callersMethodis_enabled
(self)
crates/ruff_python_formatter/src/options.rs:362
↓ 6 callersMethodis_f_string_expr
(&self)
crates/ruff_python_ast/src/generated.rs:2244
↓ 6 callersMethodis_first_party
Is this search path in "first party" code? i.e., The end user's project code.
crates/ty_module_resolver/src/path.rs:717
↓ 6 callersMethodis_fluent
(self)
crates/ruff_python_formatter/src/expression/mod.rs:1137
↓ 6 callersMethodis_fully_static
Checks whether the visited type contents contain no dynamic types. This is not a complete test for semantic staticness: the visitor skips original fu
crates/ty_python_semantic/src/types.rs:2545
↓ 6 callersFunctionis_immutable_annotation
Return `true` if `Expr` represents a reference to a type annotation that resolves to an immutable type.
crates/ruff_python_semantic/src/analyze/typing.rs:293
↓ 6 callersFunctionis_import_required_by_isort
( required_imports: &RequiredImports, stmt: StmtRef, alias: &Alias, )
crates/ruff_linter/src/rules/pyupgrade/rules/unnecessary_future_import.rs:85
↓ 6 callersMethodis_interpolated_string
Does the string have an `f`,`F`,`t`, or `T` prefix?
crates/ruff_python_ast/src/nodes.rs:2492
↓ 6 callersMethodis_intersection
Returns true if this element is an intersection of multiple callables.
crates/ty_python_semantic/src/types/call/bind.rs:511
↓ 6 callersFunctionis_keyword
See: https://github.com/python/cpython/blob/9d692841691590c25e6cf5b2250a594d3bf54825/Lib/keyword.py#L18
crates/ruff_python_stdlib/src/keyword.rs:2
↓ 6 callersMethodis_method_like
Returns `true` if this callable represents a function used as a class member.
crates/ty_python_semantic/src/types/callable.rs:907
↓ 6 callersMethodis_not
( self, because: impl std::fmt::Display, error_context: ErrorC
crates/ty_python_semantic/src/types/iteration.rs:801
↓ 6 callersMethodis_notimplemented
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types.rs:2742
↓ 6 callersMethodis_promotable
(self)
crates/ty_python_semantic/src/types/literal.rs:55
↓ 6 callersMethodis_raw_string
(&self)
crates/ruff_linter/src/docstrings/mod.rs:53
↓ 6 callersMethodis_removed
(&self)
crates/ty_python_semantic/src/lint.rs:222
↓ 6 callersFunctionis_set
Test whether the given binding can be considered a set. For this, we check what value might be associated with it through it's initialization and wha
crates/ruff_python_semantic/src/analyze/typing.rs:1097
↓ 6 callersMethodis_start
Returns `true` if `self` is any start tag.
crates/ruff_formatter/src/format_element/tag.rs:103
↓ 6 callersMethodis_terminal
(self)
crates/ty_python_core/src/narrowing_constraints.rs:58
↓ 6 callersMethodis_third_party
(self)
crates/ty_python_semantic/src/types/class/known.rs:2250
↓ 6 callersMethoditer
Return an iterator over live declarations for this place.
crates/ty_python_core/src/use_def/place_state.rs:263
↓ 6 callersMethoditer_callable_items
(&self)
crates/ty_python_semantic/src/types/call/bind.rs:1050
← previousnext →2,301–2,400 of 31,562, ranked by callers