Package dak :: Module examine_package
[hide private]
[frames] | no frames]

Module examine_package

source code

Script to automate some parts of checking NEW packages

Most functions are written in a functional programming style. They return a string avoiding the side effect of directly printing the string to stdout. Those functions can be used in multithreaded parts of dak.


Contact: Debian FTP Master <ftpmaster@debian.org>

Copyright:

License: GNU General Public License version 2 or later

Functions [hide private]
 
usage(exit_code=0) source code
 
escape_if_needed(s) source code
 
headline(s, level=2, bodyelement=None) source code
 
colour_output(s, colour) source code
 
escaped_text(s, strip=False) source code
 
formatted_text(s, strip=False) source code
 
output_row(s) source code
 
format_field(k, v) source code
 
foldable_output(title, elementnameprefix, content, norow=False) source code
 
get_depends_parts(depend) source code
 
get_or_list(depend) source code
 
get_comma_list(depend) source code
 
split_depends(d_str) source code
 
read_control(filename) source code
 
read_changes_or_dsc(suite, filename, session=None) source code
 
get_provides(suite) source code
 
create_depends_string(suite, depends_tree, session=None) source code
 
output_package_relations()
Output the package relations, if there is more than one package checked in this run.
source code
 
output_deb_info(suite, filename, packagename, session=None) source code
 
do_command(command, escaped=False) source code
 
do_lintian(filename) source code
 
extract_one_file_from_deb(deb_filename, match) source code
 
get_copyright(deb_filename) source code
 
get_readme_source(dsc_filename) source code
 
check_dsc(suite, dsc_filename, session=None) source code
 
check_deb(suite, deb_filename, session=None) source code
 
strip_pgp_signature(filename) source code
 
display_changes(suite, changes_filename) source code
 
check_changes(changes_filename) source code
 
main() source code
 
get_lintian_version() source code
Variables [hide private]
  Cnf = utils.get_conf()
  printed = threading.local()
  package_relations = {}
Store relations of packages for later output
  use_html = False
  ansi_colours = {'main': "\033[36m", 'contrib': "\033[33m", 'no...
  html_colours = {'main':('<span style="color: green">', "</span...

Imports: errno, hashlib, html, os, re, sys, apt_pkg, shutil, subprocess, tarfile, tempfile, threading, utils, Config, DBConn, get_component_by_package_suite, SignedFile, re_version, re_spacestrip, re_contrib, re_nonfree, re_localhost, re_newlinespace, re_package, re_doc_directory, re_file_binary


Variables Details [hide private]

ansi_colours

Value:
{'main': "\033[36m", 'contrib': "\033[33m", 'nonfree': "\033[31m", 'pr\
ovides': "\033[35m", 'arch': "\033[32m", 'end': "\033[0m", 'bold': "\0\
33[1m", 'maintainer': "\033[32m", 'distro': "\033[1m\033[41m", 'error'\
: "\033[1m\033[41m",}

html_colours

Value:
{'main':('<span style="color: green">', "</span>"), 'contrib':('<span \
style="color: orange">', "</span>"), 'nonfree':('<span style="color: r\
ed">', "</span>"), 'provides':('<span style="color: magenta">', "</spa\
n>"), 'arch':('<span style="color: green">', "</span>"), 'bold':('<spa\
n style="font-weight: bold">', "</span>"), 'maintainer':('<span style=\
"color: green">', "</span>"), 'distro':('<span style="font-weight: bol\
d; background-color: red">', "</span>"), 'error':('<span style="font-w\
eight: bold; background-color: red">', "</span>"),}