|
Prev: When extensibility goes bad
Next: Debugging in Slime
From: Bobtastic21 on 22 Jun 2008 11:23 I cant get Drakma to work on SBCL / Linux, but it does work on SBCL / Mac. I'm running SBCL as provided with Ubuntu 8.04, Hardy Heron I installed Drakma as follows (require 'asdf) (require 'asdf-install) (asdf-install:install :drakma) I had to skip all the GPG checks, but otherwise everything seemed to go well. When I try to use it (asdf:oos 'asdf:load-op :drakma) (defpackage :drakma-user (:use :cl :drakma)) (in-package :drakma-user) (setq *header-stream* *standard-output*) (http-request "http://lisp.org") ; in: LAMBDA NIL ; (HTTP-REQUEST "http://lisp.org") ; ; caught STYLE-WARNING: ; undefined function: HTTP-REQUEST ; ; caught STYLE-WARNING: ; This function is undefined: ; HTTP-REQUEST ; ; compilation unit finished ; caught 2 STYLE-WARNING conditions debugger invoked on a UNDEFINED-FUNCTION in thread #<THREAD "initial thread" {A84D6F9}>: The function HTTP-REQUEST is undefined. Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL. restarts (invokable by number or by possibly-abbreviated name): 0: [ABORT] Exit debugger, returning to top level. ("bogus stack frame") 0] The same process works fine on my Mac running SBCL 1.0.16 I'm probably doing something really stupid, but any advice, gratefully received. Bob
From: vanekl on 22 Jun 2008 12:49 Bobtastic21(a)googlemail.com wrote: > I cant get Drakma to work on SBCL / Linux, but it does work on SBCL / > Mac. > > I'm running SBCL as provided with Ubuntu 8.04, Hardy Heron > > I installed Drakma as follows > > (require 'asdf) > (require 'asdf-install) > (asdf-install:install :drakma) > > I had to skip all the GPG checks, but otherwise everything seemed to > go well. > > When I try to use it > > (asdf:oos 'asdf:load-op :drakma) > (defpackage :drakma-user (:use :cl :drakma)) > (in-package :drakma-user) > (setq *header-stream* *standard-output*) > (http-request "http://lisp.org") > ; in: LAMBDA NIL > ; (HTTP-REQUEST "http://lisp.org") > ; > ; caught STYLE-WARNING: > ; undefined function: HTTP-REQUEST > > ; > ; caught STYLE-WARNING: > ; This function is undefined: > ; HTTP-REQUEST > ; > ; compilation unit finished > ; caught 2 STYLE-WARNING conditions > > debugger invoked on a UNDEFINED-FUNCTION in thread #<THREAD "initial > thread" {A84D6F9}>: > The function HTTP-REQUEST is undefined. > > Type HELP for debugger help, or (SB-EXT:QUIT) to exit from SBCL. > > restarts (invokable by number or by possibly-abbreviated name): > 0: [ABORT] Exit debugger, returning to top level. > > ("bogus stack frame") > 0] > > > The same process works fine on my Mac running SBCL 1.0.16 > > I'm probably doing something really stupid, but any advice, gratefully > received. > > Bob CL-USER[1]: (require :drakma) [snip compilation messages] CL-USER[2]: (defpackage :drakma-user (:use :cl :drakma)) #<PACKAGE "DRAKMA-USER"> CL-USER[3]: (in-package :drakma-user) #<PACKAGE "DRAKMA-USER"> DRAKMA-USER[4]: (setq *header-stream* *standard-output*) #<SYNONYM-STREAM :SYMBOL SB-SYS:*STDOUT* {90F6D01}> DRAKMA-USER[5]: (http-request "http://lisp.org") GET / HTTP/1.1 Host: lisp.org User-Agent: Drakma/0.11.5 (SBCL 1.0.17.35; Linux; 2.6.17-co-0.8.0; http://weitz.de/drakma/) Accept: */* Connection: close HTTP/1.1 307 Temporary Redirect Connection: close Transfer-Encoding: chunked Date: Sun, 22 Jun 2008 16:21:12 GMT Server: AllegroServe/1.2.50 LOCATION: http://lisp.org/index.html GET /index.html HTTP/1.1 Host: lisp.org User-Agent: Drakma/0.11.5 (SBCL 1.0.17.35; Linux; 2.6.17-co-0.8.0; http://weitz.de/drakma/) Accept: */* Connection: close HTTP/1.1 200 OK Connection: close Date: Sun, 22 Jun 2008 16:21:12 GMT Server: AllegroServe/1.2.50 Content-Type: text/html Content-Length: 377 LAST-MODIFIED: Sun, 11 Feb 2007 23:08:04 GMT [snip HTML] " 200 ((:CONNECTION . "close") (:DATE . "Sun, 22 Jun 2008 16:21:12 GMT") (:SERVER . "AllegroServe/1.2.50") (:CONTENT-TYPE . "text/html") (:CONTENT-LENGTH . "377") (:LAST-MODIFIED . "Sun, 11 Feb 2007 23:08:04 GMT")) #<URI http://lisp.org/index.html> #<FLEXI-STREAMS:FLEXI-IO-STREAM {AA69839}> T "OK" DRAKMA-USER[6]: (lisp-implementation-type) "SBCL" DRAKMA-USER[7]: (lisp-implementation-version) "1.0.17.35" DRAKMA-USER[8]: <534 me -bash gnulou:/usr/local/lib/sbcl>uname -a Linux gnulou 2.6.17-co-0.8.0 #2 PREEMPT Wed Apr 25 22:15:57 CEST 2007 i686 GNU/Linux <537 me -bash gnulou:/usr/local/lib/sbcl>find drakma -iname "*lisp" -print | xargs egrep -i "def.*http-request" | grep -v darcs drakma/request.lisp:(defun http-request (uri &rest args When loading drakma make sure there were no errors (check output messages), and updating to latest versions solves a lot of problems in many cases. Debian (which i run) is the ancestor of Ubuntu so they should be similar enough.
From: Bobtastic21 on 22 Jun 2008 16:39 Thanks - that's encouraging. I've looked through the output and there are no obvious errors that I can make out. I'm pretty sure that asdf-install is pulling the latest versions of everything. I have successfully installed hunchentoot via asdf-install and that's up and working, which would suggest that several of the key libraries are working fine. I'm wondering whether there is some key platform shared library that is missing, but tracking the problem down is proving to be a challenge for my relatively lowly lisp skills.
From: vanekl on 22 Jun 2008 17:21 Bobtastic21(a)googlemail.com wrote: > Thanks - that's encouraging. > > I've looked through the output and there are no obvious errors that I > can make out. > > I'm pretty sure that asdf-install is pulling the latest versions of > everything. > > I have successfully installed hunchentoot via asdf-install and that's > up and working, which would suggest that several of the key libraries > are working fine. > > I'm wondering whether there is some key platform shared library that > is missing, but tracking the problem down is proving to be a challenge > for my relatively lowly lisp skills. just because you used asdf-install doesn't mean you have the latest versions. asdf-install tends to pull out-of-date tarballs. if you want the latest source code, you would be pulling directly from one of the source code repositories. i'm running off the repositories, so our software versions are a little different. some things to check: o are the permissions ok on the pulled files? in other words, are they world readable, and the directories writable? you didn't pull the files as root? o are the source files being compiled? can you find the .fasl files? i don't know where ubuntu sticks its .fasl files, but i can see my .fasl files next to the .lisp files, in most instances. o is the asd soft link set up between your asdf main repository and the drakma/drakma.asd file? it's real easy to add if it's not there. (you don't have to check this if you are sure that drakma is being compiled.) o are you getting at least a page of compilation/load messages when you load drakma? o did you run the "find" command that i sent in the previous email, and make sure the source code was installed? o what version of sbcl are you running? o does it look like the line endings are unixy? od -a drakma/util.lisp | head -30 you shouldn't see "cr" at the end of lines (there should be one or two newlines, "nl"). sometimes it's best to start with a fresh environment and retry all over again. what i mean by that is, delete the .fasl files, reboot, and start the drakma load over. to clean old fasl files (assuming they were placed in your drakma directory): find drakma -iname "*.fasl" -print -exec rm {} \; if none of that was any help, there's always the drakma mailing lists. you would want to first browse or search the drakma mailing list archives, and then post further questions there if you didn't find what you were looking for. http://weitz.de/drakma/
From: Bobtastic21 on 23 Jun 2008 16:56 On Jun 22, 10:21 pm, vanekl <va...(a)acd.net> wrote: > Bobtasti...(a)googlemail.com wrote: > > Thanks - that's encouraging. > > > I've looked through the output and there are no obvious errors that I > > can make out. > > > I'm pretty sure that asdf-install is pulling the latest versions of > > everything. > > > I have successfully installed hunchentoot via asdf-install and that's > > up and working, which would suggest that several of the key libraries > > are working fine. > > > I'm wondering whether there is some key platform shared library that > > is missing, but tracking the problem down is proving to be a challenge > > for my relatively lowly lisp skills. > > just because you used asdf-install doesn't mean you have the latest versions. > asdf-install tends to pull out-of-date tarballs. > if you want the latest source code, you would be pulling directly from one > of the source code repositories. i'm running off the repositories, so our > software versions are a little different. > > some things to check: > o are the permissions ok on the pulled files? > in other words, are they world readable, and the directories writable? > you didn't pull the files as root? > o are the source files being compiled? can you find the .fasl files? > i don't know where ubuntu sticks its .fasl files, but i can see my > .fasl files next to the .lisp files, in most instances. > o is the asd soft link set up between your asdf main repository and the > drakma/drakma.asd file? it's real easy to add if it's not there. > (you don't have to check this if you are sure that drakma is being compiled.) > o are you getting at least a page of compilation/load messages when > you load drakma? > o did you run the "find" command that i sent in the previous email, > and make sure the source code was installed? > o what version of sbcl are you running? > o does it look like the line endings are unixy? > od -a drakma/util.lisp | head -30 > you shouldn't see "cr" at the end of lines (there should be one > or two newlines, "nl"). > > sometimes it's best to start with a fresh environment and retry all > over again. what i mean by that is, delete the .fasl files, reboot, > and start the drakma load over. > > to clean old fasl files (assuming they were placed in your drakma directory): > find drakma -iname "*.fasl" -print -exec rm {} \; > > if none of that was any help, there's always the drakma mailing lists. > you would want to first browse or search the drakma mailing list archives, > and then post further questions there if you didn't find what you were > looking for.http://weitz.de/drakma/ Thanks - Its all working now! I uninstalled SBCL, deleted all FASL files and asdf directories and reinstalled everything and now it works .. bizarre
|
Pages: 1 Prev: When extensibility goes bad Next: Debugging in Slime |