GNU bug report logs - #44197
[PATCH] gnu: khal: Update to 0.10.2.

Previous Next

Package: guix-patches;

Reported by: Lars-Dominik Braun <lars <at> 6xq.net>

Date: Sat, 24 Oct 2020 18:24:02 UTC

Severity: normal

Tags: patch

Done: Leo Famulari <leo <at> famulari.name>

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 44197 in the body.
You can then email your comments to 44197 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Sat, 24 Oct 2020 18:24:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Lars-Dominik Braun <lars <at> 6xq.net>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 24 Oct 2020 18:24:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Lars-Dominik Braun <lars <at> 6xq.net>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: khal: Update to 0.10.2.
Date: Sat, 24 Oct 2020 20:23:33 +0200
* gnu/packages/calendar.scm (khal): Update to 0.10.2.
[source]: Drop upstream patches.
[arguments]: Drop substitute* for bug fixed upstream and ignore failing
test in 'check.
[inputs]: Add missing inputs.
---
 gnu/packages/calendar.scm | 46 +++++++++++++++------------------------
 1 file changed, 18 insertions(+), 28 deletions(-)

diff --git a/gnu/packages/calendar.scm b/gnu/packages/calendar.scm
index 1dde978d72..dabf8bfb15 100644
--- a/gnu/packages/calendar.scm
+++ b/gnu/packages/calendar.scm
@@ -168,23 +168,13 @@ data units.")
 (define-public khal
   (package
     (name "khal")
-    (version "0.10.1")
+    (version "0.10.2")
     (source (origin
-             (method url-fetch)
-             (uri (pypi-uri "khal" version))
-             (sha256
-              (base32
-               "1r8bkgjwkh7i8ygvsv51h1cnax50sb183vafg66x5snxf3dgjl6l"))
-             (patches
-               (list
-                 (origin
-                   (method url-fetch)
-                   ;; This patch fixes an issue with python-urwid-2.1.0
-                   (uri "https://github.com/pimutils/khal/commit/2c5990c2de2015b251ba23617faa40ee11b8c22a.patch")
-                   (file-name "khal-compat-urwid-2.1.0.patch")
-                   (sha256
-                    (base32
-                     "11nd8hkjz68imwqqn0p54zmb53z2pfxmzchaviy7jc1ky5s9l663")))))))
+              (method url-fetch)
+              (uri (pypi-uri "khal" version))
+              (sha256
+               (base32
+                "11qhrga44knlnp88py9p547d4nr5kn041d2nszwa3dqw7mf22ks9"))))
     (build-system python-build-system)
     (arguments
      `(#:phases (modify-phases %standard-phases
@@ -198,19 +188,14 @@ data units.")
              "doc/build/man/khal.1"
              (string-append (assoc-ref outputs "out") "/share/man/man1"))
             #t))
-        (add-before 'check 'fix-tests
-          (lambda _
-            ;; Reported upstream: <https://github.com/pimutils/khal/issues/947>.
-            (substitute* "tests/cli_test.py"
-             (("Invalid value for \"\\[ICS\\]\"") "Invalid value for \\'[ICS]\\'"))
-            #t))
         (replace 'check
-          (lambda* (#:key inputs #:allow-other-keys)
-            ;; The tests require us to choose a timezone.
-            (setenv "TZ"
-                    (string-append (assoc-ref inputs "tzdata")
-                                   "/share/zoneinfo/Zulu"))
-            (invoke "py.test" "tests"))))))
+          (lambda* (#:key inputs tests? #:allow-other-keys)
+            (if tests?
+                (begin
+                  ;; The tests require us to choose a timezone.
+                  (setenv "TZ" "UTC")
+                  ;; The disabled test expects /dev/tty.
+                  (invoke "pytest" "tests" "-k" "not test_import_from_stdin"))))))))
     (native-inputs
      `(("python-pytest" ,python-pytest)
        ("python-pytest-cov" ,python-pytest-cov)
@@ -229,6 +214,11 @@ data units.")
        ("python-icalendar" ,python-icalendar)
        ("python-tzlocal" ,python-tzlocal)
        ("python-urwid" ,python-urwid)
+       ("python-pytz" ,python-pytz)
+       ("python-setproctitle" ,python-setproctitle)
+       ("python-atomicwrites" ,python-atomicwrites)
+       ("python-click" ,python-click)
+       ("python-click-log" ,python-click-log)
        ("python-pyxdg" ,python-pyxdg)))
     (synopsis "Console calendar program")
     (description "Khal is a standards based console calendar program,
-- 
2.26.2





Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Sun, 25 Oct 2020 18:15:01 GMT) Full text and rfc822 format available.

