GNU bug report logs -
#31458
[PATCH] union: Do not warn about harmless collissions.
Previous Next
Reported by: Ludovic Courtès <ludo <at> gnu.org>
Date: Tue, 15 May 2018 08:33:01 UTC
Severity: normal
Tags: patch
Done: ludo <at> gnu.org (Ludovic Courtès)
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 31458 in the body.
You can then email your comments to 31458 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#31458
; Package
guix-patches
.
(Tue, 15 May 2018 08:33:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Ludovic Courtès <ludo <at> gnu.org>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Tue, 15 May 2018 08:33:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Until now we'd get pointless messages like:
warning: collision encountered:
/gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
/gnu/store/…-inkscape-0.92.3/share/icons/hicolor/icon-theme.cache
warning: choosing /gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
* guix/build/union.scm (%harmless-collisions): New variable.
(warn-about-collision): Honor it.
---
guix/build/union.scm | 17 +++++++++++++----
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/guix/build/union.scm b/guix/build/union.scm
index 24b366af4..fff795c4d 100644
--- a/guix/build/union.scm
+++ b/guix/build/union.scm
@@ -81,14 +81,23 @@ identical, #f otherwise."
(or (eof-object? n1)
(loop))))))))))))))
+(define %harmless-collisions
+ ;; This is a list of files that are known to collide, but for which emitting
+ ;; a warning doesn't make sense. For example, "icon-theme.cache" is
+ ;; regenerated by a profile hook which shadows the file provided by
+ ;; individual packages, and "gschemas.compiled" is made available to
+ ;; applications via 'glib-or-gtk-build-system'.
+ '("icon-theme.cache" "gschemas.compiled"))
+
(define (warn-about-collision files)
"Handle the collision among FILES by emitting a warning and choosing the
first one of THEM."
- (format (current-error-port)
- "~%warning: collision encountered:~%~{ ~a~%~}"
- files)
(let ((file (first files)))
- (format (current-error-port) "warning: choosing ~a~%" file)
+ (unless (member (basename file) %harmless-collisions)
+ (format (current-error-port)
+ "~%warning: collision encountered:~%~{ ~a~%~}"
+ files)
+ (format (current-error-port) "warning: choosing ~a~%" file))
file))
(define* (union-build output inputs
--
2.17.0
Information forwarded
to
guix-patches <at> gnu.org
:
bug#31458
; Package
guix-patches
.
(Tue, 15 May 2018 12:30:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 31458 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi Ludo,
On Tue, 15 May 2018 10:31:19 +0200
Ludovic Courtès <ludo <at> gnu.org> wrote:
> Until now we'd get pointless messages like:
>
> warning: collision encountered:
> /gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
> /gnu/store/…-inkscape-0.92.3/share/icons/hicolor/icon-theme.cache
> warning: choosing /gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
Hmm, I guess the icon-theme.cache one is harmless enough - however, there shouldn't
be many of those left anyway. Is there an easy way to check the store of hydra or something
which packages still have those files?
I've fixed inkscape now.
> +(define %harmless-collisions
> + ;; This is a list of files that are known to collide, but for which emitting
> + ;; a warning doesn't make sense. For example, "icon-theme.cache" is
> + ;; regenerated by a profile hook which shadows the file provided by
> + ;; individual packages, and "gschemas.compiled" is made available to
> + ;; applications via 'glib-or-gtk-build-system'.
> + '("icon-theme.cache" "gschemas.compiled"))
However, about gschemas.compiled I'm not sure yet.
How do we ensure that glib-or-gtk-build-system is actually used for packages that
need it?
libreoffice has some problem that makes it crash every time it tries to open a
file dialog - I wonder if that's related (libreoffice uses gnu-build-system).
But glib-or-gtk-build-system expicitly generates gschemas.compiled, ensuring a
collision - what's up with that?
Shouldn't there be a profile hook for it instead? There doesn't seem to be one.
[Message part 2 (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#31458
; Package
guix-patches
.
(Tue, 15 May 2018 12:44:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 31458 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
>Re: [bug#31458] [PATCH] union: Do not warn about harmless collissions.
typo ------------------------------------------------------------^
[Message part 2 (application/pgp-signature, inline)]
Information forwarded
to
guix-patches <at> gnu.org
:
bug#31458
; Package
guix-patches
.
(Wed, 16 May 2018 08:59:01 GMT)
Full text and
rfc822 format available.
Message #14 received at 31458 <at> debbugs.gnu.org (full text, mbox):
Hello,
Danny Milosavljevic <dannym <at> scratchpost.org> skribis:
> On Tue, 15 May 2018 10:31:19 +0200
> Ludovic Courtès <ludo <at> gnu.org> wrote:
>
>> Until now we'd get pointless messages like:
>>
>> warning: collision encountered:
>> /gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
>> /gnu/store/…-inkscape-0.92.3/share/icons/hicolor/icon-theme.cache
>> warning: choosing /gnu/store/…-gtk-icon-themes/share/icons/hicolor/icon-theme.cache
>
> Hmm, I guess the icon-theme.cache one is harmless enough - however, there shouldn't
> be many of those left anyway. Is there an easy way to check the store of hydra or something
> which packages still have those files?
No, but everyone can check in their own profile. :-)
> I've fixed inkscape now.
Since “fixing” packages like you just did is a manual step, I think it’s
still fine to ignore “icon-theme.cache” collisions. WDYT?
>> +(define %harmless-collisions
>> + ;; This is a list of files that are known to collide, but for which emitting
>> + ;; a warning doesn't make sense. For example, "icon-theme.cache" is
>> + ;; regenerated by a profile hook which shadows the file provided by
>> + ;; individual packages, and "gschemas.compiled" is made available to
>> + ;; applications via 'glib-or-gtk-build-system'.
>> + '("icon-theme.cache" "gschemas.compiled"))
>
> However, about gschemas.compiled I'm not sure yet.
>
> How do we ensure that glib-or-gtk-build-system is actually used for packages that
> need it?
I don’t think we can. :-/
> libreoffice has some problem that makes it crash every time it tries to open a
> file dialog - I wonder if that's related (libreoffice uses gnu-build-system).
It is, see <https://bugs.gnu.org/30642>.
> But glib-or-gtk-build-system expicitly generates gschemas.compiled, ensuring a
> collision - what's up with that?
glib-or-gtk-build-system wraps binaries so that they refer to the right
gschemas.compiled, so in that case the gschemas.compiled file that ends
up in the profile doesn’t matter at all.
> Shouldn't there be a profile hook for it instead? There doesn't seem to be one.
Maybe, yes, though I’m not sure how that’d work (and would it be fast
enough?).
This seems to be orthogonal to this patch, though: we can remove the
collision warnings for these files today, because there’s nothing users
can do about them and they’re effectively harmless, and later on, if we
have better gschemas.compiled handling, we can always let them through
again.
Thoughts?
Ludo’.
Information forwarded
to
guix-patches <at> gnu.org
:
bug#31458
; Package
guix-patches
.
(Wed, 16 May 2018 11:08:01 GMT)
Full text and
rfc822 format available.
Message #17 received at 31458 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi Ludo,
On Wed, 16 May 2018 10:57:57 +0200
ludo <at> gnu.org (Ludovic Courtès) wrote:
> Since “fixing” packages like you just did is a manual step, I think it’s
> still fine to ignore “icon-theme.cache” collisions. WDYT?
Definitely.
> > However, about gschemas.compiled I'm not sure yet.
> >
> > How do we ensure that glib-or-gtk-build-system is actually used for packages that
> > need it?
>
> I don’t think we can. :-/
>
> > libreoffice has some problem that makes it crash every time it tries to open a
> > file dialog - I wonder if that's related (libreoffice uses gnu-build-system).
>
> It is, see <https://bugs.gnu.org/30642>.
>
> > But glib-or-gtk-build-system expicitly generates gschemas.compiled, ensuring a
> > collision - what's up with that?
>
> glib-or-gtk-build-system wraps binaries so that they refer to the right
> gschemas.compiled, so in that case the gschemas.compiled file that ends
> up in the profile doesn’t matter at all.
>
> > Shouldn't there be a profile hook for it instead? There doesn't seem to be one.
>
> Maybe, yes, though I’m not sure how that’d work (and would it be fast
> enough?).
I wrote one in bug 31462. Seems to be quite fast. But let's think about whether
we want it, and whether we want it in addition to the wrapper.
(libreoffice works with it now FWIW)
> This seems to be orthogonal to this patch, though: we can remove the
> collision warnings for these files today, because there’s nothing users
> can do about them and they’re effectively harmless, and later on, if we
> have better gschemas.compiled handling, we can always let them through
> again.
Yeah, I just wanted to make sure we are not hiding them if they are the only
indication that something will break horribly with the program.
(see libreoffice)
But since the wrapper needs gschemas.compiled, we can't use it as indicator
for missing-glib-or-gtk-build-system anyway, so:
LGTM!
[Message part 2 (application/pgp-signature, inline)]
Reply sent
to
ludo <at> gnu.org (Ludovic Courtès)
:
You have taken responsibility.
(Thu, 17 May 2018 08:51:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Ludovic Courtès <ludo <at> gnu.org>
:
bug acknowledged by developer.
(Thu, 17 May 2018 08:51:02 GMT)
Full text and
rfc822 format available.
Message #22 received at 31458-done <at> debbugs.gnu.org (full text, mbox):
Hi Danny,
Danny Milosavljevic <dannym <at> scratchpost.org> skribis:
> On Wed, 16 May 2018 10:57:57 +0200
> ludo <at> gnu.org (Ludovic Courtès) wrote:
[...]
>> > Shouldn't there be a profile hook for it instead? There doesn't seem to be one.
>>
>> Maybe, yes, though I’m not sure how that’d work (and would it be fast
>> enough?).
>
> I wrote one in bug 31462. Seems to be quite fast. But let's think about whether
> we want it, and whether we want it in addition to the wrapper.
>
> (libreoffice works with it now FWIW)
Awesome!
>> This seems to be orthogonal to this patch, though: we can remove the
>> collision warnings for these files today, because there’s nothing users
>> can do about them and they’re effectively harmless, and later on, if we
>> have better gschemas.compiled handling, we can always let them through
>> again.
>
> Yeah, I just wanted to make sure we are not hiding them if they are the only
> indication that something will break horribly with the program.
> (see libreoffice)
Sure, that makes sense. In this particular case the gschemas.compiled
collision did not tell us much: some applications (e.g., Evince) would
work fine because they used glib-or-gtk-build-system, while others
(e.g., LibreOffice) would fail.
> But since the wrapper needs gschemas.compiled, we can't use it as indicator
> for missing-glib-or-gtk-build-system anyway, so:
>
> LGTM!
Alright, committed! :-)
Thank you,
Ludo’.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Thu, 14 Jun 2018 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 11 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.