IRC channel logs

2016-08-20.log

back to list of logs

<daviid>wingo: hello! I compiled guile-gnome against 2.1.3, make check pass. FI, the g-iddle-add.scm snipset tests (http://paste.lisp.org/+6LP8 - which runs test-4 per default) still segfault using 2.1.3, but it after 35 min instead of 3 to 4 min using 2.0.12
<daviid>sneek: later tell janneke I compiled guile-gnome against 2.1.3 and FI, I did run the g-iddle-add.scm snipset tests (http://paste.lisp.org/+6LP8 - which runs test-4 per default) which still segfault, but after 35 min (compared to the 3 to 4 min using 2.0.12)
<sneek>Okay.
<sapientech>mark_weaver: daviid thanks very much for the reply, seems exactly what im looking for!
<sapientech>currently porting rooster-graph (boost-graph library) to guile, almost there, but having difficulties with an error
<sapientech>ERROR: In procedure make-struct: Wrong type argument in position 1: #<procedure xyz-vertex (g n)>
<sapientech>since this all occurs in a huge define-macro expression, there isn't a clean backtrace
<sapientech>currently trying to get more information on the matter + not too familiar with make-struct, if anyone has some ideas let me know!
<sapientech>is make-struct called when (make-vector ...) called?
<paroneayea>holy shit davexunit, AO is awesome
<paroneayea> http://www.mattkeeter.com/projects/ao/index.html for reference
<sapientech>okay, looks like the error is coming from (define-record-type, which i assume does call make-struct
<mark_weaver>sapientech: 'make-struct' expects its first argument to be a vtable, but apparently it's getting passed a procedure instead
<mark_weaver>are you using the same identifier for both the name of the record type and for a procedure?
<sapientech>mark_weaver: ah okay i'll check
<amz3`_>here is an l system using Ao http://i.imgur.com/P2g5nkL.jpg
***amz3`_ is now known as amz3`
<amz3`>challenge complete!
<amz3`>the grammmar is not left recursive for some reason
<amz3`>I mean that the grammar procedure is not a tail call
<alezost>amz3`: instead of (eq? iteration 0) you can use (zero? iteration)
<alezost>in your 'grammar' procedure I would also move (null? seq) check inside match: (match (() '()) ((1 . rest) ...) ...)
<alezost>but you probably know better what you want :-)
***mario-go` is now known as mario-goulart
<alezost>btw why do you neet "let loop" in 'recurse'? It can be simple written as: (define (recurse grammar seed iteration) (if (zero? iteration) seed (recurse grammar (grammar seed) (1- iteration))))
<amz3`>alezost: thx for the review ^^
<cbaines>I'm having some difficulties with the repl, I've got a bug in my code, but the backtrace is mostly from ice-9/eval.scm, and while that makes sense, its not very helpful in working out where the bug is. Is there a way to get a backtrace that is relevant to the code I have written?
<cbaines>Hmm, I deleted .cache/guile and I'm now getting better backtraces
<cbaines>:)
<davexunit>my new blog, powered by Haunt, is now live. :) https://dthompson.us/
<stis>davexunit: great!
<amz3`>davexunit: cool
<davexunit>thanks!
<amz3`>cbaines: did you install guile 2.1.3?
<amz3`>what is the equivalent of numpy in guile?
<amz3`>numpy is library to do fast matrix operations
<amz3`>I have 5k valid document \\o/
<amz3`>nalaginrut: o/
<OrangeShark>morning everyone
<amz3`>morning OrangeShark
<fantazo>ACTION loves and hates the compiler tower. /me loves it because it's a cool thing, but hates it becaues he doesn't understand it.
<davexunit>OrangeShark: blog migration was a success. guile-commonmark really accelerated the process.
<OrangeShark>davexunit: awesome :)
<fantazo>davexunit, to what did you migrate your blog?
<OrangeShark>fantazo: haunt
<fantazo>from what?
<OrangeShark>pelican which is written in python
<fantazo>ah, ok.
<fantazo>what were the problems during the transition?
<OrangeShark>fantazo: I think originally his blog was written in markdown, there were no markdown->sxml until I released guile-commonmark.
<OrangeShark>one problem he had was that guile-commonmark didn't support inline/block html so he couldn't include video but he made some sort of hack to convert something to html videos
<fantazo>why using sxml? I feel for sxml that it's one of those "napkin technologies": badly documented technologies.
<OrangeShark>fantazo: easy to manipulate and write in lisp
<fantazo>OrangeShark, sure it's s-expr. but calling it "easy to manipulate" is something I couldn't find for myself. I found it more confusing and ill behaving.
<fantazo>but maybe I'm still too "new" to scheme. given that I'm off and on playing with it since five years.
<OrangeShark>well they are just lists, so you have access to all your list functions
<fantazo>I normally want so mundane things like that when I read somewhere an example for sxml -> xml conversion, which I type in and then it doesn't work. that was the last time I tried to do something with sxml. Which was a couple of months ago.
<OrangeShark>fantazo: I am pretty new to scheme as well, I haven't had any major problem with sxml
<fantazo>OrangeShark, ok.
<OrangeShark>fantazo: the guile manual has a section called Types and the Web which explains a bit about sxml
<OrangeShark>it basically the alternative to appending together strings to create xml/html
<fantazo>hmm, sxml implementation of guile seems not to support "annotations".
<fantazo>of the root node(?). Well, whatever I need to play around with it more again. but now I couldn't find the one thing which was so damn annoying about it.
***petercommand is now known as PointerCompound
***PointerCompound is now known as petercommand
<mark_weaver>fantazo: what is an "annotation" in this context?
<fantazo>mark_weaver, first do we agree that this site is important for sxml? http://okmij.org/ftp/Scheme/SXML.html
<mark_weaver>yes
<fantazo>then we have annotations here: http://okmij.org/ftp/Scheme/SXML.html#Annotations
<fantazo>and then there is this snippet here: (*TOP* (@ (id-collection id-hash)) (p (@ (id "id1")) "par1"))
<fantazo>when I do: (sxml->xml (*TOP* (@ (id-collection id-hash)) (p (@ (id "id1")) "par1")))
<fantazo>I get an error: unknown file:7:0: source expression failed to match any pattern in form (@ (id-collection id-hash))
<fantazo>so I derived from that error, that annotations aren't supported on the TOP node in guile.
<fantazo>maybe I'm wrong. but this snippet is from the page which says it specifies revision 3 of the sxml specification.
<mark_weaver>okay, this is beyond my knowledge. I've never tried to use those on the *TOP* node.
<mark_weaver>I've only tried to use them to represent attributes, which only make sense within other nodes.
<mark_weaver>I do think that our implementations of 'sxml->xml' and 'xml->sxml' have some issues regarding their handling of XML namespaces. see https://bugs.gnu.org/20339
<fantazo>it seems that I couldn't re-produce those problems I had with sxml a couple of months ago. I remember only that I typed something in and sxml->xml complained about it, even when it looked "right".
<fantazo>what's is more daunting transpiling scheme to another lisp dialect or compiling scheme to object code?
<fantazo>I looked today and yesterday at the guile compiler tower and even the brainfuck implementation makes my head spin.
<fantazo>Does really anybody beside the original author of the code understand that thing?
<fantazo>it always baffles me that I still don't know enough about scheme to be able to productively use it.
<paroneayea>whew!
<fantazo>I don't know well enough syntax-rules. nor can I judge why pmatch is needed for a specific problem and somewhere else just match.
<paroneayea>just read through the r6rs io documentation entirely. It's a pretty easy read but I'm having a pretty laaaazy saturday.
<fantazo>paroneayea, what part of r6rs do you mean by "io"? I couldn't find it.
<mark_weaver>fantazo: section 8 (I/O) of the r6rs-lib document
<mark_weaver> http://www.r6rs.org/final/html/r6rs-lib/r6rs-lib-Z-H-9.html#node_chap_8
<fantazo>mark_weaver, oh.. that wasn't obvious. has more of a footnote than something important.
<mark_weaver>a footnote? it's a fairly large chapter
<fantazo>well, nope. I just couldn't find the link on the list. needs really careful reading.
<mark_weaver>couldn't find the link to what? on what list?
<fantazo> http://www.r6rs.org the top links to each document. All those five links look the same from the name. I didn't realize that there is a standard library link there. so I clicked on the scheme language link, which defines scheme itself + base library.
<davexunit>paroneayea: finally dogfooding haunt properly: https://dthompson.us/
<paroneayea>davexunit: yayyyy!
<paroneayea><3 haunt
<paroneayea>looks nice
<davexunit>thanks! it even has syntax highlighting for scheme, xml, and c. :)
<davexunit>still need an elisp lexer...
<paroneayea>:)
<paroneayea>davexunit: I need to write a reader for restructured text
<paroneayea>so I can switch over my own site to haunt..
<davexunit>would have made my migration a lot easier ;)
<davexunit>I converted everything to markdown
<paroneayea>ha :)
<davexunit>which wasn't that bad because they are similar enough, but still tedious
<paroneayea>well I have 96 .rst files :P
<davexunit>yeah...
<paroneayea>in dustycloud's repo alone
<davexunit>I had 23
<davexunit>so more manageable
<paroneayea>14 in mediagoblin's
<davexunit>if I had 96 I would have written a parser
<paroneayea>:)
<davexunit>but rst looks like no fun to parse
<paroneayea>I think the real rst parsing solution might be to not parse rst :)
<paroneayea>leverage python's own tooling
<paroneayea>convert from rst -> something sensible
<davexunit>maybe pandoc could take care of that for you
<paroneayea>oh yeah pandoc
<paroneayea>!
<paroneayea>I forgot about that tool
<davexunit>maybe I should have used that
<paroneayea>haha :)
<davexunit>didn't even think of it until now
<paroneayea>well at least you got the valuable experience of... hm...
<davexunit>...
<davexunit>oh well :)
<paroneayea>:)
<davexunit>it didn't take thaaaat long
<davexunit>and it was pretty brainless so it was a good way to pass the time when I wasn't able to do anything mentally demanding
<fantazo>davexunit, haha yup rvm is a mess. I'm always wondering why ri isn't working with it in my env. I always get really really weird error messages.
<davexunit>fantazo: thanks to guix I don't use RVM anymore :)
<davexunit>still use bundler, though.
<davexunit>some day I hope to eliminate that, too
<fantazo>guix sounds now like a wonderweapon
<davexunit>it's been very useful for me
<fantazo>ok. the last time I skimmed it I thought I see difficult to write package definitions. when I compare that to Archlinux PKGBUILD files I find complex not so sexy.
<daviid>wingo: I found a nasty bug :) in master: when one tries to compile a module which imports (srfi srfi-1) (oop goops), declare #:duplicates to merge-generics _and_ in some code in the module you use for-each, guild compile fails with this message I reported on another circumstance: ice-9/boot-9.scm:753:26: No applicable method for #<<generic> merge-generics (3)> in call (merge-generics #<directory (foo) 2000bd0> for-each #<interface
<daviid>(guile) 1d45ea0> #<procedure for-each (f l) | (f l1 l2) | (f l1 . rest)> #<interface (srfi srfi-1) 1d8fa20> #<procedure for-each (f l) | (f l1 l2) | (f l1 . rest)> #f #f)
<fantazo>but maybe I remember it wrong. And definetly need to look at it again.
<daviid>wingo: I'll paste a tiny test in a minute
<davexunit>fantazo: I find it *much* better than arch pkgbuilds
<davexunit>never had an easier time writing packages
<davexunit>and the fact that the packages are regular scheme objects means I can do lots of great programmatic transformations to produce variants of those packages
<fantazo>davexunit, replacing rvm, bundler, npm, bower, whatever is a good move. throw that shit away. make package management not a rocket science anymore.
<davexunit>which I've taken advantage of several times
<fantazo>hmm, ok. I seem to put guix on my reading list then.
<davexunit>it's moreso that the packaging paradigm is different that makes it seem foreign at first, compared to the distros we're used to.
<daviid>wingo: here http://paste.lisp.org/+6XTN
<fantazo>docker is also some pile of snake oil. as if doing all yourself is an improvement.
<daviid>wingo: in this paste, if you either comment line 3 [the srfi-1 import] or part of line 6 [;;merge-generics], it compiles fine, but 'as is' it fails
<fantazo>ACTION runs into the woods, as he doesn't really know much about docker actually.
<daviid>wingo: although it's a bit of a 'funny module', since it does not use any srfi-1 procedure (but for-each which is replaced by srfi-1) neither does it need to merge-generics in this case, but it is the tiniest reproduction of the same bug on 1 of my module which does need this iport and merge-generics for 'good'...
<mark_weaver>daviid: wingo is on vacation for another week, iirc.
<mark_weaver>better send this in email
<paroneayea>whee
<daviid>wingo: and 2.0.12 'guild compile foo.scm' fine
<daviid>mark_weaver: ah ok thanks, will send a bug
<paroneayea>mark_weaver: do you know how to run the guile test suite for just one file?
<fantazo>davexunit, why did you write sly and didn't use the product of the market leader (unity3d) I heard is the best since sliced bread (and everybody who doesn't use it is extremly stupid) by promotors of unity3d
<mark_weaver>paroneayea: e.g. ./check-guile numbers.test
<paroneayea>mark_weaver: perfect, thank you