Message #8 received at 44197 <at> debbugs.gnu.org (full text, mbox):

From: Leo Famulari <leo <at> famulari.name>
To: Lars-Dominik Braun <lars <at> 6xq.net>
Cc: 44197 <at> debbugs.gnu.org
Subject: Re: [bug#44197] [PATCH] gnu: khal: Update to 0.10.2.
Date: Sun, 25 Oct 2020 14:14:29 -0400
On Sat, Oct 24, 2020 at 08:23:33PM +0200, Lars-Dominik Braun wrote:
> * gnu/packages/calendar.scm (khal): Update to 0.10.2.
> [source]: Drop upstream patches.
> [arguments]: Drop substitute* for bug fixed upstream and ignore failing
> test in 'check.
> [inputs]: Add missing inputs.

Thanks!

Unfortunately, the second part of the patch ("hunk 2") does not apply to
the latest Guix Git master branch:

> @@ -198,19 +188,14 @@ data units.")
>               "doc/build/man/khal.1"
>               (string-append (assoc-ref outputs "out") "/share/man/man1"))
>              #t))
> -        (add-before 'check 'fix-tests
> -          (lambda _
> -            ;; Reported upstream: <https://github.com/pimutils/khal/issues/947>.
> -            (substitute* "tests/cli_test.py"
> -             (("Invalid value for \"\\[ICS\\]\"") "Invalid value for \\'[ICS]\\'"))
> -            #t))
>          (replace 'check
> -          (lambda* (#:key inputs #:allow-other-keys)
> -            ;; The tests require us to choose a timezone.
> -            (setenv "TZ"
> -                    (string-append (assoc-ref inputs "tzdata")
> -                                   "/share/zoneinfo/Zulu"))
> -            (invoke "py.test" "tests"))))))
> +          (lambda* (#:key inputs tests? #:allow-other-keys)
> +            (if tests?
> +                (begin
> +                  ;; The tests require us to choose a timezone.
> +                  (setenv "TZ" "UTC")
> +                  ;; The disabled test expects /dev/tty.
> +                  (invoke "pytest" "tests" "-k" "not test_import_from_stdin"))))))))
>      (native-inputs
>       `(("python-pytest" ,python-pytest)
>         ("python-pytest-cov" ,python-pytest-cov)

Can you double-check and see if there is something else in your local
copy of the Guix source code?




Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Mon, 26 Oct 2020 07:38:01 GMT) Full text and rfc822 format available.

Message #11 received at 44197 <at> debbugs.gnu.org (full text, mbox):

From: Lars-Dominik Braun <lars <at> 6xq.net>
To: Leo Famulari <leo <at> famulari.name>
Cc: 44197 <at> debbugs.gnu.org
Subject: Re: [bug#44197] [PATCH] gnu: khal: Update to 0.10.2.
Date: Mon, 26 Oct 2020 08:37:24 +0100
[Message part 1 (text/plain, inline)]
Hi Leo,

> Unfortunately, the second part of the patch ("hunk 2") does not apply to
> the latest Guix Git master branch:
you’re right. Looks like there is a weird space character between “;;”
and “Reported upstream”. Maybe email ate that? I’m attaching a `git
show` instead and also uploading the change to
https://github.com/PromyLOPh/guix (branch work-khal, commit
503169b39de09e3c3969bb2dc92464f054d79560).

Thanks for taking care of this,
Lars

[khal.patch (text/x-diff, attachment)]

Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Mon, 26 Oct 2020 17:40:01 GMT) Full text and rfc822 format available.

Message #14 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Leo Famulari <leo <at> famulari.name>
To: Lars-Dominik Braun <lars <at> 6xq.net>
Cc: bug-guix <at> gnu.org, 44197-done <at> debbugs.gnu.org
Subject: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Mon, 26 Oct 2020 13:39:00 -0400
[Message part 1 (text/plain, inline)]
On Mon, Oct 26, 2020 at 08:37:24AM +0100, Lars-Dominik Braun wrote:
> Thanks for taking care of this,

Thanks for taking care of this package I use every day! :)

> commit 503169b39de09e3c3969bb2dc92464f054d79560
> Author: Lars-Dominik Braun <lars <at> 6xq.net>
> Date:   Sat Oct 24 20:17:48 2020 +0200
> 
>     gnu: khal: Update to 0.10.2.
>     
>     * gnu/packages/calendar.scm (khal): Update to 0.10.2.
>     [source]: Drop upstream patches.
>     [arguments]: Drop substitute* for bug fixed upstream and ignore failing
>     test in 'check.
>     [inputs]: Add missing inputs.

Pushed as 21955a54da2bc171f2745486f62aceeacea7993a.

I wonder, should we disable the test suite entirely? In my experience,
it's not reliable — different parts of it will succeed or fail on
subsequent runs, or on different computers, or when verbose output is
enable, etc. The upstream bug tracker is full of reports like that.

For example:

https://github.com/pimutils/khal/issues/860
[signature.asc (application/pgp-signature, inline)]

Reply sent to Leo Famulari <leo <at> famulari.name>:
You have taken responsibility. (Mon, 26 Oct 2020 17:40:02 GMT) Full text and rfc822 format available.

Notification sent to Lars-Dominik Braun <lars <at> 6xq.net>:
bug acknowledged by developer. (Mon, 26 Oct 2020 17:40:02 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Tue, 27 Oct 2020 08:15:01 GMT) Full text and rfc822 format available.

Message #22 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Lars-Dominik Braun <lars <at> 6xq.net>
To: Leo Famulari <leo <at> famulari.name>
Cc: bug-guix <at> gnu.org, 44197-done <at> debbugs.gnu.org
Subject: Re: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Tue, 27 Oct 2020 09:14:10 +0100
Hi,

> Thanks for taking care of this package I use every day! :)
yeah, me too :)

> I wonder, should we disable the test suite entirely? In my experience,
> it's not reliable — different parts of it will succeed or fail on
> subsequent runs, or on different computers, or when verbose output is
> enable, etc.
I just checked on two different machines and you’re right, on my main
machine the test suite works (even across multiple runs), on the other
one three tests[1] fail – with exactly the same Guix version
(commit 6a0fec57092d574c33b997e5972012e9c29a4dd4). This should not
happen in the build environment. Imo it would be worth figuring out why
it does nontheless.

Cheers,
Lars

[1] TestCollection.test_multi_uid_vdir, test_event_different_timezones
and test_default_calendar.





Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Tue, 27 Oct 2020 08:15:02 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Tue, 27 Oct 2020 22:00:02 GMT) Full text and rfc822 format available.

Message #28 received at 44197-done <at> debbugs.gnu.org (full text, mbox):

From: Leo Famulari <leo <at> famulari.name>
To: Lars-Dominik Braun <lars <at> 6xq.net>
Cc: 44197-done <at> debbugs.gnu.org
Subject: Re: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Tue, 27 Oct 2020 17:59:06 -0400
On Tue, Oct 27, 2020 at 09:14:10AM +0100, Lars-Dominik Braun wrote:
> I just checked on two different machines and you’re right, on my main
> machine the test suite works (even across multiple runs), on the other
> one three tests[1] fail – with exactly the same Guix version
> (commit 6a0fec57092d574c33b997e5972012e9c29a4dd4). This should not
> happen in the build environment. Imo it would be worth figuring out why
> it does nontheless.

Alright, I will disable it then.

Can you say more about the differences between the machines where it
succeeds and fails? It could help us figure out what's going on.

For me, I'm building on a Thinkpad (Intel Core i5-6300U CPU) using
Debian with Linux 5.9.1, with a tmpfs filesystem for the build
environment. I use an SSD for storage...  but I don't think the tmpfs is
ever swapping on this machine. There is a lot of unused RAM.

> 
> [1] TestCollection.test_multi_uid_vdir, test_event_different_timezones
> and test_default_calendar.

These fail for me often. I also sometimes see failures of
test_only_update_old_event, test_birthdays, test_birthdays_29feb and
test_birthdays_no_year.




Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Wed, 28 Oct 2020 07:23:02 GMT) Full text and rfc822 format available.

Message #31 received at 44197-done <at> debbugs.gnu.org (full text, mbox):

From: Lars-Dominik Braun <lars <at> 6xq.net>
To: Leo Famulari <leo <at> famulari.name>
Cc: 44197-done <at> debbugs.gnu.org
Subject: Re: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Wed, 28 Oct 2020 08:22:13 +0100
Hi,

> Can you say more about the differences between the machines where it
> succeeds and fails? It could help us figure out what's going on.
they are quite different machines unfortunately. One is Gentoo Linux
running on a Ryzen 5 3600 desktop machine (working), the other one a
Ubuntu 19.10 on a Thinkpad (Intel Core i5-8250U) Laptop (not working).
Both have SSD storage and /tmp on a tmpfs.

Could there be something leaking into the build environment to make it
fail consistently on one machine, but not the other one?

Cheers,
Lars





Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Wed, 28 Oct 2020 16:31:01 GMT) Full text and rfc822 format available.

Message #34 received at 44197-done <at> debbugs.gnu.org (full text, mbox):

From: Leo Famulari <leo <at> famulari.name>
To: Lars-Dominik Braun <lars <at> 6xq.net>
Cc: 44197-done <at> debbugs.gnu.org
Subject: Re: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Wed, 28 Oct 2020 12:30:05 -0400
On Wed, Oct 28, 2020 at 08:22:13AM +0100, Lars-Dominik Braun wrote:
> Hi,
> 
> > Can you say more about the differences between the machines where it
> > succeeds and fails? It could help us figure out what's going on.
> they are quite different machines unfortunately. One is Gentoo Linux
> running on a Ryzen 5 3600 desktop machine (working), the other one a
> Ubuntu 19.10 on a Thinkpad (Intel Core i5-8250U) Laptop (not working).
> Both have SSD storage and /tmp on a tmpfs.

Interesting that we both get failures on Core i5 processors and
Debian-family operating systems. I am not using the Debian kernel (I
build a variant of the Guix kernel), but I do use the Debian package
tooling to manage it.

> Could there be something leaking into the build environment to make it
> fail consistently on one machine, but not the other one?

Could be, but the question is what? The build environment isolation
doesn't account for things like filesystem, kernel version, time of day
(👀), CPU bugs... besides the common culprit of some race conditions in
the test suite.

Are you using the same kernel versions on your two machines? I guess the
kernel configs likely don't match between them.




Information forwarded to guix-patches <at> gnu.org:
bug#44197; Package guix-patches. (Thu, 29 Oct 2020 10:11:01 GMT) Full text and rfc822 format available.

Message #37 received at 44197-done <at> debbugs.gnu.org (full text, mbox):

From: Lars-Dominik Braun <lars <at> 6xq.net>
To: Leo Famulari <leo <at> famulari.name>
Cc: 44197-done <at> debbugs.gnu.org
Subject: Re: Disable khal test suite? (was Re: [bug#44197] [PATCH] gnu: khal:
 Update to 0.10.2.)
Date: Thu, 29 Oct 2020 11:10:44 +0100
Hi Leo,

some more data points:

- works consistently inside a VM (Common KVM processor) with Ubuntu
  20.04 → not the kernel version/configuration or OS.
- whether it works or not does not change during the day → not time
  related(?)
- works consistently on a different laptop with i5-8250U and Gentoo →
  not the processor

After looking at how test_birthdays_29feb fails, I’m leaning towards the
possiblity of a bug in khal. So, I commented here:
https://github.com/pimutils/khal/issues/860#issuecomment-718583031

> Are you using the same kernel versions on your two machines? I guess the
> kernel configs likely don't match between them.
No, previously the Ubuntu machine used 5.3 and now after upgrading to
20.04 version 5.4. The test suite is still failing there and still
succeeding on my desktop, which is using a custom kernel configuration
tailored to this particular machine (version 5.8 right now).

Cheers,
Lars





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 26 Nov 2020 12:24:11 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 157 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.