IRC channel logs

2015-10-03.log

back to list of logs

<davexunit>rekado: did you ever get skribe working with haunt?
<davexunit>I'd like to start chipping away at my own blog and move it to haunt, partly because I'm embarrassed at how you beat me to it a long time ago now.
<davexunit>if possible, I'd like to add an optional dependency on skribilo that can read Skribe and convert it to SXML
***karswell` is now known as karswell
<sturm>Hi folks. I'm trying to get sxml->xml to do UTF-8 encoding, but not having much luck eg. (sxml->xml `(p "♥")) returns <p>?</p>. Any suggestions?
<sturm>I've had a look at the SXML docs in the Guile Reference, but there's not much there about this procedure.
<paroneayea>sturm: what happens when you just evaluate
<paroneayea>"♥"
<paroneayea>does that return a string with the heart character properly?
<sturm>paroneayea: that's interesting if I run a program (display "♥") I get back a question mark. I strangely can't seem to paste the heart directly into the interpreter, instead it pastes sxml-"".
<paroneayea>sturm: I think this has to do with default port endocing stuff not being utf-8
<paroneayea>scheme@(guile-user)> (sxml->xml `(p "♥"))
<paroneayea><p>♥</p>s
<paroneayea>oops
<paroneayea>minus the last s
<paroneayea>sturm: I got that from a guile repl right at the normal command line (not through emacs)
<paroneayea>so I think it's not sxml
<paroneayea>it's guile reading characters :
<paroneayea>\\
<paroneayea>from your input
<paroneayea>sturm: but see also
<paroneayea>%default-port-encoding
<paroneayea>sturm: I dont' know how to set the port encoding of the repl and such things, you may want to ask in here while it's a bit more active
<paroneayea>sturm: also btw, if you're new to #guile, welcome!
<paroneayea>sturm: good to see a familiar face, at least :)
<sturm>thanks paroneayea, I'll look into port encoding. This is Guile build from Guix too - don't know if that may be related.
<sturm>Thanks, I feel very welcome :)
<sturm>%default-port-encoding says: #<fluid 6>
<paroneayea>sturm: try
<paroneayea>(fluid-ref %default-port-encoding)
<paroneayea>sturm: it could be guix related, especially given current locale stuff which is happening in guix
<paroneayea>not sure if you're following that
<paroneayea>but I don't know how locales work actually
<paroneayea>and I might just be confused
<paroneayea>wouldn't be the first time
<sturm>paroneayea: Yes, I think this may be Guix related - just tried my system Guile 2.0.9 and that handles unusual characters fine. Now that I notice, my Guix Guile 2.0.11 does warn on startup "warning: failed to install locale: Invalid argument".
<sturm>paroneayea: was installing Guile 2.0.11 to play with dthompson's Haunt project. :)
<artyom-poptsov>sturm: I think you should try 'setlocale' procedure: https://www.gnu.org/software/guile/manual/html_node/Locales.html#Locales
<artyom-poptsov>sturm: The locale affects the way that Guile I/O procedures work. E.g. try this: https://gist.github.com/artyom-poptsov/5c7d490ab7a8343d1e80
<artyom-poptsov>paroneayea: FWIW, ^
<sturm>artyom-poptsov: thanks very much, I'll give it a shot
<sturm>artyom-poptsov, paroneayea: I think there's something not quite right with my Guix Guile. Running (setlocale LC_ALL "") fails with "ERROR: In procedure setlocale: Invalid argument".
<sturm>I'll do some more hunting around in that respect.
<artyom-poptsov>sturm: I'm using Guile 2.0.9 and the example works fine. What version of Guile do you use (see 'guile --version')?
<artyom-poptsov>sturm: Ah, and I think you should check whether the needed locale is supported by your system. You can get the list of supported locales by means of 'locale -a' in your shell.
<artyom-poptsov>In my case there's "en_US.UTF-8" locale and therefore (setlocale LC_ALL "en_US.UTF-8") works.
<artyom-poptsov>That probably might be the catch in your case.
***micro` is now known as Guest97848
<luk>hello again, I'm still trying to compile guile-gnome. I have a more recent version of guile in /opt now that I want make to use - but I'm lost on the options to ./configure . Internet is also no much help.
<sturm>artyom-poptsov: thanks very much for the help - it turns out that while my system locale is all set up ok, Guix uses a separate set of locale data, which needs the glibc-locals package installed plus LOCPATH environment variable set.
<sturm>I eventually came across a Guix mailing list post from paroneayea with the same error.
***Guest97848 is now known as micro`
<amz3>héllo
<amz3>can we say that guile is also a procedural langage?
<taylanub>amz3: I'd say yes, since we can define and call procedures :-)
<amz3>thanks
<taylanub>although Wikipedia contrasts "procedural" to "functional" ... I think these terms are really very vague
<taylanub>in fact it apparently lists "procedral" under "imperative." then again, Scheme supports imperative programming just fine.
<taylanub>meh, "semantics"
<amz3>the context of my question is somehow asking to compare graphdb and rdbms to languages
<amz3>s/somehow/someone
<amz3>it seems to me rdbms are like java (typed and OO)
<amz3>and graphdb are like dynamic languages like python, scheme
<amz3>where guile better fits the multi-model kind of graphdb
<amz3>in the sens that it can handle different kind of programming styles
<amz3> https://news.ycombinator.com/item?id=10323505
<taylanub>ACTION is a noob on databases
<taylanub>BBL
<amz3>I don't know much either, I'm kind of database journalist, in the sens I know the thing but never use it to solve real problems
<paroneayea>sturm: yes the guix situation with locales is kinda messed up right now. I'm using `export LC_ALL`C' as my temporary solution
<paroneayea>er =C
<paroneayea>sturm: basically I set it up in the guix-enable command I use to set up the env variables
<sturm>paroneayea: thanks. I have Haunt running nicely now. Writing HTML as nested Lisp lists actually appeals to me a lot for some reason. :)
<amz3>pollen ftw!
<amz3>ACTION hides
<paroneayea>sturm: woo!
<luk_>hey daviid, how are you?
<daviid>hello guilers
<daviid>luk_: very well thanks
<daviid>did guile compile fine yesterday?
<luk_>yes, its compiled ant in /opt allright
<luk_>I tried to find the option to ./configure to use the new guile myself but so far it didn't work.
<daviid>perfect, now we start to compile guile-gnome, you need to do this in the terminal in which you'll do so:
<daviid>make distclean first then
<luk_>no rules for that - I did it yesterday
<daviid>ok
<daviid>export GUILE_WARN_DEPRECATED=detailed
<daviid>export ACLOCAL_FLAGS="-I /opt/share/aclocal"
<daviid>export PATH=/opt/bin:/sbin:/usr/sbin:/bin:/usr/bin
<daviid>export LD_LIBRARY_PATH=/opt/lib:/usr/lib:/lib
<daviid>export PKG_CONFIG_PATH="/opt/lib/pkgconfig:/usr/lib/pkgconfig"
<daviid>./autogen.sh; ./configure --prefix=/opt; make; make check
<luk_>ok, now compiling
<daviid>in the mean time can yo see if you can remove the pacman guile or not?
<luk_>I think I can
<luk_>good idea
<daviid>it will let you remove if no other package depends on it
<daviid>make sure you purge the package, not just uninstal ...
<luk_>shit, it says make depends on guile!?
<daviid>ok fine
<luk_>make check failed again :(
<daviid>is it the same error?
<daviid>in that terminal could you do
<luk_>yes. GClosure...
<daviid>which guile
<luk_>/opt/bin/guile
<daviid>it should have worked. did you uninstall yesterday?
<luk_>gnome-guile yes
<daviid>let's just make sure
<daviid>make uninstall
<luk_>ok
<daviid>make clean
<luk_>but now it has a new prefix btw
<daviid>ah yes
<daviid>you see, it's as if it's loading the old copiled lib
<daviid>could you do this
<daviid>cd /usr
<luk_>yep already there and searching ;)
<daviid>find . -name \\* | grep guile-gnome
<daviid>and double check all are empty
<luk_>only clean folders
<daviid>ok
<luk_>maybe clean the caches?
<luk_>is there only ~/.cache?
<daviid>i don't thik it is that, when make check it did say it compiled the guile-gnome modules right?
<daviid>put this in a file 'guile-2.0-opt-bash-settings' http://paste.lisp.org/+3CIY/1
<daviid>then run it like this: . guile-2.0-opt-bash-settings
<daviid>and paste the results please, then we'll start again
<luk_>well, it compiled some modules, but at gclosure.scm.go the fist error hist
<luk_>ok I'll do
<daviid>luk_: yes, your cache is ok because guile replaces with new version when it finds it has to compile .. that is not the problem
<luk_>yep ok
<luk_>just tried it anyway, same error
<daviid>weird
<luk_> http://paste.lisp.org/+3CIY/2
<daviid>ok, thanks. i'd like to compare the error with the 1 printend yesterday. let's do this:
<daviid>in that terminal f course
<daviid>make install
<daviid>guile-gnome-2
<daviid>,use (gnome gobject config)
<daviid>,use (gnome gobject utils)
<daviid>,use (gnome gobject gtype)
<luk_>sorry, recompiling because of the make clean
<daviid>,use (gnome gobject gvalue)
<daviid>ok
<daviid>,use (oop goops)
<daviid>(dynamic-call "scm_init_gnome_gobject_closures" (dynamic-link *guile-gnome-gobject-lib-path*))
<daviid>(define-class <gclosure> (<gboxed>) #:gtype-name "GClosure")
<daviid> ,backtrace #:full? #t
<daviid>and paste the resuts, thanks
<luk_> http://paste.lisp.org/+3CIY/3
<daviid>thanks
<luk_>Daviid, do you think it is productive to solve the error on my machine as it may occur again on other machines? Because personally I think I have some lib or whatever wired somewhere, I dont find it at the moment. and it could be gone if I start with a fresh distro
<luk_>we tried so much now
<daviid>well if you have the patience to install a new distro, I'm just trying to understand why... it could even be the C compiler [because part of goops is written in C], which is not my area. but right now i wanted to check it uses the new guile, it seems it does
<luk_>yes I think it does now
<luk_>was a good idea, but the error has to be somewhere else
<daviid>i did all this because there has been a refactoring of goops, which guile gnome uses and distro based on the [old now] 2.0.11 tarball do not have that refactoring ... hence the possible source of problems
<luk_>I see
<luk_>could indeed be the problem as parabola might not have the latest package
<luk_>hm
<daviid>but now the setting we set-up does not use the guile distro package anymore
<daviid>although i secretely suspect it still does, but without my hands on your computer really is difficult to prove :)
<luk_>:)
<luk_>I wanted to try out Guix SD anyway. seems so cool from the outside. I think I'll do that. Or do you have a last magic idea what I could try?
<daviid>no one has compiled guile-gnome on guix yet, i don't know if it has all the dependenices ...
<luk_>ok, I see.
<daviid>it would be better to try debian testing in a virtual machine maybe?
<luk_>probably you're right
<luk_>I decided to use debian testing now. It will take some time... Thank you so much daviid, I learned some new things even though we were not successful.
<daviid>luk_: could you ytry to save this in 'gg-build-with', chmod a+x gg-build-with; gg-build-with and paste the results if it worked [it may fail because it depends on package name which may differ on your distro
<daviid> http://paste.lisp.org/+3CIY/4
<luk_>ok I'll do
<daviid>run this in the terminal where you have compiled guile-gnome
<daviid>luk_: on debian you'll need to install -dev packages for all guile-gnome dependencies, not jut the core libs packages
<luk_>ok, thanks
<luk_>I used debian for a long time so I'm a bit familiar with that :)
<luk_> http://paste.lisp.org/+3CIY/5
<daviid>thanks
<luk_>do these build-problems occur regularly with guile-gnome? I ask because I think of potential users of programs written with it that may not have that much patience ;)
<daviid>luk_: no. but you are the second reporting this problem, i hope I can find out what causes it
<luk_>ok.
<luk_>anything else you want me to do to help? I'm asking because I actually decided to toast my current setup (Its 3 days old, the 3 days I spent on installing guile-gnome, so it would be not much of a loss to me. but for you maybe in that case?
<daviid>we don't have many guile-gnome users yet, but some installed 2.16.3 with no problem
<daviid>no, feel free to toast :)
<luk_>allright then. wget says you have 75 min left to ask for some diagnostics
<daviid>:)
<daviid>i touht you were going to keep the actual and build a vm with another distro
<luk_>actually I like to have real systems, bit old-fashioned I know. don't know why... but maybe youre right and I should try that. everybody seems to be doing it these days. and for a reason ;)
<amz3>given a set of procedure proc1 proc2 proc3, that takes stream as argument and return a stream, is it possible to compose them using the compose procedure as (compose proc3 proc2 proc1) ?
<amz3>I guess I should just try :D
<amz3>sorry for interupting
<amz3>I just discovered that define-stream and let-stream have the same "relation" as define and let-stream in terms of pratical usage
<amz3>it's the case one can compose stream -> stream procedure Guile is wonderful, things fit together like a beautifully crafted puzzle
<amz3>this means that my gremlin code is basicly an extension of (srfi 41) for the particular case of streams of graph nodes
<daviid>luk_: what is the exact system version you were using ? i will try to install in a vm here
<daviid>if i find the time, which is unlikely but
<luk_>recent stable parabola linux. one sec
<luk_> Current Release: 2015.08.01
<luk_>Included Kernel: 4.1.3-gnu
<daviid>ok
<zacts>hi guilers
<daviid>is there a parabola vm ready somwehere luk_ ?
<luk_>sorry, I'm the wrong person to ask for VMs ;)
<daviid>np
<amz3>this would also mean that I have more time to do fun stuff
<amz3>and do actually things that are useful ;)
<davexunit>ACTION hacks on SDL2 bindings while at FSF30
<daviid>luk_: fyi, the error occurs when executing the following https://developer.gnome.org/gobject/2.44/gobject-Type-Information.html#g-type-from-name with "GClosure", which we use to create a goops class using %gtype-class-bind. for some reason, on your system, "GClosure" is nt a registered GType, which just does not make sense, but that is what happens
<daviid>luk_: so, on your system, gobject fails to find its own structure defined here: https://developer.gnome.org/gobject/2.44/gobject-Closures.html#GClosure
<daviid>let's wait for your debian test now, I'm done with this for now
<daviid>the good news is that, afaict, the problem is not because of guile, neither the goops refactoring, neither guile-gnome
<daviid>luk_: do you know what compiler ws used to build the all chain?
<daviid>ah! gcc 5.2
<daviid>that might be the problem
<daviid>luk_: still there? could you install gcc 4.9.3 instead?
<luk_>back again
<luk_>I can try, never backported gcc
<daviid>if it's not too much work, i suspect it is the source of the problem
<daviid>and then you save to have to install another dostro, which does not sence by the way
<daviid>it's not the 'distro'
<luk_>yeah, of course not the distro itself but one package that I couldn't figure out ;) so I thought a completely different system might increase my chances
<luk_>hm
<luk_>ok, compiling the gcc now. I'll report back later
<daviid>ah cool. i thought you would find a pacman package
<luk_>kind of. there is this arch user repository which I now use to compile the correct version. There is a package definition so it not much work, only time
<luk_>parabola didn't have a package
<daviid>luk_: great!