[bug#34449] gnu: Add trydiffoscope.

Message ID 87wom53gij.fsf@ponder
State Accepted
Headers show
Series [bug#34449] gnu: Add trydiffoscope. | expand

Checks

Context Check Description
cbaines/applying patch fail Apply failed

Commit Message

Vagrant Cascadian Feb. 12, 2019, 2:08 a.m. UTC
* gnu/packages/package-management (trydiffoscope): New variable.
---
 gnu/packages/package-management.scm | 44 +++++++++++++++++++++++++++++
 1 file changed, 44 insertions(+)

Comments

Julien Lepiller Feb. 12, 2019, 7:31 a.m. UTC | #1
Le 12 février 2019 03:08:36 GMT+01:00, Vagrant Cascadian <vagrant@reproducible-builds.org> a écrit :
>
>* gnu/packages/package-management (trydiffoscope): New variable.
>---
> gnu/packages/package-management.scm | 44 +++++++++++++++++++++++++++++
> 1 file changed, 44 insertions(+)
>
>diff --git a/gnu/packages/package-management.scm
>b/gnu/packages/package-management.scm
>index 587d028d92..49208e3191 100644
>--- a/gnu/packages/package-management.scm
>+++ b/gnu/packages/package-management.scm
>@@ -606,6 +606,50 @@ various binary formats into more human readable
>forms to compare them.  It can
> compare two tarballs, ISO images, or PDFs just as easily.")
>     (license license:gpl3+)))
> 
>+(define-public trydiffoscope
>+ (package
>+   (name "trydiffoscope")
>+   (version "67.0.1")
>+   (source
>+    (origin
>+      (method git-fetch)
>+      (uri (git-reference
>+            (url
>"https://salsa.debian.org/reproducible-builds/trydiffoscope.git")
>+            (commit version)))
>+      (file-name (git-file-name name version))
>+      (sha256
>+       (base32
>+        "03b66cjii7l2yiwffj6ym6mycd5drx7prfp4j2550281pias6mjh"))))
>+    (arguments
>+     `(#:phases
>+       (modify-phases %standard-phases
>+         (add-after 'install 'install-doc
>+           (lambda* (#:key outputs #:allow-other-keys)
>+             (let* ((share (string-append (assoc-ref outputs "out")
>"/usr/share/")))
>+               (mkdir-p (string-append share "/man/man1/" ))
>+               (invoke "rst2man.py"
>+                       "trydiffoscope.1.rst"
>+                       (string-append share
>"/man/man1/trydiffoscope.1"))
>+               (mkdir-p (string-append share "/doc/" ,name "-"
>,version))
>+               (install-file "./README.rst"
>+                          (string-append share "/doc/" ,name "-"
>,version))))))))
>+    (native-inputs
>+     `(("gzip" ,gzip)
>+       ("python-docutils" ,python-docutils)))
>+    (build-system python-build-system)
>+    (home-page "https://try.diffoscope.org")
>+    (synopsis "Compare files and archives in depth")
>+    (description
>+     "This is a minimal diffoscope client that connects to the
>service:
>+
>+https://try.diffoscope.org.
>+
>+Diffoscope tries to get to the bottom of what makes files or
>directories
>+different.  It recursively unpacks archives of many kinds and
>transforms
>+various binary formats into more human readable forms to compare them.
> It can
>+compare two tarballs, ISO images, or PDFs just as easily.")
>+    (license license:gpl3+)))
>+
> (define-public python-anaconda-client
>   (package
>     (name "python-anaconda-client")

Hi,

Iiuc, this is a client to connect to a service that runs diffoscope for you. But we already have diffoscope, so what's the point? Also this looks like saass to me, so I think we should refrain from adding it to guix. What do you think?
Vagrant Cascadian Feb. 12, 2019, 8:16 a.m. UTC | #2
On 2019-02-12, Julien Lepiller wrote:
> Le 12 février 2019 03:08:36 GMT+01:00, Vagrant Cascadian <vagrant@reproducible-builds.org> a écrit :
>>
>>* gnu/packages/package-management (trydiffoscope): New variable.
...
>>+    (synopsis "Compare files and archives in depth")
>>+    (description
>>+     "This is a minimal diffoscope client that connects to the
>>service:
>>+
>>+https://try.diffoscope.org.
>>+
>>+Diffoscope tries to get to the bottom of what makes files or
>>directories
>>+different.  It recursively unpacks archives of many kinds and
>>transforms
>>+various binary formats into more human readable forms to compare them.
>> It can
>>+compare two tarballs, ISO images, or PDFs just as easily.")
>>+    (license license:gpl3+)))
>>+
>> (define-public python-anaconda-client
>>   (package
>>     (name "python-anaconda-client")

> Iiuc, this is a client to connect to a service that runs diffoscope
> for you. But we already have diffoscope, so what's the point?

Yes, that's the jist of it.  The main advantage is that it has a much
smaller dependency chain locally.

I find it useful on some of the not-particularly-fast ARM systems I've
been running GNU Guix, where storage may be limited or slow, and
substitutes may not be available as often, and build times
are... remarkable.


> Also this looks like saass to me, so I think we should refrain from
> adding it to guix.

It is essentially SaaSS.  The server-side is at least licensed under the
AGPL, if that mitigates concerns somewhat.

I'm not sure it supports it out of the box yet, but I suspect upstream
would be amenable to patches to make it easy for people to run their own
"diffoscope" services.


> What do you think?

I thought it was useful enough to be worth submitting, though I'd
understand if it's deemed inappropriate for GNU Guix. Still learning the
ropes. :)


live well,
  vagrant
Julien Lepiller Feb. 12, 2019, 9:34 a.m. UTC | #3
Le 2019-02-12 09:16, Vagrant Cascadian a écrit :
> 
>> Iiuc, this is a client to connect to a service that runs diffoscope
>> for you. But we already have diffoscope, so what's the point?
> 
> Yes, that's the jist of it.  The main advantage is that it has a much
> smaller dependency chain locally.
> 
> I find it useful on some of the not-particularly-fast ARM systems I've
> been running GNU Guix, where storage may be limited or slow, and
> substitutes may not be available as often, and build times
> are... remarkable.
> 
> 
>> Also this looks like saass to me, so I think we should refrain from
>> adding it to guix.
> 
> It is essentially SaaSS.  The server-side is at least licensed under 
> the
> AGPL, if that mitigates concerns somewhat.
> 
> I'm not sure it supports it out of the box yet, but I suspect upstream
> would be amenable to patches to make it easy for people to run their 
> own
> "diffoscope" services.
> 
> 
>> What do you think?
> 
> I thought it was useful enough to be worth submitting, though I'd
> understand if it's deemed inappropriate for GNU Guix. Still learning 
> the
> ropes. :)
> 
> 
> live well,
>   vagrant

I'm not completely sure either, that's why I was asking for a second 
opinion ;)
Leo Famulari Feb. 12, 2019, 8:37 p.m. UTC | #4
On Tue, Feb 12, 2019 at 12:16:42AM -0800, Vagrant Cascadian wrote:
> On 2019-02-12, Julien Lepiller wrote:
> >>+    (synopsis "Compare files and archives in depth")

This synopsis doesn't make clear that this is a client for a remote
service. Can you rewrite it?

> >>+    (description
> >>+     "This is a minimal diffoscope client that connects to the
> >>service:

Also, I think it's better to replace "diffoscope client" with something
like "client for the remote diffoscope service located at [...]" since
diffoscope is not inherently a client-service tool. Also it would be
great to mention the full diffoscope package :)

Can you send an updated patch?

> > Iiuc, this is a client to connect to a service that runs diffoscope
> > for you. But we already have diffoscope, so what's the point?
> 
> Yes, that's the jist of it.  The main advantage is that it has a much
> smaller dependency chain locally.
> 
> I find it useful on some of the not-particularly-fast ARM systems I've
> been running GNU Guix, where storage may be limited or slow, and
> substitutes may not be available as often, and build times
> are... remarkable.

Yes, and diffoscope runs can also be really expensive. It's nice to
offload them.

Also, if the service makes statements about whether submissions are
logged or made public, can you put that in the package description?

> > Also this looks like saass to me, so I think we should refrain from
> > adding it to guix.
> 
> It is essentially SaaSS.  The server-side is at least licensed under the
> AGPL, if that mitigates concerns somewhat.
> 
> I'm not sure it supports it out of the box yet, but I suspect upstream
> would be amenable to patches to make it easy for people to run their own
> "diffoscope" services.
> 
> 
> > What do you think?

We can have SaaSS in Guix. There are already some packages that are
SaaSS. So I think this package is okay.

It's "extra okay" in my opinion since the service is AGPL, part of
Debian, and we have a package for the tool in question.

Guix is developed under the Free System Distribution Guidelines, which
don't mention remote services or SaaSS at all:

https://www.gnu.org/distros/free-system-distribution-guidelines.en.html

And some discussion on the subject of services in the context of free
software that largely reflect how we handle SaaSS in Guix:

https://www.gnu.org/philosophy/network-services-arent-free-or-nonfree.en.html
Julien Lepiller Feb. 13, 2019, 8:05 a.m. UTC | #5
Le 12 février 2019 21:37:42 GMT+01:00, Leo Famulari <leo@famulari.name> a écrit :
>On Tue, Feb 12, 2019 at 12:16:42AM -0800, Vagrant Cascadian wrote:
>> On 2019-02-12, Julien Lepiller wrote:
>> >>+    (synopsis "Compare files and archives in depth")
>
>This synopsis doesn't make clear that this is a client for a remote
>service. Can you rewrite it?
>
>> >>+    (description
>> >>+     "This is a minimal diffoscope client that connects to the
>> >>service:
>
>Also, I think it's better to replace "diffoscope client" with something
>like "client for the remote diffoscope service located at [...]" since
>diffoscope is not inherently a client-service tool. Also it would be
>great to mention the full diffoscope package :)
>
>Can you send an updated patch?
>
>> > Iiuc, this is a client to connect to a service that runs diffoscope
>> > for you. But we already have diffoscope, so what's the point?
>> 
>> Yes, that's the jist of it.  The main advantage is that it has a much
>> smaller dependency chain locally.
>> 
>> I find it useful on some of the not-particularly-fast ARM systems
>I've
>> been running GNU Guix, where storage may be limited or slow, and
>> substitutes may not be available as often, and build times
>> are... remarkable.
>
>Yes, and diffoscope runs can also be really expensive. It's nice to
>offload them.
>
>Also, if the service makes statements about whether submissions are
>logged or made public, can you put that in the package description?
>
>> > Also this looks like saass to me, so I think we should refrain from
>> > adding it to guix.
>> 
>> It is essentially SaaSS.  The server-side is at least licensed under
>the
>> AGPL, if that mitigates concerns somewhat.
>> 
>> I'm not sure it supports it out of the box yet, but I suspect
>upstream
>> would be amenable to patches to make it easy for people to run their
>own
>> "diffoscope" services.
>> 
>> 
>> > What do you think?
>
>We can have SaaSS in Guix. There are already some packages that are
>SaaSS. So I think this package is okay.
>
>It's "extra okay" in my opinion since the service is AGPL, part of
>Debian, and we have a package for the tool in question.
>
>Guix is developed under the Free System Distribution Guidelines, which
>don't mention remote services or SaaSS at all:
>
>https://www.gnu.org/distros/free-system-distribution-guidelines.en.html
>
>And some discussion on the subject of services in the context of free
>software that largely reflect how we handle SaaSS in Guix:
>
>https://www.gnu.org/philosophy/network-services-arent-free-or-nonfree.en.html

Thanks for the links!

Patch

diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm
index 587d028d92..49208e3191 100644
--- a/gnu/packages/package-management.scm
+++ b/gnu/packages/package-management.scm
@@ -606,6 +606,50 @@  various binary formats into more human readable forms to compare them.  It can
 compare two tarballs, ISO images, or PDFs just as easily.")
     (license license:gpl3+)))
 
