Ticket #1265 (new ebuild-defect)

Opened 5 years ago

Last modified 5 years ago

False positives in PALUDIS_MUST_NOT_CHANGE_VARIABLES checks with SLOT (ebuild)

Reported by: loki42 Owned by:
Priority: MinorRelease Milestone:
Component: clients/cave Version: 0.82.0
Keywords: Cc:
Blocked By: Blocking:
Distribution: Gentoo

Description

Paludis complains about illegal changes of the "SLOT" from all ebuilds. The SLOT is set correctly. This results in a wrong entry in the dpk db. All ebuilds get installed as SLOT 0 resulting in self-blocking or re-installing for SLOT dependencies.

I see no reason, why an ebuild should not set his own slot.

Change History

comment:1 follow-up: ↓ 2 Changed 5 years ago by ciaranm

We (try to) enforce PMS rules for SLOT. What do you think is being blocked that shouldn't be?

comment:2 in reply to: ↑ 1 Changed 5 years ago by loki42

Replying to ciaranm:

We (try to) enforce PMS rules for SLOT. What do you think is being blocked that shouldn't be?

If an ebuild, like qt-core sets the own slot to 4, there is no reason to enforce a slot of null with eclass 4.

EAPI=4

inherit qt4-build

DESCRIPTION="The Qt toolkit is a comprehensive C++ application development framework"
SLOT="4"

Results in a QA warning that the ebuild modifed SLOT and a SLOT of 0 after installation. Every ebuild, needing qt-core:4 will pull qt-core again into the tree on installation. Some packages blocks against own installations in lower slots.

comment:3 follow-up: ↓ 4 Changed 5 years ago by ciaranm

No, there's something more to this than what you're describing. You get the message you're seeing when the value that's in the cache and the value the ebuild ends up setting are different. What is the cached value, what exactly are you doing that triggers the message, and what exactly is the message you are seeing?

comment:4 in reply to: ↑ 3 Changed 5 years ago by loki42

Replying to ciaranm:

No, there's something more to this than what you're describing. You get the message you're seeing when the value that's in the cache and the value the ebuild ends up setting are different. What is the cached value, what exactly are you doing that triggers the message, and what exactly is the message you are seeing?

~ # cat /var/db/pkg/x11-libs/qt-core-4.8.4/SLOT 
0
~ # cave resolve -zx1 qt-core
These are the actions I will take, in order:

r   x11-libs/qt-core:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    (-aqua) -c++0x -debug exceptions glib iconv icu -pch qt3support ssl build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: target, !<x11-libs/qt-core-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-core-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, 32 more
    In dependency cycle with: x11-libs/qt-assistant:4, x11-libs/qt-core:4, x11-libs/qt-dbus:4, x11-libs/qt-declarative:4, x11-libs/qt-gui:4, x11-libs/qt-opengl:4, x11-libs/qt-qt3support:4, x11-libs/qt-script:4, x11-libs/qt-sql:4, x11-libs/qt-svg:4, x11-libs/qt-webkit:4, x11-libs/qt-xmlpatterns:4; Self dependent (already met)
r   x11-libs/qt-dbus:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    (-aqua) -c++0x -debug exceptions -pch build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-dbus-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-dbus-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-dbus-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 22 more
r   x11-libs/qt-gui:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    accessibility (-aqua) -c++0x cups dbus -debug -egl exceptions gif glib -gtkstyle mng -nas -nis -pch qt3support tiff -trace xinerama xv build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-gui-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-gui-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-gui-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 28 more
r   x11-libs/qt-opengl:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    (-aqua) -c++0x -debug -egl exceptions -pch qt3support build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-opengl-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-opengl-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-opengl-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 22 more
r   x11-libs/qt-qt3support:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    accessibility (-aqua) -c++0x -debug exceptions -pch build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-qt3support-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-qt3support-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-qt3support-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 23 more
r   x11-libs/qt-script:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    (-aqua) -c++0x -debug exceptions iconv (-jit) -pch build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-script-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-script-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-script-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 23 more
r   x11-libs/qt-sql:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    (-aqua) -c++0x -debug exceptions -firebird -freetds mysql -oci8 -odbc -pch postgres qt3support sqlite build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-sql-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-sql-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-sql-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 24 more
r   x11-libs/qt-svg:4::gentoo 4.8.4 to ::installed replacing 4.8.4 [cycle 1]
    accessibility (-aqua) -c++0x -debug exceptions -pch build_options: symbols=split -optional_tests -trace work=tidyup
    Reasons: !<x11-libs/qt-svg-4.8.4:4 from x11-libs/qt-assistant-4.8.4:4::gentoo, !<x11-libs/qt-svg-4.8.4:4 from x11-libs/qt-core-4.8.4:4::gentoo, !<x11-libs/qt-svg-4.8.4:4 from x11-libs/qt-dbus-4.8.4:4::gentoo, 22 more
....

cave wants to re-install every single qt package, because the SLOT in the cache is 0.

>>> Running ebuild phases init saveenv as paludisbuild:paludisbuild...
>>> Starting builtin_init
cave@1356178020: [QA e.child.message] In thread ID '21131':
  ... In ebuild pipe command handler for 'x11-libs/qt-core-4.8.4:4::gentoo':
  ... Ebuild /usr/portage/x11-libs/qt-core/qt-core-4.8.4.ebuild illegally tried to change SLOT from '0' to '4'

And here is the qa warning. If i upgrade or install a new package, i have the same effect. I have already posted he relevant part of the ebuild.

Last edited 5 years ago by loki42 (previous) (diff)

comment:5 follow-up: ↓ 6 Changed 5 years ago by ciaranm

I'm asking about metadata cache, not VDB. Why does the metadata cache contain 0?

