freenode/#lisp - IRC Chatlog
Search
11:55:10
jackdaniel
how about making minion greet everyone entering the channel with "good morning"? and if that person answers, add some meaningful quote, like a fortune file
13:04:33
nij
Hello! I'm trying out this script, but couldn't (ql:quickload :com.informatimago.command) https://github.com/informatimago/commands/blob/master/generate-commands.lisp#L26
13:20:05
nij
How to get com.informatimago.common-lisp.cesarum? I searched in pjb's repo @@ but it doesn't seem that there's a def.
13:24:30
ck_
nij: I don't know what you mean exactly, but the package definition is right there https://gitlab.com/com-informatimago/com-informatimago/-/blob/master/common-lisp/cesarum/package.lisp
13:56:37
beach
The debugging situation for free Common Lisp implementations and tools is not that great.
13:57:11
phoe
it's about ASDF not showing the real error(s) and just going "file failed to compile but I won't tell you why"
13:59:55
jackdaniel
asdf is being continously improved; maybe such suggestion should be made to rpgoldman?
14:00:46
beach
I think it was lukego who said recently that the situation is much better now than a decade ago.
14:01:26
_death
nij: at the point this error happens, you can try to compile-file the graph.lisp file yourself
14:04:37
_death
nij: I have a small patch to informatimago whose commit message is "made to compile and load", though I don't know if it's related to your issue
14:04:52
nij
when I (ql:quickload :something-great), does it got compiled only into the running repl? or the compiled file is put somewhere?
14:05:46
jackdaniel
afaik it does compare modification dates of the source file to determine whether file needs compiling (and a dependency graph)
14:06:03
jackdaniel
modification date is not so great way of doing this, because of how reader works, i.e #+my-brilliant-feature
14:12:36
jackdaniel
"feature conditionals consider harmful for anything that is not intrinsic to the common lisp implementation" - anyone inspired - I waive rights to the article title :-)
14:15:02
jackdaniel
nij: backtraces of errors encountered when loading stuff without asdf are useless
14:15:04
phoe
this is one particular case when the backtrace tells you nothing because the compilation errors have already happened
14:15:17
jackdaniel
it doesn't mean that all backtraces are useless - usually you go to the file that errors and compile it by hand
14:16:50
beach
jackdaniel: Krystof has an article about read-time conditionals, but the emphasis is a bit different.
14:18:45
lukego
beach: yeah the CL ecosystem is in amazing shape these days. I've actually been writing Lisp code all week without once pausing to deal with any bug or rough edge in any tool or dependency.
14:19:04
nij
so for https://github.com/informatimago/commands/tree/master/sources , what i did is (ql:quickload :com.informatimago.command)
14:19:33
phoe
I assume that it could hijack *error-output* while compiling stuff, and use this information inside the error report mayhaps?
14:20:29
lukego
aside: I'm experimenting with dumping Lisp application data structures into Blender for visualization at the moment. it's pretty fun. https://twitter.com/lukego/status/1355153534275231747. maybe headed towards having a two-way bridge where Blender can request more data from Lisp. Or maybe the novelty will wear off.
14:21:37
lukego
that basically we should all be in awe every moment that we're able to run Lisp on an x86/ARM instead of a refurbish DEC Alpha :)
14:23:42
beach
phoe: Instead of that message in the REPL, there could have been a window with the source code and some colored arrow or something like that, pointing to the error.
14:25:40
jackdaniel
I have a weak recollection of asdf-slime integration which did exactly that (as when you call compile-file)
14:25:48
_death
when you C-c C-k you get red underlines.. there is also a slime-compilation window with the errors
14:30:48
phoe
when you get an ASDF compilation error while swank is hooked up, the buffer in question opens and the underlines appear
14:32:39
lukego
yeah I guess in hindsight waiting a couple of decades until emulating a Symbolics would become performant might have been a lower effort strategy for lisp
14:33:41
nij
I believe I have furthur narrowed the issue: https://github.com/informatimago/commands/blob/master/sources/script.lisp#L343
14:34:34
_death
phoe: yes.. my first thought when looking at nij's compilation error was that asdf's compile-file-error condition should include a list of conditions it has encountered, but I've not thought about it much
14:35:14
phoe
more or less what I was thinking of; it can then report their reports and locations or something
14:35:25
beach
lukego: I am afraid an environment based on Symbolics would be very vulnerable to attacks from the net. That wasn't much of an issue at the time.
14:51:04
_death
nij: if you're using sbcl, that #+clisp form should not be relevant.. you can check *features* to make sure it doesn't contain :clisp
14:55:03
nij
The error occured in line 319 (https://github.com/informatimago/commands/blob/master/sources/script.lisp#L319), and in which only those lines under #+clisp have VERSION.
15:02:27
phoe
"Dispatching macro characters continue to parse an infix numerical argument, and invoke the dispatch function."
15:07:11
_death
I think the issue is that #+ "should" (not required by CL, apparently?) act differently when the form is skipped
15:10:51
_death
#+(or) [now *read-suppress* is bound to true] #+ [sbcl rebinds *read-suppress* to nil] #.(foo) [oops] [most recent binding is undone] 42
15:18:17
_death
even if it's not on purpose btw, pjb's code should be fixed so that the symbols used are qualified with the right package
15:32:46
theothornhill
What's the general consensus regarding fukamachiware vs edweitzware? Dexador vs drakma, Woo vs Hunchentoot etc. Is one of them regarded as "better"?
15:34:46
jackdaniel
theothornhill: e.weitz wrote very clean code with documentation, e.fukamachi usually focused on scratching his own itch (and that is perfectly fine)
15:35:42
Josh_2
I'm not really a fan of ningle of ningle, although in a high performance situation the fact it works on Woo is good as Woo is pretty darn fast
15:41:58
jackdaniel
because there is quite a few unusual implementation choices (and hacks), plus undocumented dependencies
15:42:51
jackdaniel
sometimes you encounter a memory leak that can't be easily fixed, because the function only pushed to closed over variable
15:47:20
_death
I use dexador and hunchentoot as well.. unfortunately dexador picked drakma's nasty habit of returning the response as a bunch of values instead of a response object
15:49:01
easye
_death: eh, I find that the styles of multiple values isn't bad. At least dexdor tries to return a reference to text as the first value. I still have to use FLEXI-STREAMS:MUMBLE-AS-OCTETS with drakma
15:49:09
theothornhill
jackdaniel: yason is the one I've used until now, I actually found that to be the simplest. Only because it just gave me a hash-table of the thing, avoing the whole mop business for simple queries
15:49:57
easye
ACTION has been working with jsown. I have the start of a JSONpath library with jsown
15:50:09
jackdaniel
by being hard to use I mean that I've found it tricky to extend it to accept my own objects for serialization
15:51:55
_death
easye: well, I guess our usage differs.. the big reason why it's an annoyance is that I need to reach for the definition/docstring whenever I use it.. I always have lots of :force-binary t anyway
15:54:09
_death
I could write a wrapper and be done with it.. trouble is I use it in many projects and don't want them to depend on yet another one just for this
15:56:21
easye
_death: thinking of the values for an HTTP request: it is probably worth it two create two facades, one for text oriented navigation, and one for binary requests, that call the underlying request method with appropiate defaults.
15:58:33
etimmons
Dexador has the benefit of tying into windows libraries to handle https. I've never gotten openssl through drakma to really work for me on windows.
16:00:26
jackdaniel
I had one biggish problem in hunchentoot -- when you serve a file, you first need to load it into memory
16:01:00
theothornhill
jackdaniel: cl-json seemed pretty simple with class, though: (cl-json:encode-json (make-instance 'x :name "something"))
16:01:24
_death
jackdaniel: ouch.. though I have it behind nginx and user the latter to serve most static files
16:03:22
jackdaniel
or 403, that was a long time ago, and I wasn't the main implementer of that part
16:04:27
jackdaniel
we've solved that with an obscure hack by creating a temporary symlink and letting (indeed) nginx to handle the request - the link was sent to the requestor and they were able to download the file
16:05:05
_death
jackdaniel: I think hunchentoot also lets you get a hold of the stream so you can diy.. and then, it can also be patched ;)
16:05:37
jackdaniel
I'm not saying that it disqualifies hunchentoot, still it is a problematic limitation
16:48:16
citizenajb
I have a type question. I think the result type of (* 3.0 x) where we know nothing about x (type t) is (or float (complex float))? sbcl does not seem to derive this, which to me means I might be wrong! See https://pastebin.com/MDm6fsrX for a case where it matters to me.
16:51:37
aeth
afaik, every number would become a (complex long-float) over time if you just kept doing generic arithmetic on randomly-typed things (in SBCL, though, a long-float is a double-float)
16:53:44
aeth
The 3.0 assuming 3.0f0 means it has to be (or single-float double-float long-float (complex single-float) (complex double-float) (complex long-float)) and in SBCL long-float is double-float
16:54:36
aeth
Technically, a compiler might choose that over (or float (complex float)) if it has a short-float, since it won't be a short-float.
16:55:26
aeth
It always goes to the most precise float: http://www.lispworks.com/documentation/HyperSpec/Body/12_add.htm
16:57:09
pfdietz
I'll look at it. Is datafly recommended? It's Fukamachi, which might be a negative.
16:58:01
aeth
(to be very clear because someone is going to poke me in 15 hours about it... all CL compilers have short-float. What I meant by "if it has a short-float" is "if it has a distinct short-float")
17:01:34
pfdietz
(reads about manardb)Â This is a persistent object store; I was thinking more of a relational db.
17:02:07
aeth
citizenajb: and to really go into detail, SBCL supports rational as a *read-default-float-format* so without context (* 3.0 x) might result in a rational, but that would be resolved at read time, ahead of compiling it. I always do "3.0f0" when I mean single-float because sometimes I have it set to double-float when I'm using the REPL as a calculator.