GNU bug report logs - #69964
[PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.

Previous Next

Package: guix-patches;

Reported by: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>

Date: Sat, 23 Mar 2024 12:50:02 UTC

Severity: normal

Tags: patch

Done: Sharlatan Hellseher <sharlatanus <at> gmail.com>

To reply to this bug, email your comments to 69964 AT debbugs.gnu.org.
There is no need to reopen the bug first.

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#69964; Package guix-patches. (Sat, 23 Mar 2024 12:50:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 23 Mar 2024 12:50:03 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: guix-patches <at> gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sat, 23 Mar 2024 15:47:49 +0300
This patch series adds "go-multibase" package along with its dependencies.
The package is required for the newer Kubo (IPFS) versions.

Artyom V. Poptsov (4):
  gnu: Add go-github-com-multiformats-go-base32.
  gnu: Add go-github-com-multiformats-go-base36.
  gnu: Add go-github-com-multiformats-multibase.
  gnu: Add go-github-com-multiformats-go-multibase.

 gnu/packages/golang-xyz.scm | 110 ++++++++++++++++++++++++++++++++++++
 1 file changed, 110 insertions(+)


base-commit: f6f4c71df5558b168fe7a313522af7ea5fe2d0dc
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sat, 23 Mar 2024 12:57:02 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 3/4] gnu: Add go-github-com-multiformats-multibase.
Date: Sat, 23 Mar 2024 15:53:55 +0300
* gnu/packages/golang-xyz.scm (go-github-com-multiformats-multibase): New
  variable.

Change-Id: I5994e8f8927d5365cc201da30bd49abf03d17574
---
 gnu/packages/golang-xyz.scm | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index c5851cfa5f..d7fd50ae3d 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -1413,6 +1413,33 @@ (define-public go-github-com-multiformats-go-base36
      "Optimized codec for @code{[]byte} <=> @code{base36} string conversion.")
     (license (list license:asl2.0 license:expat))))
 
+(define-public go-github-com-multiformats-multibase
+  (let ((commit "4c8344e37852773de155f587dcf5897771b3fc19")
+        (revision "1"))
+    (package
+      (name "go-github-com-multiformats-multibase")
+      (version (git-version "0.0.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/multiformats/multibase")
+               (commit commit)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32 "0lz4kdysa6nx7wf1i59647w7dgm344xpvfnsac3pfk2qdky2kq8b"))))
+      (build-system copy-build-system)
+      (arguments
+       '(#:install-plan
+         '(("." "share/multibase/"))))
+      (home-page "https://github.com/multiformats/multibase")
+      (synopsis "Self identifying base encodings")
+      (description
+       "Multibase is a protocol for disambiguating the encoding of
+base-encoded (e.g., @code{base32}, @code{base36}, @code{base64}, @code{base58}, etc.)
+binary appearing in text.")
+      (license (list license:expat license:cc-by-sa3.0)))))
+
 (define-public go-github-com-multiformats-go-varint
   (package
     (name "go-github-com-multiformats-go-varint")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sat, 23 Mar 2024 12:57:03 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 4/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sat, 23 Mar 2024 15:53:56 +0300
* gnu/packages/golang-xyz.scm (go-github-com-multiformats-go-multibase): New
  variable.

Change-Id: If634f1497d628a23f2c2ebb1e8e9f6526faa3f3f
---
 gnu/packages/golang-xyz.scm | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index d7fd50ae3d..468359e2ef 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -1440,6 +1440,42 @@ (define-public go-github-com-multiformats-multibase
 binary appearing in text.")
       (license (list license:expat license:cc-by-sa3.0)))))
 