comment:6 in reply to: ↑ 5 Changed 5 years ago by loki42

Replying to ciaranm:

I'm asking about metadata cache, not VDB. Why does the metadata cache contain 0?

Sry, my fault, the metadata cache does NOT contain 0. I should read more carefully.

DEFINED_PHASES=compile configure install postinst postrm prepare setup test unpack                                                                                        
DEPEND=sys-libs/zlib glib? ( dev-libs/glib:2 ) icu? ( >=dev-libs/icu-49 ) ssl? ( dev-libs/openssl ) !<x11-libs/cairo-1.10.2-r2 !x11-libs/qt:4 virtual/pkgconfig           
DESCRIPTION=The Qt toolkit is a comprehensive C++ application development framework                                                                                       
EAPI=4                                                                                                                                                                    
HOMEPAGE=http://qt-project.org/ http://qt.digia.com/                                                                                                                      
IUSE=+glib iconv icu qt3support ssl aqua debug pch +exceptions c++0x                                                                                                      
KEYWORDS=~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~x64-sol
aris ~x86-solaris                                                                                                                                                         
LICENSE=|| ( LGPL-2.1 GPL-3 )                                                                                                                                             
PDEPEND=qt3support? ( ~x11-libs/qt-gui-4.8.4[aqua=,debug=,glib=,qt3support] )                                                                                             
RDEPEND=sys-libs/zlib glib? ( dev-libs/glib:2 ) icu? ( >=dev-libs/icu-49 ) ssl? ( dev-libs/openssl ) !<x11-libs/cairo-1.10.2-r2 !x11-libs/qt:4 !<x11-libs/qt-assistant-4.8
.4:4 !>x11-libs/qt-assistant-4.8.4-r9999:4 !<x11-libs/qt-bearer-4.8.4:4 !>x11-libs/qt-bearer-4.8.4-r9999:4 !<x11-libs/qt-core-4.8.4:4 !>x11-libs/qt-core-4.8.4-r9999:4 !<x
11-libs/qt-dbus-4.8.4:4 !>x11-libs/qt-dbus-4.8.4-r9999:4 !<x11-libs/qt-declarative-4.8.4:4 !>x11-libs/qt-declarative-4.8.4-r9999:4 !<x11-libs/qt-demo-4.8.4:4 !>x11-libs/q
t-demo-4.8.4-r9999:4 !<x11-libs/qt-gui-4.8.4:4 !>x11-libs/qt-gui-4.8.4-r9999:4 !<x11-libs/qt-multimedia-4.8.4:4 !>x11-libs/qt-multimedia-4.8.4-r9999:4 !<x11-libs/qt-openg
l-4.8.4:4 !>x11-libs/qt-opengl-4.8.4-r9999:4 !<x11-libs/qt-openvg-4.8.4:4 !>x11-libs/qt-openvg-4.8.4-r9999:4 !<x11-libs/qt-phonon-4.8.4:4 !>x11-libs/qt-phonon-4.8.4-r9999
:4 !<x11-libs/qt-qt3support-4.8.4:4 !>x11-libs/qt-qt3support-4.8.4-r9999:4 !<x11-libs/qt-script-4.8.4:4 !>x11-libs/qt-script-4.8.4-r9999:4 !<x11-libs/qt-sql-4.8.4:4 !>x11
-libs/qt-sql-4.8.4-r9999:4 !<x11-libs/qt-svg-4.8.4:4 !>x11-libs/qt-svg-4.8.4-r9999:4 !<x11-libs/qt-test-4.8.4:4 !>x11-libs/qt-test-4.8.4-r9999:4 !<x11-libs/qt-webkit-4.8.
4:4 !>x11-libs/qt-webkit-4.8.4-r9999:4 !<x11-libs/qt-xmlpatterns-4.8.4:4 !>x11-libs/qt-xmlpatterns-4.8.4-r9999:4                                                          
SLOT=4                                                                                                                                                                    
SRC_URI=http://releases.qt-project.org/qt4/source/qt-everywhere-opensource-src-4.8.4.tar.gz                                                                               
_eclasses_=eutils       d40dc948067bd3db1c8ebf7d51897313        flag-o-matic    61ad55e732e494378165e7dcd4744b91        multilib        9aa8a023e062fca0ba79362d9d0cc488 q
t4-build        a99fc3fe09eb9d8b699de07d06765ec3        toolchain-funcs 134429b842a6c67254bfd76a8753e4d4        user    d0a4d0735a6c0183d707ca919bd72f28        versionato
r       6601b4c5b3f019a993db59a50e1854e4                                                                                                                                  
_md5_=792f36c7b2f2b9d83f7ec239b6181a18

comment:7 Changed 5 years ago by ciaranm

Hrmmmmmm. That "0" is coming from somewhere... cave -Ld show qt-core::gentoo[=8.4.4] 2>&1 | grep -A10 cache ?

comment:8 Changed 5 years ago by loki42

Found it. Very strange: I have nearly the some env from dev-java/jdbc-postgresql found in /etc/profile.env

export CHOST='x86_64-pc-linux-gnu'
export DESCRIPTION='JDBC Driver for PostgreSQL'
export GENERATION='2'
export SLOT='0'
export CATEGORY='dev-java'
export PVR='9.1_p902'
export CLASSPATH='/usr/share/jdbc-postgresql/lib/jdbc-postgresql.jar'
export VM='>=virtual/jre-1.6'
export TARGET='1.6'
export SOURCE='1.6'
export MERGE_VM='icedtea-bin-6'
export MERGE_COMPILER='javac'

Located this via the trace flag. Thanks for that feature.

I could not imagine how this happens, but i will track it down, and open a new bug in the correct tracker, maybe an issue with env-update or other emerge foo.

Note: See TracTickets for help on using tickets.