[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[debbugs-tracker] bug#31458: closed ([PATCH] union: Do not warn about ha

From: GNU bug Tracking System
Subject: [debbugs-tracker] bug#31458: closed ([PATCH] union: Do not warn about harmless collissions.)
Date: Thu, 17 May 2018 08:51:01 +0000

Your message dated Thu, 17 May 2018 10:50:45 +0200
with message-id <address@hidden>
and subject line Re: [bug#31458] [PATCH] union: Do not warn about harmless 
has caused the debbugs.gnu.org bug report #31458,
regarding [PATCH] union: Do not warn about harmless collissions.
to be marked as done.

(If you believe you have received this mail in error, please contact

31458: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=31458
GNU Bug Tracking System
Contact address@hidden with problems
--- Begin Message --- Subject: [PATCH] union: Do not warn about harmless collissions. Date: Tue, 15 May 2018 10:31:19 +0200
Until now we'd get pointless messages like:

  warning: collision encountered:
  warning: choosing 

* 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)
+(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))
 (define* (union-build output inputs

--- End Message ---
--- Begin Message --- Subject: Re: [bug#31458] [PATCH] union: Do not warn about harmless collissions. Date: Thu, 17 May 2018 10:50:45 +0200 User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)
Hi Danny,

Danny Milosavljevic <address@hidden> skribis:

> On Wed, 16 May 2018 10:57:57 +0200
> address@hidden (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)


>> 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:

Alright, committed!  :-)

Thank you,

--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]