Subject: Re: bug#49228: guix import go fails when module does not have a documenation on pkg.go.dev

From: Sarah Morgensen <[email-masked]>
Date: Wed, 30 Jun 2021 21:18:09 -0700

Hi,

raingloom <[email-masked]> writes:

>> If you look at the page
>> 
>> https://pkg.go.dev/github.com/caspr-io/yamlpath
>> 
>> It has no Description, because the site cannot parse license
>> information correctly and thus conservatively does not display any
>> info.
>
> Could we use godocs.io? It's more copyleft friendly AFAIK.
> But that's just hearsay, I'm only getting into Go now, so idk much
> about the services surrouding it yet.

Right now the information from pkg.go.dev is used to populate the package's
  * synopsis
  * description, and
  * license
sections.

As far as I can tell, godocs.io does not have any information about the
package's license... *eventually* we may want to consider writing a
license guesser of our own, as that could potentially be useful across
all of Guix.

As for description, godocs.io seems to collects description information
differently (inferiorly?) than pkg.go.dev. For example, compare:

  https://godocs.io/github.com/mitchellh/go-homedir
  https://pkg.go.dev/github.com/mitchellh/go-homedir

I wonder how complicated it would be to guess at a synopsis/description
ourselves? It may be worth asking the initial committers of the go
importer.

--
Sarah