�
\�e4� � �� � d Z ddlmZ ddlZddlZddlZddlZddlZddlZddl Z ddl
mZmZm
Z
mZ ddlmZ ddlmZmZ ddlmZ ddlmZ ddlZdd lmZ ddlZdd
lmZmZ dZ d!d�Z! G d
� de"� Z# G d� de#� Z$ G d� d� Z% G d� de&e% � Z' G d� d� Z( G d� de
eef � Z) G d� d� Z* G d� dee* � Z+ G d� d� Z,ed� � Z-e.d k( r e-� yy)"z"Functionality related to packages.� )�annotationsN)�Iterable�Iterator�Mapping�Sequence)�
BadStatusLine)�Any�
no_type_check)� HTTPError)�urlopen)�gettext)�AcquireProgress�InstallProgress)�BaseDependency�
Dependency�Origin�Package�Record�Version�VersionListc � � t j j | � rYt j j | � |k( r7t | � 5 }t j |� j |k( cddd� S y# 1 sw Y yxY w)z(Return ``True`` if the file is the same.NF)�os�path�exists�getsize�open�apt_pkg�Hashes�hashes)r �sizer �fobjs �-/usr/lib/python3/dist-packages/apt/package.py�
_file_is_samer# 6 sa � � �w�w�~�~�d�������� 5�� =�
�$�Z� 9�4��>�>�$�'�.�.�&�8� 9� 9�� 9��s �
"A:�:Bc � � e Zd ZdZy)�
FetchErrorz(Raised when a file could not be fetched.N��__name__�
__module__�__qualname__�__doc__� � r" |