GNU bug report logs - #28055
[WIP] Add knot tests

Previous Next

Package: guix-patches;

Reported by: Julien Lepiller <julien <at> lepiller.eu>

Date: Fri, 11 Aug 2017 19:06:02 UTC

Severity: normal

Tags: patch

To reply to this bug, email your comments to 28055 AT debbugs.gnu.org.

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#28055; Package guix-patches. (Fri, 11 Aug 2017 19:06:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Julien Lepiller <julien <at> lepiller.eu>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Fri, 11 Aug 2017 19:06:02 GMT) Full text and rfc822 format available.

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

From: Julien Lepiller <julien <at> lepiller.eu>
To: guix-patches <at> gnu.org
Subject: [WIP] Add knot tests
Date: Fri, 11 Aug 2017 21:04:53 +0200
[Message part 1 (text/plain, inline)]
Hi,

This patch aims at adding a system test for knot. I've implemented the
DNS protocol to be able to communicate with the server and try some
queries. Unfortunately, although the server seems to be launched (the
first test passes), it then refuses to answer. Do you see anything
wrong, or anything I could do to understand why it doesn't pass?

Thanks :)
[0001-gnu-tests-Add-dns-test.patch (text/x-patch, attachment)]

Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Wed, 16 Aug 2017 09:10:02 GMT) Full text and rfc822 format available.

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

From: Ricardo Wurmus <rekado <at> elephly.net>
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Wed, 16 Aug 2017 11:09:03 +0200
Hi Julien,

> This patch aims at adding a system test for knot. I've implemented the
> DNS protocol to be able to communicate with the server and try some
> queries. Unfortunately, although the server seems to be launched (the
> first test passes), it then refuses to answer. Do you see anything
> wrong, or anything I could do to understand why it doesn't pass?

It looks like overkill to implement DNS queries with bytevectors from
the ground up.  Is there not an easier way to make a DNS test?

-- 
Ricardo

GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
https://elephly.net





Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Wed, 16 Aug 2017 13:03:02 GMT) Full text and rfc822 format available.

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

From: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Wed, 16 Aug 2017 15:02:17 +0200
[Message part 1 (text/plain, inline)]
Hm... I followed the example of mail.scm and implemented the protocol. I also thought a pure scheme implementation would be prefered. I didn't really think of anything else.

I guess I could use the host utility to query the test server. Or if I can change the default dns server, I could use hostent:addr-list that I have just found in the manual. That would be better I think.

I'll try these methods.

Le 16 août 2017 11:09:03 GMT+02:00, Ricardo Wurmus <rekado <at> elephly.net> a écrit :
>
>Hi Julien,
>
>> This patch aims at adding a system test for knot. I've implemented
>the
>> DNS protocol to be able to communicate with the server and try some
>> queries. Unfortunately, although the server seems to be launched (the
>> first test passes), it then refuses to answer. Do you see anything
>> wrong, or anything I could do to understand why it doesn't pass?
>
>It looks like overkill to implement DNS queries with bytevectors from
>the ground up.  Is there not an easier way to make a DNS test?
>
>-- 
>Ricardo
>
>GPG: BCA6 89B6 3655 3801 C3C6  2150 197A 5888 235F ACAC
>https://elephly.net

-- 
Envoyé de mon appareil Android avec Courriel K-9 Mail. Veuillez excuser ma brièveté.
[Message part 2 (text/html, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Tue, 26 Sep 2017 08:28:02 GMT) Full text and rfc822 format available.

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

From: ludo <at> gnu.org (Ludovic Courtès)
To: Ricardo Wurmus <rekado <at> elephly.net>
Cc: Julien Lepiller <julien <at> lepiller.eu>, 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Tue, 26 Sep 2017 10:27:00 +0200
Howdy,

Ricardo Wurmus <rekado <at> elephly.net> skribis:

>> This patch aims at adding a system test for knot. I've implemented the
>> DNS protocol to be able to communicate with the server and try some
>> queries. Unfortunately, although the server seems to be launched (the
>> first test passes), it then refuses to answer. Do you see anything
>> wrong, or anything I could do to understand why it doesn't pass?
>
> It looks like overkill to implement DNS queries with bytevectors from
> the ground up.  Is there not an easier way to make a DNS test?

It’s a bit overkill indeed… but I like it.  :-)

Julien: could you move the DNS code to a new module, say (guix dns), and
then add the Knot test?

(So first patch adds (guix dns), second patch adds the test.)

In passing, for (guix dns) it would be nice if you could add docstrings
as you see fit, and attempt to use full words in identifiers (“address”
rather than “addr”, “resolve” rather than “resolv”, etc.¹).

This looks really nice, thanks for working on it!

Ludo’.

¹ https://www.gnu.org/software/guix/manual/html_node/Formatting-Code.html




Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Fri, 01 Dec 2017 10:24:02 GMT) Full text and rfc822 format available.

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

From: ludo <at> gnu.org (Ludovic Courtès)
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: Ricardo Wurmus <rekado <at> elephly.net>, 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Fri, 01 Dec 2017 11:23:53 +0100
Julien,

