No description
  • Python 92.5%
  • Shell 5%
  • C 1.9%
  • Meson 0.6%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Matt Turner 14293ea6db
depgraph: don't let a || choice block a slot operator update
_slot_operator_check_reverse_dependencies() rejects an update candidate
if it does not satisfy an atom of a parent of the existing package.
When the parent chose that atom from a || group with other
alternatives, such as nvidia-drivers' || ( openssl-compat:3
openssl:0/3 ), the choice was only made because the installed package
satisfied it. Rejecting the candidate then pins the package at its old
slot even though the parent can be satisfied another way, so
dev-libs/openssl-4 was never pulled in.

Give the candidate a chance in this case, as is already done for
parents that could be upgraded or removed, and rely on backtracking to
mask it if the parent really cannot be satisfied.

Bug: https://bugs.gentoo.org/984929
Signed-off-by: Matt Turner <mattst88@gentoo.org>
2026-11-12 22:18:27 -05:00
.builds sr.ht ci: add some pytest options 2023-11-11 02:55:29 +00:00
.github ci: run pylint in the Gentoo container image 2026-11-05 16:02:38 -05:00
bin phase-functions.sh: remove nested empty directories in __dyn_clean() 2026-11-12 20:02:03 +00:00
cnf Drop "https://www." from the default User-Agent 2026-10-08 16:08:53 +01:00
doc doc: use the phrase "death hooks" 2026-08-24 06:16:52 +01:00
lib depgraph: don't let a || choice block a slot operator update 2026-11-12 22:18:27 -05:00
man Replace repoman with pkgdev 2026-11-03 22:24:31 +00:00
misc ensure GNU tar is used in most places 2025-09-16 16:40:22 +01:00
src meson: test that the native extensions import 2026-09-24 14:49:20 -04:00
.editorconfig .editorconfig: set trim_trailing_whitespace too 2023-03-24 02:17:18 +00:00
.git-blame-ignore-revs ci: update .git-blame-ignore-revs 2026-08-21 06:24:52 -07:00
.gitignore main.py, portage.util: Add docstrings and type annotations 2023-06-06 07:52:40 +01:00
.portage_not_installed Check presence of .portage_not_installed file instead of .git directory 2014-02-05 17:25:18 +01:00
.pre-commit-config.yaml Update black to 26.5.1 and re-format 2026-06-27 13:39:17 +01:00
COPYING COPYING: License field in header should be GPL-2 rather than GPL-2+ 2017-12-02 13:45:53 -08:00
DEVELOPING DEVELOPING: Make it easier to copy and paste the release instructions 2026-06-23 10:09:11 +01:00
LICENSE Bug #318241 - Add GPL-2 LICENSE file. 2010-05-17 15:31:52 -07:00
make.conf.example-repatch.sh *: use /usr/bin/env bash iso /bin/bash 2022-07-25 17:18:14 +02:00
meson.build NEWS, meson.build: prepare for portage-3.0.83 2026-10-11 00:45:12 +01:00
meson_options.txt dep: add native C dep-string parser 2026-08-05 17:05:28 -04:00
NEWS cache/metadata: put IDEPEND on the line PMS specifies 2026-11-12 22:17:24 -05:00
pylintrc pylint fixes 2025-10-24 00:45:41 -07:00
pyproject.toml pyproject.toml, NEWS: declare pytest markers. 2023-11-11 02:55:29 +00:00
README.md Increase minimum Python version from Python 3.6/3.7 -> Python 3.9 2023-07-26 08:58:30 +01:00
RELEASE-NOTES RELEASE-NOTES: mark as obsolete in favor of NEWS 2022-07-10 17:25:49 +01:00
run-pylint Add script to call pylint on all python files 2022-06-06 11:31:33 -04:00
TEST-NOTES tests: add a mode that verifies the playground metadata cache 2026-09-20 12:28:18 -04:00
testpath Rename pym→lib, for better distutils-r1 interoperability 2018-07-18 16:19:11 -07:00
tox.ini .github, tox.ini: update for latest python and github actions 2026-08-06 13:23:44 +01:00

CI

About Portage

Portage is a package management system based on ports collections. The Package Manager Specification Project (PMS) standardises and documents the behaviour of Portage so that ebuild repositories can be used by other package managers.

Contributing

Contributions are always welcome! We've started using black to format the code base. Please make sure you run it against any PR's prior to submitting (otherwise we'll probably reject it).

There are ways to integrate black into your text editor and/or IDE.

You can also set up a git hook to check your commits, in case you don't want editor integration. Something like this:

# .git/hooks/pre-commit (don't forget to chmod +x)

#!/bin/bash
black --check --diff .

One can also use pre-commit to run the configured pre-commit hooks. Utilizing pre-commit has the advantage of running the linter over only the changed files, resulting in a much faster pre-commit hook. To use, install pre-commit and then install the hook to your .git:

emerge dev-vcs/pre-commit
pre-commit install

To ignore commit 1bb64ff452 (and other reformatting commits) which is a massive commit that simply formatted the code base using black - you can do the following:

git config blame.ignoreRevsFile .git-blame-ignore-revs

Dependencies

Python and Bash should be the only hard dependencies. Python 3.9 is the minimum supported version.

Native Extensions

Portage includes some optional native extensions which can be built in the source tree by running the following command:

python setup.py build_ext --inplace --portage-ext-modules

The following setup.cfg settings can be used to enable building of native extensions for all invocations of the build_ext command (the build_ext command is invoked automatically by other build commands):

   [build_ext]
   portage_ext_modules=true

Currently, the native extensions only include libc bindings which are used to validate LC_CTYPE and LC_COLLATE behavior for EAPI 6. If the native extensions have not been built, then portage will use ctypes instead.

Licensing and Legalese

Portage is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

Portage is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with Portage; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

More information

  • DEVELOPING contains some code guidelines.
  • LICENSE contains the GNU General Public License version 2.
  • NEWS contains new features/major bug fixes for each version.
  • RELEASE NOTES contains mainly upgrade information for each version.
  • TEST-NOTES contains Portage unit test information.

Links