GNU bug report logs - #62202
[PATCH 0/21] Juliahub import script.

Previous Next

Package: guix-patches;

Reported by: Nicolas Graves <ngraves <at> ngraves.fr>

Date: Wed, 15 Mar 2023 12:49:01 UTC

Severity: normal

Tags: moreinfo, patch

Full log


View this message in rfc822 format

From: Ludovic Courtès <ludo <at> gnu.org>
To: Nicolas Graves <ngraves <at> ngraves.fr>
Cc: zimoun.toutoune <at> gmail.com, 62202 <at> debbugs.gnu.org
Subject: [bug#62202] [PATCH v4 6/6] tests: juliahub: Add unit tests for (guix import juliahub).
Date: Tue, 16 Apr 2024 18:52:10 +0200
Hi,

Nicolas Graves <ngraves <at> ngraves.fr> skribis:

> I'm currently writing it, it'll result in a handy helper for tests, such
> as :
>
> (with-git-forge  ; spawns a dumb but functional git server
>       '(("MyPackage" . ((add "a.txt" "A")
>                         (commit "First commit")
>                         (tag "v1.0.0" "Release 1.0"))))
>     (with-julia-test-servers
>         `(("/juliahub/MyPackage/" 200 ,juliahub-redirect.html)
>           ("/juliahub/MyPackage/" 200 ,juliahub-redirect.html)
>           ("/juliahub/MyPackage/MySlg/1.0.0/pkg.json" 200
>            ,(lambda (port) (display (fixture-pkg.json) port)))
>           ("/general/M/MyPackage/Package.toml" 200
>            ,(lambda (port) (display (pk 'd (general-Package.toml)) port))))
>       (juliahub->guix-package "MyPackage")))

Nice!

> However, for that I'll need the http server to be able to respond with a
>          (content-type . (application/x-git-upload-pack-advertisement))
> header to git. But in guile's web server implementation, this is not
> possible because of sanitize-response's charset addition, which is not
> configurable. 

D’oh.  I’m not sure what this is about; it’s definitely possible to add
pretty much any ‘content-type’ header (we do that in ‘guix publish’ for
instance), but if it’s going too far, then maybe you should go back to
procedure mocks.

> That's outside my field, how can we progress further ? We do indeed need
> such a server to properly test juliahub since we go get the tag from the
> actual repo (this is justified in the patch series).
>
> _____________________________________________________________________________
> ;;; Git Forge = Git HTTP Server with Dump transfer protocol and repositories

This work’s not lost: we can definitely switch back to it when the
limitations you encountered has been fixed on the Guile side, and/or in
other, simpler cases.

Thanks!

Ludo’.




This bug report was last modified 1 year and 55 days ago.

Previous Next


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