IRC channel logs

2015-11-12.log

back to list of logs

<paroneayea>ArneBab_: I think you especially will find that link interesting
<paroneayea>since it's "determine parens by indentation" among other things
<paroneayea>looks like I am going to FOSDEM then!
<paroneayea>I'd better book tickets...!
<polyphagia>where is it?
<nalaginrut>morning guilers~
<marusich>I notice that some variables etc. begin with a % in guile. Does it mean anything? I searched using Google and looked at every occurrence of % in the Guile manual, but I couldn't find a definitive answer.
<artyom-poptsov>marusich: Hi. AFAIK, one convention is that global variables that should be immutable (that is, changing of such variables will have serious or undesired consequences) should be named with '%' as a prefix. like this: '%global-immutable-variable'
<artyom-poptsov>In case of procedures, prefix '%' may indicate that this procedure is a low-level one and potentially dangerous.
<artyom-poptsov>See also: http://www.cliki.net/Naming+conventions
<artyom-poptsov>Also it seems that in Common Lisp the role of '%' is taken by '+..+': https://google.github.io/styleguide/lispguide.xml#Global_variables_and_constants
<marusich>Hm, interesting. Thank you for the info and the links.
<artyom-poptsov>There's also "Riastradh's Lisp Style Rules" <http://mumble.net/~campbell/scheme/style.txt>, but it doesn't mention '%' convention at all.
<nalaginrut>maybe because it's "Lisp Style Rules" ? ;-P
<artyom-poptsov>nalaginrut: Hi. Hmm, do you mean that '%' convention is somewhat unusual for Lisp?
<artyom-poptsov>My guess is that '%' was introduced to distinguish global mutable variables from immutable ones.
<nalaginrut>artyom-poptsov: I'm kidding ;-)
<nalaginrut>but maybe it's different in Scheme? I don't know ;-P
<artyom-poptsov>Heh, but I'd love to hear any thoughts on '%' from more experienced Lisp programmers.
<nalaginrut>personally, I add % before an inner or low-level thing
<artyom-poptsov>nalaginrut: Alright, that's the common usage of '%', I guess. Is there any Scheme coding style guide that explicitly mention this convention?
<nalaginrut>I never know that, I think it's some kind of word of mouth...
<nalaginrut>anyway, a natural rule often generated in this way
<wingo>mark_weaver: re: building on i686, excellent!
<fps>hmm, what is the usual way of signalling error conditions from within a procedure?
<artyom-poptsov>fps: Exceptions?
<fps>artyom-poptsov: that's what i would use mostly in c++, but i'm a guile noob
<fps>ok, will look up guile exceptions
<artyom-poptsov>fps: See "Exceptions" and "Error Reporting" In the Guile manual: https://www.gnu.org/software/guile/manual/html_node/Control-Mechanisms.html
<fps>artyom-poptsov: thanks
<wingo>moin
<wingo>civodul: i mentioned the ltdl thing on my blog because mark_weaver and i had discussed it here iirc
<civodul>hey, wingo
<civodul>ah ok
<wingo>i agree that though we can mention plans, observations, opinions etc elsewhere we should discuss on guile channels :)
<civodul>yeah and that bit sounded like "the libtool hackers are a bunch of assholes"
<civodul>which i think is inappropriate here
<wingo>mmm, it's not that libtool is unmaintained, ltdl was unmaintained at that point
<civodul>well, a casual observer could say that Guile is equally unmaintained
<civodul>by looking at the last release date of 2.0
<wingo>this was 2008 or 2009 or so, mind you...
<civodul>so we need to be careful ;-)
<civodul>ok
<wingo>heh fine :)
<civodul>but yeah, Libtool is probably not very active, that's for sure
<wingo>but i think that what ltdl offers us is approximately of zero value
<civodul>it has small value, because it's a small piece of code
<civodul>but i would not want to reimplement the portability stuff in Guile
<civodul>in a project at work people did reimplement that sort of stuff
<wingo>it's not just portability
<civodul>and of course, it's half-baked
<wingo>it's also versioning
<wingo>it would be nice to (dynamic-link "libm") and have it work even if libm.so isn't there
<civodul>how so?
<wingo>to be able to specify soversions you are compatible with also
<wingo>i.e. if only libm.so.N.M.O is there
<wingo>i think ltdl would not make a bad gnulib module but as a separate project it's too much trouble
<wingo>and the .la stuff is bonkers
<wingo>for dynamic linking, anyway
<civodul>so you're saying it would be fine if we bundled it?
<wingo>yes, and partially evaluated it against our needs :)
<civodul>libltdl has been around for ages, so one is unlikely to find a distro that doesn't have it
<civodul>that's not a case for bundling IMO
<civodul>regarding versions, .so.xyz is probably not the right way to go
<civodul>i think symbol versioning is more appropriate
<civodul>dlvsym and the likes
<civodul>because you wouldn't know what do put as the "xyz" in ".so.xyz"
<civodul>so this is just to say that it's not all that trivial
<wingo>that doesn't meet the use case at least. you want to be able to load libraries like libsqlite3 without caring whether the .so link is there or not
<wingo>and without forcing debian and other users to install -dev packages
<civodul>oooh that, i see
<civodul>sorry i had misunderstood what you meant
<civodul>yes i agree
<wingo>there's *also* the question about wanting to load a lib with a single major soversion
<wingo>for example
<civodul>yes, but that's where i think dlvsym might be better
<civodul>anyways
<wingo>could be, yeah, but ltdl doesn't support that
<civodul>let's add it
<wingo>nope :)
<wingo>not me, yo
<wingo>sorry, that sounds rough
<civodul>prefer to reimplement it?
<civodul>yes
<wingo>let me try again
<wingo>i am unwilling to wait for ltdl to be everywhere and to have to have compat code to ltdl versions. i think the amount of code we are talking about if we incorporated this lib would be 500 lines *at most*. that to me says we should bundle it, no question
<wingo>if it were in gnulib that would make more sense
<wingo>but not as a separate lib
<civodul>that it's already "everywhere" for my notion of everywhere, and that we *removed* the bundling of ltdl in Guile years ago, suggests to me there's no reason to go back and revisit that decision
<civodul>ltdl *was* bundled in the old days
<wingo>yep
<wingo>so, i meant "the new hacked version of ltdl"
<wingo>and regarding history: i think the landscape of operating systems is different now than it was in 2008. we can just rely on dlopen now and maybe have a windows implementation.
<wingo>and maybe end up pushing the windows implementation to gnulib
<civodul>maybe
<civodul>just to be clear, i'm actually fairly rather open on these issues, contrary to the impression i give ;-)
<civodul>what i'm opposing to is throwing the baby with the bathwater
<civodul>we have to be humble
<wingo>:)
<wingo>yeah i'm not proposing to change anything right now
<civodul>and discuss these things with those which i consider to be "members of our team"
<wingo>we'd need a reason, some sort of cost-benefit thing
<civodul>that means libtool people, gnulib people, etc.
<civodul>and think not of our own little short-term Guile benefits, but that of the greater team
<wingo>you are better at that than i am, i think :) whenever i propose something to gnulib or libtool it fizzles out
<civodul>and don't gratuitously piss off Eli and others who struggle with Guile on Windows
<civodul>s/don't/not/
<wingo>ACK :)
<civodul>well i'm not saying it's easy, there's a "communication cost" as you put it
<civodul>but doing it our own way has its costs too
<wingo>it fizzles out and so i end up not doing the thing
<civodul>and we're not Google
<civodul>yeah, i sympathize
<civodul>i mean it can be tricky, and it's not a very rewarding task
<civodul>so it's natural to be tired of that
<civodul>i'm no different in that respect ;-)
<wingo>heh
<civodul>but we must put some effort in that direction
<wingo>i don't mean to push this work off to you either :)
<wingo>so i guess saying it's a natural thing is missing the point
<civodul>i doubt it
<civodul>saying "we can do better than 'them'" is missing the point
<wingo>but even then i think there are valid reasons to avoid building a distributed system subject to combinatoric composition, with separately released modules on wildly different release and deployment schedules
<wingo>(i meant that i was missing the point)
<wingo>(not a criticism of you but of myself)
<civodul>so yeah, it's not black and white
<civodul>there are technical issues, and social issues
<civodul>maybe neither is perfect
<civodul>probably, even
<civodul>but we can't live in our own world
<wingo>i disagree with that, i guess :)
<wingo>we often have choices to re-use or to re-implement and there are costs and benefits and sometimes we will do one and sometimes the other
<wingo>saying "we can't live in our own world" is not useful imo :) we can always choose to implement. it might not be a good decision but we _can_ do it :)
<wingo>sometimes a good decision, sometimes a bad one.
<wingo>as a programming language implementation, we implement patterns of all sizes; we don't dynamically link to a ConditionalBranchProviderImplementation :)
<wingo>but we do link to libc of course
<wingo>and in between, many choices
<wingo>and this is a silly library : https://www.gnu.org/software/libtool/manual/html_node/Libltdl-interface.html :P
<wingo>also!!!
<wingo>the friggin error codes from libltdl
<wingo>the worst.
<wingo>god i hate those.
<civodul>yes, right
<civodul>it has it warts and all that, no disagreement here
<wingo>it's always "file not found". and the worst thing is, they are constrained to emit those codes because of something about their use case
<wingo>which is a use case that we don't care about
<wingo>i don't recall the details
<civodul>FSVO "we" :-)
<wingo>but to fix it you have to think hard about abstractions that don't matter to users
<wingo>and in practice: that bug is *still* there, unfixed, after probably about 10 years.
<wingo>whereas if it were in guile it would be fixed. completely bonkers
<wingo>no i really think that particular use case didn't matter to guile
<wingo>but ok, we can keep on telling users to strace their guile processes to figure out what file ltdl is failing to load :)
<wingo>ACTION did an apt-cache rdepends on libltdl and got a surprisingly long list of projects, wonders what these projects find of utility in ltdl
<wingo>an honest question
<civodul>that agressive rhetoric, "bug is *still* there", is exactly what we dislike of dak
<civodul>it's not OK
<civodul>dak keeps repeating everywhere that Guile is "unmaintained and broken beyond repair"
<civodul>same story
<civodul>in both cases, there are problems
<civodul>but pointing fingers doesn't help
<wingo>i have to figure out why i am communicating in this bad way, that's not what i meant to do
<wingo>i do think there is something wrong with the situation and it's not the fault of the libtool maintainers, or at least i don't hold them at any fault
<wingo>i would like to find a way to criticize both libtool and the organization of our project without claiming that libtool people are assholes (something that i did not intend to do, and tbh i am not sure that's what i did; could it be you are making the project->people link too strongly? dunno)
<civodul>i can hear the technical criticism, and i agree with a large part of them
<civodul>but i think that saying publicly that "project Foo is unmaintained" is aggressive
<civodul>and hostile towards the people behind Foo
<wingo>ack
<civodul>i understand that was not your intent
<civodul>but that's how i perceive it
<wingo>so here's what i was trying to say. this bug is there and unfixed, and it's not because people haven't tried to fix it.
<wingo>i know i've spent many hours on it and i think other people have as well.
<civodul>ok, understood
<wingo>and i suggest it's something about our social organization that is preventing some things from being fixed.
<civodul>ok
<wingo>for me specifically telling me to go back and spend more time there is... well it's unlikely that i do it :) hence the knee-jerk nope, just not somewhere i feel it's productive to spend my time
<wingo>i apologize for indirectly suggesting that the libtool maintainers were somehow irresponsible, i'll try to avoid that in the future
<wingo>and so for me the expected effect of this social division is probably a prolongation of the current set of bugs. not critical bugs but they sure are irritating.
<civodul>ok, got it
<civodul>maybe i was just underestimating the badness of the situation, too
<civodul>that was some time ago
<wingo>well, i had forgotten it mostly, i was just roused into vehemence remembering some of the bugs :) this indignation too will pass away :)
<wingo>happy hacking :)
<civodul>:-)
<civodul>happy hacking! ;-)
<ArneBab>paroneayea: nice! that looks roughly like wisp-on-the-fly ☺
<dsmith>wingo, make check passes on my 32bit single core system
<dsmith>real 298m40.363s
<dsmith> time (git clean -dxf; ./autogen.sh && ./configure && make -j2 && make check)
<wingo>hoo, 5 hours...
<wingo>good that make check passes tho
<dsmith>model name : Intel(R) Pentium(R) M processor 1.70GHz
<wingo>so the test
<wingo>(use-modules (rnrs bytevectors)) (define (sum bv) (let ((len (bytevector-length bv))) (let lp ((i 0) (sum 0.0)) (if (<= (+ i 4) len) (lp (+ i 4) (+ sum (bytevector-ieee-single-native-ref bv i))) sum))))
<wingo>then (define fv (make-f32vector #e1e7 1.0))
<wingo>then ,time (sum fv)
<wingo>i get 0.175s on this machine
<wingo>but anyway you should see 0 gctime
<wingo>because all the floats are unboxed in that loop
<wingo>i am going to give a go at unboxing 64-bit ints this evening on the train
<wingo>we'll see how that goes
<wingo>it seems reasonable given that so many instructions work on integers in the range [0, most-positive-fixnum]
<wingo>like vector-ref and so on
<wingo>in that loop i should be able to unbox the other loop variable too
<wingo>sadly for some reason bytevector-length isn't getting hoisted; had to do it manually :P
<wingo>need to fix that
<dsmith>;; 0.718000s real time, 0.702000s run time. 0.000000s spent in GC.
<wingo>0 in gc is good anyway :)
<dsmith>heh
<dsmith>wingo, And it's v2.1.1-29-g13edcf5
<wingo>cool
<wingo>i was getting around 60 cycles per loop iteration, you get around 120 cycles
<wingo>which i guess is explained by the difference in age of these machines, dunno tho
<taylan>wingo: it works now :) only problem is progress reporting at presence of multiple threads. is there anything I can do short of using mutexes (ew)?
<taylan>ACTION checks the Guile manual's Scheduling section
<taylan>oh, maybe mutexes aren't so bad with with-mutex
<taylan>hmm, monitor also looks interesting
<taylan>in fact it might be exactly what I need
<wingo>i think monitor is probably not what you need
<wingo>i'm not really sure what it's supposed to do, tbh
<wingo>pretty sure (with-mutex (make-mutex) FOO) is a no-op, semantically :P
<taylan>oh, I hoped it does some magic so that (par-for-each (lambda (x) ... (monitor FOO)) xs) ensures FOO not overlapping
<taylan>assumed, even
<wingo>apparently not
<wingo>i think maybe it used to do something like that
<wingo>when we had our old expander
<wingo>embedding the mutex into the AST or something
<wingo>funny, no bug reports on that :)
<taylan>not sure if I saw 'monitor' anywhere else than in Guile, so maybe nobody uses it, although it seems perfect for this use case
<taylan>hmm, Objective-C has @synchronized(obj){ ... } where a mutex is "derived" from obj
<wingo>indeed
<wingo>yeah so that's been broke since 7902c547 in 2009
<wingo>ACTION broke it
<taylan>wow :D
<taylan>kinda scary to be honest
<wingo>our threading story is kinda scary :/
<taylan>I find it very neat that we can just (begin-thread ...) and such though. and let-binding a mutex outside the par-for-each then using with-mutex should fulfill my use-case, and that's very clean too.
<wingo>that is indeed nice
<wingo>lexical scoping + threads is pleasant
<cmhobbs>hey folks! can i execute an external command with guile kind of like how backticks or %x{} works in ruby?
<cmhobbs>also, is there any batteries-included bits for parsing JSON?
<mark_weaver>cmhobbs: there's 'system' and 'system*' for running commands
<cmhobbs>cool, thanks! i'll dig those up in the reference manual
<cmhobbs>i wish i had the reference manual in info
<cmhobbs>err
<cmhobbs>not the reference manual
<cmhobbs>err wait
<cmhobbs>is the reference manual on the website different than the info pages?
<mark_weaver>as for JSON, there's guile-json, an external package, although we're not happy that they use hash tables for represent JSON objects, so davexunit has a proposed library that will soon be part of core guile. just needs some more revisions before it goes in.
<mark_weaver>cmhobbs: the reference manual on the web site is the same as the guile info manual
<cmhobbs>interesting
<cmhobbs>for whatever reason i thought they were different
<djcb>oh, nice to hear about the json lib
<cmhobbs>that'll make my life easier since i can just hit the info pages from right inside emacs
<mark_weaver>I recommend the info manual, because you can easily look things up in the index with the 'i' command.
<cmhobbs>ig uess i could look at the manual in emacs online with eww but meh
<cmhobbs>right
<cmhobbs>i prefer the info pages
<mark_weaver>info is *much* more efficient to use than the web manual
<djcb>once you have the key bindings in your muscle memory
<cmhobbs>yeah
<Petit_Dejeuner>mark_weaver: what's wrong with using hash tables?
<Petit_Dejeuner>I'm just curious.
<taylan>Petit_Dejeuner: I think the main problem is that they generally don't go well with functional programming style
<jjwatt>clojure handles them pretty well in a functional style
<taylan>I was about to mention Clojure maps :)
<taylan>sorta kinda have a distant plan of writing an SRFI for something like them, distinct from SRFI-126
<davexunit>jjwatt: those are a different data structure entirely
<taylan>^ they're immutable maps, not contentional hash tables
<davexunit>many of us really want persistent hash tables and vectors in guile core
<davexunit>a la Clojure
<jjwatt>true. but they "look" like them
<davexunit>but conventional imperative, mutable hash tables are useful in some cases
<taylan>davexunit: have you looked into ijp's pfds?
<Petit_Dejeuner>Racket has something similar for dictinaries. hash-ref and hash-set (note the lack of !)
<davexunit>taylan: yes, he has an implementation and so does wingo
<jjwatt>davexunit: that would be great
<taylan>oh, many to choose from :)
<davexunit>wingo experimented with them and gave them cute names like "fector" and "fash"
<davexunit>:)
<davexunit>I plan to use this stuff in my game engine
<taylan>ijp's vectors were also called fector, didn't know of fash
<taylan>"map" is probably too prone to confusion with map procedures
<dsmith-work>Morning Greetings, Guilers
<dsmith-work>wingo: On my work system, 4 cores:
<dsmith-work>real 94m47.712s
<dsmith-work>
<dsmith-work>v2.1.1-29-g13edcf5
<dsmith-work>wingo: 64bit Intel(R) Core(TM)2 Quad CPU Q8200 @ 2.33GHz
<dsmith-work>
<dsmith-work>wingo: And the time there is ;; 0.280389s real time, 0.280121s run time. 0.000000s spent in GC.
<jeffrin>hello all
<jeffrin>is it necessary to learn calculus to learn HTDP ?
<alexshendi>Hi folks, I built guile 2.1.1 on OpenBSD/amd64, but 3 of 37 tests fail. Is anyone interested in the output?
<davexunit>alexshendi: sure! I would send the report + logs to bug-guile@gnu.org
<alexshendi>davexunit: Where are the logs located? I did "gmake check > CHECK.LOG 2>&1" is that sufficient?
<davexunit>log files should have been automatically written to a test-suite.log file or something similar
<alexshendi>I have now run "check-guile" wich writes a "check-guile.log". Is this correct?
<davexunit>alexshendi: sounds right. take a peek inside and see if the relevent backtraces and such are in there.
<alexshendi>davexunit: It looks relevant but is about 3 MB in size. Should I gzip it and attach it or put it on my website and send a link?
<davexunit>I think a guile maintainer could answer this better than I could.
<davexunit>mark_weaver, civodul: what logs should alexshendi send to report test failures?
<civodul>check-guile.log should have everything
<civodul>+ test-suite.log
<alexshendi>I don't have test-suite.log
<cmhobbs>where would i find docs on the system/system* modules or can someone point me to example usages of them, please?
<cmhobbs>oh disregard, i think i'm being dumb
<cmhobbs>i'm liberally applying parenthesis where they don't belong
<cmhobbs>yep
<cmhobbs>it'd still be nice to see the docs for that procedure, though
<davexunit>cmhobbs: they are in the POSIX section of the manual
<davexunit>section 7.2.7
<cmhobbs>yeah, that's where i was digging. searching for "system" was too ambiguous of an option
<cmhobbs>i got it, thanks
<davexunit>also, you can use REPL metacommands to get docstrings
<davexunit>,d system
<davexunit>,d system*
<cmhobbs>woah!
<davexunit>,d is short for ,describe
<cmhobbs>what dark sorcery is this!?
<cmhobbs>amazing
<davexunit>procedures may have docstrings
<davexunit>(procedure-documentation system)
<cmhobbs>hopefully (but probably not) last question for the day: what docs should i look at if i want to get some data from an api? something like curl in gnu+linux or ruby's net::http
<davexunit>section 7.3.8 has information about guile's http client
<davexunit>http-get is the procedure you want most likely
<cmhobbs>outstanding, thanks!
<cmhobbs>yep
<davexunit>https support requires using a third party library
<davexunit>the gnutls guile bindings
<cmhobbs>i'm going to pull info from an api over http (no ssl) and use that to execute a few system commands
<davexunit>so https is more work than it should be right now.
<davexunit>cool
<cmhobbs>automating some things at the office and i'm using it as an opportunity to further practice guile
<davexunit>I think you will find it useful for this
<cmhobbs>great
<davexunit>pardon the youtube link, but just over 3 years ago I uploaded a video to youtube to show off some of my first stumblings with using Guile for game development: https://www.youtube.com/watch?v=Jez_ZdrcWCs
<davexunit>crazy that it's been 3 years
<davexunit>(and I *still* never shipped a game)
<davexunit>this was back when I did all the graphics programming in C and used libguile to embed guile into the program. things sure have changed for me since. :)
<davexunit>and knowing that guile master now has unboxed floating point ops... I think I made the right choice to move to pure Scheme.
<davidh>is there a way to redirect the output of `system'?
<davexunit>davidh: you should use pipes for this.
<davexunit>see open-pipe and friends
<davidh>i see, thanks
<cmhobbs>how do i actually get to the response body from http-get?
<cmhobbs>and sorry for the pile of questions
<davexunit>it's the second value returned from http-get
<cmhobbs>great!
<davexunit>at the REPL you should see both printed, for example
<davexunit>see call-with-values or let-values for dealing with procedures that return multiple values
<cmhobbs>i think my problem is that the response body is actually empty
<cmhobbs>red herring
<davexunit>ah
<cmhobbs>now that the body isn't empty, i'm getting a wierd format that i didn't expect:
<cmhobbs>#vu8(123 116 101 115 116 58 39 100 97 116 97 39 125)
<cmhobbs>
<cmhobbs>any idea what that might be? it should be plain text
<cmhobbs>curl returns the appropriate text
<cmhobbs>and http-get works on other urls
<cmhobbs>that's not base64
<davexunit>that's a bytevector
<cmhobbs>the rabbit hole goes deeper :D
<cmhobbs>i'll dig up docs on those
<cmhobbs>thanks
<cmhobbs>again, sorry for the pile of questions
<cmhobbs>section 6.6.6 here i come >:]
<davexunit>what headers are returned?
<davexunit>guile will automatically convert the response to a string if the content type makes sense
<cmhobbs> #<<response> version: (1 . 0) code: 200 reason-phrase: "OK" headers: ((content-type application/octet-stream)
<cmhobbs> (accept-ranges bytes) (etag "3901519478" . #t) (last-modified . #<date nanosecond: 0 second: 59 minute: 10 hour:
<cmhobbs>21 day: 11 month: 11 year: 2015 zone-offset: 0>) (content-length . 13) (connection close) (date . #<date nanosecon
<cmhobbs>d: 0 second: 43 minute: 54 hour: 17 day: 12 month: 11 year: 2015 zone-offset: 0>) (server . "EC2ws")) port: #<clos
<davexunit>utf8->string will convert a bytevector to a string
<cmhobbs>ed: file 0>>
<cmhobbs>welp
<cmhobbs>should've used pastebin
<cmhobbs>sorry
<davexunit>just don't use pastebin.com
<cmhobbs>right
<cmhobbs>i usually use paste.lisp.org
<davexunit>they are bad and block tor users
<davexunit>yeah
<davexunit>anyway
<davexunit>application/octet-stream
<davexunit>that's why you get a bytevector in return
<cmhobbs>ah, makes sense
<cmhobbs>good to know
<cmhobbs>now to convert this to something useful
<davexunit>so since it really is text use ut8->string
<davexunit>from (rnrs bytevectors)
<cmhobbs>rnrs bytevectors?
<davexunit>yes
<cmhobbs>utf8->string should be provided by ice-9 iconv, right?
<davexunit>maybe?
<davexunit>I dunno
<davexunit>it's exported by (rnrs bytevectors)
<davexunit>that's where I use it
<cmhobbs>i keep getting 'unbound variable' for it
<davexunit>it's definitely there
<davexunit>are you using an old guile or something?
<cmhobbs>2.0
<cmhobbs>on trisquel
<cmhobbs>installed via apt
<davexunit>2.0.?
<cmhobbs>2.0.11
<davexunit>okay
<davexunit>perfect
<davexunit>it's definitely in (rnrs bytevectors)
<davexunit>scheme@(guile-user)> ,a utf8->string
<davexunit>
<cmhobbs> http://paste.lisp.org/display/159292
<davexunit>you didn't import (rnrs bytevectors)
<cmhobbs>oh ffs
<cmhobbs>this is why one shouldn't program while exhausted ;)
<davexunit>np
<fantazo>emacs is planned to use guile? I read that once somewhere.
<OrangeShark>fantazo: there is already a version that uses guile
<fantazo>OrangeShark, ok. is that even emacs then? I mean emacs is known for its elisp runtime
<OrangeShark>fantazo: which is why guile is working to support elisp
<OrangeShark>guile-emacs is available on guix, but I haven't tried it yet
<ArneBab>OrangeShark: guile-emacs from guix works for me
<OrangeShark>fantazo: apparently the new release of guile has complete Emacs-compatible Elisp implementation http://lists.gnu.org/archive/html/guile-devel/2015-11/msg00007.html
<ArneBab>OrangeShark: at least guile-emacs works well enough that it can execute org-mode to export my PhD thesis to LaTeX.
<OrangeShark>ArneBab: that is great, I need to try it out when I have the chance to
<ArneBab>it’s still slow because it precompiles all modules everytime it starts, but I think it’s already really impressive
<ArneBab>OrangeShark: if you already use guix, it is really easy to get guile-emacs — it builds right away
***thomas_ is now known as Guest70756
<unknown_lamer>ArneBab: solution: never quit emacs!
<ArneBab>:)
<daviid>wingo: heya! how far from the top of your todo list is #20093 ? any approximate idea about when you plan to work on it ?
<ArneBab>unknown_lamer: that’s what I do at work…
<cmhobbs>mark_weaver: given you don't recommend the existing json parsing module and dave's module isn't in guile yet, what do you recommend for parsing json?
<cmhobbs>also, since i control the data i'm going to be consuming and it's just a string, is there a better string i can feed into guile?
<davexunit>cmhobbs: guile-json works just fine.
<davexunit>we use it in guix
<davexunit>we just think it can be done better for core guile
<cmhobbs>unknown_lamer: you people quit emacs? that's insane!
<unknown_lamer>I don't!
<cmhobbs>davexunit: alrighty. would there be a more useful string?
<unknown_lamer>oh nice, there's a json module now
<cmhobbs>i just want some keypairs
<unknown_lamer>maybe I should rewrite my crappy python hack kodi remote in guile
<davexunit>unknown_lamer: ooh sounds fun
<davexunit>cmhobbs: install guile-json
<davexunit>it will do what you need
<cmhobbs>roger that
<cmhobbs>this is coming together nicely
<unknown_lamer>davexunit: http://git.hcoop.net/?p=clinton/unknownlamer-kodi-addons.git;a=tree;f=party-upload;
<cmhobbs>i'm at that point with guile where i mostly know what i want to do and it just takes some trips through the reference manual to get me to my finished product
<unknown_lamer>davexunit: a few more features I ahven't committed, but it's fugly and I was wanting to make it more useful and the code is so bad I can't so...
<cmhobbs>like a baby deer trying to stand, heh
<davexunit>haha
<davexunit>you'll get there!
<unknown_lamer>please tell me the new guile web framework supports POST without it being a huge pain finally... that's pretty much the reason I went with cgi.py before heh
<cmhobbs>yeah, i used to use common lisp really heavily so guile flows well
<davexunit>unknown_lamer: the (web ...) family of modules do pretty much everything I've needed.
<davexunit>I don't use any web framework like artanis because I have my own preferences
<unknown_lamer>ACTION ports uncommonweb to guile
<davexunit>I use pattern matching to handling routing rather than a convential string-based routing system.
<davexunit>for example.
<unknown_lamer>ucw: seemed like such a good idea, but reality bites
<cmhobbs>what is guild?
<davexunit>a helper program
<cmhobbs>kk
<davexunit>has a variety of subcommands for doing helpful tasks like compiling
<davexunit>and it's extensible
<davexunit>so users can add new subcommands to it.
<cmhobbs>cool
<cmhobbs>just noticed it when installing guile-json
<Xe> https://gist.github.com/Xe/458a69409c3ff97c3587
<Xe>i keep getting this when trying to use guile
<cmhobbs>i'm not sure what's going on there but have you tried loading it from just plain old sh? just incase zsh has some strange PATH issues?
<mark_weaver>Xe: did you run "make install" ?
<mark_weaver>how did you install guile?
<Xe>debian package manager
<Xe>then removed the debian version and tried to `make install` guile
<Xe>then I got that error
<Xe>and continue to get it no matter what
<Xe>even after uninstalling guile completely
<mark_weaver>well, libguile has a compiled-in location where to look for ice-9/boot-9.go, and apparently it's not there
<mark_weaver>I would make sure everything it cleared out and try the debian package again.
<mark_weaver>s/it/is/
<mark_weaver>specifically, the guile-2.0 package
<mark_weaver>and then we can try running it within 'strace' to find out what's going on.
<mark_weaver>you can also run guile directly out of the built source directory by running "./meta/guile"
<mark_weaver>that should arrange to use all the things from within the source directory itself.
<mark_weaver>Xe: ^^
<Xe>strace guile: https://gist.github.com/Xe/3935d60701db4038e8aa
<mark_weaver>ACTION looks
<mark_weaver>Xe: according to https://packages.debian.org/stretch/amd64/guile-2.0-libs/filelist, the guile-2.0-libs package contains the file /usr/share/guile/2.0/ice-9/boot-9.scm, but it seems to not be there on your system.
<mark_weaver>sounds like maybe you installed the package and then manually removed that file?
<mark_weaver>the strace includes the line: stat("/usr/share/guile/2.0/ice-9/boot-9.scm", 0x7fff3ebbc6f0) = -1 ENOENT (No such file or directory)
<Xe>reinstalling that package fixed it
<mark_weaver>okay
<Xe>thanks mark_weaver
<mark_weaver>you're welcome, happy hacking!
<cmhobbs>well, hash tables feel clumsy
<nalaginrut>ACTION implemented tables in guile-lua-rebirth according to Lua-5.0
<amz3>hello
<cmhobbs>hi amz3
<amz3>how is going you hacking cmhobbs
<amz3>?
<cmhobbs>yeah, going well. building some stuff at work to automate image creation for some of our machines
<cmhobbs>it's a ruby project but i'm using guile as glue
<cmhobbs>yourself?
<amz3>well, I'm kinda doing nothing :D
<amz3>I'm writting some package for guix for software I need some stuff
<cmhobbs>outstanding!
<cmhobbs>i'm excited about guix development
<amz3>:)
<cmhobbs>i'd like to use it as my primary package manager and os some day
<davexunit>I packaged up my game engine for guix to do integration testing
<amz3>otherwise I hack on guile-wiredtiger, a leveldb like library
<davexunit>got all of the issues with the build system worked out.
<amz3>(they are bindings)
<amz3>davexunit: you debug guix with sly?
<davexunit>other way around
<davexunit>I use guix to make sure that my code builds the way I expect it to
<amz3>I'm wondering, whether, maybe, if it's possible, one day, if it's a good thing
<amz3>to have a guix builder for pure guile packages :)
<davexunit>I want to combine guix and sly to make a dungeon crawling rpg called "dependency hell"
<davexunit>in which you traverse the guix package DAG
<davexunit>and the details of the packages are used as input to the dungeon generator
<davexunit>would be hilarious.
<davexunit>the final boss is in the bootstrap binaries
<cmhobbs>bwahahaha
<cmhobbs>ACTION dies
<davexunit>it's a damn good idea
<cmhobbs>i'd play it
<cmhobbs>i'm trying to decide between trying to become a savannah hacker or finding bits of guix to help with for my spare time right now
<cmhobbs>guix would help with my guile progress, i think
<civodul>davexunit: don't forget TeX Live too ;-)
<bavier>davexunit: sounds like an excellent game idea
<davexunit>civodul: that's the secret boss
<davexunit>I think an interactive package visualization program in Sly would be fun, too.
<davexunit>with some old-school pixel art graphics
<davexunit>just for kicks
<civodul>:-)
<cmhobbs>any idea why this would retrun 'wrong type to apply'? http://paste.lisp.org/display/159324
<cmhobbs>i suspect my parens are off
<cmhobbs>the guts of that work, receive and friends
<cmhobbs>and it returns the byte vector i want when it complains about wrong type to apply
<davexunit>'response-body' is not a procedure
<cmhobbs>ah, good catch
<davexunit>I need to come up with a very easy, but neat, thing to demo in a screencast for Sly
<davexunit>time to realize the damn thing
<davexunit>er, release
<cmhobbs>awww yeah, guile code up in this repository at work. pullreq approved
<cmhobbs>they won't rip it out now :D