Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 907896 - app-eselect/eselect-ruby-20221225 calls portageq directly (seen with dev-lang/ruby-3.2.2-r2)
Summary: app-eselect/eselect-ruby-20221225 calls portageq directly (seen with dev-lang...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords: PATCH
: 907897 (view as bug list)
Depends on:
Blocks: 906129
  Show dependency tree
 
Reported: 2023-06-05 13:18 UTC by Agostino Sarubbo
Modified: 2023-06-16 07:52 UTC (History)
2 users (show)

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


Attachments
build.log (build.log,411.13 KB, text/plain)
2023-06-05 13:18 UTC, Agostino Sarubbo
Details
ruby.eselect: Call envvar from eselect's package manager lib instead of portageq (ruby.eselect.diff,634 bytes, patch)
2023-06-06 19:41 UTC, Ulrich Müller
Details | Diff
ruby.eselect: Call create_man_links unconditionally (0001-ruby.eselect-Call-create_man_links-unconditionally.patch,1.18 KB, patch)
2023-06-08 07:19 UTC, Ulrich Müller
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2023-06-05 13:18:28 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-lang/ruby-3.2.2-r2 uses portageq in ebuild scope.
Discovered on: amd64 (internal ref: ci)
Comment 1 Agostino Sarubbo gentoo-dev 2023-06-05 13:18:30 UTC
Created attachment 863331 [details]
build.log

build log and emerge --info
Comment 2 Ulrich Müller gentoo-dev 2023-06-05 16:14:40 UTC
portageq is called indirectly via ruby.eselect:

    [[ $(portageq envvar FEATURES) =~ noman ]] || create_man_links ${version}

The module should do something like this instead, using eselect's envvar function:

    inherit package-manager
    ...
    [[ $(envvar dev-lang/ruby FEATURES) =~ noman ]] || ...
Comment 3 Ulrich Müller gentoo-dev 2023-06-06 19:38:12 UTC
*** Bug 907897 has been marked as a duplicate of this bug. ***
Comment 4 Ulrich Müller gentoo-dev 2023-06-06 19:41:43 UTC
Created attachment 863426 [details, diff]
ruby.eselect: Call envvar from eselect's package manager lib instead of portageq

Attached patch should fix it. I have tested it without and with "noman" in FEATURES, and it seems to work as intended (i.e. creating or not creating the ruby.1 redirect page).

Signed-off-by: Ulrich Müller <ulm@gentoo.org>
Comment 5 Ulrich Müller gentoo-dev 2023-06-08 07:19:42 UTC
Created attachment 863530 [details, diff]
ruby.eselect: Call create_man_links unconditionally

Thinking about it, checking FEATURES=noman isn't even necessary, because create_man_links() will do nothing when the target man page doesn't exist. The empty loop will still be much faster than calling portageq.

Updated patch attached (this time, properly formatted for proj/ruby-scripts.git).
Comment 6 Larry the Git Cow gentoo-dev 2023-06-16 07:52:43 UTC
The bug has been closed via the following commit(s):

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

commit bbe1d7659a532854096624d4e2a529f47db5c7b9
Author:     Hans de Graaff <graaff@gentoo.org>
AuthorDate: 2023-06-16 07:52:06 +0000
Commit:     Hans de Graaff <graaff@gentoo.org>
CommitDate: 2023-06-16 07:52:15 +0000

    app-eselect/eselect-ruby: add 20230616
    
    Fixes: https://bugs.gentoo.org/908052
    Fixes: https://bugs.gentoo.org/907896
    Signed-off-by: Hans de Graaff <graaff@gentoo.org>

 app-eselect/eselect-ruby/Manifest                  |  1 +
 .../eselect-ruby/eselect-ruby-20230616.ebuild      | 22 ++++++++++++++++++++++
 2 files changed, 23 insertions(+)