[racket-dev] Contract problem

From: Eli Barzilay (eli at barzilay.org)
Date: Tue Jun 8 01:12:36 EDT 2010

I just ran into some problem that might be in the contract system, or
more likely in the xml collection (or maybe in both).  I basically ran
some code that I was editing, and got the lovely error message below.
IIUC, it says that xexpr is broken, which is potentially one problem.
It's probably not strict enough about what it accepts, since the
problem was basically due to my code using #<void> as the value of an
attribute.  But the second problem is this error message shows the
"Context" as a dump of the whole xexpr -- pretty printed across ~4500

/download/chronology/index.ss: running...
 broke the contract (-> xexpr? string?) on xexpr->string given to 
; Not an Xexpr. Expected a string, given #<void>

...126 lines...
         ((href "http://download.plt-scheme.org/chronology/racket5.0.html"))
         (font ((color #<void>)) "Racket" nbsp (tt () "5.0"))
...4300 lines...

 === context ===
/home/scheme/plt/collects/racket/contract/private/blame.rkt:54:0: raise-blame-error
/home/scheme/plt/collects/racket/private/more-scheme.rkt:173:2: select-handler/no-breaks
/home/scheme/iplt/web/old/common/layout.ss:44:0: xexpr->string*
/home/scheme/iplt/web/old/download/chronology/index.ss:66:0: run
/home/scheme/iplt/web/old/common/utils.ss:8:50: run-file
/home/scheme/iplt/web/old/common/build.ss:20:2: for-loop
/home/scheme/iplt/web/old/common/build.ss:20:2: for-loop
/home/scheme/plt/collects/racket/private/map.rkt:45:11: for-each
/home/scheme/iplt/web/old/common/utils.ss:8:50: build

          ((lambda (x) (x x)) (lambda (x) (x x)))          Eli Barzilay:
                    http://barzilay.org/                   Maze is Life!

Posted on the dev mailing list.