Did you have a chance to look into that?

TIA,
Ludo’.

ludo <at> gnu.org (Ludovic Courtès) skribis:

> Howdy,
>
> Ricardo Wurmus <rekado <at> elephly.net> skribis:
>
>>> This patch aims at adding a system test for knot. I've implemented the
>>> DNS protocol to be able to communicate with the server and try some
>>> queries. Unfortunately, although the server seems to be launched (the
>>> first test passes), it then refuses to answer. Do you see anything
>>> wrong, or anything I could do to understand why it doesn't pass?
>>
>> It looks like overkill to implement DNS queries with bytevectors from
>> the ground up.  Is there not an easier way to make a DNS test?
>
> It’s a bit overkill indeed… but I like it.  :-)
>
> Julien: could you move the DNS code to a new module, say (guix dns), and
> then add the Knot test?
>
> (So first patch adds (guix dns), second patch adds the test.)
>
> In passing, for (guix dns) it would be nice if you could add docstrings
> as you see fit, and attempt to use full words in identifiers (“address”
> rather than “addr”, “resolve” rather than “resolv”, etc.¹).
>
> This looks really nice, thanks for working on it!
>
> Ludo’.
>
> ¹ https://www.gnu.org/software/guix/manual/html_node/Formatting-Code.html




Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Sat, 02 Dec 2017 11:21:02 GMT) Full text and rfc822 format available.

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

From: Julien Lepiller <julien <at> lepiller.eu>
To: 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Sat, 2 Dec 2017 12:18:15 +0100
[Message part 1 (text/plain, inline)]
Le Fri, 01 Dec 2017 11:23:53 +0100,
ludo <at> gnu.org (Ludovic Courtès) a écrit :

> Julien,
> 
> Did you have a chance to look into that?
> 
> TIA,
> Ludo’.
> 

Here is a new version. The tests still don't pass though. It can't send
the request to the server.

[0001-guix-Add-DNS-implementation.patch (text/x-patch, attachment)]
[0002-gnu-tests-Add-knot-test.patch (text/x-patch, attachment)]

Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Fri, 15 Dec 2017 10:54:01 GMT) Full text and rfc822 format available.

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

From: ludo <at> gnu.org (Ludovic Courtès)
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: [bug#28055] [WIP] Add knot tests
Date: Fri, 15 Dec 2017 11:53:06 +0100
Hello,

Julien Lepiller <julien <at> lepiller.eu> skribis:

> Here is a new version. The tests still don't pass though. It can't send
> the request to the server.
>
> From ecc02fe8098d8763b95d2c71215a62e669f49568 Mon Sep 17 00:00:00 2001
> From: Julien Lepiller <julien <at> lepiller.eu>
> Date: Sat, 2 Dec 2017 10:51:18 +0100
> Subject: [PATCH 1/2] guix: Add DNS implementation.
>
> * guix/dns.scm: New file.
> * Makefile.am: Add it.

[...]

> +;;; Commentary:
> +;;;
> +;;; This module provides a DNS implementation. This modules helps construct
                                                  ^^^^^^^^^^^^
“It”.  :-)

Maybe add that it’s primarily for test purposes.

Very nice stuff!

> From 5146714c6615161fe3e496909f5a157c24d57ea0 Mon Sep 17 00:00:00 2001
> From: Julien Lepiller <julien <at> lepiller.eu>
> Date: Sat, 2 Dec 2017 12:15:28 +0100
> Subject: [PATCH 2/2] gnu: tests: Add knot test.
>
> * gnu/tests/dns.scm: New file.
> * gnu/local.mk (GNU_SYSTEM_MODULES): Add it.

[...]

