MCPcopy Create free account

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

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

↓ 4 callersMethodopenness
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/typed_dict.rs:975
↓ 4 callersMethodopposite
(self)
crates/ruff_python_ast/src/str.rs:37
↓ 4 callersMethodoptions
(&self)
crates/ty_project/src/metadata.rs:405
↓ 4 callersMethodoptions
Returns the client options for this workspace.
crates/ruff_server/src/workspace.rs:115
↓ 4 callersMethodor_never
Returns the retained type, or `Never` if every union element was disjoint.
crates/ty_python_semantic/src/types.rs:2272
↓ 4 callersMethodorder_rule_selectors
Sorts rule selectors according to their precedence. From highest to lowest precedence normal rule names An alias for another rule (the new name wins
crates/ty_project/src/metadata/options.rs:200
↓ 4 callersFunctionown_model_fields
(db: &'db dyn Db, class: StaticClassLiteral<'db>)
crates/ty_python_semantic/src/types/dedicated/django.rs:118
↓ 4 callersMethodpackage_roots
Return a mapping from Python package to its package root.
crates/ruff_workspace/src/resolver.rs:148
↓ 4 callersFunctionpad_expression
Re-formats the given expression for use within a formatted string. For example, when converting a `dict()` call to a dictionary literal within a form
crates/ruff_linter/src/rules/flake8_comprehensions/fixes.rs:322
↓ 4 callersMethodparent_range
Returns the range of the binding's parent.
crates/ruff_python_semantic/src/binding.rs:292
↓ 4 callersMethodparse
Parses a portable glob pattern. Returns an error if the pattern isn't valid.
crates/ty_project/src/glob/portable.rs:40
↓ 4 callersMethodparse_comma_separated_list_into_vec
Parses a comma separated list of elements into a vector where each element is parsed using the given `parse_element` function.
crates/ruff_python_parser/src/parser/mod.rs:755
↓ 4 callersMethodparse_generators
Parses a list of comprehension generators. These are the `for` and `async for` clauses in a comprehension, optionally followed by `if` clauses. See:
crates/ruff_python_parser/src/parser/expression.rs:2531
↓ 4 callersMethodparse_list
Parses a list of elements where each element is parsed using the given `parse_element` function.
crates/ruff_python_parser/src/parser/mod.rs:699
↓ 4 callersFunctionparse_pyproject_toml
Parse a `pyproject.toml` file.
crates/ruff_workspace/src/pyproject.rs:72
↓ 4 callersFunctionparse_string_annotation
Parses the given expression as a string annotation.
crates/ty_python_semantic/src/types/string_annotation.rs:51
↓ 4 callersFunctionpattern_binding_fallthrough_type
Return the fallthrough type for a binding that can reach a later match case. Failure of a sequence pattern establishes length and indexed-element fac
crates/ty_python_semantic/src/types/match_pattern.rs:1024
↓ 4 callersFunctionpattern_is_exhaustive_for_subject
Return whether `pattern` is statically guaranteed to match every value in `subject_ty`.
crates/ty_python_semantic/src/types/match_pattern.rs:588
↓ 4 callersMethodpeek_byte
(&self)
crates/ruff_python_parser/src/string.rs:152
↓ 4 callersFunctionplace_from_bindings_impl
Implementation of [`place_from_bindings`]. ## Implementation Note This function gets called cross-module. It, therefore, shouldn't access any AST nod
crates/ty_python_semantic/src/place.rs:1795
↓ 4 callersFunctionplace_from_bindings_with_reachability_cache
( db: &'db dyn Db, env: &ProgramEnvironment<'db>, bindings_with_constraints: BindingWithConstraint
crates/ty_python_semantic/src/place.rs:805
↓ 4 callersMethodpositive_constraints
( &self, )
crates/ty_python_semantic/src/types/constraints/paths.rs:552
↓ 4 callersMethodpositive_elements
(mut self, elements: I)
crates/ty_python_semantic/src/types/set_theoretic/builder.rs:1895
↓ 4 callersMethodpossibly_add_export
(&mut self, export: &'db Name, kind: PossibleExportKind)
crates/ty_python_core/src/re_exports.rs:77
↓ 4 callersMethodprecise_iterable_element_type
( &self, iterable: &ast::Expr, expression_type: impl FnMut(&ast::Expr) -> Type<'db>,
crates/ty_python_semantic/src/types/infer/builder.rs:5429
↓ 4 callersMethodpredicate_narrowing_targets
(&self)
crates/ty_python_core/src/use_def.rs:1612
↓ 4 callersFunctionprepare
( server: &mut crate::TestServer, path: impl AsRef<ruff_db::system::SystemPath>, position: Positio
crates/ty_server/tests/e2e/call_hierarchy.rs:301
↓ 4 callersMethodprepare_call_arguments
Infer the variadic argument types needed for call binding and emit the shared diagnostics for invalid `*args` and `**kwargs` inputs.
crates/ty_python_semantic/src/types/infer/builder.rs:9496
↓ 4 callersMethodprimary_tags
Returns the tags from the primary annotation of this diagnostic if it exists.
crates/ruff_db/src/diagnostic/mod.rs:342
↓ 4 callersMethodprogram_environment
(&self)
crates/ty_python_semantic/src/types/visitor.rs:531
↓ 4 callersMethodprogram_environment
(&self)
crates/ty_python_semantic/src/types/class/static_literal.rs:558
↓ 4 callersMethodprogram_file
(&self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/definition_resolution.rs:91
↓ 4 callersMethodproject_type_form
Projects type-form values to the static types that they represent. This projects `TypeForm[T]` to `T` and runtime class forms to their instance types
crates/ty_python_semantic/src/types/type_form.rs:37
↓ 4 callersMethodprojects_mut
Returns a mutable iterator over all project databases.
crates/ty_server/src/session.rs:586
↓ 4 callersMethodpromote_class_literals
Promote class literals to the class objects represented by `type[...]`. This is intentionally separate from regular promotion. Applying it during col
crates/ty_python_semantic/src/types.rs:3779
↓ 4 callersFunctionproperty
(value: &JsValue, name: &str)
crates/ruff_wasm/tests/api.rs:46
↓ 4 callersMethodproperty_deprecations
Collect deprecated accessor implementations without inferring their signatures or intersecting their function or descriptor types. Retain the declarat
crates/ty_python_semantic/src/types.rs:5092
↓ 4 callersMethodprovenance
(&self)
crates/ty_python_semantic/src/types.rs:12157
↓ 4 callersFunctionpublish_all_document_diagnostics
Publishes diagnostics for all open files that need push diagnostics.
crates/ty_server/src/server/api/diagnostics.rs:199
↓ 4 callersFunctionpublish_diagnostics_if_needed
Publishes the diagnostics for the given document snapshot using the [publish diagnostics notification] . Unlike [`publish_diagnostics`], this functio
crates/ty_server/src/server/api/diagnostics.rs:213
↓ 4 callersMethodpush_binding
Create a new [`Binding`] for the given `name` and `range`.
crates/ruff_python_semantic/src/model.rs:348
↓ 4 callersMethodpush_definition
(&mut self, entry: DefinitionEntry<'db>)
crates/ty_python_core/src/use_def.rs:2312
↓ 4 callersMethodpush_scope
Pushes a new scope and returns its unique id
crates/ruff_python_semantic/src/scope.rs:273
↓ 4 callersMethodpush_scope
(&mut self, node: NodeWithScopeRef)
crates/ty_python_core/src/builder.rs:510
↓ 4 callersMethodpython_version
The Python version used to resolve this module.
crates/ty_module_resolver/src/module.rs:84
↓ 4 callersMethodquote_len
The length of the quotes used to start and close the string. This does not include the length of any prefixes the string has in its opener.
crates/ruff_python_ast/src/nodes.rs:1016
↓ 4 callersMethodquote_style
(&self, flags: impl StringFlags)
crates/ruff_python_codegen/src/generator.rs:82
↓ 4 callersMethodrange
Range of the input source file covered by this formatted code, or None if the entire file is covered in this instance
crates/ruff_formatter/src/lib.rs:390
↓ 4 callersMethodrange
(&self)
crates/ruff_linter/src/suppression.rs:90
↓ 4 callersMethodrange
(&self)
crates/ruff_linter/src/rules/refurb/helpers.rs:171
↓ 4 callersMethodrange_relative
Returns the range of this section relative to [`Docstring::body`]
crates/ruff_linter/src/docstrings/sections.rs:364
↓ 4 callersMethodreachable_member_declarations
( &self, member: ScopedMemberId, )
crates/ty_python_core/src/use_def.rs:1383
↓ 4 callersMethodread_directory
( &'a self, path: &SystemPath, )
crates/ty_server/src/system.rs:269
↓ 4 callersMethodread_error
Returns `true` if there was an error when reading the content of the file.
crates/ruff_db/src/source.rs:112
↓ 4 callersMethodread_to_string
Reads the content of the file into a [`String`]. Reading the same file multiple times isn't guaranteed to return the same content. It's possible that
crates/ruff_db/src/files.rs:407
↓ 4 callersMethodreceive
Receive a message from the server. It will wait for `timeout` duration for a message to arrive. If no message is received within that time, it will r
crates/ty_server/tests/e2e/main.rs:723
↓ 4 callersMethodreceive
Receive a message from the server. It will wait for `timeout` duration for a message to arrive. If no message is received within that time, it will r
crates/ruff_server/tests/e2e/main.rs:589
↓ 4 callersMethodreceiver_constraint_types
(&self)
crates/ty_python_semantic/src/types/signatures.rs:2149
↓ 4 callersMethodrecord
(_visit: &mut dyn Visit)
crates/ruff_workspace/src/options.rs:646
↓ 4 callersMethodrecord_binding
Record a newly-encountered binding for this place.
crates/ty_python_core/src/use_def/place_state.rs:450
↓ 4 callersMethodrecord_binding_change
(&mut self)
crates/ty_python_core/src/use_def/exception_checkpoint.rs:45
↓ 4 callersMethodrecord_exception_checkpoint
Records the current flow state immediately before an operation that may raise an exception. This models exceptions from ordinary operations, not ever
crates/ty_python_core/src/builder.rs:2468
↓ 4 callersMethodrecord_reachability_constraint
( &mut self, reachability_constraint: ScopedReachabilityConstraintId, )
crates/ty_python_core/src/use_def.rs:2744
↓ 4 callersMethodrecord_reachability_constraint_id
Similar to [`Self::record_reachability_constraint`], but takes a [`ScopedPredicateId`].
crates/ty_python_core/src/builder.rs:2608
↓ 4 callersMethodrecursive_type_normalized_impl
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, div: Type<'db>,
crates/ty_python_semantic/src/types.rs:1864
↓ 4 callersMethodreferences
(&self)
crates/ty_ide/src/find_references.rs:128
↓ 4 callersMethodremove
(self, kind: TokenKind)
crates/ruff_python_parser/src/token_set.rs:24
↓ 4 callersMethodremove_redundant_entries
Two disjoint bases are allowed to coexist in an MRO if one is a subclass of the other. This method therefore removes any entry in `self` that is a sup
crates/ty_python_semantic/src/types/diagnostic.rs:3739
↓ 4 callersMethodrename
Rename a symbol (from `name` to `target`). ## How it works The renaming algorithm is as follows: 1. Determine the scope in which the rename should
crates/ruff_linter/src/renamer.rs:112
↓ 4 callersMethodrender
Render the given diagnostic into a `String`. (This will set the "printed" flag on `Diagnostic`.)
crates/ruff_db/src/diagnostic/render.rs:2707
↓ 4 callersFunctionrender_into
Renders normalized docstring source as Markdown. Outside recognized code blocks, leading indentation is encoded as non-breaking spaces. This preserve
crates/ty_ide/src/docstring/markdown/general.rs:26
↓ 4 callersFunctionrender_parameter_docstring
(description: &str, following_prose: &str)
crates/ty_ide/src/docstring/markdown/structured.rs:1068
↓ 4 callersFunctionrender_sections
(raw: &str, sections: Vec<Section>)
crates/ty_ide/src/docstring/markdown/structured.rs:1094
↓ 4 callersFunctionrender_sections_into
Renders a docstring from non-overlapping structured sections and general source fragments.
crates/ty_ide/src/docstring/markdown/structured.rs:30
↓ 4 callersFunctionreport_conflicting_metaclass_from_bases
Emit a diagnostic for a metaclass conflict where both conflicting metaclasses are inherited from base classes.
crates/ty_python_semantic/src/types/diagnostic.rs:3676
↓ 4 callersMethodreport_diagnostics_with_override
( &self, context: &InferContext<'db, '_>, node: ast::AnyNodeRef, overrides: &C
crates/ty_python_semantic/src/types/call.rs:436
↓ 4 callersFunctionreport_instance_layout_conflict
( context: &InferContext, header_range: TextRange, base_nodes: Option<&[ast::Expr]>, disjoint_
crates/ty_python_semantic/src/types/diagnostic.rs:3581
↓ 4 callersMethodrequest_project_sync
Requests fresh workspace metadata for project rediscovery.
crates/ty_project/src/uv/environments.rs:125
↓ 4 callersMethodrequest_queue
(&self)
crates/ty_server/src/session.rs:211
↓ 4 callersFunctionresolve_real_module
Resolves a module name to a module (stubs not allowed).
crates/ty_module_resolver/src/resolve.rs:159
↓ 4 callersFunctionresolve_scoped_settings
Resolve settings from a configuration file, reusing configuration files shared by the traversal.
crates/ruff_workspace/src/resolver.rs:410
↓ 4 callersFunctionresult
(diff: Diff, *, error: str | None = None)
python/ruff-ecosystem/tests/test_html.py:34
↓ 4 callersMethodresume_suspended_workspace_diagnostic_request
Resumes (retries) the workspace diagnostic request if there were any changes to the [`Session`] (the revision got bumped) since the workspace diagnost
crates/ty_server/src/session.rs:255
↓ 4 callersFunctionreturn_type
()
crates/ty_python_semantic/src/fixes.rs:1092
↓ 4 callersMethodrule
(&self)
crates/ruff_formatter/src/lib.rs:717
↓ 4 callersMethodrule_selection
(&self, _file: File)
crates/ty_python_semantic/src/db.rs:191
↓ 4 callersMethodrun
(self)
crates/ty_project/src/uv/service.rs:281
↓ 4 callersFunctionrun_uv_with_system
Runs uv in `directory` with the system's configured executable and environment. Returns an error if uv fails.
crates/ty/tests/file_watching.rs:4415
↓ 4 callersFunctionsame_enum_or_pattern_type
Return the exact set of values matched within the subject's enum by an OR of member patterns.
crates/ty_python_semantic/src/types/match_pattern.rs:962
↓ 4 callersMethodsatisfies
( &self, db: &dyn Db, importing_file: ImportingFile<'_>, request: &ImportReque
crates/ty_python_semantic/src/importer.rs:595
↓ 4 callersMethodscope
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/infer.rs:1001
↓ 4 callersMethodscope
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/enum_literal.rs:148
↓ 4 callersMethodscript_uv_override
The `project-manager.script` override that takes precedence over inline and project settings.
crates/ty_project/src/metadata.rs:401
↓ 4 callersMethodsearch_paths
(self, db: &'db dyn Db)
crates/ty_python_core/src/program.rs:47
↓ 4 callersMethodsecond
(&self)
crates/ruff_linter/src/suppression.rs:194
↓ 4 callersMethodsecond_operand
Returns the right operand of the first comparison (`b` in `a < b <= c`). # Panics Panics if there are fewer than two operands. See [`Self::first_ope
crates/ruff_python_ast/src/nodes.rs:136
↓ 4 callersFunctionsecondaryAnnotationsWithMessages
(annotations: readonly T[])
playground/shared/src/diagnostics.ts:1
↓ 4 callersMethodsecondary_annotation
Add a secondary annotation with the given message and range.
crates/ruff_linter/src/checkers/ast/mod.rs:3957
↓ 4 callersMethodsecondary_annotation_without_message
Add a secondary annotation without a message at the given range.
crates/ruff_linter/src/checkers/ast/mod.rs:3973
↓ 4 callersMethodsecondary_annotations
Returns all annotations, skipping the first primary annotation.
crates/ruff_db/src/diagnostic/mod.rs:363
← previousnext →3,501–3,600 of 31,766, ranked by callers