Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/astral-sh/ruff
/ functions
Functions
31,766 in github.com/astral-sh/ruff
⨍
Functions
31,766
◇
Types & classes
7,128
↳
Endpoints
82
↓ 1 callers
Function
normalize_output
Normalize output by replacing absolute paths with relative placeholders.
scripts/ty_benchmark/src/benchmark/snapshot.py:16
↓ 1 callers
Function
normalize_rule_selectors
(config: dict[str, Any], executable: Path)
python/ruff-ecosystem/ruff_ecosystem/projects.py:88
↓ 1 callers
Function
normalize_site_packages_paths
Site-packages placeholders are specific to ty's fixtures. Keeping their normalization outside the shared mdtest crate avoids rewriting Ruff snapshots
crates/ty_test/src/lib.rs:570
↓ 1 callers
Function
normalize_type_for_code_span
Normalizes type text so it fits in a single Markdown code span. One-line types are returned unchanged. Multi-line types are trimmed line by line, wit
crates/ty_ide/src/docstring/markdown/structured.rs:484
↓ 1 callers
Function
normalize_uri
(uri: &str)
crates/ty_ide/src/docstring/markdown/general/inline.rs:402
↓ 1 callers
Method
normalized_body
Normalizes the text of the body of a field (e.g., the documentation for a parameter).
crates/ty_ide/src/docstring/document/rst.rs:341
↓ 1 callers
Method
normalized_constructor_return
Normalize constructor return type. There are a few special cases we have to handle for constructors: `__init__` methods always return `None`, but for
crates/ty_python_semantic/src/types/call/bind/constructor.rs:890
↓ 1 callers
Method
normalized_union
( self, db: &'db dyn Db, program: Program<'db>, )
crates/ty_python_semantic/src/types/union_type_instance.rs:279
↓ 1 callers
Function
not_a_text_document
(path: impl Display)
crates/ty_server/src/system.rs:345
↓ 1 callers
Function
not_airflow
(start_date)
crates/ruff_linter/resources/test/fixtures/airflow/AIR304.py:77
↓ 1 callers
Function
not_empty
D419
crates/ruff_linter/src/rules/pydocstyle/rules/not_empty.rs:48
↓ 1 callers
Function
not_missing
D100, D101, D102, D103, D104, D105, D106, D107
crates/ruff_linter/src/rules/pydocstyle/rules/not_missing.rs:566
↓ 1 callers
Function
not_tests
E713, E714
crates/ruff_linter/src/rules/pycodestyle/rules/not_tests.rs:84
↓ 1 callers
Method
note
Override the output style for [notes][crate::Level::NOTE]
crates/ruff_annotate_snippets/src/renderer/mod.rs:228
↓ 1 callers
Method
note_separator
(&self, is_cont: bool)
crates/ruff_annotate_snippets/src/renderer/mod.rs:305
↓ 1 callers
Method
notebook_document_uris
(&self)
crates/ruff_server/src/session/index.rs:98
↓ 1 callers
Function
notebook_fix_all
(snapshot: &DocumentSnapshot)
crates/ruff_server/src/server/api/requests/code_action.rs:228
↓ 1 callers
Method
notebook_index
(&self)
crates/ruff_server/src/lint.rs:343
↓ 1 callers
Function
notebook_newline_diagnostics
Collects trailing newline diagnostics for each cell
crates/ruff_linter/src/rules/pycodestyle/rules/too_many_newlines_at_end_of_file.rs:76
↓ 1 callers
Function
notebook_organize_imports
(snapshot: &DocumentSnapshot)
crates/ruff_server/src/server/api/requests/code_action.rs:298
↓ 1 callers
Function
notification
(notif: server::Notification)
crates/ty_server/src/server/api.rs:189
↓ 1 callers
Function
notification
(notif: server::Notification)
crates/ruff_server/src/server/api.rs:100
↓ 1 callers
Function
npm_bin_path
(name: str)
scripts/ty_benchmark/src/benchmark/tool.py:432
↓ 1 callers
Function
nullable_model_string_field
DJ001
crates/ruff_linter/src/rules/flake8_django/rules/nullable_model_string_field.rs:59
↓ 1 callers
Method
num_args
(self)
crates/ruff_linter/src/rules/flake8_bugbear/rules/re_sub_positional_args.rs:109
↓ 1 callers
Function
num_branches
(stmts: &[Stmt])
crates/ruff_linter/src/rules/pylint/rules/too_many_branches.rs:166
↓ 1 callers
Function
num_decimal_digits
instead of taking the String length or dividing by 10 while > 0, we multiply a limit by 10 until we're higher. If the loop isn't exited by the `return
crates/ruff_annotate_snippets/src/renderer/render.rs:2373
↓ 1 callers
Method
num_items
(&self)
crates/ruff_linter/src/rules/ruff/rules/sequence_sorting.rs:713
↓ 1 callers
Method
num_member_segments
(self)
crates/ty_python_core/src/place.rs:139
↓ 1 callers
Method
num_nodes
(&self)
crates/ruff_python_semantic/src/cfg/visualize.rs:171
↓ 1 callers
Function
num_returns
Count the number of return statements in a function or method body.
crates/ruff_linter/src/rules/pylint/rules/too_many_return_statements.rs:74
↓ 1 callers
Method
num_segments
(&self)
crates/ty_python_core/src/member.rs:197
↓ 1 callers
Function
numeric_literal_too_long
PYI054
crates/ruff_linter/src/rules/flake8_pyi/rules/numeric_literal_too_long.rs:50
↓ 1 callers
Function
numeric_tower_group
Finds the largest numeric-tower group among the given classes. Unrelated classes are ignored so a mixed annotation can still use canonical spelling:
crates/ty_python_semantic/src/types/display.rs:3193
↓ 1 callers
Function
numpy_2_0_deprecation
NPY201
crates/ruff_linter/src/rules/numpy/rules/numpy_2_0_deprecation.rs:162
↓ 1 callers
Function
numpy_section
( checker: &Checker, docstring: &Docstring, context: &SectionContext, next: Option<&SectionCon
crates/ruff_linter/src/rules/pydocstyle/rules/sections.rs:2077
↓ 1 callers
Function
nunique_constant_series_check
PD101
crates/ruff_linter/src/rules/pandas_vet/rules/nunique_constant_series_check.rs:66
↓ 1 callers
Function
object_without_hash_method
PLW1641
crates/ruff_linter/src/rules/pylint/rules/eq_without_hash.rs:79
↓ 1 callers
Method
observe_marker
Updates internal state for a possible reST literal block marker whose text has already been split out from its source line.
crates/ty_ide/src/docstring/document/preformatted.rs:142
↓ 1 callers
Method
observe_marker_in_line
Updates internal state for a possible reST literal block marker.
crates/ty_ide/src/docstring/document/preformatted.rs:136
↓ 1 callers
Method
offset
Returns the [UTF-8 byte offset](TextSize) at `line` and `character` where character is counted using the given encoding. ## Examples ### ASCII only
crates/ruff_source_file/src/line_index.rs:482
↓ 1 callers
Function
on_failure
()
crates/ruff_linter/resources/test/fixtures/flake8_logging/LOG004_0.py:47
↓ 1 callers
Function
one_liner
D200
crates/ruff_linter/src/rules/pydocstyle/rules/one_liner.rs:62
↓ 1 callers
Method
openCodeEditor
( source: editor.ICodeEditor, resource: Uri, selectionOrPosition?: IRange | IPosition, )
playground/ty/src/Editor/Editor.tsx:809
↓ 1 callers
Function
open_alias
UP020
crates/ruff_linter/src/rules/pyupgrade/rules/open_alias.rs:55
↓ 1 callers
Method
open_close
(&self)
crates/ruff_python_semantic/src/cfg/visualize.rs:96
↓ 1 callers
Function
open_configuration_file
(config_path: &Path)
crates/ruff_server/src/session/index/ruff_settings.rs:467
↓ 1 callers
Method
open_document_handle
Returns a handle to the open document specified by its URI. # Errors Returns an error if the document is not open in the session.
crates/ty_server/src/session.rs:1351
↓ 1 callers
Method
open_file
(self, path: Path)
scripts/ty_benchmark/src/benchmark/test_lsp_diagnostics.py:208
↓ 1 callers
Method
open_file
Opens a file in the project.
crates/ty_project/src/lib.rs:602
↓ 1 callers
Method
open_file
Marks `file` as open in the editor. This is untracked state: open a file before running any queries.
crates/ty_python_semantic/src/db.rs:114
↓ 1 callers
Function
open_file_with_context_handler
SIM115
crates/ruff_linter/src/rules/flake8_simplify/rules/open_file_with_context_handler.rs:219
↓ 1 callers
Method
open_notebook_document
( &mut self, document: NotebookDocument, )
crates/ty_server/src/session/index.rs:197
↓ 1 callers
Method
open_notebook_document
(&mut self, notebook_uri: Uri, document: NotebookDocument)
crates/ruff_server/src/session/index.rs:305
↓ 1 callers
Method
open_text_document
Registers a text document at the provided `uri`. If a document is already open here, it will be overwritten.
crates/ruff_server/src/session.rs:168
↓ 1 callers
Method
open_text_document
(&mut self, uri: Uri, document: TextDocument)
crates/ruff_server/src/session/index.rs:300
↓ 1 callers
Method
open_workspace_folder
( &mut self, uri: Uri, global: &GlobalClientSettings, client: &Client, )
crates/ruff_server/src/session/index.rs:175
↓ 1 callers
Method
opener
The docstring's "opener" (the string's prefix, if any, and its opening quotes).
crates/ruff_linter/src/docstrings/mod.rs:77
↓ 1 callers
Method
opening_token_for_multiline_definition
(self)
crates/ruff_linter/src/rules/ruff/rules/sequence_sorting.rs:163
↓ 1 callers
Method
operands
(&self)
crates/ruff_python_formatter/src/expression/binary_like.rs:559
↓ 1 callers
Function
operator_dispatch_class
Returns the nominal runtime class used to dispatch binary operators. Instances dispatch through their nominal class, while class objects dispatch thr
crates/ty_python_semantic/src/types/call.rs:76
↓ 1 callers
Method
operator_result
( &self, db: &'db dyn Db, env: &ProgramEnvironment<'db>, )
crates/ty_python_semantic/src/types.rs:11195
↓ 1 callers
Method
options
(&self)
crates/ruff_formatter/src/lib.rs:243
↓ 1 callers
Method
options
Returns the format options
crates/ruff_formatter/src/formatter.rs:29
↓ 1 callers
Method
options
(&self)
crates/ruff_server/src/session/settings.rs:33
↓ 1 callers
Function
or_space
Ensure that a [`ParenthesizableWhitespace`] contains at least one space.
crates/ruff_linter/src/cst/helpers.rs:12
↓ 1 callers
Method
or_uncached
Compute the disjunction of two interior nodes in ascending ID order after a cache miss.
crates/ty_python_core/src/narrowing_constraints.rs:315
↓ 1 callers
Method
or_uncached
Compute the disjunction on a cache miss with the operands in ascending ID order. The first operand is an interior node and the second can be `AMBIGUOU
crates/ty_python_core/src/reachability_constraints.rs:452
↓ 1 callers
Function
order_imports
( block: ImportBlock<'a>, section: &ImportSection, settings: &Settings, )
crates/ruff_linter/src/rules/isort/order.rs:10
↓ 1 callers
Function
ordered_dataclass_base_class
( db: &'db dyn Db, base_class: ClassType<'db>, )
crates/ty_python_semantic/src/types/infer/builder/post_inference/static_class.rs:1450
↓ 1 callers
Method
ordering
(self, other: TextRange)
crates/ruff_text_size/src/range.rs:338
↓ 1 callers
Function
organize_imports
(snapshot: &DocumentSnapshot)
crates/ruff_server/src/server/api/requests/code_action.rs:263
↓ 1 callers
Function
organize_imports
I001
crates/ruff_linter/src/rules/isort/rules/organize_imports.rs:122
↓ 1 callers
Method
organize_imports
(&self)
crates/ruff_server/src/session/settings.rs:147
↓ 1 callers
Method
origin
(&self)
crates/ty_site_packages/src/lib.rs:448
↓ 1 callers
Function
os_chmod
PTH101
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_chmod.rs:72
↓ 1 callers
Function
os_error_alias_call
UP024
crates/ruff_linter/src/rules/pyupgrade/rules/os_error_alias.rs:191
↓ 1 callers
Function
os_error_alias_handlers
UP024
crates/ruff_linter/src/rules/pyupgrade/rules/os_error_alias.rs:163
↓ 1 callers
Function
os_error_alias_raise
UP024
crates/ruff_linter/src/rules/pyupgrade/rules/os_error_alias.rs:198
↓ 1 callers
Function
os_getcwd
PTH109
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_getcwd.rs:71
↓ 1 callers
Function
os_makedirs
PTH103
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_makedirs.rs:71
↓ 1 callers
Function
os_mkdir
PTH102
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_mkdir.rs:72
↓ 1 callers
Function
os_path_abspath
PTH100
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_abspath.rs:77
↓ 1 callers
Function
os_path_basename
PTH119
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_basename.rs:74
↓ 1 callers
Function
os_path_commonprefix
RUF071
crates/ruff_linter/src/rules/ruff/rules/os_path_commonprefix.rs:88
↓ 1 callers
Function
os_path_dirname
PTH120
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_dirname.rs:78
↓ 1 callers
Function
os_path_exists
PTH110
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_exists.rs:65
↓ 1 callers
Function
os_path_expanduser
PTH111
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_expanduser.rs:72
↓ 1 callers
Function
os_path_getatime
PTH203
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_getatime.rs:68
↓ 1 callers
Function
os_path_getctime
PTH205
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_getctime.rs:69
↓ 1 callers
Function
os_path_getmtime
PTH204
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_getmtime.rs:69
↓ 1 callers
Function
os_path_getsize
PTH202
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_getsize.rs:69
↓ 1 callers
Function
os_path_isabs
PTH117
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_isabs.rs:64
↓ 1 callers
Function
os_path_isdir
PTH112
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_isdir.rs:66
↓ 1 callers
Function
os_path_isfile
PTH113
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_isfile.rs:66
↓ 1 callers
Function
os_path_islink
PTH114
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_islink.rs:66
↓ 1 callers
Function
os_path_samefile
PTH121
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_path_samefile.rs:69
↓ 1 callers
Function
os_readlink
PTH115
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_readlink.rs:71
↓ 1 callers
Function
os_remove
PTH107
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_remove.rs:67
↓ 1 callers
Function
os_rename
PTH104
crates/ruff_linter/src/rules/flake8_use_pathlib/rules/os_rename.rs:72
← previous
next →
12,001–12,100 of 31,766, ranked by callers