Camelia, the Perl 6 bug

IRC log for #dbdi, 2010-07-20

| Channels | #dbdi index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
04:22 timbunce joined #dbdi
04:26 GitHub130 joined #dbdi
04:26 GitHub130 java2perl6: master Tim Bunce * 80b24a5 (1 files in 1 dirs): avoid undef warning if perl6 not installed, note need for portable fix
04:26 GitHub130 java2perl6: master Tim Bunce * d201ee4 (2 files in 1 dirs): prep for release
04:26 GitHub130 java2perl6: master Tim Bunce * fec4e10 (1 files in 1 dirs): fixup test for recent throws change
04:26 GitHub130 java2perl6: master commits a0380bb...fec4e10 - http://bit.ly/cat6Ka
04:26 GitHub130 left #dbdi
04:41 timbunce mberends: ping!
04:43 mberends timbunce: pong! (awake early in UK)
04:43 timbunce Good morning! Can you talk me through getting MiniDBI installed?
04:44 timbunce what do I need to do? (assume I'm clueless - as I am)
04:44 mberends yes, but be warned that it's broken since about 3rd July
04:44 timbunce all I have at the moment is a plan rakudo install
04:44 timbunce how broken?
04:44 mberends very badly
04:45 mberends it's Zavolaj that is not working, the NCI bits
04:46 mberends or rather, Zavolaj is losing parameters or return values.
04:46 timbunce ETA for a fix?
04:46 mberends It is probably a side effect of a fairly big Rakudo refactor
04:47 mberends the fix is uup to jnthn, and you can imagine how tightly stretched his tuits are
04:47 mberends I've tried superficial patches to zavolaj for a couple of hours and got nowhere
04:48 timbunce I'll ask him. Meanwhile could I use an old rakudo version?
04:48 mberends but then again, jnthn amazes us often with his productivity
04:49 mberends yes, a Rakudo older than 3rd July should be ok
04:49 mberends cxreg ran a bisect on Rakudo a few days ago, his findings are in the #perl6 irclogs
04:50 timbunce my rakudo is 26th june, so that's ok.
04:50 mberends :-) then we're good to go!
04:51 mberends you first need zavolaj, from github.com/jnthn
04:51 timbunce how do I install it?
04:52 mberends proto or pls may or may not be able to install zaovolaj, but to be certain, we'll do it manually
04:52 timbunce I've just forked and clones it
04:52 timbunce *cloned
04:53 mberends ok. zavolaj has a makefile, I think a `make help` explains what's available
04:53 mberends it would be good to verify that your Zavolaj/Rakudo combination is sound
04:54 timbunce [timbo@timac zavolaj]$ make test
04:54 timbunce make: *** No rule to make target `Test.pm', needed by `lib/NativeCall.pir'.  Stop.
04:54 mberends ugh..
04:54 timbunce Ah:
04:54 timbunce Before running 'make test', you *must* perform this:
04:54 timbunce sudo apt-get install libmysqlclient-dev
04:54 timbunce sudo apt-get install libtest-harness-perl
04:54 timbunce export PERL6LIB=lib
04:54 timbunce but I'm on a mac so apt-get isn't right for me
04:54 mberends assuming a debian-ish OS, is that ok?
04:55 timbunce nope, I'm on a mac
04:55 mberends right. would you use macports to install the mysqlclient library?
04:56 mberends to run the tests, we'll also need a mysql server. Same goes for Postgres.
04:57 * timbunce runs sudo port install mysql5-devel
04:58 mberends the -dev suffix on the client lib refers to how the client library is built. Seemed to be necessary.
04:59 mberends I guess mysql5-devel has client and server, and *.h files etc
04:59 timbunce umm mysql5-devel and mysql5-server-devel have the same description "Multithreaded SQL database server"
04:59 mberends the former is most likely client only then
05:00 timbunce I presume libtest-harness-perl is the standard perl Test:: modules.
05:01 mberends yes, it is. Whilst mysql is building, we can set up other parts.
05:02 mberends that Test.pm failure could some kind of path mixup. We know Rakudo has a Test.pm, so just remove Test.pm from Zavolaj's Makefile.
05:03 mberends (I think I'm going to do commit that to Zavolaj anyway)
05:04 snarkyboojum joined #dbdi
05:05 timbunce LIBSYSTEM = $(shell $(PERL6_EXE) -e 'print @*INC[2]') returns '.' for me.
05:05 timbunce so lib/NativeCall.pir: lib/NativeCall.pm6 $(LIBSYSTEM)/Test.pm
05:05 timbunce won't work
05:06 mberends Zavolaj provides you exactly one file, NativeCall.pm6. As long as it works, we just need that file to be findable on Rakudo's search path, preferably without a PERL6LIB patch. So the best thing is to copy it to ~/.perl6/lib
05:06 mberends local lib/ things are very non portable
05:07 mberends I'm more worried about the Zavolaj still being error prone
05:08 timbunce [timbo@timac zavolaj]$ perl6 -e 'say @*INC.perl'
05:08 timbunce ["/Users/timbo/.perl6/lib", "/Users/timbo/perl6/rakudo/parrot_instal​l/lib/2.5.0-devel/languages/perl6/lib", "."]
05:08 timbunce [timbo@timac zavolaj]$ mkdir -p /Users/timbo/.perl6/lib
05:08 timbunce [timbo@timac zavolaj]$ cp lib/NativeCall.pm6 /Users/timbo/.perl6/lib
05:08 timbunce so, what next? :)
05:08 mberends there are some manual "tests" in zavolaj/examples, with some setup instructions
05:08 timbunce mysqlclient.p6postgresqlclient​.p6sqlite3.p6win32-api-call.p6
05:09 timbunce does the pg one work?
05:09 mberends ok, for speed, we precompile NativeCall.pm6 to NativeCall.pir and put that file into the same timbo/.perl6/lib directory
05:10 mberends the pg one should be fine for 24 of the 32 tests currently defined
05:11 mberends it also depends on an installed client lib and server
05:11 timbunce [timbo@timac zavolaj]$ make lib/NativeCall.pir
05:11 timbunce perl6 --target=pir --output=lib/NativeCall.pir lib/NativeCall.pm6
05:11 timbunce [timbo@timac zavolaj]$ cp lib/NativeCall.pir /Users/timbo/.perl6/lib
05:11 mberends cool
05:11 mberends until it broke, Zavolaj was sooo stable
05:12 timbunce mysql is still building. I'm not sure what pg I have installed (probably only dev versions in nonstandard dirs)
05:12 mberends it survived generations of Parrot and Rakudo replacements. I had a version from May until the Troubles started.
05:12 timbunce and my battery is running low due to building mysql stuff.
05:12 mberends let's try to get the pg test working anyway
05:14 mberends Zavolaj "just" finds postgres by saying "is native('libpq')" so I wonder if that works on your install
05:14 timbunce I doubt it, but lets run the test and see... how?
05:15 mberends yes, try the zavolaj/examples/postgresqlclient.p6
05:16 timbunce [timbo@timac zavolaj]$ perl6 examples/postgresqlclient.p6
05:16 timbunce ===SORRY!===
05:16 timbunce The native library 'libpq' required for 'PQclear' could not be located
05:16 mberends of course it would be useful to have a database and a login/password, those are noted inside at the bottom
05:16 mberends urghh
05:17 mberends that may be due to having a local postgres, not installed in the system
05:17 timbunce ohh, progress...
05:17 timbunce [timbo@timac zavolaj]$ export DYLD_LIBRARY_PATH=:/opt/local/lib/m​ysql5/mysql:/Users/timbo/perl6/parr​ot/blib/lib:/usr/local/pgsql/lib/
05:17 mberends there is possibly a LIBPATH but I'm not sure of mac details
05:17 timbunce [timbo@timac zavolaj]$ perl6 examples/postgresqlclient.p6
05:17 timbunce connecting
05:17 timbunce Connection to database failed: could not connect to server: Connection refused
05:17 timbunce Is the server running on host "localhost" and accepting
05:17 timbunce TCP/IP connections on port 5432?
05:17 timbunce could not connect to server: Connection refused
05:17 timbunce Is the server running on host "localhost" and accepting
05:17 timbunce TCP/IP connections on port 5432?
05:17 timbunce could not connect to server: Connection refused
05:17 timbunce Is the server running on host "localhost" and accepting
05:17 timbunce TCP/IP connections on port 5432?
05:17 timbunce Null PMC access in invoke()
05:17 timbunce in 'exit_nicely' at line 68:examples/postgresqlclient.p6
05:17 timbunce in 'exit_nicely' at line 71:examples/postgresqlclient.p6
05:17 timbunce in main program body at line 104:examples/postgresqlclient.p6
05:18 mberends :-)
05:18 timbunce time to actually start the db server :)
05:18 mberends yeah, good plan!
05:19 timbunce [timbo@timac zavolaj]$ perl6 examples/postgresqlclient.p6
05:19 timbunce connecting
05:19 timbunce Connection to database failed: FATAL:  role "testuser" does not exist
05:19 timbunce progres!
05:19 mberends ...and see those prerequisite tips at the bottom of the script
05:21 timbunce yeah, it ran!
05:21 mberends ooh!
05:21 mberends then we can move on to MiniDBI
05:21 mberends another git clone, another install
05:22 timbunce actually for now postgresqlclient.p6 is all I need.
05:22 timbunce Thanks for your help!
05:22 mberends ok, my pleasure
05:22 mberends I guess time/batteries are short over by you
05:23 timbunce getting that way.
05:23 mberends have a blast at oscon!
05:23 timbunce thanks. shame your not here, but we'll meet up at yapc::eu, yes?
05:24 mberends yes :-) I hope the mysql comes through for you as well. It's a bit more mature and featureful.
05:24 timbunce in what way?
05:25 mberends it passes all 32 tests in MiniDBI/t/99-common.pl6 which is my main suite so far.
05:25 mberends so you get fetch* in more varieties, for example
05:25 timbunce ok. ttyl
05:25 mberends ok.
05:28 timbunce joined #dbdi
05:29 timbunce back again, at least till the battery runs out....
05:30 mberends the mysql DBD is online as the backend of pivo.jnthn.net as well
05:31 mberends kinda proves it's not vaporware
05:33 mberends I guess I'm going to have to install a legacy Rakudo to continue MiniDBD development. More so, other developers would need to do the same.
05:34 mberends I'm trying to draw others in, it's healthy for software projects to have more people involved
05:35 mberends so I was steering a path of trying to get as many commits to the repo being done by collaborators.
05:36 mberends I trust jnthn to prioritize his scarce time and have a look at the Zavolaj breakage. He does want MiniDBD to be an important part of the Rakudo * bundle.
05:40 mberends I'm now also thinking that quite a lot of the low level work can be used in DBI v2. I'm sure several other Rakudo contributors would like to get involved after 29th July. I'd like to spend some of our Perl 6 planning meeting in Pisa talking about database work.
05:56 timbunce joined #dbdi
09:31 snarkyboojum joined #dbdi
13:38 timbunce joined #dbdi
14:46 GitHub156 joined #dbdi
14:46 GitHub156 java2perl6: master Tim Bunce * dc717ce (1 files in 1 dirs): add --nocheck to default options for java2perl6api tests
14:46 GitHub156 java2perl6: master Tim Bunce * 1724453 (1 files in 1 dirs): more experimental DBDI work
14:46 GitHub156 java2perl6: master commits fec4e10...1724453 - http://bit.ly/ciNfuj
14:46 GitHub156 left #dbdi
15:02 timbunce joined #dbdi
15:11 snarkyboojum joined #dbdi
15:44 timbunce joined #dbdi
15:45 timbunce_ joined #dbdi
18:05 GitHub14 joined #dbdi
18:05 GitHub14 java2perl6: master Tim Bunce * cd02e6f (4 files in 1 dirs): DBDI work in progress
18:05 GitHub14 java2perl6: master Tim Bunce * 659bd0f (2 files in 1 dirs): DBDI work in progress
18:05 GitHub14 java2perl6: master Tim Bunce * 082f531 (4 files in 1 dirs): DBDI work in progress - actually fetches data!
18:05 GitHub14 java2perl6: master commits 1724453...082f531 - http://bit.ly/9faJRc
18:05 GitHub14 left #dbdi
18:53 GitHub144 joined #dbdi
18:53 GitHub144 java2perl6: master Tim Bunce * b3848d5 (2 files in 1 dirs): DBDI work in progress - actually fetches metadata! - http://bit.ly/9ur5VO
18:53 GitHub144 left #dbdi
19:01 mberends joined #dbdi
19:08 GitHub8 joined #dbdi
19:08 GitHub8 java2perl6: master Tim Bunce * d5c56fd (2 files in 1 dirs): DBDI - add meta getColumnLabel - http://bit.ly/baeI2o
19:08 GitHub8 left #dbdi
19:29 minusnine joined #dbdi
19:46 p6eval joined #dbdi
19:54 minusnine joined #dbdi
20:26 timbunce joined #dbdi
20:36 minusnine left #dbdi
20:37 minusnine joined #dbdi
22:24 timbunce joined #dbdi
22:30 timbunce mberends: do you have a postgresql installation handy?
23:32 mberends joined #dbdi

| Channels | #dbdi index | Today | | Search | Google Search | Plain-Text | summary