Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 457182 - Proper dependencies for Qt5 autotests (USE=test)
Summary: Proper dependencies for Qt5 autotests (USE=test)
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Low normal (vote)
Assignee: Qt Bug Alias
URL:
Whiteboard:
Keywords: PullRequest
: 430516 431326 431328 431330 431334 431342 (view as bug list)
Depends on:
Blocks: 473976 473978 473986 473988 473992 474002
  Show dependency tree
 
Reported: 2013-02-14 00:33 UTC by Davide Pesavento
Modified: 2024-02-16 12:03 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
graph.png (output.png,397.15 KB, image/png)
2014-12-18 09:01 UTC, Michael Palimaka (kensington)
Details
graphv2.png (output.png,448.50 KB, image/png)
2014-12-18 14:37 UTC, Michael Palimaka (kensington)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Davide Pesavento gentoo-dev 2013-02-14 00:33:27 UTC
Many deps are currently missing.
Comment 1 Davide Pesavento gentoo-dev 2013-02-14 00:38:01 UTC
*** Bug 431334 has been marked as a duplicate of this bug. ***
Comment 2 Davide Pesavento gentoo-dev 2013-02-14 00:38:19 UTC
*** Bug 431326 has been marked as a duplicate of this bug. ***
Comment 3 Davide Pesavento gentoo-dev 2013-02-14 00:38:35 UTC
*** Bug 431330 has been marked as a duplicate of this bug. ***
Comment 4 Davide Pesavento gentoo-dev 2013-02-14 00:38:57 UTC
*** Bug 431328 has been marked as a duplicate of this bug. ***
Comment 5 Davide Pesavento gentoo-dev 2013-02-14 00:40:11 UTC
*** Bug 431342 has been marked as a duplicate of this bug. ***
Comment 6 Davide Pesavento gentoo-dev 2013-02-14 00:42:17 UTC
*** Bug 430516 has been marked as a duplicate of this bug. ***
Comment 7 Michael Palimaka (kensington) gentoo-dev 2013-03-11 11:48:37 UTC
Do you think checking, say tests/auto/corelib (qtcore?), for qt module includes is a good start, or is something more advanced (eg. autodep checking filesystem hits) required?
Comment 8 Davide Pesavento gentoo-dev 2013-06-23 01:07:49 UTC
I'm still not sure how to properly handle the cyclic dependencies. Current ideas are:

1) Disable all tests that require modules that can create a cycle in the depgraph. This means for example disabling all qtcore tests.

2) List every dependency required for running the full test suite, even if they create cycles. This means that, in order to run the tests of some qt5 modules, one will need to first emerge that package with USE=-test, and then again with USE=test.

3) Check in src_test() if the cycle-inducing deps are installed, and if they are not, skip the tests that require them. Sort of automagic deps for tests.

Obviously option #1 and #3 require more work for the maintainer.

What do you guys think?
Comment 9 Michael Palimaka (kensington) gentoo-dev 2014-05-14 17:19:46 UTC
I don't think there is a good solution.

Creating accurate lists of test -> dependency mappings may prove difficult, not to mention the maintenance required.
Option #2 doesn't really give a good experience, nor is disabling tests a good solution.

Another idea I was given is to check for the required dependencies in src_test and toggle tests dynamically. We could then print some message if the user has tests enabled but the dependency is missing.
Comment 10 Michael Palimaka (kensington) gentoo-dev 2014-05-14 18:39:23 UTC
Another suggestion from axs was that for qtcore[test] we could build qttest again and use that.

I will check how many other cyclic dependencies there are.
Comment 11 Michael Palimaka (kensington) gentoo-dev 2014-12-18 09:01:00 UTC
Created attachment 391906 [details]
graph.png

First attempt at mapping test dependencies.
Comment 12 Davide Pesavento gentoo-dev 2014-12-18 13:10:51 UTC
(In reply to Michael Palimaka (kensington) from comment #11)
> Created attachment 391906 [details]
> graph.png
> 
> First attempt at mapping test dependencies.

Cool! It's quite messy and not all edges are distinguishable unfortunately. Maybe you can suppress transitive deps (i.e. do not draw the edge A->B if the graph already has A->C and C->B). Deps on qttest can also be omitted.

Did you consider optional deps too?
Comment 13 Michael Palimaka (kensington) gentoo-dev 2014-12-18 14:37:49 UTC
Created attachment 391924 [details]
graphv2.png

v2, with deps on qttest removed and edges coloured for clarity.

I haven't considered optional or transitive deps yet.
Comment 14 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2018-03-02 18:57:11 UTC
Can't you just add the necessary dependencies and accepted the circular? It's suboptimal but:

a. it is certainly better than having no tests for 5 years,

b. people are used to dealing with circular test-deps, and this can be solved reasonably easily (merge all without tests, then retry with tests),

c. silently skipping tests is horrible for arch testing (the whole purpose of tests is for me *not* to have to read through detailed logs to see if tests were run).
Comment 15 Larry the Git Cow gentoo-dev 2023-09-05 13:05:42 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2d5ab5b4b68554877a566db555c5b8cd471100b8

commit 2d5ab5b4b68554877a566db555c5b8cd471100b8
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2023-08-19 15:28:22 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2023-09-05 13:01:00 +0000

    qt6-build.eclass: support+unrestrict tests, export src_test+install
    
    Qt5's may be a lost cause at this point wrt bug #457182, but can
    do this fairly easily for Qt6 going forward (or at least for most
    components, qtbase, qttools, and qtdeclarative are messier).
    
    About src_install, it was defined but not exported. Not an issue
    before but now we need it for cleanups.
    
    Bug: https://bugs.gentoo.org/457182
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 eclass/qt6-build.eclass | 58 ++++++++++++++++++++++++++++++++++++++++---------
 1 file changed, 48 insertions(+), 10 deletions(-)