<amz3>actually I'm using format to convert the array of bytes to an hex number and then use string->number to convert it to a number <galex-713>But I’m no much sure it’s disapointingly faster than a cleaner approach :/ <galex-713>Know what? if I were you I would just code that cleanly and procedurally, and just suppose the day native compilation will come this code will be good and efficient, even if currently it’s not <galex-713>Except if you’re actually using your code for something useful, then it is different <amz3>I was planning to bind libxml2 library but this lib is so massive, that I may only bind what I need <galex-713>then you have to use the horrible-ugly-distasteful way <amz3>I should probably use ash but I'm not sure right now what to do <galex-713>amz3: does it just take more ram than it should or does it provide really inefficient functions? <amz3>galex-713: what are you talking about? <amz3>I'm not sure why you think that <amz3>I said there is a lot of things in libxml <amz3>that's why I won't create bindings for it right now <amz3>now I can benchmark libxml against ssax guile module :D <amz3>ssax is the module powering xml parsing in guile <amz3>no sxpath is something else <amz3>sxml is the output of ssax parser <galex-713>Yeah but to find hierarchized stuff in sxml you need sxpath <amz3>there is basically two apis in xml world, sax and dom <amz3>but they do different things <amz3>sax is a parser API which allows to parse an xml file without having to put it all in memory <galex-713>don’t know sax, know little of dom, hoped a doc for xpath but found none <amz3>I learned xpath on w3school website <amz3>but since I don't pratice it often I often check the syntax on SO <amz3>there is some doc now on master <galex-713>Also even if it’s more unixy, I don’t like using slashes, gt or lt are way more logical <galex-713>ijp: logical here = coherent with human culture of common meaning of « > » and common meaning of « / » outside computing legacy <amz3>yeah, css is terse syntax compared to xpath <amz3>I think there is a module in Python that allows to query JSON with css syntax <ijp>that's a very grandoise anthropological claim <galex-713>ijp: that is a claim concerning most languages including « / » or « > », especially math (except for « / », yet it has a different meaning than « including/superior to ») <brendyn>I have never quite seen a style like that <brendyn>I have never seen a style quite like that <amz3>here is a paste of my sax parser using libxml2, it segfault for some reason I'm not sure why <amz3>it doesn't segfault all the time tho <amz3>because ssax is too slow, but I might revert to that solution if I can't fix this issue <wingo>you are running over utf-8 ports on 2.1.x with buffered input? <amz3>2.1 is faster but still much slower than python's libxml2 bindings <amz3>I think it will do the job <wingo>how much slower? and is it slower for python with libxml2 using SAX or using some DOM or other library? <wingo>i would expect something like 5-7 times slower but i dunno <wingo>native compilation should get us within a factor of 2, then there are more optimizations to do <amz3>something like 10 times slower <wingo>could be more things to optimize there <ruste>How is guile doing on concurrency? I like what I've seen so far, futures etc., but how do they compare to haskell, erlang etc? <ruste>Where do we fall short? Just less efficient? Are we missing features? <davexunit>I think wingo has written about this somewhere <ruste>Hmmmm. I can't find anything on his blog. Or google can't at least. <ruste>paroneayea: for guile? We'd have most of a web scraping library at that point. All that would be left would be https support. <paroneayea>ruste: yes (and at least, for the guile library I'm working on) <ruste>Do we have https support? I think I asked about this a few days ago... <davexunit>ruste: gnutls comes with guile bindings, so you can handle https requests that way <ruste>davexunit: I tried that and was never able to get it working. Something about the server and my client not being able to agree on protocols. <ruste>I've been using guile-curl for now. <davexunit>okay, well that's the way to do it so I dunno <davexunit>does guile-curl even expose a port interface? <ruste>davexunit: it does what I need it to for now. <ruste>davexunit: I don't think so. <ruste>Just wraps the curl easy interface. ***dje is now known as xdje
<paroneayea>guile's lack of https / tls support out of the box is probably its biggest current visible hole <paroneayea>yeah there are ways to do it, but they're leaky and hard to set up. it should just work. <ruste>I'd rather it not come with https than add another dependency. <paroneayea>anyway, it's possible to have it be a configure-time option. <wingo>it could be an ambient thing <ruste>paroneayea: That is a possibility. I like things that depend on as little as possible. <wingo>like if gnutls is installed, then https is usable <wingo>otherwise you get an error telling you to install gnutls <ruste>I like that better than most other options. <wingo>when you first try to use an https link <ruste>I think I'd prefer having the whole web client thing in a separate but easily installable package that requires gnutls/ssl <ruste>Is it common to package web client libraries with a language? <davexunit>we're approaching philosophical differences here <davexunit>I really don't like stripped down minimalism <davexunit>I think Guile should come packed with useful things <davexunit>http(s) clients and servers are so commonly used that it only makes sense for guile to support them out of the box <ruste>I could see putting it in guile-lib. Then if you want minimalism you just install the core. If you want packed with useful things you install guile-lib. <ruste>python does have http, I don't see https though. <davexunit>python's huge standard library is one of its greatest strengths <davexunit>we should aspire to have something so useful <paroneayea>if you want a more minimal scheme, there are more minimal schemes out there :) <davexunit>as long as it meets a criteria of general usefulness and is worth the maintenance burden. <ruste>paroneayea: Consider me the loyal opposition. :) <ruste>paroneayea: I have used sxml. It's pretty nice. <davexunit>in the nodejs community, it's common to make libraries that provide only a single function. in fact, it's recommended. <ruste>davexunit: I've heard some pretty convincing critiques of that. <paroneayea>anyway, I think all the maintainers want https / tls support in guile, it's not whether the project wants it or not :) <davexunit>that's the extreme end of the minimalist "keep everything out of core" mentality <davexunit>the suckless project is another good example of misguided minimalism <ruste>davexunit: I fight for it knowing I'm going to lose. <davexunit>dwm, for instance, where you have to write some nasty C code and recompile it to configure it, because anything else is surely bloated. <ruste>davexunit: As far as C code goes it was pretty gorgeous, that's an argument for another day though. (They openly admit it's to keep the userbase elitist. <ruste>paroneayea: As far as implementing https goes, are we just talking about gnutls because that's what we have bindings for? <davexunit>the point is that Guile more aligns with projects like Emacs and Python <ruste>Are there licensing reasons for not using SSL? <ruste>davexunit: I agree. I think it's a good goal to strive to be like python. <ruste>As far as useability etc. goes. <ruste>davexunit: OpenSSL etc. Sorry, that was unclear. <dsmith-work>Python does seem to have a whole lot of useful stuff out-of-the-box <brendyn>Can I publish a website in sxml or do webbrowsers not support it? <davexunit>brendyn: that's not how sxml is supposed to be used. <ruste>Something about being able to render the page before it's done downloading. <davexunit>you use sxml to manipulate sxml documents within your program and then serialize it to xml <ruste>Every xml document has exactly one corresponding sxml document and vice versa. <davexunit>you can't reproduce the exact same input document <davexunit>because it doesn't preserve whitespace or comments <ruste>davexunit: Those aside, yes? <thomeith>i love sxml. programming servers in guile has been a dream come true for me thanks to it and the (web server) package. <thomeith>but i do wish we had a general functional reactive library like Rx. there is a reactive component of the Sly guile game engine which i haven't tried yet, though.