MCPcopy Create free account

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

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

↓ 2 callersFunctionserializeFiles
( files: FilesState, session: PlaygroundSession | null, )
playground/ty/src/Playground.tsx:579
↓ 2 callersFunctionserver_capabilities
Creates the server capabilities based on the resolved client capabilities and resolved global settings from the initialization options.
crates/ty_server/src/capabilities.rs:441
↓ 2 callersFunctionserver_diagnostic_options
Creates the default [`DiagnosticOptions`] for the server.
crates/ty_server/src/capabilities.rs:580
↓ 2 callersMethodset
(&mut self, rule: Rule, enabled: bool)
crates/ruff_linter/src/registry/rule_set.rs:209
↓ 2 callersFunctionset_assignment_primary_annotation
Set an assignment's primary message and return whether a message was added.
crates/ty_python_semantic/src/types/diagnostic.rs:2283
↓ 2 callersMethodset_config_file_override
(&mut self, path: impl AsRef<SystemPath>)
crates/ty/tests/file_watching.rs:424
↓ 2 callersMethodset_constructed_instance_type
(&mut self, instance_type: Type<'db>)
crates/ty_python_semantic/src/types/call/bind/constructor.rs:89
↓ 2 callersMethodset_constructor_context
( &mut self, db: &'db dyn Db, constructor_context: ConstructorContext<'db>, )
crates/ty_python_semantic/src/types/call/bind/constructor.rs:851
↓ 2 callersMethodset_context
Overwrite the error context tree with a new root context and child nodes.
crates/ty_python_semantic/src/types/relation.rs:1868
↓ 2 callersMethodset_enabled
(&self, enabled: bool)
crates/ty_python_semantic/src/types/relation_error.rs:964
↓ 2 callersMethodset_fallback_options
(&mut self, options: Options)
crates/ty/tests/file_watching.rs:432
↓ 2 callersMethodset_finish_message
(&self, message: String)
crates/ty_server/src/server/lazy_work_done_progress.rs:86
↓ 2 callersMethodset_globals
Set the [`Globals`] for the current [`Scope`].
crates/ruff_python_semantic/src/model.rs:1752
↓ 2 callersMethodset_headline_message
Sets the headline message for this diagnostic.
crates/ruff_db/src/diagnostic/mod.rs:238
↓ 2 callersMethodset_if_none
(&mut self, first: First<'a>)
crates/ruff_python_formatter/src/pattern/mod.rs:390
↓ 2 callersMethodset_if_none
(&mut self, first: First<'a>)
crates/ruff_python_formatter/src/expression/mod.rs:820
↓ 2 callersMethodset_implicitly_invoked
Record that these bindings were reached through an implicit method lookup.
crates/ty_python_semantic/src/types/call/bind.rs:946
↓ 2 callersMethodset_indent_align
(mut self, count: NonZeroU8)
crates/ruff_formatter/src/printer/call_stack.rs:69
↓ 2 callersMethodset_interpolated_string_state
( &mut self, interpolated_string_state: InterpolatedStringState, )
crates/ruff_python_formatter/src/context.rs:118
↓ 2 callersFunctionset_max_parallelism
Sets the maximum number of tasks to process in parallel. Returns the supplied limit if [`max_parallelism`] has already been read or set.
crates/ruff_db/src/lib.rs:88
↓ 2 callersMethodset_preview
(&mut self, preview: bool)
crates/ruff_server/src/session/options.rs:61
↓ 2 callersMethodset_primary_annotation_message
Set the message on the primary annotation for this diagnostic. If a message already exists on the primary annotation, then this overwrites the existi
crates/ruff_linter/src/checkers/ast/mod.rs:3850
↓ 2 callersMethodset_secondary_code
Set the secondary code for this diagnostic.
crates/ruff_db/src/diagnostic/mod.rs:465
↓ 2 callersMethodset_shutdown_requested
(&mut self, requested: bool)
crates/ty_server/src/session.rs:227
↓ 2 callersMethodset_singleton_constraints
Apply a merged result to a matching singleton, preserving this place's definition IDs.
crates/ty_python_core/src/use_def/place_state.rs:756
↓ 2 callersMethodset_source_overload_index
(&mut self, index: Option<NonZeroU32>)
crates/ty_python_semantic/src/types/signatures.rs:2530
↓ 2 callersMethodset_span
Sets the span on this annotation.
crates/ruff_db/src/diagnostic/mod.rs:858
↓ 2 callersMethodset_status
(self, status: Status)
crates/ruff_linter/resources/test/fixtures/pyflakes/F821_0.py:78
↓ 2 callersMethodset_stop
(&mut self)
crates/ty_project/src/watch/watcher.rs:140
↓ 2 callersMethodset_style_range
Set `style` for `line`, `col_start..col_end` range if: 1. That line and column range exist in `StyledBuffer` 2. `overwrite` is `true` or existing styl
crates/ruff_annotate_snippets/src/renderer/styled_buffer.rs:142
↓ 2 callersFunctionset_up_logging
(level: LogLevel)
crates/ruff_linter/src/logging.rs:124
↓ 2 callersFunctionset_uv_envs
(command: &mut Command, case: &CliTest, virtual_env: Option<&Path>)
crates/ty/tests/cli/uv_workspace.rs:90
↓ 2 callersMethodset_verbose
(self, db: &mut dyn Db, verbose: bool)
crates/ty_project/src/lib.rs:628
↓ 2 callersMethodset_version
(&mut self, version: DocumentVersion)
crates/ty_server/src/session.rs:2174
↓ 2 callersFunctionsetattr_behavior
Return the model's assignment behavior for `attribute`, or `None` if it cannot be determined.
crates/ty_python_semantic/src/types/dedicated/pydantic.rs:635
↓ 2 callersMethodsettings_for_uri
(&self, uri: &Uri)
crates/ruff_server/src/session/index.rs:364
↓ 2 callersMethodsettings_impl
(&self)
crates/ruff_server/src/session/settings.rs:37
↓ 2 callersMethodsetup
Setup a real-world project for benchmarking
crates/ruff_benchmark/src/real_world_projects.rs:63
↓ 2 callersFunctionsetupMonaco
( monaco: Monaco, settingsSchema: { fileMatch: [string]; uri: string; schema: object; }, )
playground/shared/src/setupMonaco.tsx:39
↓ 2 callersFunctionsetup_logging_with_filter
Sets up logging for the current thread and uses the passed filter to filter the shown events. Useful for capturing the tracing output in a failing tes
crates/ruff_db/src/testing.rs:174
↓ 2 callersFunctionsetup_micro_case_inner
(code: &str, venv_path: Option<&Path>)
crates/ruff_benchmark/benches/ty_shared/mod.rs:39
↓ 2 callersFunctionsetup_tracing
( level: VerbosityLevel, color: TerminalColor, writer: impl for<'a> MakeWriter<'a> + Send + Sync +
crates/ty/src/logging.rs:109
↓ 2 callersMethodshared_place_table
Shares the existing place table with another per-scope query result.
crates/ty_python_core/src/lib.rs:392
↓ 2 callersMethodshort_message
Abbreviate the message
crates/ruff_annotate_snippets/src/renderer/mod.rs:162
↓ 2 callersMethodshould_check_downstream
For constructors which may have downstreams (that is, metaclass `__call__` or `__new__`), analyze their overloads to determine whether to check downst
crates/ty_python_semantic/src/types/call/bind/constructor.rs:267
↓ 2 callersMethodshould_check_file
(&self, file: File)
crates/ty_project/src/db.rs:663
↓ 2 callersMethodshould_drop
(&mut self, element: &FormatElement)
crates/ruff_formatter/src/buffer.rs:532
↓ 2 callersMethodshould_edit_imported_name_for_import_from
Chooses an imported name edit for an import-from statement, including re-exports. For example, renaming `pkg.old` can change the imported name `old`
crates/ty_ide/src/will_rename.rs:616
↓ 2 callersMethodshould_edit_imported_name_for_plain_import
Chooses an imported name edit for a plain import statement (e.g., `pkg.old` to `pkg.new` in the statement `import pkg.old`).
crates/ty_ide/src/will_rename.rs:593
↓ 2 callersMethodshould_edit_module_member
Decides whether to edit `bound_name` when it is imported from `resolved_module` (e.g., `old` in `from facade import old`) or accessed as an attribute
crates/ty_ide/src/will_rename.rs:714
↓ 2 callersMethodshould_expand_intersection
( &self, db: &'db dyn Db, intersection: IntersectionType<'db>, )
crates/ty_python_semantic/src/types/relation.rs:1433
↓ 2 callersMethodshould_freshen
( &self, db: &'db dyn Db, generic_context: GenericContext<'db>, )
crates/ty_python_semantic/src/types/typevar.rs:949
↓ 2 callersMethodshould_index_file
Returns `true` if an included file should be indexed.
crates/ty_project/src/glob.rs:148
↓ 2 callersFunctionshould_insert_blank_line_after_class_in_stub_file
Checks if an empty line should be inserted after a class definition. This is only valid if the [`blank_line_after_nested_stub_class`](https://github.
crates/ruff_python_formatter/src/statement/suite.rs:615
↓ 2 callersMethodshould_retain_constraint
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, bound: Option<Type<'db
crates/ty_python_semantic/src/types/constraints/variables.rs:26
↓ 2 callersMethodshould_retry_after_provisional_arity
( &self, expansions: &CallArgumentExpansions<'_, '_, 'db>, )
crates/ty_python_semantic/src/types/call/bind.rs:4285
↓ 2 callersMethodshould_visit_lazy_type_attributes
(&self)
crates/ty_python_semantic/src/types/visitor.rs:535
↓ 2 callersFunctionshow_fix_status
Return `true` if the [`Printer`] should indicate that a rule is fixable.
crates/ruff/src/printer.rs:457
↓ 2 callersFunctionside_effect
Return whether `expr` has no side effects, maybe has side effects, or definitely has side effects. Unlike [`contains_effect`], which returns a simple
crates/ruff_python_ast/src/helpers.rs:234
↓ 2 callersMethodsimplified
Returns the provenance of a bound produced by simplifying two existing bounds. Simplifying bounds can make one input redundant, and a redundant input
crates/ty_python_semantic/src/types/constraints/variables.rs:85
↓ 2 callersMethodsimulate_runtime_load
Simulates a runtime load of a given [`ast::ExprName`]. This should not be run until after all the bindings have been visited. The main purpose of th
crates/ruff_python_semantic/src/model.rs:938
↓ 2 callersMethodsingle_definition
(self)
crates/ty_python_semantic/src/types/infer/builder/suspicious_conditions/exemptions.rs:480
↓ 2 callersMethodsingle_item
(&self)
crates/ty_python_semantic/src/types/call/bind.rs:1512
↓ 2 callersMethodsingle_key
(&self)
crates/ty_python_semantic/src/types/equality/enums.rs:1036
↓ 2 callersMethodsingle_required_positional_parameter_type
(&self)
crates/ty_python_semantic/src/types/signatures.rs:1335
↓ 2 callersFunctionsite_packages_editables
( db: &'db dyn Db, environment: ResolverEnvironment<'db>, )
crates/ty_module_resolver/src/resolve.rs:1034
↓ 2 callersFunctionsite_packages_filter
(python_version: &str)
crates/ty/tests/self_environment.rs:398
↓ 2 callersMethodsize_hint
(&self)
crates/ruff_python_ast/src/nodes.rs:329
↓ 2 callersFunctionskip_comment
(src: str, pos: Pos)
crates/ruff_benchmark/resources/tomllib/_parser.py:263
↓ 2 callersMethodskip_content
Skips all content until it finds the corresponding end tag with the given kind.
crates/ruff_formatter/src/printer/queue.rs:40
↓ 2 callersFunctionskip_range
( first: &Stmt, statements: &[Stmt], context: &PyFormatContext, )
crates/ruff_python_formatter/src/statement/suite.rs:931
↓ 2 callersMethodskip_source_order
(self)
crates/ruff_python_ast/generate.py:208
↓ 2 callersMethodslice
Returns the slice into the source code.
crates/ruff_python_formatter/src/comments/visitor.rs:323
↓ 2 callersMethodslot_definition
(self, db: &'db dyn Db)
crates/ty_python_semantic/src/types/class/slots.rs:290
↓ 2 callersFunctionslots_members
(body: &[Stmt])
crates/ruff_linter/src/rules/pylint/rules/redefined_slots_in_subclass.rs:124
↓ 2 callersMethodsnapshot
(&self)
crates/ty_python_semantic/src/types/constraints/paths.rs:446
↓ 2 callersFunctionsnapshot_diagnostics
( test: &MarkdownTest<'_, '_, C>, db: &dyn Db, tool_name: &'static str, relative_fixture_path:
crates/mdtest/src/lib.rs:700
↓ 2 callersMethodsnapshot_document
Captures client settings and a target for a document request.
crates/ty_server/src/session.rs:1252
↓ 2 callersMethodsnapshot_enclosing_state
( &mut self, enclosing_place: ScopedPlaceId, enclosing_place_expr: PlaceExprRef,
crates/ty_python_core/src/use_def.rs:3066
↓ 2 callersFunctionsnapshot_input_file_for_test
(root: &str, test_name: &str)
crates/ruff_python_formatter/tests/fixtures.rs:31
↓ 2 callersFunctionsnapshot_input_file_for_test
(root: &str, test_name: &str)
crates/ruff_python_parser/tests/fixtures.rs:50
↓ 2 callersMethodsnippets
(self, snippets: bool)
crates/ty_ide/src/completion.rs:145
↓ 2 callersMethodsolve_hash_map_with
( &mut self, generic_context: GenericContext<'db>, choose: &mut impl FnMut(
crates/ty_python_semantic/src/types/generics.rs:3403
↓ 2 callersMethodsolve_pending_projection
Shares recovery and normalization between streaming merged projection and correlated solution collection. The projection decides which solved evidence
crates/ty_python_semantic/src/types/generics.rs:3123
↓ 2 callersFunctionsome_func
( unformatted, args )
crates/ruff_python_formatter/resources/test/fixtures/black/cases/fmtskip8.py:2
↓ 2 callersFunctionsort_single_line_elements_sequence
Create a string representing a fixed-up single-line definition of `__all__` or `__slots__` (etc.), that can be inserted into the source code as a `ran
crates/ruff_linter/src/rules/ruff/rules/sequence_sorting.rs:220
↓ 2 callersFunctionsort_workspace_report_items
(items: &mut [WorkspaceDocumentDiagnosticReport])
crates/ty_server/tests/e2e/pull_diagnostics.rs:1201
↓ 2 callersMethodsource
Return the [`SourceValue`] of the cell.
crates/ruff_notebook/src/cell.rs:25
↓ 2 callersMethodsource_edit
Constructs a source edit, such as replacing the imported name `old` with `new`.
crates/ty_ide/src/will_rename.rs:517
↓ 2 callersFunctionsource_location_to_position
(location: &SourceLocation)
crates/ruff_server/src/edit/range.rs:117
↓ 2 callersMethodsource_map
Returns the map from extracted TOML offsets to their original script offsets.
crates/ruff_python_ast/src/script.rs:31
↓ 2 callersMethodsource_name
(&self)
crates/ruff_python_semantic/src/binding.rs:767
↓ 2 callersMethodsource_node
Returns the source expression for this base entry.
crates/ty_python_semantic/src/types/class/static_literal.rs:3528
↓ 2 callersMethodsource_order_data
(&self, source_order: SourceOrderId)
crates/ty_python_semantic/src/types/constraints.rs:1493
↓ 2 callersMethodsource_place
Separately parsed annotations and synthetic references resolve from their syntax.
crates/ty_python_semantic/src/types/infer/builder.rs:11036
↓ 2 callersMethodsource_text
(&self)
crates/ty_python_core/src/builder.rs:3482
↓ 2 callersMethodsource_tokens
Returns the [`Tokens`] for the parsed source file. Unlike [`Self::tokens`], this method always returns the tokens for the current file, even when wi
crates/ruff_linter/src/checkers/ast/mod.rs:517
↓ 2 callersMethodsource_type_for_format
Get the source type for formatter-oriented operations.
crates/ruff_server/src/session/index.rs:602
↓ 2 callersMethodsource_types_mut
(&mut self)
crates/ty_python_semantic/src/types/call/arguments.rs:115
↓ 2 callersFunctionspan_to_location
(span: &Span, context: &LspDiagnosticContext)
crates/ruff_server/src/lint.rs:546
← previousnext →7,001–7,100 of 31,766, ranked by callers