daklib.checks¶
module provided pre-acceptance tests
Please read the documentation for the Check class for the interface.
Functions
  | 
Check all fields of a control file for valid UTF-8  | 
  | 
Classes
  | 
Check the uploader is allowed to upload the packages in .changes  | 
Check for arch:all binNMUs  | 
|
Check binary packages for syntax errors.  | 
|
check members of .deb file  | 
|
check timestamps of files in binary packages  | 
|
Check changes file for syntax errors.  | 
|
  | 
base class for checks  | 
Checks hashes in .changes and .dsc against an external database.  | 
|
Check package using lintian  | 
|
Override NEW requirement  | 
|
Check signature of changes and dsc file (if included in upload)  | 
|
Check timestamp of .changes signature  | 
|
Check that the .changes targets only a single distribution.  | 
|
Check source package for syntax errors.  | 
|
Check source format is allowed in the target suite  | 
|
check for a transition  | 
|
Check version constraints  | 
|
Check that .changes and .dsc are not signed using a weak algorithm  | 
Exceptions
exception raised by failing checks  | 
|
  | 
exception raise by failing ACL checks  | 
exception raised by failing the external hashes check  | 
- class daklib.checks.ACLCheck[source]¶
 Check the uploader is allowed to upload the packages in .changes
- class daklib.checks.BinaryCheck[source]¶
 Check binary packages for syntax errors.
- class daklib.checks.BinaryTimestampCheck[source]¶
 check timestamps of files in binary packages
Files in the near future cause ugly warnings and extreme time travel can cause errors on extraction.
- class daklib.checks.Check[source]¶
 base class for checks
checks are called by
daklib.archive.ArchiveUpload. Failing tests should raise adaklib.checks.Rejectexception including a human-readable description why the upload should be rejected.- check(upload: ArchiveUpload)[source]¶
 do checks
- Parameters:
 upload – upload to check
- Raises:
 Reject – upload should be rejected
- property forcable: bool¶
 allow to force ignore failing test
Trueif it is acceptable to force ignoring a failing test,Falseotherwise
- per_suite_check(upload: ArchiveUpload, suite: Suite)[source]¶
 do per-suite checks
- Parameters:
 upload – upload to check
suite – suite to check
- Raises:
 Reject – upload should be rejected
- class daklib.checks.ExternalHashesCheck[source]¶
 Checks hashes in .changes and .dsc against an external database.
- class daklib.checks.NoSourceOnlyCheck[source]¶
 
- exception daklib.checks.RejectExternalFilesMismatch[source]¶
 exception raised by failing the external hashes check
- class daklib.checks.SignatureAndHashesCheck[source]¶
 Check signature of changes and dsc file (if included in upload)
Make sure the signature is valid and done by a known user.
- _check_hashes(upload: ArchiveUpload, filename: str, files: Iterable[HashedFile])[source]¶
 Make sure hashes match existing files
- Parameters:
 upload – upload we are processing
filename – name of the file the expected hash values are taken from
files – files to check the hashes for
- class daklib.checks.SingleDistributionCheck[source]¶
 Check that the .changes targets only a single distribution.
- class daklib.checks.SourceCheck[source]¶
 Check source package for syntax errors.
- class daklib.checks.TransitionCheck[source]¶
 check for a transition
- class daklib.checks.VersionCheck[source]¶
 Check version constraints
- class daklib.checks.WeakSignatureCheck[source]¶
 Check that .changes and .dsc are not signed using a weak algorithm
- daklib.checks.check_fields_for_valid_utf8(filename, control)[source]¶
 Check all fields of a control file for valid UTF-8
- daklib.checks.check_signature_timestamp(prefix: str, signed_file: SignedFile) bool[source]¶