VL i dZddlmZddlmZddlmZddddd d d d d dd ZeDcic]}|dc}ZGddejZ Gdde Z Gdde Z Gdde Z GddejZycc}w)z$Default formatting class for Flake8.) annotations)base) Violationzzzzzzzzzz) boldblackredgreenyellowbluemagentacyanwhiteresetc$eZdZUdZded<ddZy)SimpleFormatteraySimple abstraction for Default and Pylint formatter commonality. Sub-classes of this need to define an ``error_format`` attribute in order to succeed. The ``format`` method relies on that attribute and expects the ``error_format`` string to use the old-style formatting strings with named parameters: * code * text * path * row * col str error_formatc|j|j|j|j|j|j d|j r tzStzS)zFormat and write error out. If an output filename is specified, write formatted errors to that file. Otherwise, print the formatted error to standard out. )codetextpathrowcol) rrrfilename line_number column_numbercolorCOLORS COLORS_OFFselferrors _/mnt/ssd/data/python-lab/Trading/venv/lib/python3.12/site-packages/flake8/formatting/default.pyformatzSimpleFormatter.format(sg   JJJJNN$$&& $ v $   *4 $   Nr#rreturnz str | None)__name__ __module__ __qualname____doc____annotations__r%r&r$rrs   r&rceZdZdZdZddZy)DefaultzDefault formatter for Flake8. This also handles backwards compatibility for people specifying a custom format string. z%(bold)s%(path)s%(reset)s%(cyan)s:%(reset)s%(row)d%(cyan)s:%(reset)s%(col)d%(cyan)s:%(reset)s %(bold)s%(red)s%(code)s%(reset)s %(text)sc|jjjdk7r|jj|_yy)z!Check for a custom format string.defaultN)optionsr%lowerrr"s r$ after_initzDefault.after_initEs4 <<   $ $ &) 3 $ 3 3D  4r&Nr(None)r)r*r+r,rr6r.r&r$r0r08s 4 4r&r0ceZdZdZdZy)PylintzPylint formatter for Flake8.z%%(path)s:%(row)d: [%(code)s] %(text)sN)r)r*r+r,rr.r&r$r:r:Ks &:Lr&r:c8eZdZdZdZddZddZdfd ZxZS) FilenameOnlyz&Only print filenames, e.g., flake8 -q.z%(path)sc"t|_y)z Initialize our set of filenames.N)setfilenames_already_printedr5s r$r6zFilenameOnly.after_initVs 365&r&cy)zDo not include the source code.Nr.r!s r$ show_sourcezFilenameOnly.show_sourceZr&c|j|jvr4|jj|jt||Sy)z%Ensure we only print each error once.N)rr?addsuperr%)r"r# __class__s r$r%zFilenameOnly.format]s? >>!?!? ?  * * . .u~~ >7>%( (r&r7r') r)r*r+r,rr6rAr% __classcell__)rFs@r$r<r<Qs0L9.r&r<c eZdZdZddZddZy)NothingzPrint absolutely nothing.cy)z Do nothing.Nr.r!s r$r%zNothing.formatirBr&cy)zDo not print the source.Nr.r!s r$rAzNothing.show_sourcelrBr&Nr')r)r*r+r,r%rAr.r&r$rIrIfs#'r&rIN)r, __future__rflake8.formattingrflake8.violationrrr BaseFormatterrr0r:r<rI)ks0r$rQs*""&         $ $ae $  d(( D4o4&;_; ?*'d  'g%s A?