+(define-public go-github-com-multiformats-go-multibase
+  (package
+    (name "go-github-com-multiformats-go-multibase")
+    (version "0.2.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/multiformats/go-multibase")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "11za5yqiq9bkxfg0lvjzgr5d0kawkf2szxj90by9vfnalihqgkrr"))))
+    (build-system go-build-system)
+    (arguments
+     (list
+      #:go go-1.21
+      #:import-path "github.com/multiformats/go-multibase"
+      #:phases #~(modify-phases %standard-phases
+                   (add-after 'unpack 'copy-multibase-specs
+                     (lambda _
+                       (copy-recursively (string-append #$(this-package-native-input
+                                                           "go-github-com-multiformats-multibase")
+                                                        "/share/multibase/")
+                        "src/github.com/multiformats/go-multibase/spec"))))))
+    (native-inputs (list go-github-com-multiformats-multibase))
+    (inputs (list go-github-com-mr-tron-base58
+                  go-github-com-multiformats-go-base32
+                  go-github-com-multiformats-go-base36))
+    (home-page "https://github.com/multiformats/go-multibase")
+    (synopsis "Implementation of multibase parser in Go")
+    (description
+     "Implementation of @url{https://github.com/multiformats/multibase,
+multibase} (self identifying base encodings) in Go.")
+    (license license:expat)))
+
 (define-public go-github-com-multiformats-go-varint
   (package
     (name "go-github-com-multiformats-go-varint")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sat, 23 Mar 2024 13:03:02 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 2/4] gnu: Add go-github-com-multiformats-go-base36.
Date: Sat, 23 Mar 2024 15:53:54 +0300
* gnu/packages/golang-xyz.scm (go-github-com-multiformats-go-base36): New
  variable.

Change-Id: I27c5540fddae55ae9ce12a205d6f7f7c9a01569b
---
 gnu/packages/golang-xyz.scm | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index 5674004424..c5851cfa5f 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -1390,6 +1390,29 @@ (define-public go-github-com-multiformats-go-base32
      "@code{base32} encoding package from Go with @code{NoPadding} option")
     (license license:bsd-3)))
 
