freenode/#lisp - IRC Chatlog
Search
8:24:24
Demosthenex
cobax: i can't find screenshots for their example html application, link if you find anyone or see one running
8:27:45
Demosthenex
cobax: have you considered itemizing the features you want from a 4gl, and looking at what libraries CL has that can supply those? for instance, at https://cliki.net/web%20framework they discuss libs like bknr which do objects, template, and web presentation
8:29:21
cobax
Demosthenex: part of my having this conversation was realizing even which parts are there that I need but did not know about. it has helped me clarify a lot and I think as you said, I need to make a definite list
8:31:08
cobax
"BKNR was seen as not so much a web framework, more a persistent object framework with some web stuff wrapped around it." I love it!
8:34:13
Demosthenex
i think it's funny how the nosql crowd has screamed that SQL is too hard, why does it have to be so difficult to just store my data, without really understanding all the features a database actually offers ...
8:37:51
xificurC
yason docs say: "Interning strings coming from an external source is not recommended practice." . Is that from a security standpoint? Does INTERN allow arbitrary code execution or something?
8:40:52
xificurC
Demosthenex, cobax: this page describes a minimal complete application https://software-lab.de/doc/app.html and there's a live version of it for user's convenience here: https://7fach.de/app . un/pass is admin admin
8:45:52
Demosthenex
to be fair, looking at the source at https://github.com/picolisp/picolisp/tree/dev/app , is there something similar in CL
8:47:53
jackdaniel
i.e when I'm in a supermarket to pick up a toothbrush, I'm a subject of a choice terror
8:48:00
Demosthenex
yep. every first year compsci student learns to compose strings and immediately thinks they can make a web framework from templates ;]
8:49:59
jackdaniel
sure, but many people perceive this kind of choice and a necessity to compare things being a terror of choice, it is worth to keep that in mind if you try to figure out "what they want"
8:50:06
Shinmera
I could just tell you to use Radiance, but I'm not a salesman, so I won't just suggest it to people without knowing their needs
8:50:16
Demosthenex
cobax: picolisp might help, but it feels like a small solution. i've used many programming languages, and i find it difficult to beat CL's ability to hot-reload and debug code, ala SLIME/swank and the repl
8:52:14
Demosthenex
i'm still thrilled i added 3 lines to add lparallel into a slow process yesterday importing records, and was able to max my 8 cores and load in record time.
8:52:50
Demosthenex
Shinmera: hate to say it, but top software is often due to salesmanship more than technical quality. look at the whole windows ecosystem
8:52:57
xificurC
Demosthenex: why would it be bad to point him to another language *if* that's the correct thing to do? No point chatting with him here if he's not interested
8:53:54
cobax
Shinmera: if it helps I like these words: "easily and in such a way that they can be used on practically any setup without having to undergo special adaptations"
8:53:55
Demosthenex
xificurC: it may be, but it didn't sound like he wasn't interested, just frustrated with the features he needs.
8:54:18
Demosthenex
cobax: careful, that's awful close to the description of a "magic bullet" solution
8:55:05
cobax
Demosthenex: it is a spectrum, right? at one end, a totally integrated environment. at another end, config files and vim in a terminal, forever.
8:56:37
Demosthenex
cobax: i'm an old fart. the number of "integrated" environments i've outgrown and broken is silly to the point i no longer use them
8:57:12
cobax
Demosthenex: I'm an old far who made money doing VB6 apps for clients and it felt good, and I long for that level of productivity
8:58:27
cobax
Demosthenex: perhaps, but then that write up I linked, that team outgrew AllegroCache and went manardb
9:01:35
Demosthenex
cobax: ok, that said they had to work on every item at once on every node all the time. surely that's not your standard OLTP system
9:02:33
Demosthenex
cobax: seriously, the writeup's first paragraph says basically they need the whole db in memory at all times, not just accessing a server
9:04:17
Demosthenex
and allegro CL includes allegrocache in the free download for evaluation and personal use. if you make apps to distribute buy a license.
9:11:36
cobax
we're programmers, whatever work needs to be done to integrate these tools should be done only once and then spread wide. beautiful stuff.
9:12:55
cobax
Shinmera: everything to me is "compared to what?". I think it's beautiful, compared to all the alternatives.
9:13:45
Shinmera
cobax: I mean that the way portacle is done is a collection of really gross hacks and kludges that I had to figure out.
9:15:05
cobax
Shinmera: as opposed to the collection of really gross hacks and kludges that I have to figure out when no one integrates stuff for me? ;)
9:15:58
Shinmera
When you set up an IDE for yourself you typically don't have the requirements that portacle has and which in turn necessitate said hacks
9:24:21
cobax
changing topics, I spent a long time studying Haskell only to now conclude that a good interactive debugger is many more times preferable than the paltry benefits derived from the type checker
9:24:44
cobax
does anyone here have a similar experience with being disappointed by types and coming back to Father Lisp?
9:36:49
cobax
I believe Erik Meijer also gave up on types? Certainly I've watched some of his presentations where he was openly mocking them
9:37:52
cobax
and Alan Kay spoke of the academization of programming, and how Biology does not have the word "Science" in it thew way Computer Science does
9:44:14
cobax
_death: he made the point that Computer Science has "Science" in the name just like "Social Sciences" and some other dubious one that made the point clear
9:45:23
cobax
Demosthenex: I like how you say "end user apps". Do engineers speak of "end user skyscrapers" ? I imagine that is how Kay would answer
9:52:24
Demosthenex
https://bpaste.net/show/9c4e3ef16975 very exciting that croatoan's starting to add form support!
9:55:27
_death
I think the verisimilitudes guy made a good point.. and his acute-terminal-control library works OK, mostly.. I started using it for some project.. it would make sense to have a TUI library based on it
9:56:36
Demosthenex
_death: i think my issue is that while many low level terminal control libs exist, there are no tui environments. there were a few tries to make turbovision work, but they're all dead
9:58:46
_death
I know. thing is, it's not a big deal to come up with a basic TUI library.. in the DOS days, everyone wrote their own TUI/GUI libraries anyway
9:59:27
White_Flame
but there you had direct screen access, instead of sending terminal commands, too
10:00:59
_death
White_Flame: it's not very important.. you can easily come up with a "frame buffer" abstraction
10:03:43
_death
but it's not even clear that you'd want to do that.. back then you'd still have abstractions like gotoxy and friends
10:07:43
beach
I WIN! Here is what I ended up with for MAKE-METHOD and CALL-METHOD: https://pastebin.com/TaXeRVWe
10:11:49
beach
I think there is still some minor problems. The call to MAKE-INSTANCE should probably be evaluated at macro-expansion time.
10:20:11
no-defun-allowed
is there a consise way to FORMAT eight items on a line, then another eight on the next line and so on?
10:28:38
beach
So here, you must subclass GENERIC-FUNCTION and specialize your method to that new class.
10:29:55
jackdaniel
from other "the more you know" things if you create a handler-case you may want to handle serious-condition (which error inherits from), not error
10:30:19
no-defun-allowed
i had a need to make a readable signature generator kinda thing for hand checking diffie-hellman keys
10:30:22
jackdaniel
some conditions are not errors still you want to "catch" them (i.e timeout is not an error, same goes for out of memory)
10:30:38
no-defun-allowed
[so here's one, just cause i think the output is funny](https://gist.github.com/TheEmacsShibe/511b4fd71b5d9712e09b0408033a8d5b)
10:32:48
specbot
Constraints on the COMMON-LISP Package for Conforming Programs: http://www.lispworks.com/reference/HyperSpec/Body/11_abab.htm
10:33:31
beach
19. Defining a method for a standardized generic function which is applicable when all of the arguments are direct instances of standardized classes.
10:51:31
_death
Demosthenex: I think I already mentioned that some years ago I started writing bindings for it.. but my conclusion was that tvision's API was too convoluted because it adopted old C++ "OO" dogmas of the day (lots of inheritance and needless interaction within hierarchy levels) and a Lispy interface is too much work for too little
10:53:06
_death
Demosthenex: I think it's better to start afresh.. may have turbovision look and feel if you like
11:02:08
Demosthenex
_death: i could see that, but it's a shame to discard the architecture. i'd work on one, but i have so little experience with user interfaces that it'd come off shoddy
11:05:20
_death
well, I started a simple general purpose TUI thingy not long ago.. I touch it infrequently but at some point it will be good enough for Microsoft GitHub :)
11:11:26
Demosthenex
i don't care for github myself. i don't normally post code so i hadn't looked for an alternative, but i'm using hg and fossil
14:00:40
xificurC
I have malformed json, there's a \- sequence which falls through an ECASE in both cl-json and yason. The json output isn't mine and cannot change it. What would be the best aproach to combat this? There's no reasonable restarts provided since they are just an ECASE. Maybe I can wrap the stream in a stream that corrects this sequence?
14:16:22
dlowe
xificurC: the usual thing is to use regexes to fix your crummy data to fit into the parser
14:23:23
Shinmera
hacking in a restart to skip a char and continue seems easier and more robust to me
14:57:16
xificurC
skipping that I still get an error (using yason now) later on parsing an object. This seems to be getting a bit weird, e.g. jq parses all lines fine and yason chokes on the first ones. I'm reading a stream with (loop for line = (read-line stream nil nil) ...), that shouldn't alter anything right? Running cmd |& while IFS= read -r line; do jq . <<<"
15:39:27
makomo
pfdietz: right that is clear -- and now that the body has been fully expanded and the results have been computed, how does the outer macro fetch the results? does this transfer happen via global state or in some other way? you mentioned the inner macros "stashing" the results away, how?
15:42:22
pfdietz
It has to walk over the expanded form and somehow retrieve it from there. The inner macro will have placed it there in some form the outer macro's function can recognize.
15:43:46
makomo
pfdietz: i see, but i can't think of any way how it might do that, without affecting the code in the body.
15:46:19
pfdietz
Or into something that has useless but valid code. (progn (hey-look-at-this (quote ...)) <actual form>)
15:48:41
makomo
pfdietz: so when passing information top-down, it's possible to do it portably. when passing information bottom-up, i need MACROEXPAND-ALL to fully expand the body?
15:52:47
pfdietz
In practice, it's de facto portable. https://github.com/cbaggers/trivial-macroexpand-all
15:53:42
makomo
pfdietz: ok, i'll try to apply the technique to my case. thanks for taking the time to explain
15:55:31
makomo
MichaelRaskin: hello. this one should be fine since it's not a "user-level" implementation
15:56:26
makomo
MichaelRaskin: does the caveat concern the representation of environments? you mentioned it a few days ago but i didn't completely understand
15:57:52
makomo
MichaelRaskin: also, i wanted to give agnostic-lizard a go but i didn't find any comprehensive explanation of the whole thing. where should i start?
16:03:02
MichaelRaskin
The same page (bottom) contains the proceedings link, there is a write-up there
16:03:52
MichaelRaskin
I do follow the most popular way of writing a code walker, just with a few heuristics to approximate a solution to the impossible problem.
16:09:30
MichaelRaskin
Hm, quite a lot of implementations where trivial-macroexpand-all just ignores the env parameter
17:04:24
pfdietz
Is there a way in ASDF to say "if systems FOO and BAR are both loaded, then also load system BAZ"?
17:05:20
scymtym
there is a system called asdf-system-connections but it caused many problems when i tried it
17:05:29
pfdietz
The use case for this is when FOO has some special case handling in case BAR is loaded (for example, defines some methods on classes defined in BAR), but doesn't otherwise require BAR to work.
17:05:54
pfdietz
The specific use case was trying to use COVER and finding it didn't work on macros from ITERATE.
17:08:00
pfdietz
I'd want it to work if I loaded FOO before BAR, and also if I loaded BAR before FOO. When the second of the two loaded, BAZ would also be loaded.
17:10:40
Bike
"We do NOT recommend you use this feature. If you are tempted to write a system foo that weakly-depends-on a system bar, we recommend that you should instead write system foo in a parametric way, and offer some special variable and/or some hook to specialize its behaviour; then you should write a system foo+bar that does the hooking of things together."
17:14:32
whartung
but that sounds to me, pfdietz, that you’re trying to make some kind of “smart”, “universal” project. Why should the “project” figure out what your code needs. YOU know what it needs, and you know what you want it to do. So, do it. If you want BAZ loaded with FOO and BAR, then do that. Why have logic hanging around for BAZ if you’re not using BAR in the first place?
17:18:56
pfdietz
I want to be able to load COVER and have it work, without me (as the user) having to manually specify those dependencies.
17:19:32
pfdietz
And I don't want loading COVER to then cause all those other packages it has interactions with to also get loaded.
17:55:11
stylewarning
I wonder if the ASDF folks would be open to having a :LICENSE-FILE option for system definitions
17:55:45
stylewarning
That would be monumentally more orderly and convenient---at least for commercial folks---than the paltry license description in the :LICENSE argument.
18:16:04
_death
the asdf manual gives an example with :license but it's not actually specified in the grammar.. so I guess you could have :license (:file "LICENSE" :executive-summary :MIT)
18:28:26
oni-on-ion
i do a similar thing to use .cl extension, (defclass cl-file (cl-source-file) ((type :initform "cl")))
18:31:18
oni-on-ion
idk. this works for me, i was not sure of the expanded and fully resolved name. although naming the subclass cl-file does not clarify matters
18:33:27
oni-on-ion
ohhh i see what you are saying. it is already built in to asdf for .cl , sorry i did not see what you mean.
18:35:02
oni-on-ion
i've developed a particular interest in ".?l" extensions as of late -- prolog .pl, elisp .el, julia .jl, ocaml .ml - and i did not want CL to be left out. also it is semantically more practical to me when extensions are acronyms rather than full words
18:35:28
oni-on-ion
yes. i remember DOS Abuse game, my first exposure to lisp i think. unless i used emacs before this i cant recally
18:35:34
aeth
Don't use .LSP on Unix or NT-based Windows because three character file names have a ton of collisions
18:41:24
oni-on-ion
.pl is the same as perl, already github thinks some of my projects are not in prolog hehe.
18:44:24
aeth
It doesn't just go by extension. I've seen some 'Newlisp' and even some *Python* in CL projects as a false identification
20:05:35
Shinmera
pfdietz: I added my own system to handle that ASDF case. Essetially it defers evaluation and compilation of specific forms until a specified system is loaded.
20:07:38
Shinmera
In radiance all systems that can make use of this deferral must be a subclass of a special system, for which theres an asdf:perform :after method that triggers evaluation
20:09:03
Shinmera
you could add a method on the standard asdf:system, but who knows how long that would work for (since upstream could add a method of its own)
20:12:01
Shinmera
Typically in radiance you use this optional mechanism to provide extra functionality if an implementation of a certain interface is loaded. Since the interface's symbols are always available even without an implementation, symbol resolution in the optional code is also no problem
20:12:55
Shinmera
example: https://github.com/Shirakumo/radiance-contribs/blob/master/r-simple-auth/auth.lisp#L225-L241
20:15:47
Shinmera
The lack of a proper optional dependency spec in ASDF has always bothered me though. Would make this problem much easier
20:18:36
Xach
Well, this does help me in the quicklisp world, because I can statically set the dependencies.
20:19:34
Shinmera
Since then you could do something like: throw the optional code into an optional.lisp, then add (when (find "thing" (asdf:already-loaded-systems) :test #'string=) (load (merge-pathnames "optional.lisp" #.*compile-file-pathname*)))
20:22:54
Xach
Shinmera: the Old ways of doing it made it hard to discover optional dependencies. a new, explicit way would be ok though.
20:23:15
Xach
Like, you might not ever find out that system X required system Y because you never loaded X while Z was also loaded.