dak.check_archive

Various different sanity checks

@contact: Debian FTP Master <ftpmaster@debian.org> @copyright: (C) 2000, 2001, 2002, 2003, 2004, 2006 James Troup <james@nocrew.org> @license: GNU General Public License version 2 or later

Module Attributes

db_files

Cache of filenames as known by the database

waste

How many bytes are "wasted" by files not referenced in database

excluded

List of files which are excluded from files check

current_time

now()

Functions

Ent(Kind, Name, Link, Mode, UID, GID, Size, ...)

add_missing_source_checksums()

Add missing source checksums to source_metadata

check_build_depends()

Validate build-dependencies of .dsc files in the archive

check_checksums()

Validate all files

check_dscs()

Parse every .dsc file in the archive and check for it's validity.

check_files()

Prepare the dictionary of existing filenames, then walk through the archive pool/ directory to compare it.

check_files_in_dsc()

Ensure each .dsc lists appropriate files in its Files field (according to the format announced in its Format field).

check_files_not_symlinks()

Check files in the database aren't symlinks

check_indices_files_exist()

Ensure files mentioned in Packages & Sources exist

check_override()

Check for missing overrides in stable and unstable.

check_source_in_one_dir()

Ensure that the source files for any given package is all in one directory so that 'apt-get source' works...

check_timestamps()

Check all files for timestamps in the future; common from hardware (e.g.

chk_bd_process_dir(dirname, filenames)

main()

process_dir(unused, dirname, filenames)

Process a directory and output every files name which is not listed already in the filenames or global excluded dictionaries.

usage([exit_code])

validate_packages(suite, component, architecture)

Ensure files mentioned in Packages exist

validate_sources(suite, component)

Ensure files mentioned in Sources exist

dak.check_archive.Ent(Kind, Name, Link, Mode, UID, GID, Size, MTime, Major, Minor)[source]
dak.check_archive.add_missing_source_checksums()[source]

Add missing source checksums to source_metadata

dak.check_archive.check_build_depends()[source]

Validate build-dependencies of .dsc files in the archive

dak.check_archive.check_checksums()[source]

Validate all files

dak.check_archive.check_dscs()[source]

Parse every .dsc file in the archive and check for it’s validity.

dak.check_archive.check_files()[source]

Prepare the dictionary of existing filenames, then walk through the archive pool/ directory to compare it.

dak.check_archive.check_files_in_dsc()[source]

Ensure each .dsc lists appropriate files in its Files field (according to the format announced in its Format field).

Check files in the database aren’t symlinks

dak.check_archive.check_indices_files_exist()[source]

Ensure files mentioned in Packages & Sources exist

dak.check_archive.check_override()[source]

Check for missing overrides in stable and unstable.

dak.check_archive.check_source_in_one_dir()[source]

Ensure that the source files for any given package is all in one directory so that ‘apt-get source’ works…

dak.check_archive.check_timestamps()[source]

Check all files for timestamps in the future; common from hardware (e.g. alpha) which have far-future dates as their default dates.

dak.check_archive.chk_bd_process_dir(dirname, filenames)[source]
dak.check_archive.current_time = 1734270379.6064517

now()

dak.check_archive.db_files = {}

Cache of filenames as known by the database

dak.check_archive.excluded = {}

List of files which are excluded from files check

dak.check_archive.main()[source]
dak.check_archive.process_dir(unused, dirname: str, filenames: dict) None[source]

Process a directory and output every files name which is not listed already in the filenames or global excluded dictionaries.

Parameters:
  • dirname – the directory to look at

  • filenames – Known filenames to ignore

dak.check_archive.usage(exit_code=0)[source]
dak.check_archive.validate_packages(suite, component, architecture)[source]

Ensure files mentioned in Packages exist

dak.check_archive.validate_sources(suite, component)[source]

Ensure files mentioned in Sources exist

dak.check_archive.waste = 0.0

How many bytes are “wasted” by files not referenced in database