+
    oFjI                     t    R t ^ RIt^ RIt^ RIt^ RIHt ^ RIt ! R R]P                  P                  4      t
R# )z Debian crash database interface.N)Anyc                   L   a  ] tR t^t o RtV 3R lR ltR tR	R ltR tRt	V t
R# )
CrashDatabasezaDebian crash database.

This is a Apport CrashDB implementation for interacting with Debian BTS.
c                N   < V ^8  d   QhRS[ R,          RS[S[ S[3,          RR/# )   	auth_fileNoptionsreturn)strdictr   )format__classdict__s   "</usr/lib/python3/dist-packages/apport/crashdb_impl/debian.py__annotate__CrashDatabase.__annotate__   s3     A A#* AtCH~ A$ A    c                *   \         P                  P                  P                  WV4       W n        V P                  P                  R4      '       g   RV P                  R&   V P                  P                  R4      '       g   RV P                  R&   R# R# )zInitialize crash database connection.

Debian implementation is pretty basic as most of its bug management
processes revolve around the email interface
smtphostzreportbug.debian.org	recipientzsubmit@bugs.debian.orgN)apportcrashdbr   __init__r   get)selfr   r   s   &&&r   r   CrashDatabase.__init__   sn     	$$--dwG||
++'=DLL$||,,(@DLL% -r   c                    V P                   P                  R4      '       g   RV9  d   RVR&   RV9   d   VP                  4       '       g   RVR&   \        P                  P
                  P                  W4      # )zaCheck if this report can be uploaded to this database.
Checks for the proper settings of apport.
senderUnreportableReasonz<Please configure sender settings in /etc/apport/crashdb.conf
Stacktracez>Incomplete backtrace. Please install the debug symbol packages)r   r   has_useful_stacktracer   r   r   accepts)r   reports   &&r   r    CrashDatabase.accepts,   sr     ||)).B&.PN '(
 6!&*F*F*H*HP '( ~~++33DAAr   Nc                ^   V P                  V4      '       g   Q h VR,          P                  R4      w  rE\        P
                  ! 4       ;_uu_ 4       pTP                  P                  RT R2P                  R4      4       TP                  P                  RT R2P                  R4      4       TP                  P                  R	P                  R4      4        TR
 TP                  T4       TP                  P                  ^ 4       \        P                  P                  P                  TP                  P                  4       P                  R4      4      pRRR4       TR,          XR&   T P                   R,          TR&   T P                   R,          TR&   TP#                  RT P                   R,          4       TP#                  RRTR,          P%                  4        24       \&        P(                  ! T P                   R,          4      pTP+                  T P                   R,          T P                   R,          TP-                  4       P                  R4      4       TP/                  4        R#   \        \        3 d     R# i ; i  \         d     ELi ; i  + '       g   i     ELK; i)zUpload given problem report return a handle for it.

In Debian, we use BTS, which is heavily email oriented. This method
crafts the bug into an email report understood by Debian BTS.
Package Fz	Package: 
zUTF-8z	Version: z


z=============================

CoreDumpNTitleSubjectr   Fromr   TozX-Debbugs-CCUsertagzapport-ProblemTyper   T)r    splitKeyError
ValueErrortempfileNamedTemporaryFilefilewriteencodeseekemailmimetextMIMETextreaddecoder   
add_headerlowersmtplibSMTPsendmail	as_stringquit)	r   r!   progress_callbackuser_message_callbackbuggy_packagebuggy_versiontempmsgsmtps	   &&&&     r   uploadCrashDatabase.upload=   s    ||F####	+1)+<+B+B3+G(M ((**dIIOOib9@@IJIIOOif=DDWMNIIOO@HHQR:&
 LLIINN1**//**499>>+;+B+B7+KLC+ +.  Ill8,FLL-D	 	~t||H'=>yGF=,A,G,G,I+J"KL||DLL45LL"LL%MMO""7+	

 			S *% 		    +**sC   I1 BJJ	A<J1JJ	JJJJJ,	c                    R# )a  Return an URL that should be opened after report has been uploaded
and upload() returned handle.

Should return None if no URL should be opened (anonymous filing without
user comments); in that case this function should do whichever
interactive steps it wants to perform.
N )r   r!   handles   &&&r   get_comment_urlCrashDatabase.get_comment_urlu   s     r   )r   )NN)__name__
__module____qualname____firstlineno____doc__r   r    rK   rP   __static_attributes____classdictcell__)r   s   @r   r   r      s,     A AB"6p r   r   )rV   email.mime.textr7   r?   r1   typingr   apport.crashdbr   r   r   rN   r   r   <module>r\      s1    &     iFNN00 ir   