MCPcopy Create free account

hub / github.com/psf/black / functions

Functions1,067 in github.com/psf/black

Functionlong_lines
()
tests/data/simple_cases/function.py:45
Functionlong_one_with_long_parameter_names
( but_all_of_them, are_positional_only, arguments_mmmmkay, so_this_is_only_valid_after, th
tests/data/py_38/pep_570.py:27
Functionmain
()
tests/data/simple_cases/remove_await_parens.py:4
Functionmake_arange
(n)
tests/data/py_37/python37.py:29
Methodmake_naked
Strip @string (i.e. make it a "naked" string) Pre-conditions: * assert_is_leaf_string(@string) Returns:
src/black/trans.py:570
Methodmatch
Override match() to insist on a leaf node.
src/blib2to3/pytree.py:627
Methodmatch
Does this pattern exactly match a node?
src/blib2to3/pytree.py:807
Methodmatch
(self, node, results=None)
src/blib2to3/pytree.py:942
Methodmatch_seq
Does this pattern exactly match a sequence of nodes? Default implementation for non-wildcard patterns.
src/blib2to3/pytree.py:580
Methodmatch_seq
(self, nodes, results=None)
src/blib2to3/pytree.py:946
Methodmax_last_string_column
Returns: The max allowed width of the string value used for the last line we will construct. Note that t
src/black/trans.py:1426
Methodmaybe_append_string_operators
Side Effects: If @line starts with a string operator and this is the first line we are constructing, this
src/black/trans.py:1409
Methodmethod
Multiline method docstring
tests/data/simple_cases/docstring.py:6
Methodmock_n_calls
(responses: List[bool])
tests/test_black.py:492
Methodmore_splits_should_be_made
Returns: True iff `rest_value` (the remaining string value from the last split), should be split again.
src/black/trans.py:1467
Functionmulitline_docstring_almost_at_line_limit
long docstring................................................................. .................................................................
tests/data/simple_cases/docstring_preview.py:11
Functionmulitline_docstring_almost_at_line_limit_with_prefix
f"""long docstring................................................................ ..............................................................
tests/data/simple_cases/docstring_preview.py:18
Functionmultiline_backslash_1
hey\there\ \
tests/data/simple_cases/docstring.py:166
Functionmultiline_backslash_1
hey\there\ \
tests/data/miscellaneous/docstring_no_string_normalization.py:110
Functionmultiline_backslash_2
hey there \
tests/data/simple_cases/docstring.py:172
Functionmultiline_backslash_2
hey there \
tests/data/miscellaneous/docstring_no_string_normalization.py:116
Functionmultiline_backslash_3
already escaped \\
tests/data/simple_cases/docstring.py:182
Functionmultiline_backslash_3
already escaped \\
tests/data/miscellaneous/docstring_no_string_normalization.py:121
Functionmultiline_backslash_really_long_dont_crash
hey there hello guten tag hi hoow are you ola zdravstvuyte ciao como estas ca va \
tests/data/simple_cases/docstring.py:177
Functionmultiline_docstring_at_line_limit
first line----------------------------------------------------------------------- second line----------------------------------------------------
tests/data/simple_cases/docstring.py:211
Functionmultiline_docstring_at_line_limit
first line----------------------------------------------------------------------- second line----------------------------------------------------
tests/data/simple_cases/docstring_preview.py:33
Functionmultiline_docstring_at_line_limit_with_prefix
f"""first line---------------------------------------------------------------------- second line-------------------------------------------------
tests/data/simple_cases/docstring_preview.py:39
Functionmultiline_whitespace
tests/data/simple_cases/docstring.py:105
Functionmy_god_its_full_of_stars_1
I'm sorry Dave\u2001
tests/data/simple_cases/docstring.py:187
Functionmy_god_its_full_of_stars_2
I'm sorry Dave 
tests/data/simple_cases/docstring.py:192
Methodnext_sibling
The node immediately following the invocant in their parent's children list. If the invocant does not have a next sibling, it is None
src/blib2to3/pytree.py:192
Functionoff_and_on_without_data
All comments here are technically on the same prefix. The comments between will be formatted. This is a known limitation.
tests/data/simple_cases/fmtonoff.py:93
Methodomitting_trailers
(self)
tests/data/simple_cases/composition.py:47
Methodomitting_trailers
(self)
tests/data/simple_cases/composition_no_trailing_comma.py:47
Functionon_and_off_broken
Another known limitation.
tests/data/simple_cases/fmtonoff.py:106
Functionone_function
This is a docstring with a single line of text.
tests/data/miscellaneous/docstring_no_string_normalization.py:11
Functiononeline_whitespace
tests/data/simple_cases/docstring.py:114
Methodopens_block
Does this line open a new level of indentation.
src/black/lines.py:193
Methodoptimize
Optimize certain stacked wildcard patterns.
src/blib2to3/pytree.py:779
Functionover_indent
This has a shallow indent - But some lines are deeper - And the closing quote is too deep
tests/data/simple_cases/docstring.py:69
Functionover_indent
This has a shallow indent - But some lines are deeper - And the closing quote is too deep
tests/data/miscellaneous/docstring_no_string_normalization.py:59
Methodparse_file
Parse a file and return the syntax tree.
src/blib2to3/pgen2/driver.py:201
Methodpasses_all_checks
Returns: True iff ALL of the conditions listed in the 'Transformations' section of this classes' docstrin
src/black/trans.py:1699
Functionpatch_dump_to_file
(request: Any)
tests/test_format.py:20
Functionpoit
Lorem ipsum dolor sit amet. Consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna aliqua -
tests/data/simple_cases/docstring.py:47
Functionpoit
Lorem ipsum dolor sit amet. Consectetur adipiscing elit: - sed do eiusmod tempor incididunt ut labore - dolore magna aliqua -
tests/data/miscellaneous/docstring_no_string_normalization.py:37
Functionpositional_only_arg
(a, /)
tests/data/py_38/pep_570.py:1
Methodpost_order
Return a post-order iterator for the tree.
src/blib2to3/pytree.py:307
Methodpost_order
Return a post-order iterator for the tree.
src/blib2to3/pytree.py:465
Methodpre_order
Return a pre-order iterator for the tree.
src/blib2to3/pytree.py:313
Methodpre_order
Return a pre-order iterator for the tree.
src/blib2to3/pytree.py:469
Methodprefix
(self)
src/blib2to3/pytree.py:95
Methodprefix
The whitespace and comments preceding this node in the input.
src/blib2to3/pytree.py:320
Methodprefix
The whitespace and comments preceding this token in the input.
src/blib2to3/pytree.py:474
Methodprev_sibling
The node immediately preceding the invocant in their parent's children list. If the invocant does not have a previous sibling, it is
src/blib2to3/pytree.py:206
Functionprinttoken
(type, token, xxx_todo_changeme, xxx_todo_changeme1, line)
src/blib2to3/pgen2/tokenize.py:191
Functionpublic_func_with_blank_parentheses
()
tests/data/simple_cases/class_blank_parentheses.py:14
Functionpytest_addoption
(parser: "Parser")
tests/optional.py:45
Functionpytest_collection_modifyitems
(config: "Config", items: "List[Node]")
tests/optional.py:98
Functionpytest_configure
Optional tests are markers. Use the syntax in https://docs.pytest.org/en/stable/mark.html#registering-marks.
tests/optional.py:57
Functionread_pyproject_toml
Inject Black configuration from "pyproject.toml" into defaults in `ctx`. Returns the path to a successfully found and read configuration file, No
src/black/__init__.py:121
Functionrefresh_token
(self, device_family, refresh_token, api_key)
tests/data/simple_cases/trailing_commas_in_leading_parts.py:12
Methodreport
Dump the grammar tables to standard output, for debugging.
src/blib2to3/pgen2/grammar.py:153
Methodreturn_code
Return the exit code that the app should use. This considers the current state of changed files and failures: - if there were any fai
src/black/report.py:61
Methodset_child
Equivalent to 'node.children[i] = child'. This method also sets the child's parent attribute appropriately.
src/blib2to3/pytree.py:333
Functionset_position
((x, y), value)
tests/data/miscellaneous/python2_detection.py:11
Functionshockingly_the_quotes_are_normalized
This is a multiline docstring. This is a multiline docstring. This is a multiline docstring.
tests/data/miscellaneous/docstring_no_string_normalization.py:16
Functionshockingly_the_quotes_are_normalized_v2
Docstring Docstring Docstring
tests/data/miscellaneous/docstring_no_string_normalization.py:99
Methodshow
Pretty-print the lib2to3 AST of a given string of `code`. Convenience method for debugging.
src/black/debug.py:39
Functionshow_status
()
tests/data/simple_cases/remove_parens.py:8
Functionsigh
()
tests/data/fast/pep_572_do_not_remove_parens.py:20
Functionsingle_line
But with a newline after it!
tests/data/simple_cases/docstring.py:78
Functionsingle_line
But with a newline after it!
tests/data/miscellaneous/docstring_no_string_normalization.py:68
Functionsingle_line_docstring_with_whitespace
This should be stripped
tests/data/simple_cases/docstring.py:134
Functionsingle_literal_yapf_disable
Black does not support this.
tests/data/simple_cases/fmtonoff.py:152
Functionsingle_quote_docstring_over_line_limit
We do not want to put the closing quote on a new line as that is invalid (see GH-3141).
tests/data/simple_cases/docstring_preview.py:45
Functionsingle_quote_docstring_over_line_limit2
We do not want to put the closing quote on a new line as that is invalid (see GH-3141).
tests/data/simple_cases/docstring_preview.py:49
Functionsingle_quotes
testing
tests/data/simple_cases/docstring.py:122
Functionsome_async_func
( unformatted, args)
tests/data/simple_cases/fmtskip8.py:9
Methodsome_async_method
( self, unformatted, args )
tests/data/simple_cases/fmtskip8.py:20
Functionsome_function_with_a_really_long_name
()
tests/data/simple_cases/function_trailing_comma.py:28
Methodsome_method
( self, unformatted, args )
tests/data/simple_cases/fmtskip8.py:16
Functionsome_method_with_a_really_long_name
(very_long_parameter_so_yeah: str, another_long_parameter: int)
tests/data/simple_cases/function_trailing_comma.py:34
Functionsomething
()
tests/data/conditional_expression.py:60
Functionspaces
(a=1, b=(), c=[], d={}, e=True, f=-1, g=1 if False else 2, h="", i=r'')
tests/data/simple_cases/fmtonoff.py:41
Functionspaces
(a=1, b=(), c=[], d={}, e=True, f=-1, g=1 if False else 2, h="", i=r'')
tests/data/simple_cases/function.py:31
Functionspaces2
(result= _core.Value(None))
tests/data/simple_cases/fmtonoff.py:45
Functionspaces2
(result= _core.Value(None))
tests/data/simple_cases/function.py:35
Functionspaces_types
(a: int = 1, b: tuple = (), c: list = [], d: dict = {}, e: bool = True, f: int = -1, g: int = 1 if False else
tests/data/simple_cases/fmtonoff.py:44
Functionspaces_types
(a: int = 1, b: tuple = (), c: list = [], d: dict = {}, e: bool = True, f: int = -1, g: int = 1 if False else
tests/data/simple_cases/function.py:34
Functionspam
()
tests/data/miscellaneous/force_pyi.py:23
Functionsplit_wrapper
( line: Line, features: Collection[Feature], mode: Mode )
src/black/linegen.py:947
Functionstable_quote_normalization_with_immediate_inner_single_quote
<text here> <text here, since without another non-empty line black is stable>
tests/data/simple_cases/docstring.py:217
Functionstandalone_comment_split
Split standalone comments from the rest of the line.
src/black/linegen.py:1061
Functionstarred_return
()
tests/data/py_38/python38.py:4
Functionstarred_yield
()
tests/data/py_38/python38.py:9
Functionsubscriptlist
()
tests/data/simple_cases/fmtonoff.py:52
Functionsync_fn
()
tests/data/miscellaneous/async_as_identifier.py:15
Functiont
()
tests/data/py_38/python38.py:18
Functiontarget_version_option_callback
Compute the target versions from a --target-version flag. This is its own function because mypy couldn't infer the type correctly when it was
src/black/__init__.py:167
← previousnext →701–800 of 1,067, ranked by callers