+(define-public trydiffoscope
+ (package
+   (name "trydiffoscope")
+   (version "67.0.1")
+   (source
+    (origin
+      (method git-fetch)
+      (uri (git-reference
+            (url "https://salsa.debian.org/reproducible-builds/trydiffoscope.git")
+            (commit version)))
+      (file-name (git-file-name name version))
+      (sha256
+       (base32
+        "03b66cjii7l2yiwffj6ym6mycd5drx7prfp4j2550281pias6mjh"))))
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-after 'install 'install-doc
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((share (string-append (assoc-ref outputs "out") "/usr/share/")))
+               (mkdir-p (string-append share "/man/man1/" ))
+               (invoke "rst2man.py"
+                       "trydiffoscope.1.rst"
+                       (string-append share "/man/man1/trydiffoscope.1"))
+               (mkdir-p (string-append share "/doc/" ,name "-" ,version))
+               (install-file "./README.rst"
+                          (string-append share "/doc/" ,name "-" ,version))))))))
+    (native-inputs
+     `(("gzip" ,gzip)
+       ("python-docutils" ,python-docutils)))
+    (build-system python-build-system)
+    (home-page "https://try.diffoscope.org")
+    (synopsis "Compare files and archives in depth")
+    (description
+     "This is a minimal diffoscope client that connects to the service:
+
+https://try.diffoscope.org.
+
+Diffoscope tries to get to the bottom of what makes files or directories
+different.  It recursively unpacks archives of many kinds and transforms
+various binary formats into more human readable forms to compare them.  It can
+compare two tarballs, ISO images, or PDFs just as easily.")
+    (license license:gpl3+)))
+
 (define-public python-anaconda-client
   (package
     (name "python-anaconda-client")