freenode/#lisp - IRC Chatlog
Search
10:05:17
akr
Hi, anyone here who's using cl-smtp? I'm having trouble having it send a mail. Here's debug output, does it seem okay to you? http://paste.lisp.org/display/356519
10:07:29
akr
the code is a bit strange, it seems to be using an undocumented function exported by cl-smtp (I didn't write it)
10:26:29
akr
here's how the debug output looks when it actually works: http://paste.lisp.org/display/356522
10:33:55
antoszka
akr: I think ~%~% is the problem, you need *two* empty CRLFs to separate headers from body, ~% will emit a fresh line, *only* when the output isn't on a fresh line already.
10:35:24
akr
so this cl-smtp thing is supposed to connect to a locally running SMTP server, like Postfix, right?
10:39:41
basket
Or well, on Unix anyway; ~% would do CRLF on Windows I think, but I don't use Windows
10:59:50
flip214
you could also run strace against the python proxy, perhaps that'll show why it wouldn't relay.
11:00:39
flip214
if you paste the strace (or send privately, eg. via mail), I'll happily help interpret.
11:02:54
akr
I've asked a sysadmin guy to set up a proper SMTP server, so I think I'm off the hook for now :P
11:06:22
flip214
well, you've got somebody else looking now, so I'll just offer the mantra "read the logs" ;)
11:38:16
flip214
ACTION is currently reading some technical documentation, but sentences like "and edit the constructor request to query a specific car" start with the wrong meaning
14:15:48
Xach
hey, who wants to try out a quicklisp bootstrap (quicklisp.lisp) that includes pgp checking of all downloads, and bootstraps into a client that does pgp and sha checking of everything too?
14:17:05
Xach
dlowe: yeah, that will get things out of the way for testing. or you could use :path during install to go to a temp place.
16:29:14
jasom
JuanDaugherty: I don't see you on #lispweb, but hunchentoot has post-parameters* to get an alist of all post parameters, and it parses both multipart/form-data and application/x-www-form-urlencoded
16:56:20
some-user
strangely i can't find any recording of this https://icfp17.sigplan.org/track/scheme-2017#program , it would be weird if whole event went unrecorded
17:05:41
shrdlu68
There are a number of implementations, try ecl, ccl, or sbcl. (not the complete list)
17:08:42
iqubic
For context, newcoder was recently in #emacs asking about the differences between elisp and "lisp" not knowing the lisp was a whole family of languages and elisp is just a dialect, or version.
17:09:27
dlowe
newcoder: you can also download https://dlowe.net/tmp/sbcl.install.sh, look at it, and run it
17:10:32
astronavt
newcoder check out the book Practical Common Lisp. i'm working through it right now, it's a great introduction if you're already a programmer
17:11:49
minion
newcoder: please see gentle: "Common Lisp: A Gentle Introduction to Symbolic Computation" is a smoother introduction to lisp programming. http://www.cs.cmu.edu/~dst/LispBook/
17:12:15
Josh_2
That's what I started on when I had very little programming experience PCL is too much if you don't have any experience.
17:13:30
jasom
newcoder: portacle (which I referenced earlier) sets up an entire IDE, including a REPL with line editing as well; might be more than you need right now, but isn't a bad place to start either
17:14:12
dlowe
I wonder how hard it would be to make a gui listener specifically to embed into sbcl contrib
17:14:59
jasom
newcoder: this is because the REPL prints the value returned by write-line, *and* also prints write-line out to the console; one of the two should have quotes around it, right?
17:15:27
jasom
newcoder: in a fancier REPL (like what portacle would install) the two would also be coloured differently
17:16:49
dlowe
you can also put #!/usr/bin/sbcl --script at the top of your file, set it executable, and run it directly that way
17:18:08
dlowe
newcoder: you might consider also joining #clnoobs, which is specifically a channel for helping people get started.
17:19:01
shrdlu68
newcoder: You're doing fine, you just need to take some time and read something about common lisp.
17:19:31
newcoder
(SB-C:COMPILER-ERROR SB-C::INPUT-ERROR-IN-LOAD :CONDITION #<SB-INT:SIMPLE-READER-ERROR "no dispatch function defined for ~S" {B3E6D59}
17:20:12
jasom
newcoder: did you put a #! at the top? Don't do that if you're going to load it with sbcl --load
17:21:07
jasom
newcoder: dlowe and I were telling you two different ways of doing it, mixing and matchign isn't going to work...
17:21:48
jasom
newcoder: sbcl is "Steel Bank Common Lisp"; Common Lisp is a standard, of which there is more than one implementation
17:22:24
jasom
Clozure Common Lisp, Armed Bear Common Lisp and Embeddable Common Lisp are 3 other implementations
17:23:13
jasom
Lispworks and Allegro Common Lisp are two proprietary implementations that are probably out of your price range if you're a hobbiest
17:25:10
dlowe
CL code can be "portable" - which will run on any implementation, or "implementation-specific". most CL code is written to be portable.
17:25:14
jasom
newcoder: I highly recommend you read http://www.cs.cmu.edu/~dst/LispBook/ it's a text book for teaching lisp to new coders
17:25:16
whoman
ok, ill just leave this here too, http://www.pathwayslms.com/swipltuts/student/index.html#regulars
17:26:00
jasom
newcoder: the whole #!/usr/bin/sbcl --script trick only works with sbcl; (write-line "Hello, World!") works everywhere, as does (load "h.lisp") to load it
17:26:57
whoman
there is advice about giving too much advice, all at once, conflicting teaching plans, etc.
17:27:10
pjb
If a newbie is give Getting+Started and doesn't says thank you and ask away a new question immediately (instead of spending at least 24 hours installing and reading the material referenced on cliki), then he's just a lazy bum.
17:28:14
whoman
section 2.1: "I don’t think you’re intending to be mean, but when you demonstrate your intellect or highlight a fascinating corner of [domain], in effect you’re ignoring the poor petitioner."
17:28:15
chu
Also, pretty much trolling in #emacs earlier about emacs not being vim and then more recently about how the lisp he had used had too many (((....)))'s
17:30:00
jasom
iqubic: #! is defined by posix to work with zero or one arguments; some unixen will work with more than one argument, but /usr/sbin/sbcl --script fits into the requirement
17:31:14
jasom
newcoder: write-line only will write a string; print will try to print anything you throw at it
17:32:33
jasom
newcoder: (terpri) will just print a newline; or you can use format: (format t "foo~%") will print foo followed by a newline
17:33:17
jasom
~% is a newline and ~& will start a fresh line (i.e. only a newline if you didn't just print a newline)
17:36:01
jasom
newcoder: format is roughly equivalent to fprintf, with the first argument being where the result should go; T means the standard output
17:37:16
jasom
but usually people just use ~A unless they specifically want formatting options specific to numbers
17:38:15
jasom
newcoder: no, elisp has a format that uses printf style % operators and works more like sprintf (it always just returns a string rather than outputting anything)
17:39:06
jasom
though the %s operator for elisp's format works much like the ~A operator for lisp's format
17:40:21
jasom
^^ docs for format are there, but it's way more than you need to know now; as a noob you can do most of what you want just with ~A and ~%
17:55:11
jasom
mr_yogurt: I like meeting in the stacks at the university; less likely to get your plot discovered that way
17:59:08
jasom
mr_yogurt: but that's more like for network graphs. You could probably do worse than output gnuplot scripts using run-program to lanuch gnuplot
18:32:00
astronavt
an R <-> CL interface might be straightforward enough, since R is very lispy internally
19:39:05
phoe_
(loop for ((a b) (c d)) on '((1 2) (3 4) (5 6)) do (format t "~D ~D : ~D ~D~%" a b c d))
19:39:41
phoe_
I don't want to do (unless (null c)) because I have more variables to bind in FOR clauses before DO.
19:43:16
jasom
phoe_: only thing I can think of is hacky: in the next FOR put a (progn (when (nil c) (return)) ...)
19:44:29
jasom
e.g. (loop for ((a b) (c d)) on '((1 2) (3 4) (5 6)) for dummy = (when (null c) (return)) ...)
19:58:23
jasom
(loop for ((a b) (c d)) on '((1 2)) while c for e = (print "hello")) ; I believe this should print "hello" but it doesn't on sbcl
19:58:30
phoe_
I'm in that weird position where I'm happy that SBCL is non-conforming but sad because my code isn't as well. :(
20:00:31
jasom
Bike: clisp claims it is nonconforming, but I can't find any reference in chapter 6 to support that
20:02:08
jasom
Bike: that contradicts an earlier part that says that for-as-equals can be interleaved
20:03:10
jasom
Bike: oh, nm misread something; that was about lexical environment, not about other forms
20:03:12
Bike
phoe_ (loop with concatenated repeat n do (setf concatenated (concatenate 'vector concatenated x)) finally (return concatenated))?
20:04:25
jasom
There's also "Some clauses from the source form contribute code only to the loop prologue; these clauses must come before other clauses that are in the main body of the loop form." which while true implies something different from the grammar, which is that all clauses that contribute code to the loop prologue must come before other clauses
20:09:07
jasom
also the quote I posted earlier means that all with and initially clauses must proceed any other clauses
20:20:32
dim
phoe_: make a (* X length) vector, then replace its content in a loop from the original vector, same amount of code, much faster
20:28:22
dim
(let* ((v (make-array 10 :initial-contents '(a b c d e f g h i j))) (l (length v)) (n 3) (newvec (make-array (* l n)))) (loop for i from 0 upto (* (- l 1) n) by l do (replace newvec v :start1 i) :finally (return newvec)))