[Top][All Lists]

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

Re: [PATCH] Prototype register-path

From: Ludovic Courtès
Subject: Re: [PATCH] Prototype register-path
Date: Sun, 18 Jun 2017 01:05:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)


Caleb Ristvedt <address@hidden> skribis:

> Hash: SHA256
> Apologies for the delay - in a shocking twist, it turns out professors
> insisting on only one exit from functions had a point, and trying to
> fully understand what optimisePath_, with its 14 exits and a goto, does,
> was a challenge. I think I handle most of the main error cases (EEXIST,
> ENOSPC, EMLINK) sort of okay now (the "shrug and ignore" sort of
> exceptions are now caught, the rest are still propagated). I've also
> created guix/store/deduplication.scm, and moved the relevant stuff
> there. The tests pass to the same degree as before (2 failing, but
> neither of them are register-path).

Heheh.  :-)

> location: /home/reepca/Programming/guix/tests/store.scm:798
> source:
> + (test-assert
> +   "verify-store"
> +   (let* ((text (random-text))
> +          (file1 (add-text-to-store %store "foo" text))
> +          (file2 (add-text-to-store
> +                   %store
> +                   "bar"
> +                   (random-text)
> +                   (list file1))))
> +     (and (pk 'verify1 (verify-store %store))
> +          (begin
> +            (delete-file file1)
> +            (not (pk 'verify2 (verify-store %store))))
> +          (begin
> +            (call-with-output-file
> +              file1
> +              (lambda (port) (display text port)))
> +            (pk 'verify3 (verify-store %store))))))
> reading the Nix store...
> path 
> `/home/reepca/Programming/code-downloads/guix/test-tmp/store/000hh9y0f7i6x9jkhhc3wq1iln4lvwvy-guile-xcb-1.3-guile-builder'
>  is not in the Nix store
> actual-value: #f
> actual-error:
> + (srfi-34
> +   #<condition &nix-protocol-error [message: "executing SQLite statement: 
> FOREIGN KEY constraint failed" status: 1] 2d0dea0>)
> result: FAIL

The dreaded foreign key constraint!  Can you rerun the tests after “rm
-rf test-tmp”?  It might be that you somehow borked the database under
test-tmp while testing stuff.

> When I create a new module that directly incorporates code written by
> others (as in the case of moving reset-timestamps to (guix store
> deduplication)), should I add anything to the copyright notice at the
> top? Would that involve looking through the commit history to find
> exactly who wrote that?

Yes, try to preserve the relevant copyright lines (by looking at C-x v l
or C-x v g), and also remember to add a line for you when adding new

> I read HACKING - does the part about waiting two weeks for feedback on
> guix-patches before committing still apply to branches?

In your case (GSoC) you can go ahead.  We’ll probably review more
closely when we merge but that can be very quick if we’re already on the
same line of thought.

> I've now updated my savannah account with a key, used to sign this.

Though something went from with your email client.  :-)

What are your thoughts on the next steps?


reply via email to

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