From edi at agharta.de Mon Jun 7 21:03:07 2004 From: edi at agharta.de (Edi Weitz) Date: Mon, 07 Jun 2004 23:03:07 +0200 Subject: [tbnl-devel] New release 0.2.0 Message-ID: <873c57xer8.fsf@bird.agharta.de> Hi! A new release is available from . Here's the relevant part from the changelog: Version 0.2.0 2004-06-07 Added SESSION-STRING and *SESSION-REMOVAL-HOOK* Added GET-BACKTRACE for AllegroCL Have fun, Edi. From edi at agharta.de Thu Jun 10 14:03:34 2004 From: edi at agharta.de (Edi Weitz) Date: Thu, 10 Jun 2004 16:03:34 +0200 Subject: [tbnl-devel] New release 0.2.1 Message-ID: <87isdzeci1.fsf@bird.agharta.de> Hi! A new release is available from . Here's the relevant part from the changelog: Version 0.2.1 2004-06-10 Only create backtrace if needed (speeds up AllegroCL considerably) Have fun, Edi. From edi at agharta.de Thu Jun 10 16:31:28 2004 From: edi at agharta.de (Edi Weitz) Date: Thu, 10 Jun 2004 18:31:28 +0200 Subject: [tbnl-devel] New release 0.2.2 In-Reply-To: <87isdzeci1.fsf@bird.agharta.de> (Edi Weitz's message of "Thu, 10 Jun 2004 16:03:34 +0200") References: <87isdzeci1.fsf@bird.agharta.de> Message-ID: <873c53cr33.fsf@bird.agharta.de> Sorry for the noise today but here's yet another release: Version 0.2.2 2004-06-10 Bugfix for SESSION-GC and RESET-SESSIONS (bug introduced in 0.2.0) Cheers, Edi. From edi at agharta.de Fri Jun 11 07:24:05 2004 From: edi at agharta.de (Edi Weitz) Date: Fri, 11 Jun 2004 09:24:05 +0200 Subject: [tbnl-devel] Re: tbnl bug In-Reply-To: <40C8FF6D.4050403@itsec.co.kr> (KMP Developer's message of "Fri, 11 Jun 2004 09:40:13 +0900") References: <40C8FF6D.4050403@itsec.co.kr> Message-ID: <87k6ye1rsa.fsf@bird.agharta.de> Hi! On Fri, 11 Jun 2004 09:40:13 +0900, KMP Developer wrote: > I'm building my web app using your tbnl and today is day 2 :) > > Yesterday I found a bug in process-apache-command > function(modlisp.lisp). > > When url of client browser is invalid(for example: > "http://localhost/abc???def") the function does nothing(e.g. doesn't > return any html). I can't reproduce that here, I get a 404 reply. Are you sure you have setup httpd.conf correctly such that all localhost URLs are served through TBNL? > Based on Apache's behaviour(I'm not a http expert, btw), it should > return '404 not found' and there should be a way user can add a > friendly 'not found' page, I think. You can create your own friendly 404 page if you put a 'catch-all' handler at the end of the dispatch table or simply change the value of *DEFAULT-HANDLER* > You may know this problem, and I'd like to ask its fix before I try > to write one for myself. > > Thanks for tbnl You're welcome. Please use the mailing list for bug reports, thanks. Cheers, Edi. From edi at agharta.de Sat Jun 12 12:53:02 2004 From: edi at agharta.de (Edi Weitz) Date: Sat, 12 Jun 2004 14:53:02 +0200 Subject: [tbnl-devel] New release 0.2.3 Message-ID: <87wu2d3pld.fsf@bird.agharta.de> Hi! A new release is available from . Here's the relevant part from the changelog: Version 0.2.3 2004-06-12 Bugfix for FORM-URL-ENCODED-LIST-TO-ALIST (bug caught by Jong-won Choi) Have fun, Edi. From edi at agharta.de Sat Jun 12 12:56:52 2004 From: edi at agharta.de (Edi Weitz) Date: Sat, 12 Jun 2004 14:56:52 +0200 Subject: [tbnl-devel] Re: tbnl bug In-Reply-To: <40CAA420.2020003@itsec.co.kr> (KMP Developer's message of "Sat, 12 Jun 2004 15:35:12 +0900") References: <40C8FF6D.4050403@itsec.co.kr> <87k6ye1rsa.fsf@bird.agharta.de> <40CAA420.2020003@itsec.co.kr> Message-ID: <87smd13pez.fsf@bird.agharta.de> On Sat, 12 Jun 2004 15:35:12 +0900, KMP Developer wrote: > I traced the problem and I found who's throwing. In (defmethod > initialize-instance :after ((request request) &rest init-args)) : > (form-url-encoded-list-to-alist > (cl-ppcre:split "&" "abc=1&def=2")) ; OK > > (form-url-encoded-list-to-alist > (cl-ppcre:split "&" "???abc")) ; Throws an exception Ah, now I see it! You didn't mention which Lisp you were using and I only tested against AllegroCL which doesn't expose this problem. I've now tested with CMUCL and see what's going wrong. I've uploaded a new version (0.2.3) which should fix this. > I found my original message is not good enough as a bug > report. Sorry about that No problem. Thanks for finding the bug! >>Please use the mailing list for bug reports, thanks. >> > I'll do that next time. You could have started with this reply... :) Thanks and have a nice weekend, Edi. From lam at tuxfamily.org Tue Jun 15 13:13:00 2004 From: lam at tuxfamily.org (Nicolas Lamirault) Date: Tue, 15 Jun 2004 09:13:00 -0400 Subject: [tbnl-devel] Problem with my tests Message-ID: hello, il make some tests with tbnl, and i have some problems this is how i proceed : ; SLIME 2004-04-28 CL-USER> (push "/home/nlamirault/src/cl-ini/" asdf:*central-registry*) ("/home/nlamirault/src/cl-ini/" #p"/usr/share/common-lisp/systems/" (MERGE-PATHNAMES #p".clc/systems/" (USER-HOMEDIR-PATHNAME)) *DEFAULT-PATHNAME-DEFAULTS*) CL-USER> (push "/home/nlamirault/src/url-rewrite/" asdf:*central-registry*) ("/home/nlamirault/src/url-rewrite/" "/home/nlamirault/src/cl-ini/" #p"/usr/share/common-lisp/systems/" (MERGE-PATHNAMES #p".clc/systems/" (USER-HOMEDIR-PATHNAME)) *DEFAULT-PATHNAME-DEFAULTS*) CL-USER> (push "/home/nlamirault/src/tbnl-0.2.3/" asdf:*central-registry*) ("/home/nlamirault/src/tbnl-0.2.3/" "/home/nlamirault/src/url-rewrite/" "/home/nlamirault/src/cl-ini/" #p"/usr/share/common-lisp/systems/" (MERGE-PATHNAMES #p".clc/systems/" (USER-HOMEDIR-PATHNAME)) *DEFAULT-PATHNAME-DEFAULTS*) CL-USER> (push "/home/nlamirault/src/clwl/" asdf:*central-registry*) ("/home/nlamirault/src/clwl/" "/home/nlamirault/src/tbnl-0.2.3/" "/home/nlamirault/src/url-rewrite/" "/home/nlamirault/src/cl-ini/" #p"/usr/share/common-lisp/systems/" (MERGE-PATHNAMES #p".clc/systems/" (USER-HOMEDIR-PATHNAME)) *DEFAULT-PATHNAME-DEFAULTS*) CL-USER> (asdf:operate 'asdf:load-op :clwl) [...] CL-USER> (tbnl:start-tbnl) # i have defined this on clwl.lisp : (setq *dispatch-table* (nconc (mapcar (lambda (args) (apply #'create-prefix-dispatcher args)) '(("/tbnl/clwl" main) ("/tnbl/clwl/login.html" login) ("/tbnl/clwl/about.html" about))) (list #'default-dispatcher))) on url : http://localhost/tbnl/clwl/index.html, i obtain the tbnl's default page : > TBNL Default Page > This the TBNL default page. You're most likely seeing it because the > server administrator hasn't set up his own default page yet. > TBNL is a toolkit for building dynamic websites with Common Lisp and > Apache. More info about TBNL can be found at http://weitz.de/tbnl/. I think that it is comportement normal because : CL-USER> tbnl:*dispatch-table* (TBNL:DEFAULT-DISPATCHER) i have create an init function : > (defun clwl () > (setf *conf* (load-config "/home/nlamirault/src/clwl/clwl.conf")) > (setf *db* (get-database-connection *conf*)) > (setf *dispatch-table* > (nconc > (mapcar (lambda (args) > (apply #'create-prefix-dispatcher args)) > '(("/tbnl/clwl" main) > ("/tnbl/clwl/login.html" login) > ("/tbnl/clwl/about.html" about))) > (list #'default-dispatcher)))) CL-USER> (clwl:clwl) ; [GC threshold exceeded with 17,686,392 bytes in use. Commencing GC.] ; [GC completed with 5,849,408 bytes retained and 11,836,984 bytes freed.] ; [GC will next occur when at least 17,849,408 bytes are in use.] (# # # #) after this call, the URL http://localhost/tbnl/clwl show what i want it's ok the logs : [Tue Jun 15 15:08:26 2004] [warn] [TBNL] New template printer for #p"templates/blog.html" created so i would like to view the about page with this URL : http://localhost/tbnl/clwl/about.html, but i have a "loop", and after i come back to the home page :( this is what i have on the apache logs : [Tue Jun 15 15:08:43 2004] [error] [TBNL] Main [Tue Jun 15 15:08:44 2004] [error] [TBNL] Main [Tue Jun 15 15:08:45 2004] [error] [TBNL] Main [Tue Jun 15 15:08:46 2004] [error] [TBNL] Main [Tue Jun 15 15:08:46 2004] [error] [TBNL] Main [Tue Jun 15 15:08:47 2004] [error] [TBNL] Main [Tue Jun 15 15:08:47 2004] [error] [TBNL] Main [Tue Jun 15 15:08:48 2004] [error] [TBNL] Main PS : i have this on my functions : (defun main () (log-message :error "Main") ...) (defun login () (log-message :error "Login") ...) (defun about () (log-message :error"About clwl") ...) any idea about my pb ? thanks for any help -- Nicolas Lamirault From edi at agharta.de Tue Jun 15 13:21:56 2004 From: edi at agharta.de (Edi Weitz) Date: Tue, 15 Jun 2004 15:21:56 +0200 Subject: [tbnl-devel] Problem with my tests In-Reply-To: (Nicolas Lamirault's message of "Tue, 15 Jun 2004 09:13:00 -0400") References: Message-ID: <878yepj6rv.fsf@bird.agharta.de> On Tue, 15 Jun 2004 09:13:00 -0400, Nicolas Lamirault wrote: > i have defined this on clwl.lisp : > > (setq *dispatch-table* > (nconc > (mapcar (lambda (args) > (apply #'create-prefix-dispatcher args)) > '(("/tbnl/clwl" main) > ("/tnbl/clwl/login.html" login) > ("/tbnl/clwl/about.html" about))) > (list #'default-dispatcher))) As the docs say in "The dispatchers in *DISPATCH-TABLE* are tried in turn until one of them returns a handler." So it looks like in your case "/tbnl/clwl" will always match and always return the MAIN function without a chance for the other dispatch functions to be called. You should chance the order in your dispatch table - make MAIN the last entry (or the one directly before #'DEFAULT-DISPATCHER). HTH, Edi. From lam at tuxfamily.org Tue Jun 15 13:31:29 2004 From: lam at tuxfamily.org (Nicolas Lamirault) Date: Tue, 15 Jun 2004 09:31:29 -0400 Subject: [tbnl-devel] Problem with my tests In-Reply-To: <878yepj6rv.fsf@bird.agharta.de> (Edi Weitz's message of "Tue, 15 Jun 2004 15:21:56 +0200") References: <878yepj6rv.fsf@bird.agharta.de> Message-ID: Edi Weitz writes: > On Tue, 15 Jun 2004 09:13:00 -0400, Nicolas Lamirault wrote: > >> i have defined this on clwl.lisp : >> >> (setq *dispatch-table* >> (nconc >> (mapcar (lambda (args) >> (apply #'create-prefix-dispatcher args)) >> '(("/tbnl/clwl" main) >> ("/tnbl/clwl/login.html" login) >> ("/tbnl/clwl/about.html" about))) >> (list #'default-dispatcher))) > > As the docs say in > > "The dispatchers in *DISPATCH-TABLE* are tried in turn until one of > them returns a handler." > > So it looks like in your case "/tbnl/clwl" will always match and > always return the MAIN function without a chance for the other > dispatch functions to be called. You should chance the order in your > dispatch table - make MAIN the last entry (or the one directly before > #'DEFAULT-DISPATCHER). This will learn to me has to better read the next time ! thanks, it works fine > HTH, > Edi. > -- Nicolas Lamirault From edi at agharta.de Tue Jun 15 23:00:37 2004 From: edi at agharta.de (Edi Weitz) Date: Wed, 16 Jun 2004 01:00:37 +0200 Subject: [tbnl-devel] Problem with my tests In-Reply-To: (Nicolas Lamirault's message of "Tue, 15 Jun 2004 10:29:09 -0400") References: <878yepj6rv.fsf@bird.agharta.de> <874qpdj63q.fsf@bird.agharta.de> Message-ID: <87isdsa0kq.fsf@bird.agharta.de> On Tue, 15 Jun 2004 10:29:09 -0400, Nicolas Lamirault wrote: > for tbnl i make this now : > >> (defun clwl-start () >> "Load configuration file, create a SQL database handler, >> and initialize the tbnl dispatcher for Clwl" >> (setf *conf* (load-config "/home/nlamirault/src/clwl/clwl.conf")) >> (setf *db* (get-database-connection *conf*)) >> (setf *dispatch-table* >> (nconc >> (mapcar (lambda (args) >> (apply #'create-prefix-dispatcher args)) >> '(("/tnbl/clwl/login.html" login) >> ("/tbnl/clwl/about.html" about) >> ("/tbnl/clwl/" main) >> )) >> (list #'default-dispatcher))) >> (start-tbnl)) > >> (defun clwl-stop () >> (setf *conf* nil) >> (setf *db* nil) >> (setf *dispatch-table* nil) >> (stop-tbnl)) > > so i can load clwl very quickly with asdf operations and > (clwl:clwl-start) > > i use html-template to load the html template file, and create my > web page (with data contained in sql database) but in fact i have a > problem of CSS ... > > for exemple this page : http://localhost/tbnl/clwl/index.html this > page is correcte but css isn't load > > i have this on the HTML template : > > > > and my architecture is like this : > > ~/src/clwl/ > *.lisp > templates/ > *.css > *.html > > > ~/public_html/tbnl/clwl <-- a link towards : ~/src/clwl/ > > > i a write this in the template : > > > there is no change :( > i don't really understand > any help ? I suppose you have Apache configured to delegate all pages below /tbnl/ to TBNL. As index.html is at /tbnl/clwl/index.html the address of the style sheet resolves to /tbnl/clwl/templates/advogato.css which is fed through TBNL which serves MAIN. (You can verify this with something like Ethereal. Or you can add a LOG-MESSAGE form to the MAIN function which logs the SCRIPT-NAME the browser requested.) The easiest way to solve this problem is to give static pages their own root independently of TBNL, something like this: > Ps : i'm on #lisp, nickname : lam I usually don't have time for IRC... :) (If I'm there - very rarely - I'm nhabedi.) Cheers, Edi. From edi at agharta.de Wed Jun 30 14:25:00 2004 From: edi at agharta.de (Edi Weitz) Date: Wed, 30 Jun 2004 16:25:00 +0200 Subject: [tbnl-devel] Apache 2.0 support Message-ID: <87isd986o3.fsf@bird.agharta.de> The attached email was sent to tbnl-devel when common-lisp.net was down. I'm resending it now because I think it's interesting for people who want to try out TBNL with Apache 2.0. -------------- next part -------------- An embedded message was scrubbed... From: Pete Kazmier Subject: Re: TBNL Question Date: Fri, 28 May 2004 09:44:32 -0400 Size: 4221 URL: