IRC channel logs
2025-08-21.log
back to list of logs
<mgd>Hello all. Thank you for your help the other day. I had to log off but I went through the logs. <mgd>Again, I ask this coming from other languages but how do you remember what modules do? I'm struggling with the naming conventions like srfi-9? It looks like the ice-9 module is a bit easier as you can say (ice-9 regex) for example. Am I missing something? <ArneBab>mgd: I check https://srfi.schemers.org/ (and know a few, i.e. srfi-26 is cut). I import these via (import (srfi :26 cut) ← the last part is just a label that’s currently not actually checked. <ArneBab>ice-9 I remember by name ; became easier to remember the ice-9 namespace after reading the background (ice-9: the perfect crystal seed) <ArneBab>mgd: to make code reading easier, you can use (import (only (srfi :26) cut)) ← this is now checked, and that way I know where a symbol comes from by reading the code. <mgd>ArneBab: I did read that. Very cool :) <mgd>Is that convention to import like that within Guile? <ArneBab>mgd: that’s the r7rs way to import but it works in Guile <ArneBab>mgd: guile has a use-modules form that also enables selecting specfic modules, but I prefer import. <ArneBab>I think the srfi :N <label> way only works with import. <ArneBab>on the srfi page you can filter by topic, that makes it pretty convenient to find the library you need. <mgd>Thank you. Basically I'm interested in building tools to help with conservation efforts. I've done this in the past with python and I am trying to replicate that with Guile. I use Emacs/EXWM and now Guix. The reproducible build part intrigued me. I also always wanted to learn a scheme/lisp outside of elisp. <mgd>Most of my tooling is geospatial based using PostGIS, Geopandas and QGIS/Grass. I appreciate that Guile probably doesn't have libraries for this but it would be interesting to see what can be achieved <mgd>ArneBab: would I use that import statement in a (use-modules) statement? <ArneBab>mgd: no, you just use (import ...) on top-level. It can be used interchangeably with use-modules. <mgd>ArneBab: The chart on the link you send is amazing! Really helpful <jfred>mgd: It's really cool that you're looking into using Guile in a project for conservation efforts! :) <identity>mgd: for SRFI library names, see SRFI 261; R^{6,7}RS is good reference material, i myself consult R^7RS regularly, as are The Guile Reference Manual and The Scheme Programming Language by R. Kent Dybvig <mgd>jfred: I've done back end with Spring before but I really want to do some good in the world. I think open source can play a big part in that. Have a look at https://wildlabs.net/ for examples of nature based tech <mgd>Is there some function for shuffling a list? <identity>mgd: Guile has RNGs, see (info "(guile) Random") and (info "(guile) SRFI-27"), so implementing a ‘shuffle-list’ procedure should be easy <old>mgd: I'm interested to know more about that conservation efforts. Could you expand or show a link? <mgd>It's a really interesting field <identity>that is more useful for vectors, though i guess you could (vector->list (shuffle (list->vector list))) <rlb>Ahh, yeah -- in my case I was building a result vector from a lazy sequence. <old>new wish: Add a set-default-C-thread-stack-size! procedure <old>I get segfault while evaluating huge s-expr in threads other than the main thread. on x86-64, the default size of the stack is 2MB and Guile recursively evaluate s-expr on the C stack <sneek>I've been aware for 7 months <sneek>This system has been up 30 weeks, 5 days, 6 hours, 27 minutes