[racket-dev] dynamic require and collapsed snips?

From: Robby Findler (robby at eecs.northwestern.edu)
Date: Tue Sep 13 16:00:22 EDT 2011

Well, this took longer than I'd hoped to fix, but it is now fixed in
git. Unfortunately, you'll need to use a new version of DrRacket to
create the files to be able to load them in a gui-less context. I hope
that's okay for your purposes. If not, there is a way around it, but
it requires you to call some library to initialize things so I thought
 I'd wait and see how important that was.


On Sun, Sep 11, 2011 at 6:20 PM, Robby Findler
<robby at eecs.northwestern.edu> wrote:
> The GUI-less error you were getting is a bug in the implementation of the
> collapsed snip. Specifically it is not wired into the non-GUI reading
> support stuff in the wxme library.
> Unfortunately it does not seem easy to support the same strategy that the
> GUI version uses
> In the non-GUI context because the wxme library does not seem to provide a
> way to say "here's a snipclass name; please read one of those from this here
> port ".
> Robby
> On Sunday, September 11, 2011, Danny Yoo <dyoo at cs.wpi.edu> wrote:
>>> So there must be some context that I'm missing here.  What should I be
>>> doing to not get this error at the terminal?  Thanks!
>> Following up: I figured out that I need to use (make-gui-namespace) to
>> create a namespace that knows about the snip classes.  e.g.
>> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
>> #lang racket/base
>> (require racket/gui/base)
>> (parameterize ([current-namespace (make-gui-namespace)])
>>  (dynamic-require '(file "snips.rkt") #f))
>> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
>> Thanks!
>> _________________________________________________
>>  For list-related administrative tasks:
>>  http://lists.racket-lang.org/listinfo/dev

Posted on the dev mailing list.