ruote log_2010-05-19

2010-05-19 08:52:39 utc anb_ rubygems is frustrating
2010-05-19 08:52:53 utc jmettraux what are you fighting against ?
2010-05-19 08:53:15 utc anb_ I'm not sure :)
2010-05-19 08:53:38 utc anb_ simply trying to get ruote-kit running
2010-05-19 08:53:50 utc anb_ I used to clone the git of ruote-kit
2010-05-19 08:53:52 utc anb_ and rackup
2010-05-19 08:53:55 utc anb_ was fine
2010-05-19 08:54:26 utc anb_ but now I wanted to have it use a system gem of ruote-kit
2010-05-19 08:55:07 utc anb_ see, in config.ru it seemed to require 'lib/ruote-kit' and I guess that means it will use the source from the cloned git, right ?
2010-05-19 08:55:24 utc jmettraux yes
2010-05-19 08:55:42 utc jmettraux feel free to replace that with require "ruote-kit"
2010-05-19 08:55:46 utc anb_ so I changed it to require 'ruote-kit' instead of 'lib/ruote-kit' and removed the $:.unshift 'lib'
2010-05-19 08:55:54 utc jmettraux perfect
2010-05-19 08:56:02 utc anb_ I made sure ruote-kit was installed gem list ruote-kit
2010-05-19 08:56:16 utc anb_ ruote-kit (2.1.8.2)
2010-05-19 08:56:34 utc anb_ tthen if I rackup : `require': no such file to load -- ruote-kit
2010-05-19 08:57:07 utc tosch_le did you include a require 'rubygems' ?
2010-05-19 08:58:05 utc jmettraux tosch_le: hello !
2010-05-19 08:58:11 utc jmettraux (hello anb_)
2010-05-19 08:58:15 utc anb_ Hello tosch_le, yes I thought about that, but it doesn't help
2010-05-19 08:58:19 utc anb_ Hello John :)
2010-05-19 08:58:25 utc anb_ but
2010-05-19 08:58:29 utc tosch_le http://gist.github.com/406108
2010-05-19 08:58:39 utc tosch_le see an example config.ru by mine
2010-05-19 08:58:46 utc tosch_le that one works fine at my site
2010-05-19 08:58:59 utc tosch_le hi @all!
2010-05-19 08:58:59 utc anb_ it's exactly my config.ru
2010-05-19 08:59:05 utc anb_ but but
2010-05-19 08:59:17 utc anb_ I tried to remove the begin -end bundler trick
2010-05-19 08:59:24 utc anb_ then I can rackup
2010-05-19 08:59:32 utc anb_ Webrick listening ...
2010-05-19 08:59:39 utc anb_ but if I request anything
2010-05-19 08:59:53 utc anb_ wait
2010-05-19 08:59:56 utc tosch_le do you have bundler installed?
2010-05-19 09:00:08 utc jmettraux (bundle install) ?
2010-05-19 09:00:09 utc tosch_le what does "bundle check" say?
2010-05-19 09:00:25 utc anb_ Sinatra::RespondTo::UnhandledFormat at /_ruote/
2010-05-19 09:00:31 utc anb_ let me try
2010-05-19 09:00:38 utc jmettraux tosch_le: excellent, I didn't know that one
2010-05-19 09:00:46 utc jmettraux tosch_le: thanks !
2010-05-19 09:00:56 utc anb_ The Gemfile's dependencies are satisfied
2010-05-19 09:01:16 utc tosch_le strange. the rackup should work then without problems
2010-05-19 09:01:46 utc anb_ yes, now rackup works (if I remove the begin block on top of the config.ru) but I'm getting sinatra error
2010-05-19 09:02:15 utc tosch_le the rackup should work with the bundler block
2010-05-19 09:02:22 utc tosch_le do you have a Gemfile?
2010-05-19 09:02:41 utc anb_ I copied the one from ruote-kit git
2010-05-19 09:02:42 utc tosch_le what does it look like? (i've included mine in the gist above)
2010-05-19 09:02:58 utc tosch_le that will be overkill, i suppose
2010-05-19 09:03:25 utc anb_ that's what happens when one does not understands what he's doing :)
2010-05-19 09:03:36 utc anb_ let me try with your Gemfile
2010-05-19 09:04:40 utc anb_ rackup works with your gemfile
2010-05-19 09:05:17 utc anb_ but still, ../_ruote/ gives me Sinatra::RespondTo::UnhandledFormat
2010-05-19 09:07:09 utc jmettraux IIRC, there is no binding for /_ruote/
2010-05-19 09:07:38 utc jmettraux maybe /_ruote/processes/ or /_ruote/processes works
2010-05-19 09:08:54 utc anb_ /_ruote/processes/ => Sinatra::RespondTo::UnhandledFormat
2010-05-19 09:08:58 utc jmettraux ouch
2010-05-19 09:09:05 utc jmettraux processes without / ?
2010-05-19 09:09:06 utc anb_ /_ruote/processes => undefined method `default_internal' for Encoding:Class
2010-05-19 09:09:10 utc jmettraux aaah
2010-05-19 09:09:20 utc anb_ so I think the right one is with trailing slash
2010-05-19 09:09:49 utc anb_ but still :)
2010-05-19 09:10:01 utc anb_ WAIT
2010-05-19 09:10:11 utc jmettraux I have the impression that the right one is without the trailing slash
2010-05-19 09:10:31 utc jmettraux too bad, ruote-kit's web interface is half-baked :(
2010-05-19 09:10:51 utc anb_ not sure because with slash it's a format error while without it's no method found
2010-05-19 09:11:18 utc jmettraux Sinatra::RespondTo::UnhandledFormat should be replaced by a 404
2010-05-19 09:11:21 utc anb_ maybe it is some utf-8 dependency on my system
2010-05-19 09:11:28 utc jmettraux exactly
2010-05-19 09:11:29 utc anb_ oh ok
2010-05-19 09:18:30 utc tosch_le jmettraux: the right one is the one without the trailing slash
2010-05-19 09:18:50 utc anb_ all right
2010-05-19 09:18:52 utc anb_ thx
2010-05-19 09:18:56 utc jmettraux happy moments : http://gist.github.com/406128 (I replied I don't know what he is referring to)
2010-05-19 09:19:02 utc jmettraux tosch_le: thanks !
2010-05-19 09:19:17 utc tosch_le \/_ruote should work, too
2010-05-19 09:19:56 utc jmettraux /_ruote and /_ruote/ never worked for me :(
2010-05-19 09:20:21 utc tosch_le didn't they? strange.
2010-05-19 09:20:43 utc jmettraux I should have complained, sorry
2010-05-19 09:21:01 utc tosch_le /_ruote should look like http://ruote.torstenschoenebaum.de/_ruote
2010-05-19 09:21:10 utc jmettraux but you and Kenneth have probably better things to do
2010-05-19 09:21:13 utc tosch_le (attention, there's no running worker atm)
2010-05-19 09:22:17 utc tosch_le anb_: can you gist a more complete traceback for "undefined method `default_internal' for Encoding:Class"
2010-05-19 09:24:22 utc anb_ sure
2010-05-19 09:27:27 utc anb_ http://gist.github.com/406134
2010-05-19 09:27:37 utc tosch_le jmettraux: nice mail
2010-05-19 09:30:05 utc anb_ argh it's a bit messed up
2010-05-19 09:30:33 utc anb_ I scrolled back in the console from less and got text from another run, but the error is there.
2010-05-19 09:32:18 utc anb_ gist updated
2010-05-19 09:32:34 utc tosch_le and where is it?
2010-05-19 09:32:41 utc tosch_le i missed the link ;-)
2010-05-19 09:32:49 utc anb_ still there http://gist.github.com/406134 :)
2010-05-19 09:33:11 utc tosch_le oups. sorry
2010-05-19 09:33:54 utc anb_ don't be, glad you're taking the time to check this
2010-05-19 09:33:56 utc tosch_le what ruby version do you use?
2010-05-19 09:34:12 utc anb_ ruby 1.9.0 (2008-06-20 revision 17482) [x86_64-linux]
2010-05-19 09:35:40 utc tosch_le i don't know, but iirc, 1.9.0 is a bit buggy concerning string encodings
2010-05-19 09:36:01 utc tosch_le is it possible to update your ruby to something more recent?
2010-05-19 09:36:06 utc jmettraux +1 1.9.0 is to avoid
2010-05-19 09:36:11 utc anb_ damned
2010-05-19 09:36:37 utc anb_ I will update :)
2010-05-19 09:36:44 utc anb_ that's the one I got from apt
2010-05-19 09:36:47 utc tosch_le rvm is really cool for managing different ruby versions
2010-05-19 09:37:02 utc tosch_le http://rvm.beginrescueend.com/
2010-05-19 09:37:03 utc jmettraux :)
2010-05-19 09:37:25 utc anb_ I should have used it :)
2010-05-19 09:37:45 utc tosch_le forget about the packaged rubies, they are out of date and a bit of crap most of the time
2010-05-19 09:37:58 utc anb_ seems to be, yes
2010-05-19 09:37:59 utc jmettraux cyklus: welcome to #ruote
2010-05-19 09:38:13 utc cyklus thanks
2010-05-19 09:39:54 utc cyklus looking for a scheduler that can run a task on an interval, starting at a certain time and ending at another time...and I need to be able to specify this in code at run time and not in a config file... any suggestions?
2010-05-19 09:40:25 utc jmettraux what is the context ? Ruby or Ruby on Rails ?
2010-05-19 09:41:38 utc cyklus jmettraux: Ruby on Rails... and if the server crashes I need to be able to keep running all the scheduled tasks when the system comes back up.
2010-05-19 09:42:50 utc tosch_le anb_: ruby-1.9.1-p378 is working fine at my site
2010-05-19 09:43:38 utc jmettraux cyklus: http://github.com/bvandenbos/resque-scheduler
2010-05-19 09:44:09 utc jmettraux cyklus: http://adamblog.heroku.com/past/2010/4/13/rethinking_cron/
2010-05-19 09:44:27 utc anb_ tosch_le: thanks, will update this afternoon. will probably solve my problem
2010-05-19 09:45:11 utc cyklus jmettraux: taking a look
2010-05-19 09:45:28 utc jmettraux cyklus: placing the tasks in a queue or in a model and polling from time to time the queue/table for things to trigger could work
2010-05-19 09:45:36 utc tosch_le anb_: _that_ wouldn't be strange to me ;-)
2010-05-19 09:46:10 utc jmettraux cyklus: but that presupposes you have a thread that does the polling, that might not play well with unicorn / passenger and the like
2010-05-19 09:46:40 utc cyklus jmettraux: yeah thats what I am thinking... so use the "scheduler" to run a method that checks my own table of tasks and runs them... thats what your suggesting right?
2010-05-19 09:46:59 utc jmettraux yes
2010-05-19 09:47:18 utc cyklus jmettraux: any thought on BackgroundRb?
2010-05-19 09:47:29 utc cyklus jmettraux: came across that one as well
2010-05-19 09:47:38 utc jmettraux no clue about this one
2010-05-19 09:48:12 utc jmettraux you could have a cronjob that fires a rake task which triggers your scheduled tasks
2010-05-19 09:48:14 utc cyklus jmettraux: ok, thanks for the help... time for lunch :)
2010-05-19 09:48:22 utc jmettraux bye !
2010-05-19 11:35:01 utc cyklus jmettraux: you still around?
2010-05-19 11:35:08 utc jmettraux cyklus: yes
2010-05-19 11:35:51 utc cyklus jmettraux: nice... doesnt seem the scheduler you recommend can handle what I need... here is an attempt at a better explanation:
2010-05-19 11:36:17 utc cyklus I need to schedule a recurring background task that will select a number of records from a model and then spawn a thread to perform a task for each record returned.
2010-05-19 11:36:21 utc jmettraux sorry, it wasn't a recommendation, just a suggested reading
2010-05-19 11:37:28 utc cyklus The records in the model each contain an URL that I need to make a request to... which is the reason why each record should have its own thread to make a http request
2010-05-19 11:37:34 utc cyklus jmettraux: ic..
2010-05-19 11:38:08 utc jmettraux what about the classical cron job that triggers a rake task in a dedicated process ?
2010-05-19 11:40:41 utc cyklus jmettraux: but that dedicated process would then need to spawn a thread for each record in the model... is that possible?
2010-05-19 11:41:07 utc jmettraux records.each { |rec| Thread.new { do_process(rec) } }
2010-05-19 11:42:41 utc jmettraux maybe something like http://gist.github.com/406215
2010-05-19 11:45:31 utc cyklus jmettraux: nice... I think that would work... then I could use any scheduler plugin or cron to call that code on a regular basis
2010-05-19 11:45:44 utc jmettraux indeed
2010-05-19 11:46:57 utc anb_ tosch_le : it works with 1.9.1p378
2010-05-19 11:47:16 utc anb_ so ruby 1.9.0 : no good
2010-05-19 11:49:09 utc tosch_le anb_: great news.
2010-05-19 11:49:49 utc tosch_le did you try rvm?
2010-05-19 11:50:36 utc anb_ tried a few weeks ago, yes. but on this machine I went without it.
2010-05-19 11:51:33 utc anb_ but ruby on apt is a real mess
2010-05-19 11:51:58 utc jmettraux anb_: that's why rvm is your saviour ;-)
2010-05-19 11:52:22 utc jmettraux get whatever apt ruby, and use it to install rvm
2010-05-19 11:52:32 utc jmettraux afterwards, you're safe
2010-05-19 11:52:36 utc anb_ jmettraux: yes I didn't use it out of laziness but in the end I lost a lot of time
2010-05-19 12:03:02 utc wayneeseguin bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head ) # http://rvm.beginrescueend.com/rvm/install/
2010-05-19 12:29:58 utc jmettraux kennethkalmer: http://livercake.tumblr.com/post/602114624/some-gringos-are-so-stupid-its-almost-cute
2010-05-19 12:51:37 utc anb_ hehe thanks wayneeseguin :)
2010-05-19 12:53:06 utc tosch_le ACTION repeats himself and begs to vote for wayne as ruby hero at http://www.rubyheroes.com/
2010-05-19 12:53:39 utc wayneeseguin *blush*
2010-05-19 12:54:11 utc tosch_le jmettraux: nice image. produced quite a laugh in the office here.
2010-05-19 12:55:15 utc jmettraux :)
2010-05-19 13:16:13 utc kennethkalmer jmettraux: bwahaaahahahaaaaaa
2010-05-19 13:16:16 utc kennethkalmer hey guys
2010-05-19 13:16:19 utc kennethkalmer awesome pic
2010-05-19 14:55:23 utc weyus Howdy
2010-05-19 14:55:52 utc weyus What is the relationship between ruote and rufus?
2010-05-19 14:55:57 utc weyus If any?
2010-05-19 14:56:42 utc kennethkalmer het weyus
2010-05-19 14:56:47 utc kennethkalmer just quickly, I'm on my way out
2010-05-19 14:56:57 utc kennethkalmer they share the same author, jmettraux
2010-05-19 14:57:01 utc weyus No worries
2010-05-19 14:57:06 utc kennethkalmer ruote leverages some rufus libs internally
2010-05-19 14:57:16 utc weyus Is the spelling on purpose?
2010-05-19 14:57:18 utc weyus :)
2010-05-19 14:57:23 utc kennethkalmer like rufus-json, rufus-scheduler & rufus-verbs
2010-05-19 14:57:31 utc kennethkalmer it means something, can't recall for the life of me
2010-05-19 14:57:39 utc kennethkalmer john does everything with intent :)
2010-05-19 14:57:48 utc weyus I figured as much
2010-05-19 14:57:55 utc weyus Cheers Kenneth - looking forward to using it
2010-05-19 14:58:02 utc weyus I really need the Jabber stuff :)
2010-05-19 14:58:16 utc kennethkalmer ah, I need to get the jabber updated !
2010-05-19 14:58:17 utc weyus Thanks for the presentation.
2010-05-19 14:58:20 utc kennethkalmer trial with AMQP first
2010-05-19 14:58:26 utc kennethkalmer the switch to XMPP is minimal
2010-05-19 14:58:28 utc kennethkalmer really, minimal
2010-05-19 14:58:36 utc kennethkalmer ttyl, please hang around
2010-05-19 14:59:38 utc weyus Will do
2010-05-19 16:24:45 utc kennethkalmer weyus: i have 15 minutes before i need to make dinner
2010-05-19 16:24:51 utc kennethkalmer can you talk ?
2010-05-19 16:37:08 utc kennethkalmer ACTION is afk for a couple of hours
2010-05-19 23:46:59 utc jmettraux seeingidogeleven: hello, welcome to #ruote
2010-05-19 23:52:20 utc seeingidogeleven hello, thanks