Bug 1720234 - dnf show executing of script .. but theres none in the package
Summary: dnf show executing of script .. but theres none in the package
Keywords:
Status: CLOSED DUPLICATE of bug 1724779
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 29
Hardware: x86_64
OS: Linux
medium
medium
Target Milestone: ---
Assignee: amatej
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-06-13 12:59 UTC by customercare
Modified: 2019-10-17 07:30 UTC (History)
11 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-10-17 07:30:00 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description customercare 2019-06-13 12:59:25 UTC
Description of problem:

Updating nodejs via dnf generates this ( german ) output :

# dnf update ... 
...
Pakete werden heruntergeladen:
(1/3): nodejs-10.16.0-3.fc29.x86_64.rpm         673 kB/s | 101 kB     00:00    
(2/3): npm-6.9.0-1.10.16.0.3.fc29.x86_64.rpm    4.6 MB/s | 3.8 MB     00:00    
(3/3): nodejs-libs-10.16.0-3.fc29.x86_64.rpm    6.5 MB/s | 8.7 MB     00:01    
-----------------------------------------------------------------------------------
Gesamt                                          8.5 MB/s |  13 MB     00:01     
Transaktionsüberprüfung wird ausgeführt
Transaktionsprüfung war erfolgreich.
Transaktion wird getestet
Transaktionstest war erfolgreich.
Transaktion wird ausgeführt
  Ausgeführtes Scriptlet: npm-1:6.9.0-1.10.16.0.3.fc29.x86_64 1/1 
  Vorbereitung läuft    :                                     1/1 
  Aktualisieren         : nodejs-libs-1:10.16.0-3.fc29.x86_64 1/6 
  Aktualisieren         : npm-1:6.9.0-1.10.16.0.3.fc29.x86_64 2/6 
  Aktualisieren         : nodejs-1:10.16.0-3.fc29.x86_64      3/6 
  Aufräumen             : nodejs-1:10.15.3-1.fc29.x86_64      4/6 
  Aufräumen             : npm-1:6.4.1-1.10.15.3.1.fc29.x86_64 5/6 
  Aufräumen             : nodejs-libs-1:10.15.3-1.fc29.x86_64 6/6 
  Ausgeführtes Scriptlet: nodejs-libs-1:10.15.3-1.fc29.x86_64 6/6 
  Überprüfung läuft     : nodejs-1:10.16.0-3.fc29.x86_64      1/6 
  Überprüfung läuft     : nodejs-1:10.15.3-1.fc29.x86_64      2/6 
  Überprüfung läuft     : nodejs-libs-1:10.16.0-3.fc29.x86_64 3/6 
  Überprüfung läuft     : nodejs-libs-1:10.15.3-1.fc29.x86_64 4/6 
  Überprüfung läuft     : npm-1:6.9.0-1.10.16.0.3.fc29.x86_64 5/6 
  Überprüfung läuft     : npm-1:6.4.1-1.10.15.3.1.fc29.x86_64 6/6 

Aktualisiert:
  nodejs-1:10.16.0-3.fc29.x86_64 nodejs-libs-1:10.16.0-3.fc29.x86_64 npm-1:6.9.0-1.10.16.0.3.fc29.x86_64                                                        

Fertig.


As you can see we have these lines there:

  Ausgeführtes Scriptlet: npm-1:6.9.0-1.10.16.0.3.fc29.x86_64 1/1 
  Ausgeführtes Scriptlet: nodejs-libs-1:10.15.3-1.fc29.x86_64 6/6 

There is only one small problem: nodejs-libs does not have a scriptlet !

[root ~]# rpm -q --scripts nodejs-libs
[root ~]# 

npm has one : 

[root ~]# rpm -q --scripts npm
pretrans scriptlet (using <lua>):
-- Remove all of the symlinks from the bundled npm node_modules directory
-- Drop this scriptlet when F29 is EOL
base_path = "/usr/lib/node_modules/npm/node_modules/"
d_st = posix.stat(base_path)
if d_st then
  for f in posix.files(base_path) do
    path = base_path..f
    st = posix.stat(path)
    if st and st.type == "link" then
      os.remove(path)
    end
  end
