unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: zimoun <zimon.toutoune@gmail.com>
Cc: 45615@debbugs.gnu.org, Hartmut Goebel <h.goebel@crazy-compilers.com>
Subject: bug#45615: SWH API break?
Date: Mon, 11 Jan 2021 14:12:14 +0100	[thread overview]
Message-ID: <87a6tffwi9.fsf@gnu.org> (raw)
In-Reply-To: <CAJ3okZ1Js7xMVZJ+dQVdmRUKM34++_+3Tha8HPfg-S8ngtKU4g@mail.gmail.com> (zimoun's message of "Thu, 7 Jan 2021 16:41:46 +0100")

Hi!

zimoun <zimon.toutoune@gmail.com> skribis:

> It comes from 'visit-snapshot-url' returning #<unspecified> instead of
> #f.  Then 'swh-url' fails because the 'path' argument is not a string.
>
> Well, I do not how to fix it.  I am confused by:
>
> ;; <https://archive.softwareheritage.org/api/1/origin/52181937/visits/>
> (define-json-mapping <visit> make-visit visit?
>   json->visit
>   (date visit-date "date" string->date*)
>   (origin visit-origin)
>   (url visit-url "origin_visit_url")
>   (snapshot-url visit-snapshot-url "snapshot_url" string*) ;string | #f
>   (status visit-status "status" string->symbol)   ;'full | 'partial | 'ongoing
>   (number visit-number "visit"))
>
> and why it is not string or #f.

As discussed on IRC the other day, the culprit seems to be the recent
guile-json upgrade (from 4.3.2 to 4.4.1, commit
f9e1baa8933ea2ed385d0272dbfbe4e22f192bde).

Were you able to check the raw JSON and see where the value is getting
lost?

Thanks,
Ludo’.




  reply	other threads:[~2021-01-11 13:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-02 22:14 bug#45615: Wrong type argument in "guix lint -c archival" Hartmut Goebel
2021-01-07 15:41 ` bug#45615: SWH API break? zimoun
2021-01-11 13:12   ` Ludovic Courtès [this message]
2021-01-11 14:45     ` zimoun
2021-01-11 15:16       ` Ludovic Courtès
2021-01-14 11:09       ` Ludovic Courtès
2021-01-21 10:25         ` bug#45615: Wrong type argument in "guix lint -c archival" Ludovic Courtès
2021-01-16 16:59 ` Aleix via web
2021-01-21 10:27   ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a6tffwi9.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=45615@debbugs.gnu.org \
    --cc=h.goebel@crazy-compilers.com \
    --cc=zimon.toutoune@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).