house9

random code and what not

Assembla to start charging for all private services

well I guess it had to happen sooner or later - Assembla to start charging for all private services

they do offer a great service and the fact that it has been free up until now has been really great!
I can understand why they need to start charging and it still seems very reasonable,
but it would be nicer if it was based purely on disk space instead of per project

read more here

Comments

C. G. Brown
Oh I almost forgot… we’re at http://www.projectlocker.com . Thanks!
C. G. Brown
Hi, I’m with ProjectLocker, and we have hosted Subversion, Trac, and soon Git hosting for as little as $2.50/month annualized for 2 users and 1 GB. Our low-cost plans are metered on space and users but have unlimited projects and no pre-set bandwidth limits. We also have a number of cool features such as the ability to e-mail tickets to Trac and to run code reviews on Java projects. If you’re looking for a new provider, we encourage you to try us out.

ActionView::TemplateError uninitialized constant

ActionView::TemplateError (uninitialized constant ActionView::Base::CompiledTemplates::Literals) on line #10 of …

I just made a silly mistake which was generating this error; I have a Literals class in my Ruby on Rails application that has some strings stored as constants, everything was working great until I put this code on a server (Linux) didn’t have any issues on the mac or windows machines before deploying

turned out to be so simple…
I originally named the file Literals.rb which defined the class Literals

the fix: rename Literals.rb to literals.rb

- doh!

Comments

Anonymous
Thanks a lot for this hint. I named a class KursTeilnahme (capital T) and got the same error. For Kursteilnahme everything is okay.

GE Microwaves are junk

my GE Microwave worked great until the one year warranty was up, then it developed this really cool feature where the fan will not turn off - unless…

usually if I have the fan on and want to turn it off, I setting it to off (but it stays on) and then do a quick cook of 2 minutes, 8 out of 10 times this will turn off the fan when it finishes, other times it will turn if I do the 2 minute quick cook again - but that doesn’t always work either…

sometimes I have to unplug the thing to turn off the fan, out of curiosity I googled ‘GE Microwave fan’ and came across this youtube video that pretty much tells the tale





Don’t you just love quality products…

scRUBYt

I needed to do some screen scrapping using Ruby, so after a few google searches I came across this post which looked very promising, after a quick scan through the comments scRUBYt looked even better.

stumbling block #1: well it did take me a bit to get it installed, turns out it is currently (0.3.4) hard-wired to use RubyInline 3.6.3, but I had RubyInLine 3.7.0 installed, this post gives the details to work around this issue, otherwise you will get an error something like Gem::Exception: can’t activate RubyInline (= 3.6.3), already activated RubyInline-3.7.0].


stumbling block #2: trying the simple example for scrapping google here I got the following error -  can’t convert Hash into String. So I tried commenting out some of the code, just limiting it to hit the submit button, the result - no error but no output either? after looking around on the scRUBYt forums turns out scRUBYt logging is not on by default, so turn it on… Scrubyt.logger = Scrubyt::Logger.new and run the code again [ERROR] No extractor defined, exiting… ok, so un-comment the code and run it again now that I have the logging on, same error, I am obviously doing something wrong? try a couple other code samples, more fun error messages - The error occurred while evaluating nil.example_type.

Well it turns out I was jumping ahead because I was calling this code from inside a Rake task. After moving the code into a regular ruby file and calling it using ruby instead of rake everything works just great! I did not look into why this code is failing from inside the rake task but I am guessing there is some conflict with the libraries? an exercise for another day…

Comments

vinay
hi,

i am using scrubyt, and below is my code to scap

google.

Scrubyt.logger = Scrubyt::Logger.new
google_data = Scrubyt::Extractor.define do
#Perform the action(s)
fetch 'http://www.google.com/'
fill_textfield 'q', 'ruby'
submit
#Construct the wrapper
#
link "//div[3]/div/ol/li" do

head "/h3[@class='r']"
des "/div[@class='s']"

end
next_page "Next", :limit => 2
end


and this wil output some thing like this

# Ruby Programming Language
# A dynamic, interpreted, open source programming language with a focus on simplicity and productivity. Site includes news, downloads, documentation, …www.ruby-lang.org/ - 12k - Cached - Similar pagesDownloadsDocumentationin Twenty MinutesWhat's RubyDownload RubyLibrariesAbout RubySecurityMore results from ruby-lang.org »
# Ruby (programming language) - Wikipedia, the free encyclopedia
# Ruby is a dynamic, reflective, general purpose object-oriented programming language that combines syntax inspired by Perl with Smalltalk-like features. …en.wikipedia.org/wiki/Ruby_(programming_language) - 118k - Cached - Similar pages

since div class ='s' has text and some child nodes. I m getting all text of div class ='s' as well as its chlid nodes.

how to filter this( i dont want child node's text). Can any body help in this. What procedure i have to follow.

Buy.com and Google checkout doesn’t work

Buy.com and Google checkout doesn’t work - I don’t think I’ll be using either product going forward.

I select 3 items, each with free shipping, select check out, select Google Checkout and I am presented with shipping costs none of which says ‘Free’

I’ve used Google checkout a few times before without issue and I’ve ordered from buy.com before without issue, but after wasting my time with ‘false advertising’ - no more

I guess I’ll go order my stuff from Amazon instead.

Archipelago Studio Apartments Port Douglas Australia

Archipelago Studio Apartments Port Douglas Australia

72 Macrossan Street, Port Douglas, QLD 4877, Australia

http://www.archipelago.com.au/




View Larger Map

This place was great! Port Douglas is great!



Next to the door is an electric burner not as nice as cooking with gas but good enough to cook in, if you like 


Walk outside the apartments, turn to your left, yes! that is the ocean and the start of four mile beach just a few hundred yards from the apartments