<    March 2010    >
Su Mo Tu We Th Fr Sa
    1  2  3  4  5  6
 7  8  9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31
00:04 flexd joined
00:14 benschwarz joined
00:22 flexd joined
00:25 path[l] joined
00:27 hipe joined
00:29 pietia joined
00:36 RichGuk joined
00:42 mkristian joined
00:47 sickill joined
00:49 rsim joined
00:51 mkristian1 joined
00:52 mkristian1 left
01:03 irjudson joined
01:11 irjudson joined
01:11 irjudson joined
01:13 mkristian joined
01:16 irjudson joined
01:17 RichGuk joined
01:23 mkristian left
01:42 Fullmoon joined
01:42 flexd joined
01:45 splattael joined
01:54 RichGuk joined
01:57 flexd joined
02:09 botanicus joined
02:09 slaskis joined
02:09 <slaskis> is there a blob type in datamapper?
02:09 <slaskis> it doesn't say anything about it in http://datamapper.org/docs/properties
02:11 <slaskis> should i use Object for anything binary?
02:39 benschwarz joined
02:51 ashley_moran joined
02:56 <Tass`> slaskis, nah, string
02:56 <Tass`> slaskis, or Text
02:56 <slaskis> what i want to store is a png
02:57 <Tass`> slaskis, what's a png in ruby?
02:58 <slaskis> Tass`: hah, since you ask i'm assuming a string? :P
02:58 <Tass`> slaskis, yep. ;>
02:58 <Tass`> slaskis, so store it as a Text
02:58 <Tass`> lazy loaded.
02:59 <slaskis> cool, didn't know that. i just remember using blob types in mysql when i was still writing php :P
02:59 <slaskis> Tass`: thanks
03:00 <Tass`> slaskis, well, probably there is Blob, but I'd use Text.
03:01 <Tass`> slaskis, and are you sure a MongoMapper wouldn't do better? ;-)
03:02 <slaskis> Tass`, a MongoMapper? I was going to use s3 first for storage, but since it's so little i was hoping to avoid setting that stuff up and store it in the db instead
03:07 <Tass`> slaskis, NoSQL
03:07 <notheory> Mongo db is a type of non-relational store
03:07 <notheory> bah stupid reconnects
03:09 ludicco joined
03:11 <slaskis> yeah, nosql would fit much better
03:15 <Tass`> snusnu1, *ping* about git pull :-)
03:16 <slaskis> it doesn't want to save the image...and i'm not sure if it's the terminal or if it's actually an error in the query but the update looks like this: ~ (0.002447) UPDATE "logos" SET "image" = '?PNG
03:16 <slaskis> ' WHERE "id" = 3
03:17 jeremyevans joined
03:17 <Tass`> slaskis, just get it and check the size of the image... :-)
03:23 <slaskis> hmm, checking the db with Base shows that it's there, but Logo.get() does not return anything...
03:24 <Tass`> slaskis, .get.size - might be a bit too much
03:24 <Tass`> anyway, got me a script to reproduce?
03:25 <slaskis> Tass`: sure, just a minute
03:33 <slaskis> Tass`: here's an example: https://gist.github.com/c299855a2c0160aea38d
03:34 <slaskis> the puts shows a realistic size, while the second one shows 4 as size
03:38 postmodern joined
03:38 <Tass`> slaskis, lemme install some gems... (killed my OS last week)
03:38 <slaskis> sure
03:38 hassox joined
03:38 <slaskis> i'm running dm 0.10.2 btw
03:45 <Tass`> slaskis, installed git version via rip ,-)
03:47 <slaskis> Tass`: cool, i tried rip a while ago but it was very unstable on my machine, is it better than rubygems?
03:47 <Tass`> slaskis, it's just different. rip is for git repos
03:48 <slaskis> ah, right
03:48 <slaskis> now that's brilliant :)
03:49 <Tass`> gotta go eating... no idea :-/
03:50 <slaskis> too bad, thanks for checking though
03:59 <slaskis> Tass`: if you're interested still, base64 encoding/decoding it got it working
04:01 g0bl1n joined
04:02 <g0bl1n> hi, can someone using do_postgres 0.10.1 on OSX please tell me if it runs fine ?
04:03 <g0bl1n> I keep have this problem: dyld: lazy symbol binding failed: Symbol not found: _PQsetdbLogin
04:03 <g0bl1n> the gem installs fine, but when using it to connect do a postgres server (local or remote) it crashes
04:05 <g0bl1n> datamapper 0.10.2 and do_postgres 0.10.1
04:07 <namelessjon> g0bl1n: I'm pretty sure dbussink develops on a mac.
04:08 <slaskis> g0bl1n: i used postgres the other week with datamapper without any problems
04:08 <g0bl1n> namelessjon: ty, I have it working on all my linux boxes, but not on my mac... It complies fine, no problem, but when using it, crashes on login
04:08 <g0bl1n> namelessjon: I am using it agains EnterpriseDB postgres package. Can that be it ?
04:10 <slaskis> g0bl1n: i used postgres 8.4.2 compiled from source using homebrew on osx 10.6.2 if that helps...
04:10 <g0bl1n> namelessjon: going for that right now ;) ty
04:10 <g0bl1n> ty
04:10 <namelessjon> g0bl1n: It _could_ be, yeah. I'm only guessing, I've never used a mac
04:11 <g0bl1n> namelessjon: macs are nice for desktop, but for development my opinion is: debian + gnome rocks !
04:12 <* namelessjon> runs archlinux
04:13 <g0bl1n> :)
04:14 <g0bl1n> namelessjon: just a guess, did you go to arch after gentoo ? It seems to be a behavior pattern :)
04:15 <namelessjon> g0bl1n: Nah, after flipping between ubuntu and fedora a few times.
04:16 <* g0bl1n> been flipping too but always comes home (debian)
04:23 irjudson joined
04:25 botanicu_ joined
04:27 irjudson1 joined
04:44 irjudson joined
05:03 <g0bl1n> namelessjon: oh well... homebrew rocks once again. Dumped the EnterpriseDB package, installed postgres via Homebrew and.. works! TY!
05:09 <namelessjon> g0bl1n: Glad you got things sorted.
05:09 pdelgallego joined
05:09 <g0bl1n> namelessjon: ;-)
05:24 slaskis joined
05:50 solnic joined
05:55 irjudson joined
06:03 path[l] joined
06:16 greeneggandham joined
06:19 greeneggandham joined
06:20 irjudson joined
06:21 path[l] joined
06:23 irjudson joined
06:42 adamaig joined
06:56 sickill joined
06:58 <sickill> snusnu1: Do you have an idea how can I get serializing DM models (ie to_json) to work in Rails3? I see there is "Think about integrating dm-serializer" in dm-rails readme :)
07:13 dfd joined
07:25 _pol joined
07:28 Booster joined
07:29 altrux joined
07:43 stepheneb joined
07:49 afrench joined
07:49 afrench joined
07:50 rsim joined
07:56 pdelgallego joined
08:14 solnic joined
08:44 dkubb joined
08:53 adamaig_ joined
08:56 botanicus joined
08:57 jdomg joined
09:02 stepheneb joined
09:09 <Tass`> namelessjon, soooo may I poke you to push? ;-)
09:13 snusnu joined
09:14 snusnu joined
09:25 adamaig joined
09:53 botanicus joined
09:58 Booster joined
10:12 path[l] joined
10:14 path[l] joined
10:19 hipe joined
10:21 <dkubb> good morning from Salt Lake City (or just outside)
10:21 <dkubb> anyone else attending mwrc?
10:23 candeller joined
10:35 hipe joined
10:41 <dkubb> snusnu: :)
10:42 <snusnu> hey dkubb :)
10:44 <dkubb> snusnu: probably nothing, but it's weird that so much of the gemspec changed
10:44 <snusnu> dkubb: whitespace jeweler formatting i believe?
10:44 <snusnu> dkubb: i was surprised too, but iirc i blamed it on that without further looking
10:45 <dkubb> yeah, I probably won't worry about it, just curious why
10:45 <snusnu> dkubb: anyway, i need to test it again with 0.9.11 later on today, but last time i checked it worked
10:45 <dkubb> snusnu: dm-core 0.9.11 ?
10:46 <dkubb> snusnu: or bundler?
10:46 <snusnu> bundler
10:46 <dkubb> heh
10:46 <* dkubb> has not had any coffee yet
10:46 <snusnu> dm-core-0.9.11 has no more space in my brain :P
10:47 <dkubb> snusnu: the whitespace diff is probably due to the rubygems change
10:47 <snusnu> me neither and it's already 7pm damnit … (coffee machine broke)
10:47 <dkubb> snusnu: you know, whenever you want to push your AS branch into the mainline go for it. we just have to make sure the specs make it in before the next dm-core 0.10.3 release, which won't be for a few weeks yet
10:48 <snusnu> dkubb: ok good to know, and actually i wanted to work on it for quite some time already … i got overwhelmed with lots of work issues lately tho
10:49 <snusnu> dkubb: thing's cooled down a bit already tho
10:49 <dkubb> snusnu: i'd much rather get people running it now, and deal with the problems sooner than to wait until just before the release
10:49 <dkubb> snusnu: yeah, believe me I understand. I always have trouble balancing my time
10:50 <d-snp> time balancing :(
10:50 <snusnu> dkubb: yeah that's how it goes … but you're right, better letting people hit bugs now, than closer to the release
10:51 <d-snp> I'll be using datamapper in a project that runs at ~10k concurrent users probably :)
10:51 <snusnu> dkubb: i will run all specs later on today and if everything goes right i'll push it to master (or next first?)
10:51 <dkubb> d-snp: awesome
10:51 kstephens joined
10:52 <dkubb> d-snp: I've heard of some high volume apps using DM. what's yours going to be?
10:52 <d-snp> though I kind of only abuse it for its easy constructor :|
10:52 <dkubb> snusnu: master is fine. I usually only push to next when I'm not finished something
10:53 <snusnu> dkubb: heh, that was my reasoning for next, it's probably not yet finished .. then again, it should be quite good already, will push to master once specs ran
10:53 <dkubb> snusnu: well, DM itself is not yet finished.. but my definition would be that there are things I know aren't done that will affect the users. not having moved over all the specs probably won't affect the users
10:53 <d-snp> dkubb: well I can't really go into specifics, since I'm under NDA, but it's for a large organisation that deploys to a popular community site in the netherlands :P
10:54 <dkubb> d-snp: no problem, I understand
10:55 <dkubb> I heard a few months ago that Nestle made a Facebook app using DM, and it was in the *top 10* most used facebook apps for a while
10:55 <d-snp> cool
10:55 <d-snp> that's good to know, this project is sort of like a facebook app :)
10:55 datka joined
10:56 <d-snp> atm I'm using some kind of ugly dm/activerecord hybrid solution
10:56 <d-snp> getting native extensions installed is sort of a big deal, so I can't really use mysql_do unless I got a good reason
10:56 adamaig joined
10:57 <d-snp> but perhaps when I figure this thing out it'll turn out using datamapper for the whole thing is the best solution and I'll just request mysql_do to be installed
10:57 <datka> Hey guys. I have an application where we're using 3 different databases, each using their own module, and each specifying their own repository. Is that the best setup for something like this, or are we doing something wrong.?
11:01 sickill joined
11:01 em-dash joined
11:06 qhoxie joined
11:10 stepheneb joined
11:11 RichGuk joined
11:27 dkubb|away joined
11:30 stepheneb joined
11:41 snusnu joined
11:42 zodiak joined
11:46 pietia joined
11:55 datka` joined
12:02 path[l] joined
12:15 ribrdb joined
12:34 myabc joined
12:35 benburkert joined
12:36 badcarl joined
12:38 datka` joined
12:47 rsim joined
13:01 ludicco joined
13:04 adamaig_ joined
13:12 pdelgallego joined
13:22 _pol joined
13:28 fpauser1 joined
13:30 _pol joined
13:32 dkubb joined
13:33 adamaig joined
13:33 dkubb joined
13:34 benschwarz joined
13:42 adamaig_ joined
13:47 benburkert joined
13:49 DireFog_ joined
13:57 robgleeson joined
13:58 hipe joined
14:05 stepheneb joined
14:15 siplux joined
14:15 slaskis_ joined
14:19 siplux joined
14:24 datka` joined
14:38 benburkert joined
15:16 postmodern joined
15:40 <Tass`> datka`, sounds halfway good ;-)
15:46 <datka`> is there a half I'm missing?
15:47 <Tass`> datka`, the half I'm missing :D
15:48 <datka`> I think we made a mistake by trying to inherit from a base class that pulled in Resource and set the default rrepository, but now when I try to unravel it, everything is breaking
15:49 <Tass`> uh - don't do inheritance unless STI
15:49 <Tass`> modules are better
15:49 <datka`> I've been struggling to find a good testing scenario with DataMapper, Test::Unit, and multiple repositories
15:49 badcarl joined
15:49 <Tass`> factory_girl
15:49 <datka`> ok, better than sweatshop?
15:50 <Tass`> yep.
15:50 <datka`> I used factory_girl recently on my last project
15:50 <datka`> good to know
15:50 <Tass`> http://github.com/Tass/factory_girl
15:50 <Tass`> bit patched
15:51 <datka`> checking it out, thanks
15:52 <datka`> do you use auto_migrate to create your schema?
15:53 <datka`> previously, I was using our SQL dumps, because it's what I had, and this is a legacy system, but for testing...
15:53 <Tass`> yes
15:55 <Tass`> datka`, well, my last commit isn't specced, but it solves the problem :-)
16:25 dkubb joined
16:25 dkubb joined
16:25 narretgrez joined
16:26 narretgrez left
16:31 kenphused joined
16:36 nitsujw joined
16:42 benburke_ joined
16:49 benburkert joined
17:01 stepheneb joined
17:15 <postmodern> snusnu, ping
17:15 <postmodern> snusnu, so i got a beta app im working on in rails3 that's using AR currently
17:15 <postmodern> snusnu, and now im having to work with multiple DBs
17:15 <postmodern> snusnu, so obviously, it's time to start looking at dropping dm-rails in
17:16 <postmodern> snusnu, what's the best method to migrate an existing app and test it out?
17:18 <snusnu> hey postmodern, well, you need to add dm-rails to the gemfile … replace the require 'activerecord/railtie' with 'dm-rails/railtie' in config/application.rb .. write dm models .. what else comes to mind?
17:19 <snusnu> postmodern: it's probably a good idea to read through dm-rails' README too
17:20 adamaig joined
17:20 <snusnu> postmodern: if your config/application.rb contains require 'rails/all' then you need to replace that with only the railties you need, dm-rails included
17:22 <snusnu> postmodern: about rspec, well, the integration is not yet really complete i guess .. i rather regularly updated rspec deps (currently 2.0.0.beta.3 iirc) .. and last time i checked 1 example failed when running specs for a freshly generated app
17:22 <snusnu> postmodern: for some mysterious reason sqlite3 won't work properly in specs, mysql fine tho, probably some automigration / test db setup problem
17:22 <postmodern> interesting
17:23 <snusnu> postmodern: i hope i find more time next week to have a look again at dm-rails, finish the refactorings and such
17:26 <postmodern> snusnu, well im jumping in now
17:26 <postmodern> snusnu, so hopefully i can find some bugs, and properly track them down
17:26 <postmodern> snusnu, and make patches
17:31 <snusnu> postmodern: that'd be most awesome, tbh, i haven't yet written more than a bare sample app with crud forms
17:32 <snusnu> postmodern: it'd be cool if you find a need for http://github.com/snusnu/dm-accepts_nested_attributes too .. i'd really like to see that fully usable in rails3 .. i guess it's something people coming from AR won't wanna miss
17:33 <snusnu> postmodern: of course i mean, *if* you have a need :P
17:42 <postmodern> snusnu, well my oversee'ers have me working with a shared db schema, and multiple dbs now
17:42 <postmodern> snusnu, so it's looking like datamapper from here on out
17:48 altrux joined
17:51 robgleeson joined
17:56 <siplux> i was trying to convert a merb app to rails3 - worked pretty well except i had issues with the bundler (not sure if it was due to user error however)
17:57 <snusnu> siplux: what problems did you have? rails3 should work very well with bundler
17:59 <siplux> snusnu: weird loading errors, i was writing a plugin which dynamically extended some of the classes (if they existed), it would load all the model classes, then load my plugin, then load some of the models again (effectively wiping out the extensions)
17:59 <siplux> snusnu: by classes i mean DM models
18:00 <snusnu> siplux: you're using dm-rails ?
18:01 <siplux> snusnu: no, i was just using rails3_datamapper
18:01 <snusnu> siplux: ok, that's now http://github.com/datamapper/dm-rails
18:02 <siplux> snusnu: i followed your github instructions, but I guess they're outdated?
18:02 altrux_ joined
18:03 <snusnu> siplux: probably not that much, depends on when you've last read them
18:04 <snusnu> siplux: reading your error again .. that may be related to dm-rails needing to preload all models explicitly … rails3 alone would lazy load them
18:04 <siplux> snusnu: so switching to dm-rails from rails3_datamapper would probably help that?
18:05 <snusnu> siplux: preloading is necessary since belongs_to and has declarations establish properties on the related models, and to initialize these, all model descendants need to be traversed and the relationships be touched
18:06 <snusnu> siplux: i can't promise that it will help, but it's definitely worth making the switch, dm-rails is here to stay
18:06 <snusnu> siplux: and it's the same codebase
18:06 myabc joined
18:06 <siplux> snusnu: well its probably going to have to happen one way or another
18:07 <siplux> snusnu: how are you feeling about the stability of rails 3 at this point?
18:08 altrux_ joined
18:08 <snusnu> siplux: tbh, i haven't yet started any serious project with rails3, but nevertheless i'd consider it totally usable
18:08 <siplux> snusnu: gotcha
18:08 <siplux> snusnu: it's so sad to let merb go ... even though yehuda has done such a nice job with rails3, I find the merb source much easier to read
18:11 <snusnu> siplux: yeah, i'm still really pleased with merb, and it's still small and nice to read compared to rails3 .. but i really think that rails3 is more advanced .. and what i'm really enjoying, is finally being back somewhere with active discussions and lots of docs .. merb was "fine" at the time too .. but the last year was sad
18:20 <siplux> snusnu: definitely, its nice to not have to reinvent the wheel all the time. I wish they kept a few merb conventions, but I guess they needed backwards compatibility
18:22 TomV-415 joined
18:23 <careo> siplux: they'll have to pry merb from my cold dead hands with a Giant Crowbar of Amazing Features +1
18:23 <careo> s/+1/+5
18:24 <siplux> hahaha
18:24 <snusnu> hehe
18:26 <siplux> porting an app, half the time I'm pissed off because it doesn't work how merb works, the other half i'm pleased because I forgot how X was easier in rails
18:27 <snusnu> for me, i still believe that the resource controller abstraction i used with merb, will make the switch to rails3 really easy … of course it depends on the app, but i never found myself needing to do something out of the ordinary most of the times
18:28 <careo> mind you, dm was half my reason for going for merb
18:28 <snusnu> also, you gotta love respond_to/respond_with
18:29 <snusnu> heh careo, same here
18:29 <siplux> me too
18:29 <snusnu> dm will be (and already is) awesome with rails(3)
18:29 <snusnu> :P
18:31 <siplux> still not sure how respond_to is better than provides?
18:31 <careo> snusnu: hehe, considering my application.rb has "before :force_json" and then a definition of it...
18:36 <snusnu> siplux: i like the naming more, it's symmetric with respond_with .. respond_to/respond_with is much better imho than provides/display (display/render being kinda ambiguous)
18:36 <siplux> snusnu: true, i never did like the ambiguity
18:37 <careo> but which is faster? :P
18:37 <* careo> loves seeing timings come out in scientific notation
18:38 <snusnu> hehe, i wouldn't expect rails3 to be particularly slow, merb may still be faster, then again, i don't think that performance was all top priority till now .. i'm sure they'll keep working on that too
18:39 <siplux> i haven't seen any benchmarks directly comparing rails3 to merb, just rails3 to rails2
18:40 <careo> I mean, I don't like falling victim to premature optimization as much as anyone. I just don't want to engage in premature *de*optimization...
18:44 <siplux> i feel like 3.0 is going to be a lot of unspaghettifying of code and optimizations will come down the pipeline
18:46 TomV-415 joined
18:47 <dkubb> I feel like Rails 3 is a natural evolution for Rails.. I certainly wouldn't want to maintain the 2.x series
18:52 <siplux> is someone trying to?
18:52 <siplux> or do you mean end users of the framework?
18:54 <dkubb> oh, no, I don't think anyone will.. other than the normal maintenance phase
18:55 <siplux> rails 2.x definitely hit that point in life where it was just accumulating more and more cruft to fix problems - would really suck to have to main that
18:59 jbrennan joined
19:01 qhoxie joined
19:01 <siplux> do i have any other options other than an indexer (like ferret) when it comes to full-text search on an rdbms? Those things always cause problems
19:03 <careo> doesn't postgres itself have something?
19:03 <dkubb> I think there's a sphinx adapter
19:04 <siplux> dkubb: i meant not using an indexer at all. I was thinking of some crazy schema ... but wondering if there was something i wasn't aware of
19:04 <siplux> careo: stuck on mysql for now :(
19:04 <careo> siplux: there's fulltext something or another in myisam.
19:04 <careo> if you're willing to use myisam, that is
19:04 <siplux> heh
19:09 <careo> there's some easy magic for mysql+sphinx I think
19:09 <siplux> maybe i just had a bad experience with ferret, but it crashed if i looked at it crossways and leaked memory like a sieve
19:11 <siplux> so i've been trying to see if i could get by without having to pay the piper, so to speak
19:17 <careo> yeah. sphinx actually looks pretty cool
19:19 <careo> looks like it even has a mysql storage engine that does a lot of magic for you 28889
19:19 <careo> erm. copy, then paste. http://sphinxsearch.com/docs/manual-0.9.9.html#sphinxse
19:21 <siplux> interesting - thanks for that
19:23 <careo> np. I'm curious to know how it does. kinda hoping you be the guinea pig
19:23 <careo> there are some ruby libs for sphinx I recall seeing too
19:27 <siplux> haha - yeah, unless i can figure out a way around having to use full-text search, that looks like the top candidate
19:40 kstephens joined
19:44 fpauser joined
19:51 cardmagic joined
19:51 cardmagic left
20:12 postmodern joined
20:26 hassox joined
20:38 TomV-415 joined
20:58 benburkert joined
20:59 stepheneb joined
21:01 path[l] joined
21:29 <hassox> allo
21:33 <hassox> anyone with any clues on how to pass some sql through as a condition?
21:53 <siplux> hassox: I think you can just do :conditions => ["..sql..", arg1,arg2"]
21:53 snusnu joined
22:13 zodiak joined
22:38 kenphused joined
22:53 <hassox> siplux: what if I want to doa find_by_sql?
23:05 Fullmoon joined
23:17 <siplux> hassox: I belive find_by_sql allows you to run raw SQL queries, however it returns structs instead of objects
23:17 <hassox> that's not terrible in this case
23:18 <hassox> NoMethodError: undefined method `find_by_sql' for Company:Class
23:18 <siplux> repository(:default).adapter.query('SELECT * FROM foos WHERE name = ?', val)
23:18 <siplux> is the default way
23:18 <siplux> otherwise you'll have to include "dm-ar-finders"
23:19 <siplux> not sure if that returns structs or objects
23:19 <siplux> require "dm-ar-finders" rather
23:20 <hassox> kk
23:20 <hassox> thx
23:22 <siplux> np
23:23 dkubb joined
23:24 dkubb joined