bg:dZddlmZddlZddlZddlmZmZddlm Z ddl m Z ddl m Z ddlmZejd krdd lmZndd lmZer dd lmZdd lmZed eeeeeeeeeeeeed ZGdde ZGddeZddZdS)zJSON reporter.) annotationsN) TYPE_CHECKINGOptional) UNDEFINED)Message) BaseReporter)MessageLocationTuple)) TypedDict)PyLinter)Section OldJsonExport typemoduleobjlinecolumnendLine endColumnpathsymbolmessage message-idcbeZdZdZdZdZddZdd Zdd Ze ddZ e ddZ dS)BaseJSONReporterz$Report messages and layouts in JSON.jsonlayoutSection | NonereturnNonecfdjD}ttj|djdS)zLaunch layouts display.c:g|]}|S) serialize).0rselfs o/builddir/build/BUILD/cloudlinux-venv-1.0.7/venv/lib/python3.11/site-packages/pylint/reporters/json_reporter.py z5BaseJSONReporter.display_messages..6s%NNNW00NNN)indent)fileN)messagesprintrdumpsout)r(r json_dumpables` r)display_messagesz!BaseJSONReporter.display_messages4sHNNNN NNN  djq111AAAAAAr+rcdS)z#Don't do anything in this reporter.Nr%r(rs r)display_reportsz BaseJSONReporter.display_reports9r+cdS)z Do nothing.Nr%r6s r)_displayzBaseJSONReporter._display<r8r+rrrctNNotImplementedErrorrs r)r&zBaseJSONReporter.serialize?!!r+message_as_jsonctr<r=rAs r) deserializezBaseJSONReporter.deserializeCr@r+N)rr r!r")rrr!r"rrr!rrArr!r) __name__ __module__ __qualname____doc__name extensionr4r7r: staticmethodr&rDr%r+r)rr.s.. DIBBBB 2222"""\""""\"""r+rcBeZdZdZed dZed dZd S) JSONReportera TODO: 3.0: Remove this JSONReporter in favor of the new one handling abs-path and confidence. TODO: 2.16: Add a new JSONReporter handling abs-path, confidence and scores. (Ultimately all other breaking change related to json for 3.0). rrr!rc |j|j|j|j|j|j|j|j|j|j pd|j d S)Nr) categoryrrrrend_line end_columnrrmsgmsg_idr?s r)r&zJSONReporter.serializeRsR$n;Ln' +Ln{(b!.   r+rAct|d|d|dt|d|d|d|d|d|d|d |d  t S) Nrrrrrrrrrr)abspathrrrrrrSrT)rVrrUlocation confidence)rr rrCs r)rDzJSONReporter.deserializebs"<0"8, *)'/$V,&x0#E*$V,&x0(3*;7   !!    r+NrErF)rGrHrIrJrMr&rDr%r+r)rOrOHs^    \     \   r+rOlinterr r!r"c:|tdSr<)register_reporterrO)r[s r)registerr^xs \*****r+)r[r r!r")rJ __future__rrsystypingrrpylint.interfacesrpylint.messagerpylint.reporters.base_reporterr pylint.typingr version_infor typing_extensionspylint.lint.pylinterr pylint.reporters.ureports.nodesrstrintrrrOr^r%r+r)rls """""" ********''''''""""""777777......v       ++++++8------777777 C=c]   $"""""|"""4- - - - - #- - - `++++++r+