gddo icon indicating copy to clipboard operation
gddo copied to clipboard

Subdirectories are not listed when using an import path comment

Open arp242 opened this issue 7 years ago • 3 comments

https://godoc.org/github.com/carpetsmoker/test doesn't list all the subdirectories (there should be a, b, and c), only a, which I manually visited at https://godoc.org/github.com/carpetsmoker/test/a

It doesn't list b either, even though that is referenced in https://github.com/carpetsmoker/test

It seems to work as expected if I don't add an import path comment:

package a // import "github.com/carpetsmoker/a"

Note that this is probably not related to the recent change in #560; I had the same issue with arp242.net/sconfig last year (which I fixed by manually loading all the packages, I didn't investigate in detail back then). It also has the same problem again with a new directory I added handlers/html/template (which doesn't show up).

Related issues: #529, #268

arp242 avatar Aug 31 '18 15:08 arp242

I'm seeing a, b, and c at https://godoc.org/github.com/carpetsmoker/test now.

It's expected that subdirectories might take a while to show up, even if referenced by other code. They show up when the crawler gets around to the new repository. They show up immediately when visited directly.

dmitshur avatar Sep 05 '18 19:09 dmitshur

Hm, not sure why those show now.

I have several examples that are not being updated at all though; for example:

  • https://godoc.org/github.com/teamwork/utils – doesn't show several subdirs; those that it does show are those thatI manually loaded.
  • https://godoc.org/arp242.net/sconfig – doesn't show the handlers/html/template directory that I added in June. I clicked "Refresh now" five days ago and today, but doesn't show.

arp242 avatar Sep 05 '18 19:09 arp242

It's possible the crawler can't navigate the subdirectories because the GitHub canonical case doesn't match the import path comment (just a hypothesis; I haven't verified). As a workaround, you can explicitly visit the doc page for packages that are missing to get them to show up.

https://arp242.net/sconfig/handlers/html/template is 404, which is why docs for that package cannot be fetched.

dmitshur avatar Sep 05 '18 22:09 dmitshur