end


In case i used rpm in the wrong way, sorry to interrupt.

I hope you can clarify this, as we have a nodejs problem, and need to know for sure if a script does something to the system we can't see. I suggest to add the nodejs maintainer sgallagh to this br.


Version-Release number of selected component (if applicable):

dnf-4.2.5-1


Actual results:

A none existing script gets executed

Expected results:

no execution of something not existing

Additional info:

Comment 1 Panu Matilainen 2019-06-13 13:28:41 UTC
With just rpm (with extra debug output added):
---
[root@sopuli rpm]# ./rpm -Uvh /tmp/n*10.16*.rpm
Verifying...                          ################################# [100%]
runScript: running scriptlet 1151 on npm-1:6.9.0-1.10.16.0.3.fc30.x86_64
Preparing...                          ################################# [100%]
Updating / installing...
   1:nodejs-libs-1:10.16.0-3.fc30     ################################# [ 17%]
   2:npm-1:6.9.0-1.10.16.0.3.fc30     ################################# [ 33%]
   3:nodejs-1:10.16.0-3.fc30          ################################# [ 50%]
Cleaning up / removing...
   4:nodejs-1:10.15.3-1.fc30          ################################# [ 67%]
   5:npm-1:6.4.1-1.10.15.3.1.fc30     ################################# [ 83%]
   6:nodejs-libs-1:10.15.3-1.fc30     ################################# [100%]
runScript: running scriptlet 1100 on glibc-common-2.29-15.fc30.x86_64
runScript: running scriptlet 1100 on man-db-2.8.4-4.fc30.x86_64
runScript: running scriptlet 1102 on glibc-common-2.29-15.fc30.x86_64
runScript: running scriptlet 1102 on man-db-2.8.4-4.fc30.x86_64
[root@sopuli rpm]#
---

With dnf:
---
[...]
Running transaction
  Running scriptlet: npm-1:6.9.0-1.10.16.0.3.fc30.x86_64                    1/1 
  Preparing        :                                                        1/1 
  Upgrading        : nodejs-libs-1:10.16.0-3.fc30.x86_64                    1/6 
  Upgrading        : npm-1:6.9.0-1.10.16.0.3.fc30.x86_64                    2/6 
  Upgrading        : nodejs-1:10.16.0-3.fc30.x86_64                         3/6 
  Cleanup          : nodejs-1:10.15.3-1.fc30.x86_64                         4/6 
  Cleanup          : npm-1:6.4.1-1.10.15.3.1.fc30.x86_64                    5/6 
  Cleanup          : nodejs-libs-1:10.15.3-1.fc30.x86_64                    6/6 
  Running scriptlet: nodejs-libs-1:10.15.3-1.fc30.x86_64                    6/6 
  Verifying        : nodejs-1:10.16.0-3.fc30.x86_64                         1/6 
  Verifying        : nodejs-1:10.15.3-1.fc30.x86_64                         2/6 
  Verifying        : nodejs-libs-1:10.16.0-3.fc30.x86_64                    3/6 
  Verifying        : nodejs-libs-1:10.15.3-1.fc30.x86_64                    4/6 
  Verifying        : npm-1:6.9.0-1.10.16.0.3.fc30.x86_64                    5/6 
  Verifying        : npm-1:6.4.1-1.10.15.3.1.fc30.x86_64                    6/6 

Upgraded:
---

So there are actually multiple scriptlets (file triggers) running from other packages, but for some reason dnf only shows one and accounts it to nodejs-libs. Based on that I'd assume it's indeed a dnf bug (and not rpm)

Comment 2 amatej 2019-10-17 07:30:00 UTC

*** This bug has been marked as a duplicate of bug 1724779 ***


Note You need to log in before you can comment on or make changes to this bug.