+(define-public go-github-com-multiformats-go-base36
+  (package
+    (name "go-github-com-multiformats-go-base36")
+    (version "0.2.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/multiformats/go-base36")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1wfhsmxkvm97pglfwgiw3ad5g9vqc9nhd61i0kyvsb9lc006g8qq"))))
+    (build-system go-build-system)
+    (arguments
+     (list
+      #:import-path "github.com/multiformats/go-base36"))
+    (home-page "https://github.com/multiformats/go-base36")
+    (synopsis "Optimized @code{base36} codec for Go")
+    (description
+     "Optimized codec for @code{[]byte} <=> @code{base36} string conversion.")
+    (license (list license:asl2.0 license:expat))))
+
 (define-public go-github-com-multiformats-go-varint
   (package
     (name "go-github-com-multiformats-go-varint")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sat, 23 Mar 2024 13:05:02 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 1/4] gnu: Add go-github-com-multiformats-go-base32.
Date: Sat, 23 Mar 2024 15:53:53 +0300
* gnu/packages/golang-xyz.scm (go-github-com-multiformats-go-base32): New
  variable.

Change-Id: If6c54a3c2d0a62e61e524da85c76ad6bf7f7bcbe
---
 gnu/packages/golang-xyz.scm | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/gnu/packages/golang-xyz.scm b/gnu/packages/golang-xyz.scm
index cf0b52a043..5674004424 100644
--- a/gnu/packages/golang-xyz.scm
+++ b/gnu/packages/golang-xyz.scm
@@ -40,6 +40,7 @@
 (define-module (gnu packages golang-xyz)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (guix build-system go)
+  #:use-module (guix build-system copy)
   #:use-module (guix gexp)
   #:use-module (guix git-download)
   #:use-module (guix packages)
@@ -1366,6 +1367,29 @@ (define-public go-github-com-mreiferson-go-svc
 @url{https://github.com/judwhite/go-svc/raw/master/svc/svc_windows_test.go,here}.")
       (license license:expat))))
 
+(define-public go-github-com-multiformats-go-base32
+  (package
+    (name "go-github-com-multiformats-go-base32")
+    (version "0.1.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/multiformats/go-base32")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "0ala6gaa5r5mqcg6cdwfg492hpz41cjbfwyn1ljd6qvya3n0qqiv"))))
+    (build-system go-build-system)
+    (arguments
+     (list
+      #:import-path "github.com/multiformats/go-base32"))
+    (home-page "https://github.com/multiformats/go-base32")
+    (synopsis "Go @code{base32} encoding package with @code{NoPadding} option")
+    (description
+     "@code{base32} encoding package from Go with @code{NoPadding} option")
+    (license license:bsd-3)))
+
 (define-public go-github-com-multiformats-go-varint
   (package
     (name "go-github-com-multiformats-go-varint")
-- 
2.41.0





Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sat, 23 Mar 2024 20:17:02 GMT) Full text and rfc822 format available.

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

From: Sharlatan Hellseher <sharlatanus <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
Subject: [PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sat, 23 Mar 2024 20:14:20 +0000
[Message part 1 (text/plain, inline)]
Hi,

Thank you for the patches.

I started the review process.

Did you check a better place in gnu/packages for this one
https://github.com/multiformats/multibase?tab=readme-ov-file#implementations

It looks like a map of formats and the implementations may be not just in
golang.

Check encoding module and consider to name it lees package specific.

Thanks,
Oleg
[Message part 2 (text/html, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sun, 24 Mar 2024 13:06:01 GMT) Full text and rfc822 format available.

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

From: "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>
To: Sharlatan Hellseher <sharlatanus <at> gmail.com>
Cc: 69964 <at> debbugs.gnu.org
Subject: Re: [PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sun, 24 Mar 2024 16:03:56 +0300
[Message part 1 (text/plain, inline)]
Hello Oleg!

> I started the review process.

Great, thanks!

> Did you check a better place in gnu/packages for this one
> https://github.com/multiformats/multibase?tab=readme-ov-file#implementations
>
> It looks like a map of formats and the implementations may be not just in golang.

Yes, I saw this.  I just wasn't sure what module to use for the
"multibase" package.

> Check encoding module and consider to name it lees package specific.

Should I create "encodings.scm"?  Or maybe "specs.scm" is a better name
for it?  Because if there will be need for other protocol/format
specifications we can place the packages to "specs.scm".

Also what is the proper way to update the patch series?

Thanks!

- avp

-- 
Artyom "avp" Poptsov <poptsov.artyom <at> gmail.com>
Home page: https://memory-heap.org/~avp/
CADR Hackerspace co-founder: https://cadrspace.ru/
GPG: D0C2 EAC1 3310 822D 98DE  B57C E9C5 A2D9 0898 A02F
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#69964; Package guix-patches. (Sun, 24 Mar 2024 21:07:01 GMT) Full text and rfc822 format available.

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

From: Sharlatan Hellseher <sharlatanus <at> gmail.com>
To: 69964 <at> debbugs.gnu.org
Cc: Artyom avp Poptsov <poptsov.artyom <at> gmail.com>
Subject: [PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sun, 24 Mar 2024 21:04:46 +0000
[Message part 1 (text/plain, inline)]
Hi,

I've checked https://github.com/multiformats, and it looks like a very
nice project which is in use by others large ones:

- IPFS https://ipfs.tech/
- CIDs https://github.com/multiformats/cid
- libp2p https://github.com/libp2p/libp2p
- IPLD https://github.com/ipld/ipld

> Should I create "encodings.scm"?  Or maybe "specs.scm" is a better name
> for it?  Because if there will be need for other protocol/format
> specifications we can place the packages to "specs.scm".

I'm not quite sure what to answer here, after a brief check of any
relevant modules. I've only found that there are only language specific
*-base* packages.

I'll give it another round to find some appropriate place for
specification distributed as CSV file from
<https://github.com/multiformats/multibase>, or we may ping someone else
from core/mentor team.

Based on the project's check, they provide verity language
implementations e.g. in Rust, Python, Go, Java, JavaScript so having
spec file in golang-*.scm is not the best place.

> Also what is the proper way to update the patch series?

I can't suggest any tooling, just describe my common flow.

I usually create patches on my local Guix checkout branch e.g.
'local/astro-update' and I use Emacs's Magit. If I need new patch series
I pull all, rebase on master select amended/update commits and place
new version prefix.

In short, use the same commit headers but add prefix 'PATCH v2' which
will be identified nicely by QA and the patch series may be obtained
much easily.

--
Oleg
[signature.asc (application/pgp-signature, inline)]

Reply sent to Sharlatan Hellseher <sharlatanus <at> gmail.com>:
You have taken responsibility. (Sat, 06 Apr 2024 22:41:02 GMT) Full text and rfc822 format available.

Notification sent to "Artyom V. Poptsov" <poptsov.artyom <at> gmail.com>:
bug acknowledged by developer. (Sat, 06 Apr 2024 22:41:03 GMT) Full text and rfc822 format available.

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

From: Sharlatan Hellseher <sharlatanus <at> gmail.com>
To: 69964-done <at> debbugs.gnu.org
Subject: [PATCH 0/4] gnu: Add go-github-com-multiformats-go-multibase.
Date: Sat, 06 Apr 2024 23:40:36 +0100
[Message part 1 (text/plain, inline)]
Closing this as resolved based on <https://issues.guix.gnu.org/70234>.

--
Oleg
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 27 days ago.

Previous Next


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