NixOS: (help map) does not find documentation

63 views
Skip to first unread message

unlimitedscolobb

unread,
Apr 14, 2020, 6:53:09 PM4/14/20
to Racket Users
Hello,

I noticed the following behaviour today:

> (require racket/help)
> (help map)
Loading help index...
; help: no documentation found for: map provided by: "/nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/collects/racket/base.rkt"
; Context:
;  /nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/collects/racket/repl.rkt:11:26

Also, weirdly:

```
my-test.rkt> (help)
Sending to web browser...
  file: /nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/doc/index.html
```

Turns out this file does not even exist on my machine, but /nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/share/doc/index.html does!  (mind the added share/)

I'm running Racket 7.6 and I am on nixos-unstable channel.

Does any one of you have similar symptoms?

For the reference, I ran into this problem with Greg Hendershott's help: https://github.com/greghendershott/racket-mode/issues/446

-
Sergiu

Asumu Takikawa

unread,
Apr 15, 2020, 6:42:46 PM4/15/20
to Racket Users
On 2020-04-14 15:53:09 -0700, unlimitedscolobb wrote:
> Turns out this file does not even exist on my machine, but
> /nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/share/doc/index.html
> does!  (mind the added share/)
>
> I'm running Racket 7.6 and I am on nixos-unstable channel.
>
> Does any one of you have similar symptoms?

I suspect this is because of a packaging bug in Racket that changes
where things get installed:

https://github.com/racket/racket/issues/3046

You should be able to work around this by adjusting the configure flags
for the Racket Nix package. Here's a commit for nixpkgs that should do
that:

https://github.com/takikawa/nixpkgs/commit/b766b42f0a2f79f19f9e73f46264f91ba6cb3bdd

When I built this locally, `(help map)` and such seemed to work for me.

If someone can land a fix for #3046 for Racket 7.7, that'd be really
great. This bug also affects the packaging for Debian, Ubuntu PPA (these
shipped with the workaround) and probably other distros too.

Cheers,
Asumu

unlimitedscolobb

unread,
Apr 16, 2020, 8:19:26 AM4/16/20
to Racket Users
Hi Asumu and great thanks for your answer!


On Thursday, April 16, 2020 at 12:42:46 AM UTC+2, asumu wrote:
On 2020-04-14 15:53:09 -0700, unlimitedscolobb wrote:
>    Turns out this file does not even exist on my machine, but
>    /nix/store/za0k7s00bg3v5sasyqalv12ii7pxjbjn-racket-7.6/share/doc/index.html
>    does!  (mind the added share/)
>
>    I'm running Racket 7.6 and I am on nixos-unstable channel.
>
>    Does any one of you have similar symptoms?

I suspect this is because of a packaging bug in Racket that changes
where things get installed:

  https://github.com/racket/racket/issues/3046

You should be able to work around this by adjusting the configure flags
for the Racket Nix package. Here's a commit for nixpkgs that should do
that:

  https://github.com/takikawa/nixpkgs/commit/b766b42f0a2f79f19f9e73f46264f91ba6cb3bdd

When I built this locally, `(help map)` and such seemed to work for me.
 
That's excellent, thank you very much!  I'll test that locally in a moment.
 
If someone can land a fix for #3046 for Racket 7.7, that'd be really
great. This bug also affects the packaging for Debian, Ubuntu PPA (these
shipped with the workaround) and probably other distros too.



Would you mind submitting a PR from your `racket-enable-useprefix` branch?

If you don't have time, I can handle that as well, but it's probably best that it comes from you.

-
Sergiu

Cheers,
Asumu

Asumu Takikawa

unread,
Apr 16, 2020, 1:48:35 PM4/16/20
to Racket Users
On 2020-04-16 05:19:26 -0700, unlimitedscolobb wrote:
> I started a discussion on NixOS Discourse here:
> https://discourse.nixos.org/t/racket-does-not-find-documentation-after-update/
> Would you mind submitting a PR from your `racket-enable-useprefix` branch?
> If you don't have time, I can handle that as well, but it's probably best
> that it comes from you.

No problem, and thanks for testing it! I submitted a PR here:

https://github.com/NixOS/nixpkgs/pull/85385

Cheers,
Asumu

unlimitedscolobb

unread,
Apr 17, 2020, 7:09:32 AM4/17/20
to Racket Users
Cool, thank you!  I made some noise on the PR and on the corresponding thread on Discourse, let's hope your change gets merged soon.

-
Sergiu
 

Cheers,
Asumu
Reply all
Reply to author
Forward
0 new messages