> +(define (run-knot-test)
> +  "Return a test of an OS running Knot service."
> +  (define vm
> +    (virtual-machine
> +     (operating-system (marionette-operating-system
> +                        %knot-os
> +                        #:imported-modules '((gnu services herd))))
> +     (port-forwardings '((1053 . 53)))))

Note that this creates *TCP* port forwardings (see
‘port-forwardings->qemu-options’ in (gnu system vm)).

Perhaps you’ll want UDP forwarding?

> +          (test-eq "get the correct answer"
> +            #$%ip4-addr

Should be ‘test-equal’ since you’re comparing strings.

> +            (begin
> +              (format #t "test:\n")
> +              (let* ((query (simple-a-query "mail.guix-test.org"))
> +                     (dns (socket AF_INET SOCK_STREAM 0))
> +                     (addr (make-socket-address AF_INET INADDR_LOOPBACK 1053)))
> +                (connect dns addr)

I learned from
<https://serverfault.com/questions/181956/is-it-true-that-a-nameserver-have-to-answer-queries-over-tcp>
that DNS servers are now supposed to listen for TCP requests, but are we
sure this is the case here?

What error do you get?  Does the ‘connect’ call fail?  Does the message
go through?

Thanks!

Ludo’.




Added tag(s) patch. Request was from Christopher Baines <mail <at> cbaines.net> to control <at> debbugs.gnu.org. (Mon, 19 Mar 2018 08:21:01 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Thu, 13 Jan 2022 15:14:01 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: bug#28055: [WIP] Add knot tests
Date: Thu, 13 Jan 2022 16:12:14 +0100
Hi Julien,

On Sat, 02 Dec 2017 at 12:18, Julien Lepiller <julien <at> lepiller.eu> wrote:

> Here is a new version. The tests still don't pass though. It can't send
> the request to the server.

What is the status of this patch [1] adding DNS system tests for knot?

It seems almost ready, no?

1: <http://issues.guix.gnu.org/issue/28055>


Cheers,
simon




Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Wed, 23 Mar 2022 10:52:02 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: bug#28055: [WIP] Add knot tests
Date: Wed, 23 Mar 2022 11:48:21 +0100
Hi,

On Thu, 13 Jan 2022 at 16:12, zimoun <zimon.toutoune <at> gmail.com> wrote:
> On Sat, 02 Dec 2017 at 12:18, Julien Lepiller <julien <at> lepiller.eu> wrote:
>
>> Here is a new version. The tests still don't pass though. It can't send
>> the request to the server.
>
> What is the status of this patch [1] adding DNS system tests for knot?
>
> It seems almost ready, no?
>
> 1: <http://issues.guix.gnu.org/issue/28055>

What is the status of this old patch [1]?  It is there since a long time
and not a comment since the past 9 weeks.  Therefore, I am going to
close it in the coming weeks.


1: <http://issues.guix.gnu.org/issue/28055>


Cheers,
simon




Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Thu, 23 Jun 2022 10:03:01 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: bug#28055: [WIP] Add knot tests
Date: Thu, 23 Jun 2022 11:55:25 +0200
Hi,

On Wed, 23 Mar 2022 at 11:48, zimoun <zimon.toutoune <at> gmail.com> wrote:
> On Thu, 13 Jan 2022 at 16:12, zimoun <zimon.toutoune <at> gmail.com> wrote:
>> On Sat, 02 Dec 2017 at 12:18, Julien Lepiller <julien <at> lepiller.eu> wrote:
>>
>>> Here is a new version. The tests still don't pass though. It can't send
>>> the request to the server.
>>
>> What is the status of this patch [1] adding DNS system tests for knot?
>>
>> It seems almost ready, no?
>>
>> 1: <http://issues.guix.gnu.org/issue/28055>
>
> What is the status of this old patch [1]?  It is there since a long time
> and not a comment since the past 9 weeks.  Therefore, I am going to
> close it in the coming weeks.

Any objection for closing?


Cheers,
simon




Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Sun, 18 Sep 2022 18:30:01 GMT) Full text and rfc822 format available.

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

From: Julien Lepiller <julien <at> lepiller.eu>
To: zimoun <zimon.toutoune <at> gmail.com>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: bug#28055: [WIP] Add knot tests
Date: Sun, 18 Sep 2022 20:28:52 +0200
[Message part 1 (text/plain, inline)]
Hi Simon,

I think I have an idea for this patch, please keep it open :)

Le 23 juin 2022 11:55:25 GMT+02:00, zimoun <zimon.toutoune <at> gmail.com> a écrit :
>Hi,
>
>On Wed, 23 Mar 2022 at 11:48, zimoun <zimon.toutoune <at> gmail.com> wrote:
>> On Thu, 13 Jan 2022 at 16:12, zimoun <zimon.toutoune <at> gmail.com> wrote:
>>> On Sat, 02 Dec 2017 at 12:18, Julien Lepiller <julien <at> lepiller.eu> wrote:
>>>
>>>> Here is a new version. The tests still don't pass though. It can't send
>>>> the request to the server.
>>>
>>> What is the status of this patch [1] adding DNS system tests for knot?
>>>
>>> It seems almost ready, no?
>>>
>>> 1: <http://issues.guix.gnu.org/issue/28055>
>>
>> What is the status of this old patch [1]?  It is there since a long time
>> and not a comment since the past 9 weeks.  Therefore, I am going to
>> close it in the coming weeks.
>
>Any objection for closing?
>
>
>Cheers,
>simon
[Message part 2 (text/html, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#28055; Package guix-patches. (Tue, 24 Oct 2023 09:02:02 GMT) Full text and rfc822 format available.

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

From: Simon Tournier <zimon.toutoune <at> gmail.com>
To: Julien Lepiller <julien <at> lepiller.eu>
Cc: 28055 <at> debbugs.gnu.org
Subject: Re: bug#28055: [WIP] Add knot tests
Date: Mon, 23 Oct 2023 23:00:04 +0200
Hi Julien,

On Sun, 18 Sep 2022 at 20:28, Julien Lepiller <julien <at> lepiller.eu> wrote:

> I think I have an idea for this patch, please keep it open :)

We are now more than one year later, about #28055 [1].  Did you have a
chance to look into this?

Cheers,
simon


1: https://issues.guix.gnu.org/issue/28055




This bug report was last modified 192 days ago.

Previous Next


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