mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-05-15 21:18:30 +08:00
Add _write method to flake8.formatting.BaseFormatter (#12312)
It is very useful for real-life custom formatters. Example: https://github.com/wemake-services/wemake-python-styleguide/blob/470d81174684eb9a175603aec02f0ac6589b8acd/wemake_python_styleguide/formatter.py#L92-L96 Definition: https://github.com/PyCQA/flake8/blob/65a38c42a7f1a05ff8d99b313160754fc9b7a0d8/src/flake8/formatting/base.py#L173-L178
This commit is contained in:
@@ -21,4 +21,5 @@ class BaseFormatter:
|
||||
def show_benchmarks(self, benchmarks: list[tuple[str, float]]) -> None: ...
|
||||
def show_source(self, error: Violation) -> str | None: ...
|
||||
def write(self, line: str | None, source: str | None) -> None: ...
|
||||
def _write(self, output: str) -> None: ...
|
||||
def stop(self) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user