Ë
    ëSûe†  ã                   ó¦  — U d Z ddlZddlmZ ddlmZ ddlmZ ej                  Zddl	m
Z
mZ ddlmZmZ ddlmZmZmZ dd	lmZmZ dd
lmZ ddlmZ dZej2                  Zej6                  aej8                  aej:                  Zej<                  Zej>                  Zej@                  Z ejB                  Z!	 ddl"m#Z# dZ$ ejL                  d«      Z' ejL                  d«      Z( ejR                  e*«      Z+ ejX                  «       Z-e-j]                  e'«       e-j_                  e«       e+ja                  e-«       ej2                  ejb                  ejd                  dœZ3e4e5d<   e$rD e#«       Z6e6j_                  ejb                  «       e6j]                  e'«       e+ja                  e6«       e+j_                  ejd                  «       dde7ddfd„Z8de9ddfd„Z:ejv                  Z;ejx                  Z<ejz                  Z=ej|                  Z>ej~                  Z?ej€                  Z@ej‚                  ZAej„                  ZBej†                  ZCejˆ                  ZDejŠ                  ZEejŒ                  ZFejŽ                  ZGej�                  ZHej’                  ZIej”                  ZJej–                  ZKej˜                  ZLejš                  ZMejœ                  ZNy# e%$ r dZ$Y �Œw xY w)aÊ  
Copyright (c) 2019-2022, Ian Santopietro
All rights reserved.

This file is part of RepoLib.

RepoLib is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

RepoLib is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License
along with RepoLib.  If not, see <https://www.gnu.org/licenses/>.
é    N)ÚPathé   )Ú__version__)Ú
SourceFileÚSourceFileError)ÚSourceÚSourceError)Ú	PPASourceÚPopdevSourceÚshortcut_prefixes)Ú	SourceKeyÚKeyFileError)Úutil)Úsystemz/var/log/repolib.log)ÚJournalHandlerTFz(%(name)-21s: %(levelname)-8s %(message)sz6%(asctime)s - %(name)-21s: %(levelname)-8s %(message)s)r   r   é   Úlog_level_mapÚtestingÚreturnc                 óp   — t        j                  | ¬«       t         j                  at         j                  ay)zPuts Repolib into testing mode©r   N)r   Úset_testingÚKEYS_DIRÚSOURCES_DIRr   s    ú2/usr/lib/python3/dist-packages/repolib/__init__.pyr   r   [   s&   € ô
 	×Ñ˜WÕ%Ü�}‰}€HÜ×"Ñ"�Kó    Úlevelc                 ó\   — | dkD  rd} | dk  rd} t         |    }t        j                  |«       y)a´  Set the logging level for this current repolib

    Accepts an integer between 0 and 2, with 0 being the default loglevel of
    logging.WARNING, 1 being logging.INFO, and 2 being logging.DEBUG.

    Values greater than 2 are clamped to 2. Values less than 0 are clamped to 0.

    Note: This only affects console output. Log file output remains 
    at logging.INFO
    
    Arguments:
        level(int): A logging level from 0-2
    r   r   N)r   Úconsole_logÚsetLevel)r   Ú	LOG_LEVELs     r   Úset_logging_levelr"   e   s4   € ð ˆq‚yØˆØˆq‚yØˆÜ˜eÑ$€IÜ×Ñ˜Õ#r   )T)OÚ__doc__ÚloggingÚlogging.handlersÚhandlersÚpathlibr   Ú r   ÚVERSIONÚfiler   r   Úsourcer   r	   Ú	shortcutsr
   r   r   Úkeyr   r   r   r   ÚLOG_FILE_PATHÚWARNINGr!   r   r   ÚTESTINGÚKEYSERVER_QUERY_URLÚDISTRO_CODENAMEÚPRETTY_PRINTÚCLEAN_CHARSÚsystemd.journalr   Úsystemd_supportÚImportErrorÚ	FormatterÚ
stream_fmtÚfile_fmtÚ	getLoggerÚ__name__ÚlogÚStreamHandlerr   ÚsetFormatterr    Ú
addHandlerÚINFOÚDEBUGr   ÚdictÚ__annotations__Újournald_logÚboolr   Úintr"   Ú	RepoErrorÚSourceFormatÚ
SourceTypeÚAptSourceEnabledÚscrub_filenameÚurl_validatorÚprettyprint_enableÚvalidate_deblineÚstrip_hashesÚcompare_sourcesÚcombine_sourcesÚsourcesÚfilesÚkeysÚerrorsÚ
valid_keysÚoptions_inmapÚoptions_outmapÚtrue_valuesÚload_all_sources© r   r   ú<module>r]      s˜  ðòó( Ý #å å à
×
!Ñ
!€ç -ß 'ß AÑ Aß (Ý Ý à&€Ø�O‰O€	Ø�=‰=€Ø×Ñ€Ø
�,‰,€Ø×.Ñ.Ð Ø×&Ñ&€Ø× Ñ €Ø×Ñ€ðÝ.Ø€Oð
 ˆW×ÑØ/ó€
ð ˆ7×ÑØ<ó€ð €g×Ñ˜Ó!€à#ˆg×#Ñ#Ó%€Ø × Ñ ˜Ô $Ø × Ñ �YÔ ð ‡�ˆ{Ô ð ‡�Ø‡|�|Ø‡}�}ñ€ˆdó ñ Ù!Ó#€LØ×Ñ˜'Ÿ,™,Ô'Ø×Ñ˜jÔ)Ø‡N�N�<Ô à ‡�ˆW�]‰]Ô ñ#˜ð #¨ó #ð$˜Cð $ Dó $ð* �N‰N€	Ø× Ñ €Ø�_‰_€
Ø×(Ñ(Ð à×$Ñ$€Ø×"Ñ"€Ø×,Ñ,Ð Ø×(Ñ(Ð Ø× Ñ €Ø×&Ñ&€Ø×&Ñ&€Ø
�,‰,€Ø�
‰
€Ø‡y�y€Ø	�‰€à�_‰_€
Ø×"Ñ"€Ø×$Ñ$€Ø×Ñ€à×*Ñ*Ñ øðy ò ØƒOðús   Â7K ËKËK