MCPcopy Create free account

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

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

↓ 1 callersFunctionreport_match_pattern_against_non_runtime_checkable_protocol
( context: &InferContext, pattern_cls: T, protocol: ProtocolClass, )
crates/ty_python_semantic/src/types/diagnostic.rs:4037
↓ 1 callersFunctionreport_match_pattern_against_typed_dict
( context: &InferContext, pattern_cls: T, class: ClassLiteral, )
crates/ty_python_semantic/src/types/diagnostic.rs:4060
↓ 1 callersFunctionreport_missing_typed_dict_key
( context: &InferContext<'db, '_>, constructor_node: AnyNodeRef, typed_dict_ty: Type<'db>, mis
crates/ty_python_semantic/src/types/diagnostic.rs:4814
↓ 1 callersMethodreport_mixed_string_literal_error
(&mut self, strings: &[StringType], range: TextRange)
crates/ruff_python_parser/src/parser/expression.rs:1498
↓ 1 callersMethodreport_module_getattr_import_diagnostic
Reports a failed module `__getattr__` call on a `from` import. Imports defer this diagnostic until they have ruled out a real submodule: ```python f
crates/ty_python_semantic/src/types.rs:1017
↓ 1 callersFunctionreport_named_tuple_field_with_leading_underscore
( context: &InferContext<'db, '_>, class: StaticClassLiteral<'db>, field_name: &str, field_def
crates/ty_python_semantic/src/types/diagnostic.rs:4754
↓ 1 callersFunctionreport_namedtuple_field_without_default_after_field_with_default
( context: &InferContext<'db, '_>, class: StaticClassLiteral<'db>, (field, field_def): (&str, Opti
crates/ty_python_semantic/src/types/diagnostic.rs:4705
↓ 1 callersFunctionreport_overridden_final_method
( context: &InferContext<'db, '_>, member: &str, subclass_definition: Definition<'db>, // N.B.
crates/ty_python_semantic/src/types/diagnostic.rs:5528
↓ 1 callersFunctionreport_overridden_final_variable
( context: &InferContext<'db, '_>, member: &str, subclass_definition: Definition<'db>, supercl
crates/ty_python_semantic/src/types/diagnostic.rs:5713
↓ 1 callersFunctionreport_pep695_function_legacy_typevar
( context: &InferContext<'db, '_>, typevar: TypeVarInstance<'db>, range: TextRange, )
crates/ty_python_semantic/src/types/infer/builder/post_inference/function.rs:331
↓ 1 callersFunctionreport_possibly_unresolved_reference
( context: &InferContext, expr_name_node: &ast::ExprName, )
crates/ty_python_semantic/src/types/diagnostic.rs:3250
↓ 1 callersMethodreport_redundant_length_comparison
( &self, test: &ast::Expr, test_subexpression: &ast::Expr, subexpression_type:
crates/ty_python_semantic/src/types/infer/builder/suspicious_conditions/diagnostic.rs:878
↓ 1 callersFunctionreport_run
(comment: dict)
scripts/publish_pr_report.py:276
↓ 1 callersFunctionreport_runtime_check_against_non_runtime_checkable_protocol
( context: &InferContext, call: &ast::ExprCall, protocol: ProtocolClass, function: KnownFuncti
crates/ty_python_semantic/src/types/diagnostic.rs:3933
↓ 1 callersFunctionreport_runtime_check_against_typed_dict
( context: &InferContext, call: &ast::ExprCall, class: ClassLiteral, function: KnownFunction,
crates/ty_python_semantic/src/types/diagnostic.rs:4019
↓ 1 callersMethodreport_semantic_error
(&self, error: SemanticSyntaxError)
crates/ruff_python_parser/tests/fixtures.rs:640
↓ 1 callersFunctionreport_slice_step_size_zero
(context: &InferContext, node: AnyNodeRef)
crates/ty_python_semantic/src/types/diagnostic.rs:1799
↓ 1 callersFunctionreport_subclass_of_class_with_non_callable_init_subclass
( context: &InferContext<'db, '_>, call_error: CallError<'db>, class: StaticClassLiteral<'db>,
crates/ty_python_semantic/src/types/diagnostic.rs:6247
↓ 1 callersFunctionreport_too_many_positional_patterns_for_class_pattern
( context: &InferContext, first_excess_pattern: T, positional_limit: usize, positional_count:
crates/ty_python_semantic/src/types/diagnostic.rs:3889
↓ 1 callersFunctionreport_typed_dict_field_override
( context: &InferContext<'db, '_>, class: StaticClassLiteral<'db>, field_name: &str, reason: &
crates/ty_python_semantic/src/types/infer/builder/post_inference/typed_dict.rs:472
↓ 1 callersFunctionreport_undeclared_protocol_attribute
( context: &InferContext, target: &ast::ExprAttribute, protocol_class: ProtocolClass, )
crates/ty_python_semantic/src/types/diagnostic.rs:4309
↓ 1 callersFunctionreport_undeclared_protocol_member
( context: &InferContext, definition: Definition, protocol_class: ProtocolClass, class_symbol_
crates/ty_python_semantic/src/types/diagnostic.rs:4223
↓ 1 callersFunctionreport_undefined_reveal
(context: &InferContext, name: &ast::ExprName)
crates/ty_python_semantic/src/types/diagnostic.rs:3368
↓ 1 callersMethodreport_unresolved_reference
(&self, expr_name_node: &ast::ExprName)
crates/ty_python_semantic/src/types/infer/builder.rs:11000
↓ 1 callersFunctionreport_unsound_assignment
Report an assignment whose value is not a subtype of its declared type.
crates/ty_python_semantic/src/types/diagnostic.rs:2377
↓ 1 callersFunctionreport_unsound_return
( context: &InferContext, object_range: impl Ranged, return_type_range: impl Ranged, expected_
crates/ty_python_semantic/src/types/diagnostic.rs:2944
↓ 1 callersFunctionreport_unsound_yield
( context: &InferContext, yield_value: impl Ranged, kind: YieldKind, return_type_span: Option<
crates/ty_python_semantic/src/types/diagnostic.rs:3095
↓ 1 callersFunctionreport_unsupported_comparison
( context: &InferContext<'db, '_>, error: &UnsupportedComparisonError<'db>, range: TextRange,
crates/ty_python_semantic/src/types/diagnostic.rs:5767
↓ 1 callersFunctionrepository_file
(repository: str, path: str, revision: str)
scripts/collect_ty_ecosystem_run_metadata.py:351
↓ 1 callersMethodrepr
(&self, db: &'db dyn Db, env: &ProgramEnvironment<'db>)
crates/ty_python_semantic/src/types.rs:10821
↓ 1 callersMethodrepresentation
( self, db: &'db dyn Db, env: &'env ProgramEnvironment<'db>, settings: Display
crates/ty_python_semantic/src/types/display.rs:764
↓ 1 callersFunctionrequest
Processes a request from the client to the server. The LSP specification requires that each request has exactly one response. Therefore, it's crucial
crates/ty_server/src/server/api.rs:32
↓ 1 callersFunctionrequest
Processes a request from the client to the server. The LSP specification requires that each request has exactly one response. Therefore, it's crucial
crates/ruff_server/src/server/api.rs:47
↓ 1 callersFunctionrequest
()
crates/ruff_linter/resources/test/fixtures/flake8_async/ASYNC210.py:61
↓ 1 callersFunctionrequest_check
(sender: &crossbeam_channel::Sender<()>)
crates/ty/src/lib.rs:950
↓ 1 callersFunctionrequest_with_no_cert_validation
S501
crates/ruff_linter/src/rules/flake8_bandit/rules/request_with_no_cert_validation.rs:52
↓ 1 callersFunctionrequest_without_timeout
S113
crates/ruff_linter/src/rules/flake8_bandit/rules/request_without_timeout.rs:61
↓ 1 callersFunctionrequired_typeddict_key
Return a synthesized `TypedDict` that represents safe subscript access for a present key on a `TypedDict`-containing type. For `TypedDict`s, a positi
crates/ty_python_semantic/src/types/narrow.rs:5612
↓ 1 callersMethodrequires_default_inference
(self)
crates/ty_python_semantic/src/types/infer/builder.rs:13128
↓ 1 callersMethodrequires_lazy_evaluation
( &self, db: &'db dyn Db, checker: &TypeRelationChecker<'_, '_, 'db>, )
crates/ty_python_semantic/src/types/signatures.rs:811
↓ 1 callersMethodrequires_member_import
( &self, module: Option<String>, name: String, as_name: Option<String>,
crates/ruff_linter/src/rules/isort/settings.rs:82
↓ 1 callersMethodrequires_module_import
(&self, name: String, as_name: Option<String>)
crates/ruff_linter/src/rules/isort/settings.rs:76
↓ 1 callersMethodrequires_one_argument
Return `true` if this type qualifier requires exactly one argument when used in a type expression.
crates/ty_python_semantic/src/types/special_form.rs:1097
↓ 1 callersMethodreserve_bindings
Reserves capacity for at least `additional` more bindings.
crates/ruff_python_semantic/src/scope.rs:88
↓ 1 callersMethodreserve_loop_header
(&mut self)
crates/ty_python_core/src/use_def.rs:2304
↓ 1 callersMethodreset_unstaged
Reverts any unstaged changes and reverts the source text of `file` to the last staged changed or its original content.
crates/ty_python_semantic/src/fixes.rs:630
↓ 1 callersMethodreset_usage_count
Reset the usage count for the group name by the given value. This function is called when there is a `continue`, `break`, or `return` statement.
crates/ruff_linter/src/rules/flake8_bugbear/rules/reuse_of_groupby_generator.rs:110
↓ 1 callersMethodresolve
(&self, preview: PreviewMode)
crates/ruff_workspace/src/configuration.rs:97
↓ 1 callersMethodresolve
Resolve the [`CollectedImport`] into a [`FilePath`].
crates/ruff_graph/src/resolver.rs:35
↓ 1 callersMethodresolve
Resolves the loaded value, calling `visit` once per source as it is evaluated. The visitor can inspect or narrow the source before the resolver merge
crates/ty_python_semantic/src/place_load.rs:94
↓ 1 callersMethodresolve_applicability
(&self, fix: &Fix)
crates/ruff_linter/src/checkers/ast/mod.rs:3892
↓ 1 callersMethodresolve_bindings
(&self, bindings: BindingWithConstraintsIterator<'_, 'db>)
crates/ty_python_semantic/src/place_load.rs:214
↓ 1 callersFunctionresolve_bool_arg
(yes: bool, no: bool)
crates/ty/src/args.rs:564
↓ 1 callersFunctionresolve_bytes_literal
Try to resolve `name` to an [`ExprBytesLiteral`] in `semantic`.
crates/ruff_linter/src/rules/ruff/rules/unnecessary_regular_expression.rs:394
↓ 1 callersFunctionresolve_configuration
Recursively resolve a [`Configuration`] from a `pyproject.toml` file at the specified [`Path`].
crates/ruff_workspace/src/resolver.rs:342
↓ 1 callersMethodresolve_del
Resolve a `del` reference to `symbol` at `range`.
crates/ruff_python_semantic/src/model.rs:477
↓ 1 callersMethodresolve_enclosing_scopes
( &mut self, )
crates/ty_python_semantic/src/place_load.rs:636
↓ 1 callersFunctionresolve_enum_method
Resolves a user-defined method without falling through an opaque binding to the known default.
crates/ty_python_semantic/src/types/enums.rs:1608
↓ 1 callersMethodresolve_exports
(self)
crates/ty_python_core/src/re_exports.rs:85
↓ 1 callersFunctionresolve_file_module_with_filter
( directory: &ModuleDirectory, resolver_state: &ResolverContext, name: &str, filter: Component
crates/ty_module_resolver/src/resolve.rs:1574
↓ 1 callersFunctionresolve_from_import_submodule_definitions
Helper to resolve `from x.y import z` assuming `x.y.z` is a module.
crates/ty_python_semantic/src/types/definition_resolution.rs:801
↓ 1 callersMethodresolve_global
Resolves a load that has reached the module's explicit global scope. An eager nested scope uses the global snapshot captured when it began, so a clas
crates/ty_python_semantic/src/place_load.rs:792
↓ 1 callersMethodresolve_load
Resolve a `load` reference to an [`ast::ExprName`].
crates/ruff_python_semantic/src/model.rs:500
↓ 1 callersMethodresolve_module
Resolves a module name to a module.
crates/ruff_graph/src/resolver.rs:111
↓ 1 callersFunctionresolve_module_file
(db: &dyn Db, module_name: &ModuleName)
crates/ty_ide/src/will_rename.rs:1103
↓ 1 callersMethodresolve_module_type
Resolve the given import made in this file to a Type
crates/ty_python_semantic/src/semantic_model.rs:169
↓ 1 callersFunctionresolve_name
Given a module name and a list of search paths in which to lookup modules, attempt to resolve the module name
crates/ty_module_resolver/src/resolve.rs:1208
↓ 1 callersMethodresolve_nested_reference_scope
Finds the nearest visible ancestor scope that actually owns a local binding for `name`.
crates/ty_python_core/src/builder.rs:871
↓ 1 callersMethodresolve_preview
(self)
crates/ruff/src/args.rs:640
↓ 1 callersMethodresolve_qualified_import_name
Given a `module` and `member`, return the fully-qualified name of the binding in the current scope, if it exists. E.g., given: ```python from sys im
crates/ruff_python_semantic/src/model.rs:1302
↓ 1 callersFunctionresolve_reachable_definitions
( db: &'db dyn Db, env: &ProgramEnvironment<'db>, symbol_name: &str, definitions: impl IntoIte
crates/ty_python_semantic/src/types/definition_resolution.rs:569
↓ 1 callersMethodresolve_real_module
Resolves a module name to a module (stubs not allowed).
crates/ruff_graph/src/resolver.rs:125
↓ 1 callersFunctionresolve_requires_python_lower_bound
( requires_python: &RangedValue<VersionSpecifiers>, )
crates/ty_project/src/metadata/pyproject.rs:72
↓ 1 callersFunctionresolve_script_options
( db: &dyn Db, metadata: &ScriptMetadata, uv_metadata: Option<&UvMetadata>, file: File, di
crates/ty_project/src/script.rs:219
↓ 1 callersFunctionresolve_script_program_settings
( db: &dyn Db, options: &Options, context: OptionsContext<'_>, project_name: &str, file: F
crates/ty_project/src/script.rs:303
↓ 1 callersFunctionresolve_script_settings
( db: &dyn Db, options: &Options, context: OptionsContext<'_>, diagnostics: &mut ScriptConfigu
crates/ty_project/src/script.rs:280
↓ 1 callersFunctionresolve_search_paths
Resolve module search paths for the given source roots and Python environment.
crates/ruff_graph/src/db.rs:42
↓ 1 callersMethodresolve_source
Evaluates one source of a place load's value without expression-specific narrowing.
crates/ty_python_semantic/src/place_load.rs:153
↓ 1 callersFunctionresolve_src
Given a list of source paths, which could include glob patterns, resolve the matching paths.
crates/ruff_workspace/src/configuration.rs:1458
↓ 1 callersFunctionresolve_string_literal
Try to resolve `name` to an [`ExprStringLiteral`] in `semantic`.
crates/ruff_linter/src/rules/ruff/rules/unnecessary_regular_expression.rs:414
↓ 1 callersFunctionresolve_stub_package_in_search_path
( context: &ResolverContext<'db>, search_path: &SearchPath, stub_name: &str, )
crates/ty_module_resolver/src/resolve.rs:1393
↓ 1 callersMethodresolve_submodule
Given a `BindingId`, return the `BindingId` of the submodule import that it aliases.
crates/ruff_python_semantic/src/model.rs:1127
↓ 1 callersFunctionresolve_typevar_reference
Resolves a reference to a type variable that must already be bound. Unlike [`bind_typevar`], this function never introduces a binding in the current
crates/ty_python_semantic/src/types/generics.rs:124
↓ 1 callersMethodresolve_value
( self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, value: ProtocolPropert
crates/ty_python_semantic/src/types/protocol_class.rs:1661
↓ 1 callersMethodresolve_workspace_trust
(self)
crates/ruff/src/args.rs:632
↓ 1 callersMethodresolver_environment
The resolver environment used to resolve this module.
crates/ty_module_resolver/src/module.rs:57
↓ 1 callersMethodresolver_environment
(self, db: &'db dyn Db)
crates/ty_module_resolver/src/module_name.rs:509
↓ 1 callersMethodresolver_file
Returns the existing resolver key or materializes one when required.
crates/ty_module_resolver/src/module_name.rs:521
↓ 1 callersMethodrespect_gitignore
(&self)
crates/ruff_workspace/src/resolver.rs:136
↓ 1 callersFunctionrespond_silent_error
Sends back an error response to the server using a [`Client`] without showing a warning to the user.
crates/ruff_server/src/server/api.rs:340
↓ 1 callersFunctionrestore
()
playground/ruff/src/Editor/settings.ts:90
↓ 1 callersMethodrestore
(&mut self, snapshot: BindingSnapshot<'db>)
crates/ty_python_semantic/src/types/call/bind.rs:9686
↓ 1 callersFunctionrestoreFilters
()
docs/js/rule-filters.js:2
↓ 1 callersFunctionrestoreLocal
()
playground/ty/src/Editor/persist.ts:85
↓ 1 callersFunctionrestoreLocal
()
playground/ruff/src/Editor/settings.ts:118
↓ 1 callersFunctionrestoreWorkspace
( session: PlaygroundSession, state: { files: { [name: string]: string }; current: string; },
playground/ty/src/Playground.tsx:792
↓ 1 callersMethodrestore_snapshot
(&mut self, snapshot: BufferSnapshot)
crates/ruff_formatter/src/buffer.rs:163
↓ 1 callersMethodrestore_snapshot
(&mut self, snapshot: BufferSnapshot)
crates/ruff_formatter/src/formatter.rs:249
↓ 1 callersMethodrestore_subject
Replace all subject-aliasing contributions with one restored subject type. Contributions for extracted values remain unchanged.
crates/ty_python_semantic/src/types/narrow.rs:389
↓ 1 callersMethodrestrict
Restricts this specialization to only include the typevars in a generic context. If the specialization does not include all of those typevars, returns
crates/ty_python_semantic/src/types/generics.rs:1324
← previousnext →12,801–12,900 of 31,562, ranked by callers