summaryrefslogtreecommitdiff
path: root/apt
AgeCommit message (Collapse)AuthorFilesLines
2014-11-07apt/debfile.py: use apt_pkg.open_maybe_clear_signed_file() when opening a ↵Michael Vogt1-1/+2
.dsc file
2014-09-03fix testsMichael Vogt2-3/+5
2014-09-03read all tags from a dsc file and improve testsMichael Vogt1-6/+6
2014-09-03add support for apt.debfile.DscSrcPackage.filelistMichael Vogt1-3/+12
2014-09-02Stop reading after the "Format" stanza in a .dsc fileMichael Vogt1-0/+3
This makes the tagfile parser skip the last gpg signature part that also contains a "Version:" line.
2014-08-28tests/test_auth.py: update for gnupg 1.4.18Mauricio Faria de Oliveira1-0/+6
The test 'test_add_key_from_server_mitm' needs updating for gnupg 1.4.18 which fail differently/earlier when 'fingerprints do not match' since commit 'Screen keyserver responses' (5230304349490f31aa64ee2b69a8a2bc06bf7816) With that change gnupg actually checks itself(!) if the key that the server send matches the key that the user asked for. Closes: #755342
2014-06-30make pep8 happy (again)Michael Vogt3-16/+16
2014-04-02apt/package.py: Do not shadow _Julian Andres Klode1-3/+3
This can lead to bugs later on and makes pyflakes 0.8 cry.
2014-03-10Revert "* apt/cache.py:" (rootdir change)Julian Andres Klode1-4/+1
This reverts commit 5e76e9fccee519c63602562dc4065deb3f97748b. Conflicts: apt/cache.py debian/changelog
2014-01-25apt/package.py: Pass an apt_pkg.Dependency to BaseDependencyJulian Andres Klode1-19/+41
Instead of passing the properties to __init__(), let's just pass the apt_pkg.Dependency. Store that in a _dep attribute, and provide properties to provide the API. The other classes do it this way as well. Reported-by: Michael Schaller <michael@5challer.de>
2014-01-25apt/package.py: Improved readability and documentation of ↵Michael Schaller1-3/+18
BaseDependency.__dstr().
2014-01-06apt/package.py: Fix BaseDependency.__dstr.__ne__()Julian Andres Klode1-1/+1
It turns out I missed this. Just simplify it to return not self.__eq__(other). Also add a test case for it. Reported-by: Michael Schaller <michael@5challer.de>
2014-01-06Unify list of comparison type values everywhereJulian Andres Klode1-1/+1
They are now ordered and include the != and < operators in all cases.
2014-01-06apt, doc: Fix the list of comp_type valuesJulian Andres Klode1-1/+1
Reported-by: Michael Schaller <michael@5challer.de>
2014-01-06Use a single code base for Python 2 and 3Julian Andres Klode5-17/+33
This is much better than running 2to3 during the build, as it gives us more control over the Python 3 code.
2014-01-06Use print_function everywhereJulian Andres Klode11-62/+83
This brings the code closer to Python 3. Automatically converted using 2to3 -f print.
2014-01-05make test_pep8.py passMichael Vogt6-89/+129
2014-01-05make pyflakes cleanMichael Vogt4-2/+3
2014-01-05apt/cache.py, apt/package.py: Fixed PEP8 and pyflakes issuesMichael Schaller2-49/+44
This commit removed the unused local variable 'transient' in 'apt/cache.py' and the unused import 'warnings' in 'apt/package.py'.
2013-11-23* apt/cache.py:Michael Vogt1-1/+4
- when using apt.Cache(rootdir=/some/dir) only read the APT configuration from this rootdir instead of /etc (closes: #728274)
2013-10-24apt/cache.py: Call os.path.abspath() on a supplied rootdir (LP: #792295)Julian Andres Klode1-0/+1
When the rootdir option is set to a relative path, that path appears multiple times in the dir::state::status path, as we also prepend it there.
2013-10-21apt/debfile.py: Pass strip_multi_arch=False to parse_depends.Julian Andres Klode1-6/+8
Patch by Michael, tests derived from the ones provided by the reporter. I included the test debs without the source package, as for our use case, all needed "source code" is included in the package itself anyway. Reported-By: Francois Gouget <fgouget@free.fr> Closes: #717859 Closes: #717861
2013-10-10apt, aptsources: Only call init_config() if not already initializedJulian Andres Klode1-2/+4
Based on an idea by the bug reporter. Reported-by: Dominique Lasserre <lasserre.d@googlemail.com> Closes: #686403
2013-10-10apt/package.py: mark_upgrade misuses FromUser to set auto-installedDaniel Hartwig1-2/+3
Package.mark_upgrade uses FromUser for it's side effect of setting a package as auto-installed (or not). However, FromUser is also influential in pkgDepCache::IsModeChangeOk to determine whether an action should override a dpkg hold, etc.. Closes: #686726
2013-10-08apt/package.py: Add a Package.has_config_files property (Closes: #712749)Julian Andres Klode1-0/+5
The name might be a bit misleading, but I cannot find a short name that completely describes this check.
2013-09-11Completely remove deprecated stuffJulian Andres Klode8-725/+0
2013-06-06add support for "key in apt.debfile.DebPackage" (closes: #710541)Michael Vogt1-0/+3
2013-05-08merged from experimental and uploaded to sidMichael Vogt3-1/+27
2013-03-19* apt/package.py:Michael Vogt1-0/+2
- export codename in apt.package.Origin as well (closes: #703401)
2013-03-13Fix the last commitJulian Andres Klode1-4/+2
2013-03-13apt/package.py: Try both filenames for package file listsJulian Andres Klode1-6/+11
(Closes: #700715)
2012-10-23build fixes for python3.3Michael Vogt1-1/+2
2012-10-15apt/cache.py: add commentMichael Vogt1-0/+1
2012-10-15close cache on (re)openMichael Vogt1-0/+2
2012-10-15merged lp:~jconti/python-apt/closeable-cache Michael Vogt1-0/+20
2012-10-10cherry pick robustness fixes for keyid (allow leading 0x, allow lowercase)Michael Vogt1-1/+3
2012-10-04* apt/cache.py:Jason Conti1-0/+20
- Add Cache.close() to delete the records and free up file descriptors - Add with statement support for Cache.close()
2012-10-02* lp:~mvo/python-apt/recv-key-lp1016643:Michael Vogt1-6/+75
- Only support long (v4) keyids when downloading keys and check the keys fingerprint before importing. This avoids man-in-the-middle attacks (LP: #1016643)
2012-10-02apt/auth.py: fix trailing whitespaceMichael Vogt1-1/+1
2012-10-01fix crash when a pkgname has no candidateMichael Vogt1-0/+1
2012-10-01apt/auth.py: proper cleanupMichael Vogt1-2/+1
2012-10-01check fingerprint after downloading a key and before adding itMichael Vogt1-4/+68
2012-10-01support only downloading long keyids (160bit) in add_key_from_keyserver()Michael Vogt1-3/+9
2012-07-30apt/auth.py: Forward stderr from apt-key to our stderr if non-emptyJulian Andres Klode1-0/+4
2012-07-30apt/auth.py: Do not merge stdout and stderr (Closes: #678706)Julian Andres Klode1-5/+5
2012-07-28Fix typos: the the -> the (closes: #679432)Jakub Wilk1-1/+1
2012-06-25Use Popen.communicate() instead of stdin, stdoutJulian Andres Klode1-10/+12
2012-06-25* apt/auth.py:Julian Andres Klode1-25/+27
- Use tempfile.NamedTemporaryFile to create temporary file
2012-06-12Drop __del__ statement, which is unsafe: ↵Evan Dandrea1-4/+1
http://www.algorithm.co.il/blogs/programming/python-gotchas-1-__del__-is-not-the-opposite-of-__init__/
2012-06-12merged lp:~glatzor/python-apt/authMichael Vogt1-0/+176