summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/depgraph.py
Commit message (Collapse)AuthorAgeFilesLines
...
* Migrate from codecs.open() to io.open().Zac Medico2011-07-101-3/+2
| | | | | | | | | | | | | | | | | 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.
* depgraph: more debug output for _add_pkgZac Medico2011-07-101-15/+39
| | | | | This should make it easier to debug cases like bug 374423, among others.
* depgraph: reject USE conditionals in argumentsZac Medico2011-07-091-0/+8
|
* circular_dependency: show debug graph earlierZac Medico2011-07-091-2/+1
| | | | | This might help in some cases like bug 374397 where we're troubleshooting the circular_dependency code.
* depgraph: include pkg.repo in debug outputZac Medico2011-07-091-2/+3
|
* Qualify "missed update" message as WARNING.Zac Medico2011-07-081-2/+2
|
* Show repository in error message about missing USE flags.Arfrever Frehtes Taifersar Arahesis2011-07-031-1/+1
|
* extract_affecting_use: less strict for installedZac Medico2011-06-211-2/+6
|
* misspell-suggestions: filter the input cpZac Medico2011-06-171-1/+7
| | | | | Obviously, we don't want to consider the input cp as a possible suggestion, as reported in bug 372033.
* expand_set_args: add root SetArg nodes to graphZac Medico2011-06-161-0/+5
| | | | | This prevents get_dep_chain from triggering a KeyError some cases as reported in bug #371767.
* pkg_use_enabled: return early for built pkgsZac Medico2011-06-131-1/+3
| | | | | | | | Built/installed packages have frozen USE settings, so there's no sense in considering them for autounmask USE config changes. They'll simply be rejected by select_package, and an unbuilt ebuild will be selected instead. This will fix bug 371423 by avoiding unnecessary use_reduce calls on the deps of installed packages.
* test_merge_order: test smallest runtime cycleZac Medico2011-06-121-0/+6
| | | | | | | | | In the case of multiple runtime cycles, where some cycles may depend on smaller independent cycles, it's optimal to merge smaller independent cycles before other cycles that depend on them. Therefore, we search for the smallest cycle in order to try and identify and prefer these smaller independent cycles.
* Fix a typo in a comment.v2.2.0_alpha40Arfrever Frehtes Taifersar Arahesis2011-06-111-1/+1
|
* serialize_tasks: debug output for runtime cyclesZac Medico2011-06-111-1/+12
|
* serialize_tasks: asap ignore medium_soft earlierZac Medico2011-06-111-5/+11
| | | | | | This allows us to avoid the less efficient runtime cycle pathway for cases in which an asap node is a leaf if medium_soft deps are ignored. Ths should increase efficiency without changing behavior.
* serialize_tasks: minimize runtime cycles moreZac Medico2011-06-111-3/+6
|
* serialize_tasks: minimize nodes in runtime cyclesZac Medico2011-06-101-30/+30
| | | | | | | When gathering the nodes belonging to a runtime cycle, we want to minimize the number of nodes gathered, since this tends to produce a more optimal merge order. Ignoring all medium_soft deps serves this purpose.
* depgraph._serialize_tasks: revert formatting diffZac Medico2011-06-101-6/+5
|
* depgraph._serialize_tasks: move libperl/perl codeZac Medico2011-06-101-14/+17
| | | | | This ensures that all asap_nodes are explored before setting prefer_asap to False.
* depgraph._serialize_tasks: tweak last commit moreZac Medico2011-06-101-3/+3
|
* depgraph._serialize_tasks: tweak last commitZac Medico2011-06-101-7/+9
| | | | This code is only intended when more than one node is selected.
* show_unsatisfied_blockers: don't omit any pkgsZac Medico2011-06-101-17/+10
| | | | | It can be essential to see all the packages here, so don't omit any. If the list is long, people can simply use a pager.
* depgraph._serialize_tasks: fix libperl/perl orderZac Medico2011-06-101-5/+17
| | | | | | In some cases, the asap_nodes code caused selection of a large runtime cycle that was obviously sub-optimal. Now such cases are detected and avoided.
* show_masked_packages: EAPI metadata safetyZac Medico2011-06-091-0/+3
| | | | | When masked by EAPI, metadata is mostly useless since it doesn't contain essential things like SLOT.
* _show_unsatisfied_dep: fix logic for EAPI maskZac Medico2011-06-091-6/+9
| | | | This will fix bug #370465.
* autounmask-write: prefer package.accept_keywordsZac Medico2011-06-081-2/+2
|
* extract_affecting_use: _get_useflag_re(eapi)Zac Medico2011-06-081-2/+4
| | | | | This is needed for EAPI="4-python" added in commit 586760f37fb9784327d8447182d49810662f4427.
* autounmask-write: support package.accept_keywordsZac Medico2011-06-081-1/+6
|
* Fix some typos.Arfrever Frehtes Taifersar Arahesis2011-06-061-1/+1
|
* autounmask: include comments from package.maskZac Medico2011-06-031-0/+13
| | | | This will fix bug #369985.
* --autounmask: show note suggesting how to disableZac Medico2011-06-031-0/+16
| | | | | | | | | | | Now that --autounmask is enabled by default, people are dealing with local masks that trigger unsatisfied dependencies often complain about --autounmask behavior being inappropriate for their situation. Therefore, show a helpful note when the autounmask code is triggered and --quiet is not enabled: NOTE: This --autounmask behavior can be disabled by setting EMERGE_DEFAULT_OPTS="--autounmask=n" in make.conf.
* autounmask-write: force configpro if non-existentZac Medico2011-06-021-1/+6
| | | | | | We want to force new_protect_filename to ensure that the user will see all our changes via etc-update, even if file_to_write_to doesn't exist yet.
* add_pkg_dep_string: fix reversed inst_pkgs orderZac Medico2011-06-021-3/+6
| | | | | | This code was intended to iterate over packages in descending order, but match_pkgs() returns them in ascending order, so we need to reverse it.
* add_pkg_dep_string: remove unused root_slot varZac Medico2011-06-021-1/+0
|
* Use bool(digraph) instead of empty()/is_empty().Zac Medico2011-06-021-4/+4
|
* dep_zapdeps: use digraph for preference selectionZac Medico2011-05-301-0/+3
| | | | | | | | | | This is required in order for dep_zapdeps to work as intended for solving cases of bug #264434 in which there is an installed package that may need to be uninstalled in order to resolve blockers. It fixes a failure to resolve blockers when attempting to replace media-video/ffmpeg with media-video/libav (symptom is similar to bug #339164, but with new-style virtual instead of old-style PROVIDE virtual).
* backtrack_depgraph: display_problems for each runZac Medico2011-05-271-2/+13
|
* autounmask_broke_use_dep: flag masked pkgs tooZac Medico2011-05-261-2/+2
|
* depgraph: always check for autounmask breakageZac Medico2011-05-251-9/+10
| | | | | The 2.1.9 branch already does the same thing since commit 65736474c0d70cb10ff1290b3787b61d8a502aed.
* rebuilt-binaries: prefer newer unbuiltZac Medico2011-05-251-1/+7
|
* Fix a typo in last commit's debug message.Zac Medico2011-05-241-1/+1
|
* depgraph: detect deps broken by autounmaskZac Medico2011-05-241-1/+37
| | | | This will fix bug #368429.
* test_merge_order: test asap PDEPEND (bug #180045)Zac Medico2011-05-241-0/+1
|
* _serialize_tasks: prefer unsatisfied asap childZac Medico2011-05-221-6/+22
| | | | | Optimally, satisfied deps are always merged after the asap nodes that depend on them.
* _add_pkg_dep_string: handle satisfied virt_depZac Medico2011-05-221-0/+14
| | | | | This fixes a problem with the asap LIBC_PACKAGE_ATOM test case for bug #303567.
* _validate_blockers: reference bug 128809Zac Medico2011-05-221-4/+7
|
* Package: add new _gen_hash_key methodZac Medico2011-05-221-16/+6
|
* DepPriority: remove "rebuild" attributeZac Medico2011-05-211-12/+0
| | | | | | | | | | | | | | | | Since the addition of DepPriorityNormalRange and DepPrioritySatisfiedRange in commit bd369956b2a2fbc019a655a372628998499156c0, which solves most cases of bug 199856, the Depriority.rebuild attribute doesn't appear to make any difference. The edges that this attribute differentiates are already naturally differentiated by the fact that the child node of a satisfied buildtime dependency that's not being rebuilt will naturally be identified as a leaf node earlier and removed from the graph, thereby eliminating the edge before there's an opportunity to compare it with a higher priority rebuild edge. The addition of the "optional" attribute (in commit 15476805a156acd11fdaaa19212691e8ee09b309) also plays a role here, since it converts some satisfied buildtime edges to optional edges, thereby reducing their priority.
* test_merge_order: test hard blocker resolutionZac Medico2011-05-201-2/+1
|
* _pkg_visibility_check: if in graph then visibleZac Medico2011-05-171-0/+9
|