summaryrefslogtreecommitdiffstats
path: root/pym/portage/dbapi/bintree.py
Commit message (Collapse)AuthorAgeFilesLines
* Use unicode_literals more.Zac Medico2013-01-181-5/+7
| | | | | This helps to ensure consistent results, regardless of whether we're using Python 2 or Python 3.
* BinpkgVerifier: use async FileDigesterZac Medico2013-01-051-13/+25
|
* binarytree: tweak deprecated constructor paramZac Medico2012-12-241-5/+5
|
* update_dbentry: add parent arg for bug #367215Zac Medico2012-11-131-1/+1
|
* Remove old binhost protocol for bug #438640.Zac Medico2012-10-171-69/+1
| | | | | The old protocol has been deprecated since portage-2.1.6 (2009), so it should be completely irrelevant now.
* bintree/portree: fix getslot for EAPI 5 sub-slotZac Medico2012-10-171-4/+2
|
* Add experimental EAPI 5-hdepend support.Ambroz Bizjak2012-09-241-5/+7
|
* _apply_hash_filter: make hash_filter simplerZac Medico2012-08-211-1/+2
| | | | | Now any callable object will work, which might be helpful for consumers of the Manifest.checkFileHashes() method.
* Implement PORTAGE_CHECKSUM_FILTER for bug #432170Zac Medico2012-08-211-1/+5
|
* emaint binhost: support compress-indexZac Medico2012-08-091-21/+25
|
* bintree.inject(): write Packages.gz atomicallyZac Medico2012-08-081-3/+6
|
* Portage writes a compressed copy of 'Packages' index file.W-Mark Kubacki2012-08-081-6/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | This behaviour is enabled by FEATURES="compress-index". The resulting file is 'Packages.gz' and its modification time will match that of 'Packages'. Web-servers use that copy to avoid repeated on-the-fly compression. In order to re-use 'atomic_ofstream' usage of 'codecs.zlib_codec' has been considered and discarded, because 'GzipFile' yields smaller files. (According to Mark's tests 62% smaller.) Example usage, Nginx: location =/Packages { gzip_static on; default_type text/plain; } Apache httpd (use with caution): RewriteRule ^(.*)/Packages$ $1/Packages.gz [T=text/plain,E=GZIP:gzip,L] <FilesMatch "Packages\.gz$"> Header set Content-Encoding gzip </FilesMatch>
* Fix index file's mtime, which can differ from TIMESTAMP.W-Mark Kubacki2012-08-011-1/+5
| | | | | | | | | | | | This enables Portage to reliably query for remote indices with HTTP-header If-Modified-Since. Without this patch mtime is greater than TIMESTAMP for large indices and slow storages - because writing a large file takes time. If the difference spans a second (TIMESTAMP 08:00:00, mtime 08:00:01), then Portage will always fetch the remote index because it will appear being modified (mtime is used there) after the copy has been made (local copy's TIMESTAMP is used here).
* Use If-Modified-Since HTTP-header and avoid downloading a remote index if ↵W-Mark Kubacki2012-08-011-3/+21
| | | | the local copy is recent enough.
* portage.update: use isvalidatom for EAPI checkZac Medico2012-07-171-5/+10
|
* move: respect EAPI wrt dots_in_PN, bug #426476Zac Medico2012-07-171-2/+5
|
* Propagate EAPI for update_dbentry (bug #426476).Zac Medico2012-07-171-1/+5
|
* Fix bugs in binarytree.invalids usage.Zac Medico2012-07-011-1/+3
|
* Move post_src_install metadata code to one func.Zac Medico2012-06-111-1/+0
|
* bintree: validate remove cpv morev2.2.0_alpha105Zac Medico2012-05-141-2/+14
|
* Split out _hide_url_passwd() and use it more.Zac Medico2012-05-131-4/+3
|
* binhost: http auth for python3 (bug #413983)Zac Medico2012-05-131-3/+2
| | | | | | | | This uses the code from commit 58a8cd1bb943522bc53d02c008ee8eff798bfaaa as a fallback for python3 when the default urlopen function fails. This has been tested and is known to work with thttpd password authentication (it works unencrypted and also when encrypted with stunnel).
* Revert "Bug #413983: Add portage.util.urlopen(), which transparently handles ↵Zac Medico2012-05-131-2/+3
| | | | | | | authentication in the way compatible with Python 3." This reverts commit 0a9cc38a66ded0cf0e5b534cb24b970fc9c21920. As reported in bug #415579, that commit broke FTP authentication.
* Add a _pkg_str class to cache catpkgsplit resultsZac Medico2012-05-121-2/+4
| | | | | This will compensate for the removal of the catpkgsplit cache in commit 68888b0450b1967cb70673a5f06b04c167ef879c.
* Bug #413983: Add portage.util.urlopen(), which transparentlyArfrever Frehtes Taifersar Arahesis2012-05-011-4/+3
| | | | handles authentication in the way compatible with Python 3.
* Replace @returns with @return.Zac Medico2012-03-271-3/+3
|
* REQUIRED_USE: don't save in built packagesZac Medico2011-11-071-3/+2
| | | | | | | It should be safe to assume that REQUIRED_USE is satisfied if the package is built, so it's a waste to save it. Also, fix code which assumes that built Package instances have a REQUIRED_USE key in their metadata.
* Deprecate unused 'virtual' constructor parametersZac Medico2011-10-281-1/+8
|
* stacklevel=3 for properties warningsZac Medico2011-10-271-1/+1
| | | | There's an extra level for the @property wrapper.
* deprecate "root" attributesZac Medico2011-10-241-3/+25
| | | | | | In preparation for prefix support, were EROOT will be used in place of ROOT in many places, deprecate unnecessary "root" attributes in order to eliminate them as a possible source of confusion.
* Add bindbapi.getfetchsizes() like pordbapi has.Zac Medico2011-10-191-0/+28
|
* Migrate from codecs.open() to io.open().Zac Medico2011-07-101-2/+3
| | | | | | | | | | | | | | | | | The io.open() function is the same as the built-in open() function in python3, and its implementation is optimized in python-2.7 and later. In addition to the possible performance improvement, this also allows us to avoid any future compatibility issues with codecs.open() that may arise if it is delegated to the built-in open() function as discussed in PEP 400. The main caveat involved with io.open() is that TextIOWrapper.write() raises TypeError if given raw bytes, unlike the streams returned from codecs.open(). This is mainly an issue for python2 since literal strings are raw bytes. We handle this by wrapping TextIOWrapper.write() arguments with our _unicode_decode() function. Also, the atomic_ofstream class overrides the write() method in python2 so that it performs automatic coercion to unicode when necessary.
* bintree: don't provide default VERSION headerv2.2.0_alpha41Zac Medico2011-06-131-1/+0
| | | | | We want to make sure that we know when the VERSION header is missing, so we shouldn't provide a default value.
* bintree: verify that default REPO is legitZac Medico2011-06-101-1/+1
| | | | | We need to check the RepoConfig.missing_repo_name attribute to make sure the repo_name is really defined.
* bintree: handle pkgindex CHOST header like REPOZac Medico2011-06-101-1/+2
| | | | | This allows an existing CHOST header entry to properly override our default.
* bintree: always populate pkgindex REPO headerZac Medico2011-06-101-10/+16
| | | | | | | The previous code would only populate it when there was no existing index file. Now, the default will be populated even if the file exists already. If an existing pkgindex header already defines these keys, then they will appropriately override our defaults.
* bintree: populate REPO header for empty pkgindexv2.2.0_alpha38Zac Medico2011-06-061-1/+8
|
* emerge: add --rebuild and --norebuild-atoms optsDavid James2011-05-011-1/+7
| | | | | | | | | | | | | | | | | | | | | | | Rebuild when build-time/run-time deps are upgraded. If pkgA has been updated, and pkgB depends on pkgA at both build-time and run-time, pkgB needs to be rebuilt. This feature ensures that all packages are consistent when dependencies that are used at both runtime and build time are changed. This feature only rebuilds packages one layer deep. That means that if you upgrade libcros, for example, packages that depend directly on libcros will be rebuilt and reinstalled, but indirect dependencies will not be rebuilt. BUG=chromium-os:14296 TEST=Test whether packages rebuilding a bunch of packages. Change-Id: Idbc0532b4b1de28fd9e5a0abe3b7dbe1a3abd2c8 Review URL: http://codereview.chromium.org/6905107
* Fix unhandled FileNotFound from previous commit.Zac Medico2011-02-131-1/+1
| | | | | There is an existing handler for EnvironmentError, so raise that instead of FileNotFound.
* Add support for grabbing Packages files using external programs.David James2011-02-131-2/+14
| | | | | | | | | | | | | If the user specifies FETCHCOMMAND_*, Portage should honor this when grabbing Packages files. This allows users to setup support for grabbing Packages files from other protocols. BUG=chrome-os-partner:2026 TEST=Try downloading prebuilts from gs:// when FETCHCOMMAND_GS is setup in make.conf Change-Id: I96b239819351633dd02d608954e81a1c363a4687 Review URL: http://codereview.chromium.org/6458015
* bintree: cleanup/fix old binhost code moreZac Medico2011-02-021-4/+2
|
* bintree: clean up dict use in old binhost codeZac Medico2011-02-021-2/+3
|
* bintree: add missing del from previous commitZac Medico2011-02-021-1/+1
|
* bintree: remove unused __remotepkgsZac Medico2011-02-021-10/+5
|
* bintree: warn for missing binhost TIMESTAMPZac Medico2011-01-291-0/+2
| | | | This seems to be the case that's triggered in bug 353189 and bug 350139.
* binarytree: fix BASE_URI for old-style binhostZac Medico2011-01-261-0/+1
|
* binarytree: fix broken BASE_URI initializationZac Medico2011-01-261-2/+3
|
* Update Portage to support multiple binhosts.David James2011-01-261-15/+19
| | | | | | | | | | | BUG=chromium-os:11295 TEST=Build x86-mario with multiple binhosts (board binhost, preflight binhost) and verify that binaries are picked up from both binhosts. Also verify that if one of the binhosts fails, the other binhost is used correctly. Review URL: http://codereview.chromium.org/6329022 Change-Id: I095f28c82e3effbc25105af6ac89e42c335e6381
* Omit user:pass@ from binhost Packages cache path.Zac Medico2010-12-311-2/+11
|
* bintree: add timeout for closing binhost connv2.2.0_alpha11Zac Medico2010-12-311-2/+13
| | | | Hopefully this solves bug #350139.