Part of lp.archiveuploader
Class | UploadError | All upload errors are returned in this form. |
Class | UploadWarning | All upload warnings are returned in this form. |
Class | DpkgSourceError | Undocumented |
Function | get_source_file_extension | Get the extension part of a source file name. |
Function | determine_source_file_type | Determine the SourcePackageFileType of the given filename. |
Function | determine_binary_file_type | Determine the BinaryPackageFileType of the given filename. |
Function | prefix_multi_line_string | Utility function to split an input string and prefix, |
Function | extract_component_from_section | Undocumented |
Class | ParseMaintError | Exception raised for errors in parsing a maintainer field. |
Function | parse_maintainer | Parses a Maintainer or Changed-By field into the name and address. |
Function | parse_maintainer_bytes | Wrapper for parse_maintainer to handle both Unicode and bytestrings. |
Function | rfc822_encode_address | Return a Unicode RFC822 encoding of a name and an email address. |
Function | extract_dpkg_source | Extract a source package by dsc file path. |
Function | parse_file_list | Undocumented |
Function | merge_file_lists | Merge Files, Checksums-Sha1 and Checksums-Sha256 fields. |
Function | parse_and_merge_file_lists | Undocumented |
Each line with a token or tag. Can be used for quoting text etc.
maintainer, name and address are all Unicode.
It verifies the content type and transforms it to a unicode with guess(). Then we can safely call parse_maintainer().
name and email must be Unicode. If they contain non-ASCII characters, the result is not RFC822-compliant and you should use something like format_address instead.
This is similar to email.utils.format_addr, except that it handles special characters using the 'email (name)' format rather than '"name" (email)'.
Parameters | dsc_filepath | Path of the DSC file |
target | Target directory |
Turns lists of (MD5, size, [extras, ...,] filename), (SHA1, size, filename) and (SHA256, size, filename) into a list of (filename, {algo: hash}, size, [extras, ...], filename).
Duplicate filenames, size conflicts, and files with missing hashes will cause an UploadError.
'extras' is (section, priority) if changes=True, otherwise it is omitted.