[racket] wxme-port -> string error

From: Todd O'Bryan (toddobryan at gmail.com)
Date: Fri Oct 22 10:57:37 EDT 2010

I'm trying to read a student program (which might include images or
not) as text, just so I can look at it.

I tried this:

#lang racket
(require wxme)

(define/contract (read-assignment-file path)
  (-> (or/c string? path-string?) bytes?)
  (let* ([the-path (if (path-string? path)
                       (string->path path))]
         [file-port (open-input-file the-path)]
         [port (if (is-wxme-stream? file-port)
                   (wxme-port->text-port file-port #t)
         [contents (port->string port)])

And got this error:

read-bytes: cannot load snip-class reader: #"(lib \"image-core.ss\" \"mrlib\")"

Am I close to doing the right thing? Do I need to require something else?


Posted on the users mailing list.