unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: "Timo Wilken" <guix@twilken.net>
To: 63001@debbugs.gnu.org
Subject: bug#63001: Go importer doesn't know MODULE/vX.Y version tags
Date: Fri, 21 Apr 2023 19:39:53 +0200	[thread overview]
Message-ID: <CS2M99VHXHVN.WOF38A5PXLE9@lap.twilken.net> (raw)

Some Golang repositories apparently use a tagging scheme where each
submodule in the repo gets its own tags.

In this case, the example is cloud.google.com/go and its submodules
(hosted at https://github.com/googleapis/google-cloud-go).

For example, for the cloud.google.com/go/longrunning submodule at
version 0.4.1, the Go importer should look for a tag called
"refs/tags/longrunning/v0.4.1" in the Git repository.

#+begin_example
$ guix import go -r cloud.google.com/go/longrunning
Backtrace:
          19 (primitive-load "/home/timo/.config/guix/current/bin/gu…")
In guix/ui.scm:
   2300:7 18 (run-guix . _)
  2263:10 17 (run-guix-command _ . _)
In guix/scripts/import.scm:
    89:11 16 (guix-import . _)
In ice-9/boot-9.scm:
  1752:10 15 (with-exception-handler _ _ #:unwind? _ # _)
In guix/scripts/import/go.scm:
   114:22 14 (_)
In guix/import/utils.scm:
   638:27 13 (recursive-import _ #:repo->guix-package _ #:guix-name . #)
   630:33 12 (lookup-node "cloud.google.com/go/longrunning" #f)
In guix/memoization.scm:
     98:0 11 (mproc "cloud.google.com/go/longrunning" # #<procedure…> …)
In unknown file:
          10 (_ #<procedure 7fb3e173c820 at guix/memoization.scm:17…> …)
In guix/import/go.scm:
   685:10  9 (_ _ #:version _ #:repo _)
In ice-9/exceptions.scm:
   406:15  8 (go-module->guix-package* . _)
In ice-9/boot-9.scm:
  1752:10  7 (with-exception-handler _ _ #:unwind? _ # _)
In guix/import/go.scm:
   511:19  6 (go-module->guix-package "cloud.google.com/go/longrunn…" …)
In guix/git.scm:
    291:4  5 (update-cached-checkout _ #:ref _ #:recursive? _ # _ # _ …)
   277:19  4 (resolve _)
In git/reference.scm:
     60:8  3 (_ _ _)
In git/bindings.scm:
     77:2  2 (raise-git-error _)
In ice-9/boot-9.scm:
  1685:16  1 (raise-exception _ #:continuable? _)
  1683:16  0 (raise-exception _ #:continuable? _)

ice-9/boot-9.scm:1683:16: In procedure raise-exception:
Git error: reference 'refs/tags/v0.4.1' not found
#+end_example

The same is true for other modules, e.g.
github.com/Azure/azure-sdk-for-go/sdk/internal, where the tag is
called "refs/tags/sdk/internal/v1.3.0" instead:

#+begin_example
$ guix import go -r github.com/Azure/azure-sdk-for-go/sdk/internal
Backtrace:
          19 (primitive-load "/home/timo/.config/guix/current/bin/gu…")
In guix/ui.scm:
   2300:7 18 (run-guix . _)
  2263:10 17 (run-guix-command _ . _)
In guix/scripts/import.scm:
    89:11 16 (guix-import . _)
In ice-9/boot-9.scm:
  1752:10 15 (with-exception-handler _ _ #:unwind? _ # _)
In guix/scripts/import/go.scm:
   114:22 14 (_)
In guix/import/utils.scm:
   638:27 13 (recursive-import _ #:repo->guix-package _ #:guix-name . #)
   630:33 12 (lookup-node "github.com/Azure/azure-sdk-for-go/sdk/in…" …)
In guix/memoization.scm:
     98:0 11 (mproc "github.com/Azure/azure-sdk-for-go/sdk/internal" …)
In unknown file:
          10 (_ #<procedure 7fa449ec0300 at guix/memoization.scm:17…> …)
In guix/import/go.scm:
   685:10  9 (_ _ #:version _ #:repo _)
In ice-9/exceptions.scm:
   406:15  8 (go-module->guix-package* . _)
In ice-9/boot-9.scm:
  1752:10  7 (with-exception-handler _ _ #:unwind? _ # _)
In guix/import/go.scm:
   511:19  6 (go-module->guix-package "github.com/Azure/azure-sdk-f…" …)
In guix/git.scm:
    291:4  5 (update-cached-checkout _ #:ref _ #:recursive? _ # _ # _ …)
   277:19  4 (resolve _)
In git/reference.scm:
     60:8  3 (_ _ _)
In git/bindings.scm:
     77:2  2 (raise-git-error _)
In ice-9/boot-9.scm:
  1685:16  1 (raise-exception _ #:continuable? _)
  1683:16  0 (raise-exception _ #:continuable? _)

ice-9/boot-9.scm:1683:16: In procedure raise-exception:
Git error: reference 'refs/tags/v1.3.0' not found
#+end_example




                 reply	other threads:[~2023-04-24  6:08 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=CS2M99VHXHVN.WOF38A5PXLE9@lap.twilken.net \
    --to=guix@twilken.net \
    --cc=63001@debbugs.gnu.org \
    /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).