Bug 1003691 - firefox pretrans scriptlet issues
firefox pretrans scriptlet issues
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: firefox (Show other bugs)
20
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Jan Horak
Fedora Extras Quality Assurance
AcceptedBlocker
:
: 1003230 1003587 1004766 (view as bug list)
Depends On:
Blocks: F20AlphaBlocker
  Show dependency treegraph
 
Reported: 2013-09-02 14:36 EDT by Kevin Fenzi
Modified: 2013-09-07 15:53 EDT (History)
12 users (show)

See Also:
Fixed In Version: firefox-23.0.1-4.fc19
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-09-06 01:23:20 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Kevin Fenzi 2013-09-02 14:36:34 EDT
In ec429e944715fe7a0471a68f225b35e267fe8d67 a pretrans scriptlet was added to firefox. 

+%pretrans
+# Moves defaults/preferences to browser/defaults/preferences in Fedora 19+
+%if 0%{?fedora} >= 19
+if [ -L %{mozappdir}/browser/defaults/preferences ]; then
+  rm %{mozappdir}/browser/defaults/preferences
+  mkdir -p %{mozappdir}/browser/defaults/preferences
+  if [ -d %{mozappdir}/defaults/preferences ]; then
+    mv %{mozappdir}/defaults/preferences/* %{mozappdir}/browser/defaults/preferences
+    rm -f %{mozappdir}/defaults/preferences/*
+    echo "Content of this directory has been moved to %{mozappdir}/browser/defaults/preferences." >
+  fi
+fi
+%endif

This causes any composes that use firefox to fail, because rpm can't be sure and have bash before the transaction since it's a new install. 

See: 
https://fedoraproject.org/wiki/Packaging:Guidelines?rd=Packaging/Guidelines#The_.25pretrans_scriptlet

So, at the very least you need to re-write this in lua so it can use the rpm copy of lua. Bash will never work here on new/fresh installs.
Comment 1 Elad Alfassa 2013-09-02 14:38:42 EDT
I would suggest moving it to firefox.sh, seems more reasonable
Comment 2 Martin Stransky 2013-09-03 01:28:47 EDT
Hm, looks more complicated than we expected.
Comment 3 Martin Stransky 2013-09-03 01:31:52 EDT
IMHO We can also run it from some other rpm script where the bash can be used, like %post or so.
Comment 4 Martin Stransky 2013-09-03 01:33:37 EDT
https://fedoraproject.org/wiki/Packaging:Guidelines?rd=Packaging/Guidelines#Scriptlets seems to provide useful guide.
Comment 5 Tim Flink 2013-09-03 10:40:08 EDT
*** Bug 1003230 has been marked as a duplicate of this bug. ***
Comment 6 Tim Flink 2013-09-03 10:50:07 EDT
Can we get this fixed soon? It's causing a lot of problems with f20 alpha as you can't really do an installation without de-selecting firefox
Comment 7 Tim Flink 2013-09-03 10:52:42 EDT
This was already proposed as a F20 alpha blocker, but it does violate the following F20 alpha release criterion [1]:

There must be no errors in any package on the release-blocking images which cause the package to fail to install.

[1] http://fedoraproject.org/wiki/Fedora_20_Alpha_Release_Criteria#No_broken_packages

It does break the installation process but this criterion is more accurate since it's a broken package issue
Comment 8 Jan Horak 2013-09-03 11:37:54 EDT
This is actually fix for bug 976420. It can't be fixed in firefox.sh nor %post section because symlink must be removed before installation. Otherwise it fails. I will have to rewrite it to lua then.
Comment 9 Tim Flink 2013-09-03 11:51:36 EDT
(In reply to Jan Horak from comment #8)
> This is actually fix for bug 976420. It can't be fixed in firefox.sh nor
> %post section because symlink must be removed before installation. Otherwise
> it fails. I will have to rewrite it to lua then.

Any idea when we can expect a rewritten script? I'd really like to get this taken care of for the next f20 alpha TC (in the next day or two).
Comment 10 Jan Horak 2013-09-03 12:24:05 EDT
Firefox-23.0.1-4 is fixing this issue. Builds should be finished in koji soon. You don't need update in bodhi for F20, do you?
Comment 11 Tim Flink 2013-09-03 13:29:19 EDT
(In reply to Jan Horak from comment #10)
> Firefox-23.0.1-4 is fixing this issue. Builds should be finished in koji
> soon. You don't need update in bodhi for F20, do you?

As long as the build is done before alpha freeze later today, I don't think an update is needed.
Comment 12 Tim Flink 2013-09-03 21:06:20 EDT
http://koji.fedoraproject.org/koji/buildinfo?buildID=461257 has been built as a fix for this bug and it will be included in F20 alpha TC3. Moving to ON_QA
Comment 13 Dan Mashal 2013-09-03 22:19:53 EDT
Thanks.
Comment 14 Dethlef Madsen 2013-09-04 12:29:13 EDT
*** Bug 1003587 has been marked as a duplicate of this bug. ***
Comment 15 Kamil Páral 2013-09-04 12:56:31 EDT
Discussed at 2013-09-04 blocker review meeting [1]. This is accepted as an Alpha blocker, because it violates the following F20 alpha release criterion for firefox, which is part of the default gnome install: "There must be no errors in any package on the release-blocking images which cause the package to fail to install." [2]

[1] http://meetbot.fedoraproject.org/fedora-blocker-review/2013-09-04/
[2] https://fedoraproject.org/wiki/Fedora_20_Alpha_Release_Criteria#No_broken_packages
Comment 16 Andrew McNabb 2013-09-04 18:47:32 EDT
I'm also seeing this error ("script error with package firefox") in a Fedora 19 netinstall. Is the fix going to be backported to Fedora 19 as well?
Comment 17 Chris Smart 2013-09-04 20:05:43 EDT
Thank you, this was breaking my livecd-creator builds with:

Error creating Live CD : Dependency check failed : (('firefox', '23.0.1', '3.fc19'), ('/bin/sh', ''), 0, 0, None)

Works fine when I pull in koji's firefox-23.0.1-4.

-c
Comment 18 Samuel Sieb 2013-09-05 01:31:09 EDT
Please submit an update for F19 as well. This breaks the installer when updates are enabled.
Comment 19 Fedora Update System 2013-09-05 05:11:45 EDT
firefox-23.0.1-4.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/firefox-23.0.1-4.fc18
Comment 20 Fedora Update System 2013-09-05 05:12:08 EDT
firefox-23.0.1-4.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/firefox-23.0.1-4.fc19
Comment 21 David Woodhouse 2013-09-05 08:41:55 EDT
*** Bug 1004766 has been marked as a duplicate of this bug. ***
Comment 22 Fedora Update System 2013-09-06 01:16:23 EDT
Package firefox-23.0.1-4.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing firefox-23.0.1-4.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-15912/firefox-23.0.1-4.fc18
then log in and leave karma (feedback).
Comment 23 Fedora Update System 2013-09-06 01:23:20 EDT
firefox-23.0.1-4.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

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