[racket] DrRacket package suggestions

From: Robby Findler (robby at eecs.northwestern.edu)
Date: Mon May 5 12:35:37 EDT 2014

DrRacket will now offer to update your package catalog for you when
there is a missing-module exn and no suggestions (via the check syntax
error message line and always via the error message printout in the
repl). Hopefully that's a bit better than what we had before.

Robby

On Sat, May 3, 2014 at 12:24 AM, Asumu Takikawa <asumu at ccs.neu.edu> wrote:
> On 2014-05-02 16:53:31 -0500, Robby Findler wrote:
>> I'm not sure either, but it is the exn:missing-module? and
>> exn:missing-module-accessor functions that are supposed to be
>> conveying the information. So trying to find a program that should
>> work with those functions (but doesn't) is probably the place to
>> start.
>
> I think the issue may be that the call to
> `pkg-catalog-suggestions-for-module` to get the actual suggestions
> always returns an empty list for me.
>
> This is when expanding a program like:
>
>   #lang racket
>   (require aosd)
>
> which has a `require` that corresponds to a package on the online
> catalog.
>
> Since the call to `pkg-catalog-suggestions-for-module` doesn't specify a
> catalog file, I think it uses the default value of the parameter. But
> the default catalog file doesn't seem to contain much useful
> information:
>
>   Welcome to Racket v6.0.1.6.
>   -> (require pkg/db)
>   -> (get-pkgs)
>   '()
>   -> (get-catalogs)
>   '()
>   -> (require pkg/lib)
>   -> (pkg-catalog-suggestions-for-module 'aosd)
>   ; query-rows: no such table: modules [,bt for context]
>
> Should this be using some other catalog file or somehow be populating it
> with more information from pkgs.racket-lang.org or something else?
>
> Cheers,
> Asumu

Posted on the users mailing list.