[kpax-devel] static-root problem

Sven Van Caekenberghe scaekenberghe at common-lisp.net
Tue May 8 14:02:59 UTC 2007


Matthias,

On 08 May 2007, at 15:07, Matthias Teege wrote:

> Moin,
>
> I try to define a webapp with a static-route like this:
>
> (defwebapp :blub
>     (:index 'blub-home)
>   (:static-root "static/")
>   (:unsecure t))
>
> If I try to compile this part on SBCL I've got
>
> The value NIL
> is not of type
>   (OR (VECTOR CHARACTER) (VECTOR NIL) BASE-STRING PATHNAME FILE- 
> STREAM).
>    [Condition of type TYPE-ERROR]
>
> I'snt "static/" a string?
>
> Many thanks
> Matthias
>
> _______________________________________________
> KPAX-devel mailing list
> KPAX-devel at common-lisp.net
> http://common-lisp.net/cgi-bin/mailman/listinfo/kpax-devel

Did you by any chance evaluate the defwebapp form from within an  
editor to a listener or directly into a listener ? This does not work  
and might give you an error like the one above. You have to write  
defwebapp forms in a file and compile or load them as a whole.

The reason is that the defwebapp macro uses (or *load-truename*  
*compile-file-truename*) to resolve the static root relative against  
the location of the source file.

HTH,

Sven





More information about the kpax-devel mailing list