[rails-oceania] Re: Checking .html.erb file validity

2020-05-12 Thread Ben Koshy
Hi Tom

I found this gem:

https://github.com/w3c-validators/w3c_validators

The trick would be to integrate it into your view specs. I'm not sure if 
there's an easy way to do that, but at least there's a place to start.

regards
Ben

On Wednesday, July 20, 2016 at 10:10:19 PM UTC+10, Tom Hale wrote:
>
> I'm want to check the validity of .html.erb files, at both the erb and 
> HTML levels. 
>
> I purposely put in weird, unmatched tags to test out rails-erb-lint[1] and 
> rails-erb-check[2]. I also changed a <% else %> to <% elXse %> and both 
> said my file was valid. 
>
> So... 
>
> Q1) How do I get feedback on what is actually wrong with my .erb syntax? 
>
> Q2) How can I validate that the eventual HTML output is also valid, and 
> not just relying on my browser being tolerant? 
>
> Q3) Do many people use erb in production or should I be using something 
> "better"? Something with a decent error checker? (bonus points for 
> integrating with vim/syntastic) 
>
> Thanks all, 
> Tom 
>
> [1] https://rubygems.org/gems/rails-erb-lint/versions/1.1.6 
> [2] https://github.com/jugyo/rails-erb-check 
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/rails-oceania/c1570811-cbaa-4678-b873-4c9226df50d0%40googlegroups.com.


[rails-oceania] Re: Questions about recruiters in AU

2016-02-23 Thread Ben Turner
Hi Adler, 

Welcome to Melbourne ! 

There is a monthly Ruby meetup where a lot of companies post roles they are 
look to fill 
(https://groups.google.com/forum/?utm_source=digest&utm_medium=email#!topic/rails-oceania/7kUbpd-ldWo)
 
- there are usually notes taken, which are posted up later on, although 
I've been unable to find anything from January's meetup - perhaps someone 
else can help out here?

Beyond that, I can certainly add a +1 to recommending the fine folks at 
Lookahead Search - not only are they a genuinely helpful outfit, but they 
are all from a technical background, so understand the market they are 
recruiting for. Most importantly, they are just really nice people who you 
will end up meeting as part of the Ruby community anyway. In my 20 years of 
programming, they are the only recruitment outfit I have ever seen fit to 
recommend to anyone else.

That said, there are certainly a number of open Ruby / Rails roles around 
if your happy to do your own investigations; as I say, the RORO 
Melbourne Meetup notes should have a list of some of the companies looking. 
I'll also give a quick plug to my former employer, as they were are really 
fun place to work at, with a lot of awesome smart technologists - 
https://www.aconex.com/careers/listing?jid=ENG17&fam=job-eng®=reg-aus 
- I certainly enjoyed my years there, and was able to grow a lot as a 
full-stack rubyist during that time.

Whichever way you go, no doubt you'll find a great Ruby community in 
Melbourne; in the five years I've been here, I've found it a really 
welcoming crowd.

Cheers,
Ben

On Tuesday, 23 February 2016 21:49:30 UTC+11, Adler Hsieh wrote:
>
> Hi everyone, 
>
> My name is Adler, will be moving to Melbourne in May and looking for a mid 
> to senior level Ruby on Rails job. In addition to my own job-search, I may 
> need some help from recruiters, but I have some questions since I have 
> never worked with a recruiter before.
>
> 1. Is it ok to work with multiple recruiters at the same time if I want to 
> find an appropriate job ASAP?
> 2. Is there any list of Rails-related recruiting companies in Melbourne? I 
> didn't find any related resources on Google, or was I using the wrong terms?
>
> It's my first time going Australia and I can't wait to join the Rails 
> community in Melbourne :) Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at https://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


Re: [rails-oceania] Re: Recruiters and Coders

2016-02-01 Thread Ben Woodward
It’s simply because there is huge demand for developers and not enough supply, 
which creates a profitable situation for developers and recruiters. From the 
developers perspective, we are bombarded with emails from the recruiters who 
treat recruitment like a game of minesweeper. To make it worse, many of these 
recruiters don’t bother to learn about the technologies they are recruiting 
for. This gist posted by DHH sums up the situation: 
https://gist.github.com/dhh/1285068 


These recruiters I know, do not represent all recruiters, I think this is an 
inevitable phenomenon / side-effect of the economics at work in the industry. 
However, it does get tiring responding to thousands of generic emails pinged to 
your inbox every year and it’s hard not to feel frustrated sometimes. I no 
longer look at my LinkedIn anymore because it’s so overwhelming.


Ben
  —


Ben Woodward
Freelance Ruby+iOS Developer
Mobile: +61 (0)467 094 998
Email: b...@benw.me
Skype: benw.me





> On Feb 2, 2016, at 4:44 PM, Andrew Mead  wrote:
> 
> 
> Apologies for digging up an old thread, but wanted to put in my $0.02.
> 
> 
> I'm a recruiter. But I haven't always been one - so I've had to deal with 
> both good and bad recruiters. The bad ones are the ones that don't call you 
> back when they say they will (if at all) or they put you forward for roles 
> that just aren't right for you - very frustrating and annoying! The good ones 
> though will actually take the time to listen to what YOU want and try to 
> match you as best they can with the RIGHT client.
> 
> 
> I'm trying to be a good recruiter. But like all humans, I don't always get it 
> right. I really enjoy finding jobs for people and working with cool, 
> innovative companies.
> 
> 
> Normally, you'll only ever deal with a recruiter when you really need one. 
> There are a lot of dodgy cowboys/girls out there but luckily there are some 
> good ones too.
> 
> 
> Cheers,
> 
> 
> Andrew
> 
> On Wednesday, April 22, 2015 at 7:57:07 PM UTC+10, Dan Draper wrote:
>> In the developer community you often hear of resentment towards recruiters. 
>> I have my own ideas but I'd love to hear what people think on this. Why do 
>> coders often dislike recruiters?
>> 
>> 
>> -- 
>> Dan Draper
>> CEO and Co-founder
>> www.codehire.com
>> 
>> 
>> Twitter: @danieldraper
>> Skype: danieldraper100
>> Mobile: AUS: +61 403 089 661 US: +1 (310) 310 1721
>> 
>> LinkedIn: http://www.linkedin.com/in/ddraper
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com
> .
> To post to this group, send email to rails-oceania@googlegroups.com
> .
> Visit this group at https://groups.google.com/group/rails-oceania
> .
> For more options, visit https://groups.google.com/d/optout
> .

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at https://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


Re: [rails-oceania] How specced out should a development MBP be?

2014-10-05 Thread Ben Hoskings
As others have said, any Mac from the past few years is fine. In fact even if 
you made a point of buying the slowest new Mac you could find, it'd still be 
fine.

(Mine is a 3-year-old 11" i7/4GB Air.)

With that in mind, I think there are other things that are more important. For 
example, in my experience Airs run a fair bit cooler than Pros. That, and the 
tapered shape, makes them much more comfortable on your lap.

They're also around half the weight, which makes them much more comfortable in 
your bag especially if it's one of several things you carry.

- Ben


> On 6 Oct 2014, at 5:37 am, Michael Pearson  wrote:
> 
> 8 GB RAM, 4 cores (real cores, not HT 'concurrent threads'), any Apple SSD.
> 
> Then https://github.com/grosser/parallel_tests to take advantage of the cores.
> 
> This is assuming you have (or expect to have) slow tests. If not .. anything 
> will do.
> 
> Also, run whatever database you're using in YOLO mode during development: 
> turn off fsync, data safety, etc.
> 
> Disk space is only helpful for storing virtual machines and gargantuan music 
> collections.
> 
> If it's my money, I'd go the 2.5ghz. If it's your employer's, 2.8ghz.
> 
> 
>> On Sun, Oct 5, 2014 at 10:38 PM, Andrew Grimm  
>> wrote:
>> I know this is a bit "How long is a piece of string?", but if a MacBook Pro 
>> is being used for Rails development, how specced out should it be?
>> 
>> Does CPU play a role in performance? Is it beneficial to have a 2.8GHz 
>> Quad-core CPU compared to a 2.5GHz Quad-core CPU?
>> 
>> How disk space hungry is Rails development? Is it better to have a 1TB drive 
>> compared to a 512GB drive?
>> 
>> Andrew
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to rails-oceania+unsubscr...@googlegroups.com.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> Visit this group at http://groups.google.com/group/rails-oceania.
>> For more options, visit https://groups.google.com/d/optout.
> 
> 
> 
> -- 
> Michael Pearson
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


Re: [rails-oceania] [MEL] How to get Ruby employment with limited Ruby but plenty of programming experience

2014-07-31 Thread Ben Hoskings
Sorry, I wasn't clear :) You're right, there is backwards-incompatible syntax 
in ruby 2.x. I was thinking of the large number of forwards-incompatible 
changes between python 2 and 3: to my (limited) knowledge, upgrading python 
programs developed against v2 to run against v3 is a major exercise.

- Ben


On Thu, 31 Jul 2014, at 09:06 PM, Tim Moore wrote:
> I think that's good advice, but it's not *super* important. The differences 
> are relatively minor, but there is some new syntax in 2.0 and 2.1 that 
> isn't backwards-compatible with older versions, and 1.8.x in particular is 
> past its end-of-life period and is not supported by many recent versions of 
> gems. Ruby 1.9.3 is still generally well-supported but earlier 1.9.x 
> versions are not.
> 
> If you're on a Mac, Mavericks ships with Ruby 2.0. Otherwise, if you have 
> to install Ruby anyway, you might as well use the latest version.
> 
> On Thursday, July 31, 2014 8:34:35 PM UTC+10, Marky Mark wrote:
> >
> > Quite right, my out-by-one. It says "*Make* sure you install Ruby 2.0 or 
> > Ruby 2.1, but *not* Ruby 1.8 or 1.9." (Original emphasis.)
> >
> > On Thursday, July 31, 2014 7:56:32 PM UTC+10, ben_h wrote:
> >>
> >> Sounds like a typo, the latest ruby is v2.1.2, and rails is at 
> >> 4.1.something.
> >>
> >> Unlike python there's no great compatibility gap between 2.x and earlier 
> >> major versions. There are some differences, but they're minor things that 
> >> can be caught by a test suite, and that don't affect most code. To my 
> >> knowledge there are no breaking syntax changes or stdlib API redesigns 
> >> like 
> >> in python 3.
> >>
> >> In sum, unless you have a project-specific reason not to, it's best to 
> >> use the latest versions of both.
> >>
> >> - Ben
> >>
> >>
> >> On 31 Jul 2014, at 6:26 pm, Marky Mark  wrote:
> >>
> >> Thanks adz, you're quite right, I need to get out there and hack/network 
> >> (hackwork?)
> >>
> >> Haskell? I bow to your infinite superiority. I don't think I'll ever have 
> >> the time to get that esoteric.
> >>
> >> ruby.learncodethehardway.org says "use Ruby 3.x, not 2.x". Is there that 
> >> much difference? Are they as incompatible as The Two Pythons, or The Two 
> >> Perls? So much to learn...
> >>
> >> On Thursday, July 31, 2014 6:03:50 PM UTC+10, adz wrote:
> >>>
> >>> Definitely get to a Ruby meetup, and join in some hack sessions. Just 
> >>> being involved means devs in hiring companies are at least aware of you, 
> >>> and at best mentoring you. I think you'll be surprised at how many people 
> >>> are eager to help.
> >>>  
> >>> Then you can always build some open source stuff on github. Getting 
> >>> someone more experienced to look at will be great -- and eye opening.  
> >>> You 
> >>> need to see how things are done in a different environment.
> >>>
> >>> There's more jobs than experienced Rubyists, and experience in other 
> >>> languages is valued. 
> >>>
> >>> BTW: I'm doing this same thing now, but with Haskell and for the purpose 
> >>> of broadening my thinking (maybe I should say: exploding my brain?).  I'm 
> >>> now working through exercises from the book Real World Haskell on a 
> >>> github 
> >>> repo, since just reading stuff was not doing it for me.  
> >>>
> >>> You could do this easily with Ruby as there is so much free material 
> >>> available: maybe try exercises from something like 
> >>> http://ruby.learncodethehardway.org/book/
> >>>
> >>>
> >>> On 31/07/2014 11:58 AM, "Marky Mark"  wrote:
> >>>
> >>>> I've been programming mostly in C++ for years and years. I'm currently 
> >>>> job-seeking but there are very few C++ jobs out there. Ruby seems like a 
> >>>> much better bet (and an intrinsically attractive language) so I would 
> >>>> like 
> >>>> to jump technical ship. How can I do this though? I'm teaching myself 
> >>>> Ruby 
> >>>> (and for that matter JavaScript, Python, etc, etc but there are only so 
> >>>> many hours in the day) but obviously I can't apply for jobs that want 
> >>>> experienced Rubyists. How can I get started properly 

Re: [rails-oceania] [MEL] How to get Ruby employment with limited Ruby but plenty of programming experience

2014-07-31 Thread Ben Hoskings
Sounds like a typo, the latest ruby is v2.1.2, and rails is at 4.1.something.

Unlike python there's no great compatibility gap between 2.x and earlier major 
versions. There are some differences, but they're minor things that can be 
caught by a test suite, and that don't affect most code. To my knowledge there 
are no breaking syntax changes or stdlib API redesigns like in python 3.

In sum, unless you have a project-specific reason not to, it's best to use the 
latest versions of both.

- Ben


> On 31 Jul 2014, at 6:26 pm, Marky Mark  wrote:
> 
> Thanks adz, you're quite right, I need to get out there and hack/network 
> (hackwork?)
> 
> Haskell? I bow to your infinite superiority. I don't think I'll ever have the 
> time to get that esoteric.
> 
> ruby.learncodethehardway.org says "use Ruby 3.x, not 2.x". Is there that much 
> difference? Are they as incompatible as The Two Pythons, or The Two Perls? So 
> much to learn...
> 
>> On Thursday, July 31, 2014 6:03:50 PM UTC+10, adz wrote:
>> Definitely get to a Ruby meetup, and join in some hack sessions. Just being 
>> involved means devs in hiring companies are at least aware of you, and at 
>> best mentoring you. I think you'll be surprised at how many people are eager 
>> to help.
>> Then you can always build some open source stuff on github. Getting someone 
>> more experienced to look at will be great -- and eye opening.  You need to 
>> see how things are done in a different environment.
>> 
>> There's more jobs than experienced Rubyists, and experience in other 
>> languages is valued.
>> 
>> BTW: I'm doing this same thing now, but with Haskell and for the purpose of 
>> broadening my thinking (maybe I should say: exploding my brain?).  I'm now 
>> working through exercises from the book Real World Haskell on a github repo, 
>> since just reading stuff was not doing it for me.  
>> 
>> You could do this easily with Ruby as there is so much free material 
>> available: maybe try exercises from something like 
>> http://ruby.learncodethehardway.org/book/
>> 
>> 
>> 
>>> On 31/07/2014 11:58 AM, "Marky Mark"  wrote:
>>> I've been programming mostly in C++ for years and years. I'm currently 
>>> job-seeking but there are very few C++ jobs out there. Ruby seems like a 
>>> much better bet (and an intrinsically attractive language) so I would like 
>>> to jump technical ship. How can I do this though? I'm teaching myself Ruby 
>>> (and for that matter JavaScript, Python, etc, etc but there are only so 
>>> many hours in the day) but obviously I can't apply for jobs that want 
>>> experienced Rubyists. How can I get started properly in this field?
>>> 
>>> Any pointers gratefully received. Yeah I know Ruby doesn't have pointers :-)
>>> 
>>> Mark the R00b (Ruby n00b).
>>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "Ruby or Rails Oceania" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>> email to rails-oceani...@googlegroups.com.
>>> To post to this group, send email to rails-...@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/rails-oceania.
>>> For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


[rails-oceania] July presentation - hardware or software focus?

2014-06-18 Thread Ben Turner
My vote would be on the "no such thing as magic" talk. 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


[rails-oceania] Re: Melbourne RORO talk topic?

2014-04-16 Thread Ben Turner
+1 for factories / machinist and most importantly, a non-factory approach 
to testing (surely not just fixtures ?!)

Ben

On Wednesday, 16 April 2014 10:18:56 UTC+10, Pete Yandell wrote:
>
> Hi folks,
>
> So I'm giving a talk at the next Melbourne RORO meetup, and I've got a 
> couple of possible talk topics in mind, but I thought I'd ping everyone and 
> see if there's anything folks would particularly like me to talk about.
>
> For those who don't know me, I'm the lead architect for the Envato 
> marketplaces, so have had my head buried pretty deep in running and scaling 
> a big Rails app for the past 4 years or so. The app has made the transition 
> from Rails 0.8 to Rails 3.2 over its lifetime (and will hopefully move to 
> Rails 4 soon), so has a lot of history reflected in it. We've now got ~25 
> devs working on it, so I've learnt a fair bit about scaling teams too. If 
> there are any particular aspects of that experience that people are 
> interested in, I could talk about those.
>
> I'm also the author of Machinist, a sin for which I am still repenting. I 
> don't actively maintain it anymore, because I don't tend to use factories 
> in tests these days. I could also talk about that, or my experience 
> building open source projects in general.
>
> Discuss!
>
> - Pete
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


[rails-oceania] [JOB] South Melbourne - Rails and JS Developer wanted at Tickbox

2014-03-24 Thread Ben Goodvach-Draffin
Hey Team!

Tickbox is a small company of about twenty people with a ten person strong 
development team. We’re based in a modern office near the South Melbourne 
markets.

What we’re building is probably best described as an international social 
media platform for philanthropy and volunteering.
It is completely community driven and its general purpose is to connect 
good will and (ideally) make the world a better place. 
Our project has been in development for about a year now and we’re about to 
ramp up in preparation for its internal and then public release in a few 
months’ time. 

We’re run by the same company that operates The Body Shop in Australia and 
so we can ensure that you’ll be well looked after.
We don’t have to do overtime (you’re literally out the door by 5pm and if 
for some reason you’re in the office past 7pm the alarm goes off). 
If you do happen to stay back then any time extra is paid out in lieu. You 
also get coffee in the mornings, massages on Tuesdays and pay half price at 
The Body Shop for all those soaps you’ve been craving.

We’re looking for an Ruby on Rails developer with strong JavaScript skills 
to join our team. This role includes working on a rapidly improving web 
application with an established code.

You don’t need to be a crack developer, if you can prove a solid technical 
proficiency of software development then you should definitely give us a 
buzz! 

Your responsibilities will include:
• Working on a RESTful Rails API
• Working on a front end JavaScript MVC application
• Provide technical input, estimates, and high level designs where required
• Communicate openly with the team

Required Experience
• Ruby on Rails
• JavaScript
• HTML
• CSS
• Object Oriented Programming
• Test Driven Development
• Strong familiarity with the MVC pattern

Desirable Skills
• Creating a RESTful API
• JavaScript MVC frameworks
• HTML5 and CSS3
• Basic SQL
• Apache Solr experience
• Working knowledge of the Devise Ruby gem 
• Agile Development Practices

If you like the idea of being a part of our team and working on an 
international altruistic project then please shoot me an email at 
ben.goodvach-draf...@tickbox.com.au 

Cheers!

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/d/optout.


[rails-oceania] [ JOB ] Ruby on Rails Developer VOD Website

2014-02-11 Thread Ben
I am looking for an experienced Ruby on Rails developer to help develop a 
new video-on-demand website. 

Great opportunity to get in at the ground level of a business (and get 
paid). With potential to become tech co-founder. 

Developer can work from home as contractor initially. 

Cheers, 

Ben


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] Re: In memory ruby full text search

2014-01-03 Thread Ben Schwarz
Interesting problem… Where are the documents being stored? Would there be 
benefit in the documents being served via an API once they've been "found"? 
Perhaps couchdb or some other document store with an index running over the 
top (lucene for couch) could be a good fit? 

You're going to want something pretty robust / well utilised to get solid 
word stemming / language support, so you'd want to utilise a bonafide 
search service. (Not Rubby)  
Also, you mentioned that the content is HTML — can be stored in markdown or 
something with less… structure? There could be challenges here too! 

--

On Friday, 3 January 2014 10:27:10 UTC+11, Mikel wrote:
>
> Hi there fellow Railers, 
>
> Have a requirement for full text search on a small static set of documents 
> in 8 languages.  The documents are committed to the repository don't change 
> outside of a deploy.  Talking about 2mb total inclusive of all languages 
> across about 20 HTML documents per language. 
>
> I want to get full text search happening on these documents, with weighted 
> results and simple AND / OR type matching. 
>
> Obviously, using something like Sphinx / Postgres full text search would 
> handle it, but feels like over kill to spin up a separate search server 
> instance to manage and index. 
>
> Using something lix xapian is an option, could build the index on app 
> boot, but needs packages installed on the server (trying to do this simply) 
>
> Anyone know of a xapian like ruby full text search that can run in memory 
> of off temp files that doesn't have external dependencies? 
>
> I've done some googling and can't find anything that really suits.  I 
> think the simplest thing might be building PostgreSQL full text search 
> tables on app boot and using them as the app is already using PostgreSQL. 
>
> But I welcome other ideas if they exist :) 
>
> Mikel 
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [rails-oceania] In memory ruby full text search

2014-01-02 Thread Ben Hoskings
My first stop would be to load them into a postgres DB in a deploy task, and 
then search the data from there.

Also, I wouldn't worry about the 'in memory' part; the kernel will take care of 
keeping the data in memory via the page cache as long as the box has enough 
memory.

- Ben


> On 3 Jan 2014, at 9:27 am, Mikel Lindsaar  wrote:
> 
> Hi there fellow Railers,
> 
> Have a requirement for full text search on a small static set of documents in 
> 8 languages.  The documents are committed to the repository don't change 
> outside of a deploy.  Talking about 2mb total inclusive of all languages 
> across about 20 HTML documents per language.
> 
> I want to get full text search happening on these documents, with weighted 
> results and simple AND / OR type matching.
> 
> Obviously, using something like Sphinx / Postgres full text search would 
> handle it, but feels like over kill to spin up a separate search server 
> instance to manage and index.
> 
> Using something lix xapian is an option, could build the index on app boot, 
> but needs packages installed on the server (trying to do this simply)
> 
> Anyone know of a xapian like ruby full text search that can run in memory of 
> off temp files that doesn't have external dependencies?
> 
> I've done some googling and can't find anything that really suits.  I think 
> the simplest thing might be building PostgreSQL full text search tables on 
> app boot and using them as the app is already using PostgreSQL.
> 
> But I welcome other ideas if they exist :)
> 
> Mikel
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania.
> For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [rails-oceania] Melbourne Ruby Notes - November 2013

2013-12-15 Thread Ben Turner
Apologies, have a reorganization of my Dropbox, forgot I had links coming 
from that presentation.

New link is here: https://www.dropbox.com/s/qtjq2sxp2jx6kz9/ansible.pdf

On Wednesday, 11 December 2013 17:43:22 UTC+11, Bing Xie wrote:
>
> Hi Ben, have you removed the pdf? It's unavailable now.
>
> On Sunday, December 1, 2013 1:18:16 PM UTC+11, Ben Turner wrote:
>>
>> I've put a PDF of my slides up at 
>> https://www.dropbox.com/s/ryrkc4cniczhv1y/ansible.pdf
>>
>> Ben
>>
>> On Friday, 29 November 2013 18:06:56 UTC+11, Pat Allan wrote:
>>>
>>> Hi Dave
>>>
>>> Tom’s slides are here: http://slid.es/tomspacek/dokku--2
>>>
>>> Morten’s slides were mostly photos and require his storytelling to have 
>>> any relevance. Hopefully Ben and Rhiana can share theirs though :)
>>>
>>> — 
>>> Pat
>>>
>>> On 29 Nov 2013, at 9:37 am, Dave Burt  wrote:
>>>
>>> Hi,
>>>
>>> Sorry not to have been able to make it.
>>>
>>> Are slides available from the talks?
>>>
>>> Cheers,
>>> Dave Burt
>>> Allori
>>>
>>>
>>> On Thu, Nov 28, 2013 at 11:03 PM, Pat Allan 
>>> wrote:
>>>
>>>> Hi All
>>>>
>>>> Thanks to all who came along tonight - it was a great event, excellent 
>>>> mix of topics and it seems people like the switch from pizza to a variety 
>>>> of finger food from the Asylum Seeker Resource Centre’s catering service. 
>>>> Mario and I are certainly keen to have a mix of food instead of all pizza 
>>>> all the time.
>>>>
>>>> The notes from the night are below - we already have two speakers lined 
>>>> up for January, which is fantastic, but if anyone’s keen to put their hand 
>>>> up, do get in touch, we should be able to fit in at least one more, 
>>>> possibly two.
>>>>
>>>> And don’t forget to tell our sponsors they’re awesome - they make it 
>>>> far easier for us to put together these wonderful events.
>>>>
>>>> Speaking of events, we have a pretty full calendar for December:
>>>>
>>>> * InstallFest - Thursday December 5th at Envato
>>>> * Hack Night - Tuesday December 10th at Inspire9
>>>> * Christmas Social - Thursday December 19th at Envato
>>>>
>>>> They can all be found here: 
>>>> http://www.meetup.com/Ruby-On-Rails-Oceania-Melbourne/
>>>>
>>>> There’s also other Ruby-friendly events:
>>>>
>>>> * Code Retreat - Saturday December 14th
>>>>
>>>> https://www.eventbrite.com.au/e/global-day-of-coderetreat-melbourne-2013-tickets-9467574771
>>>> * Random Hacks of Kindness - 7th/8th December, Swinburne University in 
>>>> Hawthorn
>>>> http://www.rhokmelbourne.org
>>>>
>>>> And finally, everyone is welcome to attend Inspire9’s Christmas party 
>>>> on Friday next week - if you use the code ‘friends’, you get a discount. 
>>>> Early registrations are appreciated to help manage catering numbers. The 
>>>> party was a ton of fun last year :)
>>>> https://canbook.me/inspire9-xmas-in-space
>>>>
>>>> Thanks
>>>>
>>>> Pat
>>>>
>>>> __  __  _ _   _
>>>> |  \/  | ___| | |__   ___  _   _ _ __ _ __   ___  |  _ \ _   _| |__  _ 
>>>>   _
>>>> | |\/| |/ _ \ | '_ \ / _ \| | | | '__| '_ \ / _ \ | |_) | | | | '_ \| | 
>>>> | |
>>>> | |  | |  __/ | |_) | (_) | |_| | |  | | | |  __/ |  _ <| |_| | |_) | 
>>>> |_| |
>>>> |_|  |_|\___|_|_.__/ \___/ \__,_|_|  |_| |_|\___| |_| \_\\__,_|_.__/ 
>>>> \__, |
>>>> 
>>>>  |___/
>>>> Sponsors:
>>>>   * Thanks to Inspire9 for the awesome venue!
>>>>   * Thanks to Envato and Lookahead Search for filling us with delicious 
>>>> food!
>>>>   * Thanks to Zendesk for the tasty beverages!
>>>>
>>>> Welcome!
>>>>   * Something different with food: ASRC Catering
>>>>
>>>> Upcoming Events
>>>>   * December
>>>> * InstallFest - Thursday December 5th at Envato
>>>> * Hack Night - Tuesday December 10th at Inspire9
>>>> * December Social - Thursday D

Re: [rails-oceania] Melbourne Ruby Notes - November 2013

2013-11-30 Thread Ben Turner
I've put a PDF of my slides up 
at https://www.dropbox.com/s/ryrkc4cniczhv1y/ansible.pdf

Ben

On Friday, 29 November 2013 18:06:56 UTC+11, Pat Allan wrote:
>
> Hi Dave
>
> Tom’s slides are here: http://slid.es/tomspacek/dokku--2
>
> Morten’s slides were mostly photos and require his storytelling to have 
> any relevance. Hopefully Ben and Rhiana can share theirs though :)
>
> — 
> Pat
>
> On 29 Nov 2013, at 9:37 am, Dave Burt > 
> wrote:
>
> Hi,
>
> Sorry not to have been able to make it.
>
> Are slides available from the talks?
>
> Cheers,
> Dave Burt
> Allori
>
>
> On Thu, Nov 28, 2013 at 11:03 PM, Pat Allan 
> 
> > wrote:
>
>> Hi All
>>
>> Thanks to all who came along tonight - it was a great event, excellent 
>> mix of topics and it seems people like the switch from pizza to a variety 
>> of finger food from the Asylum Seeker Resource Centre’s catering service. 
>> Mario and I are certainly keen to have a mix of food instead of all pizza 
>> all the time.
>>
>> The notes from the night are below - we already have two speakers lined 
>> up for January, which is fantastic, but if anyone’s keen to put their hand 
>> up, do get in touch, we should be able to fit in at least one more, 
>> possibly two.
>>
>> And don’t forget to tell our sponsors they’re awesome - they make it far 
>> easier for us to put together these wonderful events.
>>
>> Speaking of events, we have a pretty full calendar for December:
>>
>> * InstallFest - Thursday December 5th at Envato
>> * Hack Night - Tuesday December 10th at Inspire9
>> * Christmas Social - Thursday December 19th at Envato
>>
>> They can all be found here: 
>> http://www.meetup.com/Ruby-On-Rails-Oceania-Melbourne/
>>
>> There’s also other Ruby-friendly events:
>>
>> * Code Retreat - Saturday December 14th
>>
>> https://www.eventbrite.com.au/e/global-day-of-coderetreat-melbourne-2013-tickets-9467574771
>> * Random Hacks of Kindness - 7th/8th December, Swinburne University in 
>> Hawthorn
>> http://www.rhokmelbourne.org
>>
>> And finally, everyone is welcome to attend Inspire9’s Christmas party on 
>> Friday next week - if you use the code ‘friends’, you get a discount. Early 
>> registrations are appreciated to help manage catering numbers. The party 
>> was a ton of fun last year :)
>> https://canbook.me/inspire9-xmas-in-space
>>
>> Thanks
>>
>> Pat
>>
>> __  __  _ _   _
>> |  \/  | ___| | |__   ___  _   _ _ __ _ __   ___  |  _ \ _   _| |__  _   _
>> | |\/| |/ _ \ | '_ \ / _ \| | | | '__| '_ \ / _ \ | |_) | | | | '_ \| | | 
>> |
>> | |  | |  __/ | |_) | (_) | |_| | |  | | | |  __/ |  _ <| |_| | |_) | |_| 
>> |
>> |_|  |_|\___|_|_.__/ \___/ \__,_|_|  |_| |_|\___| |_| \_\\__,_|_.__/ \__, 
>> |
>>  |___/
>> Sponsors:
>>   * Thanks to Inspire9 for the awesome venue!
>>   * Thanks to Envato and Lookahead Search for filling us with delicious 
>> food!
>>   * Thanks to Zendesk for the tasty beverages!
>>
>> Welcome!
>>   * Something different with food: ASRC Catering
>>
>> Upcoming Events
>>   * December
>> * InstallFest - Thursday December 5th at Envato
>> * Hack Night - Tuesday December 10th at Inspire9
>> * December Social - Thursday December 19th at Envato
>> * Code Retreat - Saturday December 14th
>> * Inspire 9 space-themed Christmas party - Friday December 6th at 
>> Inspire9, discount code: friends
>> * Random Hacks of Kindness - Coding for Charity - 7th/8th December, 
>> Swinburne University in Hawthorn
>>   * January
>> * Hack Night - Tuesday January 14th at Inspire9
>> * Talk Meet - Thursday January 30th at Inspire9
>>
>> News:
>>   * Charlie broke Ruby again (discovered a float-parsing exploit). All 
>> versions of Ruby have new patch-level releases, you should upgrade. Ubuntu 
>> has security releases available as well.
>>   * W3C may accept DRM as part of the HTML5 Spec. If this matters to you, 
>> make some noise.
>>   * AWS RDS for Postgres was released.
>>
>> Hiring:
>>   * Will - needs a Ruby dev, food-focused project 
>> wi...@dibble.com.au
>>   * Jason - Zendesk is looking for data engineers 
>> http://zendesk.com/careers
>>   * Matt - Lookahead has plenty of jobs, also happy to chat about 
>> figuring out what level of dev you may be. 
>> ma..

[rails-oceania] Re: Melbourne Ruby November

2013-11-18 Thread Ben Turner
Think that should be Thursday the _28th_ November.

On Monday, 18 November 2013 14:48:28 UTC+11, Pat Allan wrote:
>
> Hi all 
>
> The Melbourne Ruby meet returns next week on Thursday night. 
>
> WHEN:  Thursday 29th November, arrive at 6pm for a 6:30pm start. 
> WHERE: Inspire9, Level 1, 41-43 Stewart Street 
> WHAT:  Four speakers, plus socialising, food and drinks. 
>
> Our four speakers this month are: 
>
> * Tom Spacek: Migrating away from Heroku to a local Australian host. 
> * Ben Turner: Ansible - your first step into server provisioning. 
> * Rhiana Heath: How to present. 
> * Morten Primdahl: Growing Zendesk. 
>
> Morten is Zendesk’s CTO/co-founder, and it’s great that he’s making time 
> to share some thoughts on his experiences growing the company while he’s 
> visiting Melbourne. 
>
> This time around we'll be enjoying food from ASRC Catering - something a 
> little different from the standard pizza, and we'll definitely have 
> vegan/gluten-free/lactose-free options in the mix. The food is sponsored by 
> Envato and Lookahead Search, the drinks by Zendesk, and the space by 
> Inspire9. Our sponsors are superb, and this month we’re particularly 
> appreciative of Lookahead Search joining our list of regulars. 
>
> If you have a meetup account, it’d be great if you could RSVP in the next 
> 24 hours or so to give us a chance at providing somewhat accurate numbers 
> for the catering. 
> http://www.meetup.com/Ruby-On-Rails-Oceania-Melbourne/events/135216992/ 
>
> If anyone has any questions or thoughts, feel free to contact Mario or 
> myself - we’re looking forward to seeing you all there :) 
>
> — 
> Pat 
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] Re: [JOB] Software Engineer - Ruby

2013-11-10 Thread Ben Immanuel
Role is based in the Melb CBD and the candidate is required to work 
on-site

On Monday, November 11, 2013 2:22:27 PM UTC+11, Ben Immanuel wrote:
>
> *About the company;*
>
> C3 is a business intelligence consultancy that makes its own software. We 
> have an existing product, Integrity, that allows users to define rules over 
> data imports before it reaches the data warehouse. We are currently doing 
> some green fields development with a new client and are looking to bring 
> another developer into the team.
>
> *About the team;*
>
> You would be working with 3 other developers, on existing and new 
> products. We do most of our own ops work, puppet on everything and have a 
> swanky new PowerEdge-C that needs some attention before we head off to the 
> data centre and rack it.
>
> *What are we looking for?*
>
> For this position, we're looking for an experienced Ruby dev, someone who 
> can hit the ground running with minimal to no supervision. We need someone 
> who can communicate their ideas to business owners, clients, the 
> development team, and potentially the rest of C3.
>
> *You will have;*
>
> Rails 3/4, resque/sidekiq, MRI/JRuby, capybara, rspec, jquery, devise, 
> cancan, the usual suspects.
>
> Experience with databases outside MySQL/PostgreSQL is a big bonus as we 
> encounter them more often than not (DB2 and Teradata), however this isn't 
> required.
>
> *Compensation?*
>
> Access to the latest technologies, casual work environment, good career 
> path, competitive remuneration and a bi-annual bonus review.
>
> *Are you interested? *
>
> If you'd like more details, get in touch, including the MD5 sum of this 
> sentence in your message.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] [JOB] Software Engineer - Ruby

2013-11-10 Thread Ben Immanuel


*About the company;*

C3 is a business intelligence consultancy that makes its own software. We 
have an existing product, Integrity, that allows users to define rules over 
data imports before it reaches the data warehouse. We are currently doing 
some green fields development with a new client and are looking to bring 
another developer into the team.

*About the team;*

You would be working with 3 other developers, on existing and new products. 
We do most of our own ops work, puppet on everything and have a swanky new 
PowerEdge-C that needs some attention before we head off to the data centre 
and rack it.

*What are we looking for?*

For this position, we're looking for an experienced Ruby dev, someone who 
can hit the ground running with minimal to no supervision. We need someone 
who can communicate their ideas to business owners, clients, the 
development team, and potentially the rest of C3.

*You will have;*

Rails 3/4, resque/sidekiq, MRI/JRuby, capybara, rspec, jquery, devise, 
cancan, the usual suspects.

Experience with databases outside MySQL/PostgreSQL is a big bonus as we 
encounter them more often than not (DB2 and Teradata), however this isn't 
required.

*Compensation?*

Access to the latest technologies, casual work environment, good career 
path, competitive remuneration and a bi-annual bonus review.

*Are you interested? *

If you'd like more details, get in touch, including the MD5 sum of this 
sentence in your message.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] Re: Ruby Australia AGM minutes - 3rd November 2013

2013-11-04 Thread Ben Schwarz
Gregs question was whether we could cost the projects created at railscamp 
(on the internal github) could be moved to a public place (perhaps 
github.com/rubyaustralia).
There were no objections to doing this, but I'm also yet to hear of anyone 
who wanted to host their projects under the ruby australia account. 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] Re: [OT] Railscamp vullagers, boardgames and pokah

2013-10-28 Thread Ben Turner
I've got a stupidity of boardgames, including most currently on the "Bounty 
List", but as I'm flying from Melbourne I may not get too many in the 
luggage 
(that full set of Arkham Horror may not quite get under the baggage 
limit... not to mention take up half the weekend to set up and play, which 
might limit the hacking stuff :)

Perhaps if people are keen to game, and see something already on the Bounty 
List they'd want to play, they could shove a "+1" next to it on the 
spreadsheet, to gauge popularity ?

Personally, I'll be bringing along "The Resistance" which is very much like 
werewolf (but better), only plays with up to 10 people, but no-one goes out 
until the very end, and for this reason (and a few others) tends to be a 
better game when you've got 8-10 people. Yes, a better game than werewolf, 
there, I said it. 

A game I've also got is Shadows over Camelot (as featured on TableTop !) if 
there might be 5-6 other people interested in a bigger game of something 
(1-2 hours) ? Maybe if someone else shoves it on the Bounty list and it 
gets a +1, I'll see if it fits into my luggage. Good, simple to learn, 
longer "find the traitor" game. With knights, round tables and stuff. 

Cheers,
Ben

On Monday, 28 October 2013 00:15:05 UTC+11, Daryl wrote:
>
> Much like RC Tassie I was hoping some attendees could bring along some of 
> their well-loved games to play (and teach) in the evenings. I, myself, have 
> a deeply unhealthy relationship with werewolf and it's one of my favourite 
> things about the Railscamps, so will be bringing a pack (as will others, 
> I'm sure).
>
> So, if people have some things they'd like to bring (Cataan, G 
> Annihilation, Dominion, Zombies: LNOE, 7 wonders, MtG, anything 
> @defectiveyeti has ever endorsed etc), I'm sure you can find peeps to play 
> and I was wondering if they could throw them on the list here so we know 
> who's got what:
>
> http://goo.gl/xKKdOP
> *(you can also add to the bounty list if there's something you're 
> particularly interested in playing)*
>
> *Pokah* I'm travelling light to camp (as moving countries), so can't 
> bring my weighty poker set to RCXIV, but if someone else wants to bring 
> one, I'm very happy to run a tourney for up to 9-10 on one of the evenings.
>
> Finally, if you're new to Railscamps, I *highly* recommend playing 
> Werewolf at least once whether you've ever played or not (doubly so, if 
> not). If werewolf's not your thing, I'm sure a game of Durak or two will be 
> going as well.
>
> ciao !
> Daryl.
> PS> I am always, *always* a villager... =p 
>
>
>
>
>
>
>
>  

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


Re: [rails-oceania] Feedback from newbie night

2013-09-01 Thread Ben Hoskings
I agree. I don't think it makes sense to try to steer learners away from 
dangers ahead of time: the best way to learn is from the experience of getting 
things wrong, because otherwise you do things the way you do "because I was 
told to do it like this".

On the other hand, it's not feasible to do every last thing from first 
principles. On the shoulders of giants and so on.

IMO the most important thing is to get people interested, because curiosity is 
an excellent teacher. (And then to help again when they come back with their 
ensuing mistakes.)

This is anecdotal, but the points of design that I'm most confident in arguing 
for, and in my answers to (immutability, separation of concerns, and so on) are 
all in mental territory that I mapped by making wrong turns.

- Ben


On 01/09/2013, at 7:15 PM, Jack Chen  wrote:

> On a somewhat related note, I feel that for the next newbie night, there 
> should be more emphasis on why we do things, rather than the how. Getting 
> into Ruby on Rails is not an easy task especially when everyone is telling 
> you to test, worry about architecture, performance and security. 
> 
> It might be obvious to the rest of us, but personally I don't fully 
> understood concepts until the "why" made sense to me. For example, I never 
> fully understood testing until I had an app grow big and complex and had to 
> deal with bugs.
> 
> I feel it's more valuable to guide people to make mistakes that everyone once 
> made, then teach them how to fix them.
> 
> Just my 2c.
> 
> chendo
> 
> On Sunday, 1 September 2013 at 4:41 PM, Pat Allan wrote:
> 
>> Hi Richard
>> 
>> I think the night was definitely a success - we had maybe 90 people along, 
>> most of whom hadn't been to more than one Melbourne Ruby meet previously. I 
>> had plenty of people tell me they found it useful, though I think there's 
>> still room for improvement (I know I struggled with condensing the topic of 
>> RSpec into a lightning-ish talk).
>> 
>> Next time something like this happens, I'm thinking we should run an 
>> installfest first (rather than our intro night last month, and installfest 
>> next month), but I'll certainly be making an effort to line up beginner 
>> talks to mix in amongst the more experienced topics at the coming Melbourne 
>> Ruby meets.
>> 
>> And even though I'm an organiser now (and perhaps more than a touch biased 
>> generally), I agree wholeheartedly with your assessment - I've managed to 
>> visit several Ruby meets around the world, and Melbourne (and Australia 
>> generally) has something pretty special going on when it comes to the Ruby 
>> community.
>> 
>> Cheers
>> 
>> -- 
>> Pat
>> 
>> On 29/08/2013, at 11:42 PM, Richard McGain wrote:
>> 
>>> Hey, 
>>> 
>>> Despite moving to Canada, I am still on the roro list so I noticed that you 
>>> guys did a newbie night. How did it go? Were there many newbies there and 
>>> did they find it useful? We are thinking about doing something similar here 
>>> in Montreal (possibly combining it with an install fest).
>>> 
>>> Having been to a bunch of different ruby meetups in various cities, 
>>> Melbourne ranks as the friendliest and most useful I have been to, so 
>>> thanks!
>>> 
>>> Richard.
>>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "Ruby or Rails Oceania" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>> email to rails-oceania+unsubscr...@googlegroups.com.
>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/rails-oceania.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to rails-oceania+unsubscr...@googlegroups.com.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> Visit this group at http://groups.google.com/group/rails-oceania.
>> For more options, visit https://groups.google.com/groups/opt_out.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@goog

Re: [rails-oceania] Re: Melbourne Ruby, newbie night tomorrow night (Thursday 29th August)

2013-08-29 Thread Ben Hoskings
Hi all, here are the 'further reading' notes I linked in my git talk.

http://d.pr/NKZj

Feel free to fire questions in my direction.

- Ben


On 29/08/2013, at 10:34 PM, j10io  wrote:

> Hey All,
> 
> What an awesome meetup, so great to see so many faces.
> 
> Slides etc... should be posted here by those who gave talks in the near 
> future.
> 
> Below are the meeting notes.
> 
> Regards
> Jeremy
> @j10io
> 
> __  __  _ _   _ 
> |  \/  | ___| | |__   ___  _   _ _ __ _ __   ___  |  _ \ _   _| |__  _   _ 
> | |\/| |/ _ \ | '_ \ / _ \| | | | '__| '_ \ / _ \ | |_) | | | | '_ \| | | | 
> | |  | |  __/ | |_) | (_) | |_| | |  | | | |  __/ |  _ <| |_| | |_) | |_| | 
> |_|  |_|\___|_|_.__/ \___/ \__,_|_|  |_| |_|\___| |_| \_\\__,_|_.__/ \__, | 
>  |___/ 
> Sponsors: 
> 
> * Thanks to Inspire9 for the awesome venue! 
> * Thanks to Envato for filling us with delicious pizza! 
> * Thanks to Zendesk for the tasty beverages! 
> 
> Welcome!
> 
> 
> News: 
> * New meetup group (if you're so inclined) 
> http://www.meetup.com/Ruby-On-Rails-Oceania-Melbourne/
> * Next Hack Night: Tuesday September 10th
> * Ruby on Rails InstallFest thanks to reInteractive for hosting and envato 
> for the venue: 
> http://www.meetup.com/Ruby-On-Rails-Oceania-Melbourne/events/134648802/
> * Railscamp (Camp Yarramundi, 1hr drive from Sydney) - November 1-4 - 
> http://syd14.railscamps.org/ 
>   ** Scholarships are Available!!!
> * CampJS coming up in Feb - campjs.com
> 
> 
> Hiring: 
> * Ben Aconex - Devops, ruby role, javascript (angular would be awesome) 
> @phantomwhale
> * Ivan App.io IOS and Android apps - looking for awesome engineers . 
> Melbourne or SF. Ruby/Go/JS - i...@app.io
> * Envato hiring for all the things, ruby obviously. Talk to @asellitt or 
> http://techjobs.envato.com/
> * Leonard - reInteractive. Always looking for ROR devs. 100% remote - @lgarvey
> * Matt from Lookahead, developers and recruiters. Ruby and Node @mattallen
> * John - 19 years old runs a small business, fixes broken computers, not 
> looking for developers, doing big things with new accounts they've brought 
> online. Help with website also needed. Doesn't know how to twitter - 0431 665 
> 220.
> * REA - 13 dev roles. careers.realestate.com.au
> 
> 
> Talks: 
> * Leonard Garvey  - I've written the 15 minute blog, what's next?
> * Pat Allan   - RSpec
> * Charlie Somerville  - Better Errors
> * Chendo  - Developer productivity
> * Gareth Townsend - Security 101
> * Daniel Heath- Querying with Active Record
> * Ben Hoskings- Git is awesome
> * Matt Delves - Single page app with Emberjs
> 
> Next Month: 
> * Melbourne Ruby - Thursday 26th September (back to @pat and @mariovisic)
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania.
> For more options, visit https://groups.google.com/groups/opt_out.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] Re: RailsCamp 14 Sydney signup is now open.

2013-08-20 Thread Ben Schwarz
Julian, we discussed this strategy for the Melbourne camp — and we decided 
to keep it simple and ship with the version that you're familiar with. 

I'm sure that given some railscamp hacking (or via pull request) we could 
make those changes for next time. (ping Tim Lucas [sorry Tim] or myself and 
we'll be happy to review or help) 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.


[rails-oceania] [Off-topic] The electoral roll closes at 8pm tonight

2013-08-11 Thread Ben Hoskings
Hi folks, just a quick reminder. I'm sure most of you are already
aware, but still:

The electoral roll closes tonight. Whoever you plan to vote for next
month, you'll have to enrol before 8pm to do it:

http://www.aec.gov.au/enrol/

Democratically yours,
Ben H

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Re: Love-letter to RORO

2013-07-02 Thread Ben Schwarz
Yo Jeremy, 

I run a bunch of events and I'm a member of the ruby org committee — Its 
so, so nice to hear great feedback like this. 
John and I are super proud of how railscamp went overall, but its even 
better that you had such a good experience. 

<3

\o/

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Important railscamp details

2013-06-18 Thread Ben Schwarz
Hi all, 


Railscamp is mere days away, I hope you're ecstatically excited, this 
weekend is going to be a total blast! 

There are three items of concern that we want you to know, and they're all 
super important. 


   1. Despite careful review in our correspondence so far, we missed the 
   fact that you will need to *bring your own pillow*! 
  - If bringing a pillow (and a sleeping bag) sounds like a *huge*hassle 
and you'd rather not, the camp will be happy to supply you with top 
  and bottom sheets, a blanket, pillow and pillow case. This honour will 
set 
  you back $25… but if you're flying in, that might be a good option. 
   2. Only 50% of people have replied to our 
form<https://docs.google.com/forms/d/1IaYu46bsHuJORmGNWacZxA0UzZmfejOP0t5vUbIAYnY/viewform>regarding
 transport options. 
  - We need to know if you *are* or *aren't *going to catch the bus. 
  Tell us, it'll only take 11 seconds. ( I timed it ) 
  - Fill out the form 
now<https://docs.google.com/forms/d/1IaYu46bsHuJORmGNWacZxA0UzZmfejOP0t5vUbIAYnY/viewform>
   3. We're going to meet up *this Thursday night* at Horse Bazaar 
   (Melbourne CBD) for a drink (there is food available too) from 5:30pm. 
   (Railscamp ticket not required) 

That, my friends is all you need to know (for anything else, please refer 
to the emails we've delivered to you - sent from jrbar...@gmail.com).

<3's

Ben, John & Tim


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] [JOB] - Web Application Developer

2013-06-17 Thread Ben Silcock
Hi, 

We are looking to work with a freelance developer to develop an online 
training web application for the High Performance Academy. The development 
will integrate video lessons, quiz questions, progress reports and support 
forums. 

Remote work is acceptable. My preference is to find someone local 
(Auckland, New Zealand)

The High Performance Academy teaches students the fundamentals of EFI 
Tuning in via online videos. Our current website is 
http://www.learntotune.com

I'm unsure of the level required and the amount of initial work required, 
this could lead to a full time position.  

**Contact**
b...@learntotune.com or +64 21 611 455 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] MelbourneHack night - getting ready for RailsCamp

2013-06-07 Thread Ben Turner
Hey all,

Just wanted to throw it out there that I'm probably looking to head down to 
Inspire9 this coming Tuesday for the Hack Night, but with a purpose of 
"Getting ready for Railscamp" !

Maybe the concept of no / limited internet is worrying me - or the fact 
that my lil' laptop doesn't really get used much for rails hacking - but I 
suspect an evening devoted to getting my laptop and environment into shape 
for the weekend would be a good thing.

Also be good to get a skeleton idea of something to work on over the 
weekend - any other RailsCampers else coming down that night ? Even if just 
to hear what other people are planning, be good to confer, share ideas and 
get inspired :)

Cheers,
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] So, who *is* going to RedDotRuby in Singapore?

2013-06-05 Thread Ben Caldwell
Will be there, flying out tonight. Where's the werewolf happening at?

- BC

On Wednesday, June 5, 2013 9:03:23 PM UTC+8, Daryl wrote:
>
> Well, there *may* be a ww pack in my bag already =] 
>
> D
>
>
>
> On Wed, Jun 5, 2013 at 10:06 PM, Andrew Grimm 
> 
> > wrote:
>
>> Play werewolf with the Singaporeans!
>>
>> http://www.slideshare.net/agrimm/avoiding-niseko-syndrome
>>
>> Andrew
>>
>> Sent from my iPhone
>>
>> On 03/06/2013, at 12:17 PM, Daryl Manning > 
>> wrote:
>>
>> I know a few people have had to bow out, so was just wondering who will 
>> be in Singapore for RDRC (and whether I should be bringing werewolf 
>> cards... =p ).
>>
>> Do we need to start a Goog spreadsheet of flights and such?
>>
>> ciao!
>> Daryl.
>>
>>
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to rails-oceani...@googlegroups.com .
>> To post to this group, send email to rails-...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to rails-oceani...@googlegroups.com .
>> To post to this group, send email to rails-...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Railscamp Melbourne, June 21—24

2013-05-17 Thread Ben Taylor
And then converted to JSFuck? http://www.jsfuck.com/

- Ben


On Friday, 17 May 2013 at 5:40 PM, freshto...@gmail.com wrote:

> Nah, at Rails Camp it would be something written in Go that compiles to 
> asm.js.
>  
>  
> On 17 May 2013 17:00, Ben Taylor  (mailto:m...@taybenlor.com)> wrote:
> > > BTW, I wonder if ballot is the wrong word? It's not really a vote.  
> > In this case, perhaps the one doing the voting is Rails itself. Making this 
> > a true Rails Camp.
> >  
> > Although it's using Sinatra… so not Rails. Which fits with my experiences 
> > at Rails Camp.  
> >  
> > - Ben
> >  
> >  
> > On Friday, 17 May 2013 at 4:56 PM, Gus Gollings wrote:
> >  
> > > On 17/05/2013, at 3:58 PM, Ben Hoskings  > > (mailto:b...@hoskings.net)> wrote:
> > >  
> > > > Bah, ruby, who needs it? :)
> > > >  
> > > > UPDATE entrants SET chosen = true WHERE id IN (
> > > > SELECT id FROM entrants ORDER BY random() LIMIT 100
> > > > )
> > > >  
> > >  
> > >  
> > > Ha! That's awesome ;)
> > >  
> > > I was thinking:
> > >  
> > > > > entrants.shuffle.first(QUOTA)
> > >  
> > > BTW, I wonder if ballot is the wrong word? It's not really a vote.
> > >  
> > > Perhaps a raffle or lottery is more the activity at hand.
> > >  
> > > Regards,
> > >  
> > > Gus
> > >  
> > > > On 17 May 2013 15:49, Tim Lucas  > > > (mailto:t.lu...@toolmantim.com)> wrote:
> > > > On Friday, May 17, 2013 12:45:55 PM UTC+10, Mike Bailey wrote:
> > > > What process is being used for the ballot draw?  
> > > >  
> > > > Has a transparent ballot been considered? Given it's a community event 
> > > > open to anyone I think a transparent process would be good.
> > > >  
> > > > I'm in charge of the ballot, and I'll be trying to make it transparent 
> > > > as practically possible.
> > > >  
> > > > The code's open source already:
> > > > https://github.com/benschwarz/railscamp-13  
> > > >  
> > > > I'm working on the random allocation script now. I emailed this the 
> > > > other day to the Basecamp we're using to organise the camp:
> > > > https://gist.github.com/toolmantim/0072595dffd2c0d1
> > > >  
> > > > Aside from those helping to organise the camp, everyone will be in the 
> > > > ballot and randomly allocated from a single run of a yet-to-be-commited 
> > > > Ruby script.
> > > >  
> > > > — tim
> > > >  
> > > >  
> > > > --  
> > > > You received this message because you are subscribed to the Google 
> > > > Groups "Ruby or Rails Oceania" group.
> > > > To unsubscribe from this group and stop receiving emails from it, send 
> > > > an email to rails-oceania+unsubscr...@googlegroups.com 
> > > > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > > > To post to this group, send email to rails-oceania@googlegroups.com 
> > > > (mailto:rails-oceania@googlegroups.com).
> > > > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > > > For more options, visit https://groups.google.com/groups/opt_out.
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > > --  
> > > > Cheers
> > > > Ben
> > > >  
> > > >  
> > > > --  
> > > > You received this message because you are subscribed to the Google 
> > > > Groups "Ruby or Rails Oceania" group.
> > > > To unsubscribe from this group and stop receiving emails from it, send 
> > > > an email to rails-oceania+unsubscr...@googlegroups.com 
> > > > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > > > To post to this group, send email to rails-oceania@googlegroups.com 
> > > > (mailto:rails-oceania@googlegroups.com).
> > > > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > > > For more options, visit https://groups.google.com/groups/opt_out.
> > > >  
> > > >  
> > > >  
> > >  
> > >  
> > > --  
> > > You received this message because you are subscribed to the Google Groups 
> > > "Ruby or Rails Oceani

Re: [rails-oceania] Re: Railscamp Melbourne, June 21—24

2013-05-17 Thread Ben Taylor
> BTW, I wonder if ballot is the wrong word? It's not really a vote.

In this case, perhaps the one doing the voting is Rails itself. Making this a 
true Rails Camp.

Although it's using Sinatra… so not Rails. Which fits with my experiences at 
Rails Camp.

- Ben


On Friday, 17 May 2013 at 4:56 PM, Gus Gollings wrote:

> On 17/05/2013, at 3:58 PM, Ben Hoskings  (mailto:b...@hoskings.net)> wrote:
>  
> > Bah, ruby, who needs it? :)
> >  
> > UPDATE entrants SET chosen = true WHERE id IN (
> > SELECT id FROM entrants ORDER BY random() LIMIT 100
> > )
> >  
>  
>  
> Ha! That's awesome ;)
>  
> I was thinking:
>  
> > > entrants.shuffle.first(QUOTA)
>  
> BTW, I wonder if ballot is the wrong word? It's not really a vote.
>  
> Perhaps a raffle or lottery is more the activity at hand.
>  
> Regards,
>  
> Gus
>  
> > On 17 May 2013 15:49, Tim Lucas  > (mailto:t.lu...@toolmantim.com)> wrote:
> > On Friday, May 17, 2013 12:45:55 PM UTC+10, Mike Bailey wrote:
> > What process is being used for the ballot draw?  
> >  
> > Has a transparent ballot been considered? Given it's a community event open 
> > to anyone I think a transparent process would be good.
> >  
> > I'm in charge of the ballot, and I'll be trying to make it transparent as 
> > practically possible.
> >  
> > The code's open source already:
> > https://github.com/benschwarz/railscamp-13  
> >  
> > I'm working on the random allocation script now. I emailed this the other 
> > day to the Basecamp we're using to organise the camp:
> > https://gist.github.com/toolmantim/0072595dffd2c0d1
> >  
> > Aside from those helping to organise the camp, everyone will be in the 
> > ballot and randomly allocated from a single run of a yet-to-be-commited 
> > Ruby script.
> >  
> > — tim
> >  
> >  
> > --  
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >  
> >  
> >  
> >  
> >  
> > --  
> > Cheers
> > Ben
> >  
> >  
> > --  
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >  
> >  
> >  
>  
>  
> --  
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Railscamp Melbourne, June 21—24

2013-05-17 Thread Ben Schwarz
The site code is already available on my github account — the ballot will 
be a random script written by Tim & I. 
I'd rather not get into the community reviewing our code or creating 
further overhead for us. 

… You'll see the code committed on github, I don't think anyone needs to 
see more than that.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Railscamp Melbourne, June 21—24

2013-05-16 Thread Ben Hoskings
Bah, ruby, who needs it? :)

UPDATE entrants SET chosen = true WHERE id IN (
  SELECT id FROM entrants ORDER BY random() LIMIT 100
)


On 17 May 2013 15:49, Tim Lucas  wrote:

> On Friday, May 17, 2013 12:45:55 PM UTC+10, Mike Bailey wrote:
>
>> What process is being used for the ballot draw?
>>
>> Has a transparent ballot been considered? Given it's a community event
>> open to anyone I think a transparent process would be good.
>>
>
> I'm in charge of the ballot, and I'll be trying to make it transparent as
> practically possible.
>
> The code's open source already:
> https://github.com/benschwarz/railscamp-13
>
> I'm working on the random allocation script now. I emailed this the other
> day to the Basecamp we're using to organise the camp:
> https://gist.github.com/toolmantim/0072595dffd2c0d1
>
> Aside from those helping to organise the camp, everyone will be in the
> ballot and randomly allocated from a single run of a yet-to-be-commited
> Ruby script.
>
> — tim
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Re: Railscamp Melbourne, June 21—24

2013-05-16 Thread Ben Schwarz
Reminder folks: You have until *midnight on Monday *to register for 
Railscamp, so get in the ballot ASAP!

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Railscamp Melbourne, June 21—24

2013-05-13 Thread Ben Schwarz
Go register!

http://railscamps.org
http://melb13.railscamps.org

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Running rack apps

2013-05-07 Thread Ben Hoskings
I already am, I just got confused writing that message yesterday :)

https://github.com/benhoskings/babushka-deps/blob/master/deploy.rb#L220

And yeah, I agree that everyone (including me) should read the signals
manpage repeatedly.

- Ben



On 7 May 2013 17:21, Paul Annesley  wrote:

>
> On 07/05/2013, at 4:59 PM, Ben Hoskings  wrote:
>
> > Chris --
> >
> > That's what I mean; USR2 restarts involve the original process
> disappearing completely, but that is usually treated as an error by upstart
> and the like. It's not good enough to exit the unicorn and have the
> monitoring restart it, because that causes downtime. (I might be
> misunderstanding you there.)
> >
> > I don't monitor unicorn with a separate tool; I treat the unicorn master
> as monitoring for the workers. I use upstart to monitor things like
> delayed_job, though, and restart them on deploy (the deploy process just
> sends them SIGQUIT).
>
> I suspect you should be using SIGTERM rather than SIGQUIT to stop
> delayed_job.
>
> Unicorn handles SIGQUIT in a non-standard (nice) way, but delayed_job
> doesn't seem to:
>
> https://github.com/collectiveidea/delayed_job/blob/master/lib/delayed/worker.rb#L134-144
> It traps SIGTERM (normal clean shutdown) and SIGINT (ctrl-c clean
> shutdown).
>
> Aside: if you're using Unicorn, you should read
> http://unicorn.bogomips.org/SIGNALS.html many times.
>
> TL;DR for the following: SIGQUIT is a user-requested crash, process
> shouldn't clean up after itself.
>
>
> > The SIGQUIT signal is sent to a process by its controlling terminal when
> the user requests that the process perform a core dump.
> — http://en.wikipedia.org/wiki/Unix_signal#POSIX_signals
>
> > The SIGQUIT signal is similar to SIGINT, except that it's controlled by
> a different key—the QUIT character, usually C-\—and produces a core dump
> when it terminates the process, just like a program error signal. You can
> think of this as a program error condition “detected” by the user.
> >
> > See Program Error Signals, for information about core dumps. See Special
> Characters, for information about terminal driver support.
> >
> > Certain kinds of cleanups are best omitted in handling SIGQUIT. For
> example, if the program creates temporary files, it should handle the other
> termination requests by deleting the temporary files. But it is better for
> SIGQUIT not to delete them, so that the user can examine them in
> conjunction with the core dump.
> —
> http://www.gnu.org/software/libc/manual/html_node/Termination-Signals.html
>
>
> — Paul
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>


-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Running rack apps

2013-05-07 Thread Ben Hoskings
Chris --

That's what I mean; USR2 restarts involve the original process disappearing
completely, but that is usually treated as an error by upstart and the
like. It's not good enough to exit the unicorn and have the monitoring
restart it, because that causes downtime. (I might be misunderstanding you
there.)

I don't monitor unicorn with a separate tool; I treat the unicorn master as
monitoring for the workers. I use upstart to monitor things like
delayed_job, though, and restart them on deploy (the deploy process just
sends them SIGQUIT).

- Ben



On 7 May 2013 16:17, Michael Pearson  wrote:

> Yep.
>
> If you send it the USR2 signal, it will fork and make an entirely new
> master, but the original process will die.
>
> It's possible to end up in fun infinite restart loops this way as upstart
> (or monit) tries to keep unicorn running.
>
> If your deployment process doesn't involve the USR2 signal, I recommend
> checking it out. Here is some reading (specifically the "Slow Deploys"
> signal): https://github.com/blog/517-unicorn
>
>
>
> On Tue, May 7, 2013 at 4:12 PM, Chris Berkhout wrote:
>
>> If the parent unicorn died, bash and sh would exit and upstart would
>> respawn the whole thing.
>>
>> Am I missing something?
>>
>>
>> On Tue, May 7, 2013 at 3:53 PM, Ben Hoskings  wrote:
>>
>>> In that case, how does it spawn a new version of itself?
>>>
>>>
>>> On 7 May 2013 15:00, Chris Berkhout  wrote:
>>>
>>>> I don't have unicorn daemonize, so upstart keeps the pid of the bourne
>>>> shell it started (which runs bash, which runs unicorn).
>>>>
>>>> # service restful_geof status
>>>> restful_geof start/running, process 2777
>>>> # ps -F -p 2777
>>>> UIDPID  PPID  CSZ   RSS PSR STIME TTY  TIME CMD
>>>> root  2777 1  0  1099   612   0 May06 ?00:00:00 /bin/sh
>>>> -e /proc/self/fd/9
>>>>
>>>> upstart doesn't know anything about the child unicorns. I'm not sure
>>>> whether that could lead to zombies. I think it won't necessarily if unicorn
>>>> manages the child processes properly.
>>>>
>>>>
>>>>
>>>> On Tue, May 7, 2013 at 2:27 PM, Paul Annesley  wrote:
>>>>
>>>>>
>>>>> On 07/05/2013, at 2:15 PM, Samuel Richardson 
>>>>> wrote:
>>>>>
>>>>> > Interesting. I've tried switching over to Upstart a couple of times
>>>>> but ran into trouble with it monitoring Sidekiq (I think, I can't remember
>>>>> exactly what process it was but it had forking behaviour).
>>>>>
>>>>> Probably not Sidekiq, I don't believe it forks.
>>>>> It's threaded and uses https://github.com/celluloid/celluloid
>>>>>
>>>>> ~/github/sidekiq ⸩ ack --ruby '^[^#]*fork'
>>>>> # $? == 1
>>>>>
>>>>> Unicorn certain forks, though. Also, Resque I believe.
>>>>>
>>>>> — Paul
>>>>>
>>>>>
>>>>> >
>>>>> > Because of that, I'd stuck with monit as I could just point it at a
>>>>> PID file and be done with it.
>>>>> >
>>>>> > Runit with the REST interface looks very nice though.
>>>>> >
>>>>> > Samuel Richardson
>>>>> > www.richardson.co.nz | 0405 472 748
>>>>> >
>>>>> >
>>>>> > On Tue, May 7, 2013 at 2:12 PM, Michael Pearson 
>>>>> wrote:
>>>>> > This was a long time ago, so it's fuzzy, but: its configuration
>>>>> language was confusing, it had confusing semantics for stopping/starting
>>>>> jobs, and it didn't log output at all, so you had no idea _why_ a
>>>>> particular process wasn't starting or stopping properly.
>>>>> >
>>>>> > I then switched to runit, which was pretty simple (and good).
>>>>> >
>>>>> > When I upgraded our systems to Ubuntu 12.04 I checked out upstart,
>>>>> and they'd made many improvements since what shipped with 10.04 (including
>>>>> output logs), and I haven't looked back.
>>>>> >
>>>>> >
>>>>> > On Tue, May 7, 2013 at 2:09 PM, Samuel Richardson <
>>>>> s...@richardson.co.nz> wrote:
>>>>> >

Re: [rails-oceania] [BEGINNER] Implicit vs Explicit return values

2013-05-06 Thread Ben Hoskings
Yep. The term for that in ruby is a block, which is a closure passed to a
method call. A closure is an anonymous function that runs in the scope of
where it was defined, not where it was called.

(Javascript functions are closures, but ruby methods aren't.)

In this case, what it means is that Enumerable#all? or Array#map can invoke
that block of mine by calling 'yield(item)' for each item of the list.
Because it's a closure, it runs in the binding it was defined, which is why
it can see #run_requirement.

A closure is a way of passing a context around -- it says to 'all?' or
'map', "here's some custom logic, if you pass control to me at the right
moment then I'll run it in my house and return the resulting value".

- Ben



On 7 May 2013 15:35, Sam Howie  wrote:

> @Simon
>
> Haha, yes the example was for structure. And, as you caught, I haven't
> quite kicked the habit of typing in all those parentheses! Thanks for
> confirming that implicit return values are still the established convention
> here.
>
> @Ben
>
> Thank you for sharing your code. I love how succinct it is and can see
> what you are getting at. It's not all readable to me yet, showing that I
> have a bit further to go in learning Ruby's syntax. This is off topic, but
> I have particular trouble with:
>
> {|r| run_requirement(r, and_meet) }
>
> Is that defining an annonymous function where |r| is the parameter,
> similar to the javascript:
>
> function(r){run_requirement(r, and_meet)}
>
>
>
>
>
> On Tue, May 7, 2013 at 3:24 PM, Simon Russell wrote:
>
>> Obviously you'd write your thing as:
>>
>> def is_grater_than_five(a)
>>   a > 5
>> end
>>
>> But I assume you mean the structure; yes, that's normal, and it
>> becomes readable.  As long as you don't have returns making things
>> complex in the middle.  (Also, no parentheses around the if
>> condition.)
>>
>> On Tue, May 7, 2013 at 3:15 PM, Sam Howie  wrote:
>> > *EDIT
>> >
>> > def is_grater_than_five(a)
>> >   if (a > 5)
>> > true
>> >   else
>> > false
>> >   end
>> > end
>> >
>> >
>> > On Tue, May 7, 2013 at 3:14 PM, Sam Howie  wrote:
>> >>
>> >> Thanks everyone. It seems pretty decisive that implicit returns are the
>> >> established convention, where explicit returns are acceptable when
>> exiting
>> >> the function early.
>> >>
>> >> But how about in conditional logic?
>> >>
>> >> def is_grater_than_five(a)
>> >>   if (a > 5)
>> >> true
>> >>   else
>> >> false
>> >> end
>> >>
>> >> This seems pretty readable with a simple function like the above, but I
>> >> could see those implicit returns becoming lost in messier code (which
>> of
>> >> course no one ever writes ;P)
>> >>
>> >>
>> >>
>> >> On Tue, May 7, 2013 at 2:59 PM, Steve H  wrote:
>> >>>
>> >>> I agree with Craig - I only use explicit returns for early exits. That
>> >>> seems to be the general convention.
>> >>>
>> >>> The GitHub style guide is generally close to what people consider
>> >>> idiomatic Ruby to be: https://github.com/styleguide/ruby
>> >>>
>> >>> --
>> >>> You received this message because you are subscribed to the Google
>> Groups
>> >>> "Ruby or Rails Oceania" group.
>> >>> To unsubscribe from this group and stop receiving emails from it,
>> send an
>> >>> email to rails-oceania+unsubscr...@googlegroups.com.
>> >>> To post to this group, send email to rails-oceania@googlegroups.com.
>> >>> Visit this group at
>> http://groups.google.com/group/rails-oceania?hl=en.
>> >>> For more options, visit https://groups.google.com/groups/opt_out.
>> >>>
>> >>>
>> >>
>> >>
>> >
>> > --
>> > You received this message because you are subscribed to the Google
>> Groups
>> > "Ruby or Rails Oceania" group.
>> > To unsubscribe from this group and stop receiving emails from it, send
>> an
>> > email to rails-oceania+unsubscr...@googlegroups.com.
>> > To post to this group, send email to rails-oceania@googlegroups.com.
>> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>> >

Re: [rails-oceania] [BEGINNER] Implicit vs Explicit return values

2013-05-06 Thread Ben Hoskings
Yep. To me this means "use lambda, not proc" as well as "don't use return".
(Procs are also absent from my idealised ruby) :)

Sam, you're right, the value that's being implicitly returned can be hard
to see in a complex method. I actually view this as a point in favour of
implicit returns, because when costs are visible, the fix (refactoring the
method) is clear.

- Ben



On 7 May 2013 15:48, Paul Annesley  wrote:

> Maybe a better example:
>
> # unsurprising:
> lambda { proc { 1 }.call + 1 }.call  # => 2
> lambda { lambda { return 1 }.call + 1 }.call  # => 2
>
> # surprising?
> lambda { proc { return 1 }.call + 1 }.call  # => 1
>
> — Paul
>
>
> On 07/05/2013, at 3:42 PM, Paul Annesley  wrote:
>
> > Returning in a lambda returns from the lambda back to its caller.
> > This is normally what you want.
> >
> > pry(main)> lambda { return }.call
> > => nil
> >
> > Returning in a proc returns from the caller, up to its caller… usually
> unexpected.
> >
> > pry(main)> proc { return }.call
> > LocalJumpError: unexpected return
> > from (pry):5:in `block in __pry__'
> >
> > Stabby-syntax is the nice lambda behaviour:
> >
> > [7] pry(main)> ->{ return }.call
> > => nil
> >
> > So running a non-lambda proc is kind of like eval'ing its code in your
> current context, rather than adding to the call stack.
> >
> > — Paul
> >
> >
> >
> > On 07/05/2013, at 3:38 PM, Michael Gall  wrote:
> >
> >> I seem to recall some weirdness with explicit returns in relation to
> lamdas, procs or blocks. Something like:
> >>
> >> %w(a b c).map do |i|
> >>  puts i
> >>  return i
> >> end
> >>
> >>
> >> This is invalid code, throws an unexpected return error, meaning that
> moving style between that sort of calls with explicit returns is crappy.
> >>
> >> There's another instance where returning from a proc or a lambda
> changes the behaviour. Anyone care to jog my memory?
> >>
> >>
> >>
> >>
> >> On Tue, May 7, 2013 at 3:24 PM, Simon Russell 
> wrote:
> >> Obviously you'd write your thing as:
> >>
> >> def is_grater_than_five(a)
> >>  a > 5
> >> end
> >>
> >> But I assume you mean the structure; yes, that's normal, and it
> >> becomes readable.  As long as you don't have returns making things
> >> complex in the middle.  (Also, no parentheses around the if
> >> condition.)
> >>
> >> On Tue, May 7, 2013 at 3:15 PM, Sam Howie  wrote:
> >>> *EDIT
> >>>
> >>> def is_grater_than_five(a)
> >>>  if (a > 5)
> >>>true
> >>>  else
> >>>false
> >>>  end
> >>> end
> >>>
> >>>
> >>> On Tue, May 7, 2013 at 3:14 PM, Sam Howie  wrote:
> >>>>
> >>>> Thanks everyone. It seems pretty decisive that implicit returns are
> the
> >>>> established convention, where explicit returns are acceptable when
> exiting
> >>>> the function early.
> >>>>
> >>>> But how about in conditional logic?
> >>>>
> >>>> def is_grater_than_five(a)
> >>>>  if (a > 5)
> >>>>true
> >>>>  else
> >>>>false
> >>>> end
> >>>>
> >>>> This seems pretty readable with a simple function like the above, but
> I
> >>>> could see those implicit returns becoming lost in messier code (which
> of
> >>>> course no one ever writes ;P)
> >>>>
> >>>>
> >>>>
> >>>> On Tue, May 7, 2013 at 2:59 PM, Steve H  wrote:
> >>>>>
> >>>>> I agree with Craig - I only use explicit returns for early exits.
> That
> >>>>> seems to be the general convention.
> >>>>>
> >>>>> The GitHub style guide is generally close to what people consider
> >>>>> idiomatic Ruby to be: https://github.com/styleguide/ruby
> >>>>>
> >>>>> --
> >>>>> You received this message because you are subscribed to the Google
> Groups
> >>>>> "Ruby or Rails Oceania" group.
> >>>>> To unsubscribe from this group and stop receiving emails from it,
> send an
> >>>>> email to rails-oceania+uns

Re: [rails-oceania] Re: Running rack apps

2013-05-06 Thread Ben Hoskings
In that case, how does it spawn a new version of itself?


On 7 May 2013 15:00, Chris Berkhout  wrote:

> I don't have unicorn daemonize, so upstart keeps the pid of the bourne
> shell it started (which runs bash, which runs unicorn).
>
> # service restful_geof status
> restful_geof start/running, process 2777
> # ps -F -p 2777
> UIDPID  PPID  CSZ   RSS PSR STIME TTY  TIME CMD
> root  2777 1  0  1099   612   0 May06 ?00:00:00 /bin/sh -e
> /proc/self/fd/9
>
> upstart doesn't know anything about the child unicorns. I'm not sure
> whether that could lead to zombies. I think it won't necessarily if unicorn
> manages the child processes properly.
>
>
>
> On Tue, May 7, 2013 at 2:27 PM, Paul Annesley  wrote:
>
>>
>> On 07/05/2013, at 2:15 PM, Samuel Richardson 
>> wrote:
>>
>> > Interesting. I've tried switching over to Upstart a couple of times but
>> ran into trouble with it monitoring Sidekiq (I think, I can't remember
>> exactly what process it was but it had forking behaviour).
>>
>> Probably not Sidekiq, I don't believe it forks.
>> It's threaded and uses https://github.com/celluloid/celluloid
>>
>> ~/github/sidekiq ⸩ ack --ruby '^[^#]*fork'
>> # $? == 1
>>
>> Unicorn certain forks, though. Also, Resque I believe.
>>
>> — Paul
>>
>>
>> >
>> > Because of that, I'd stuck with monit as I could just point it at a PID
>> file and be done with it.
>> >
>> > Runit with the REST interface looks very nice though.
>> >
>> > Samuel Richardson
>> > www.richardson.co.nz | 0405 472 748
>> >
>> >
>> > On Tue, May 7, 2013 at 2:12 PM, Michael Pearson 
>> wrote:
>> > This was a long time ago, so it's fuzzy, but: its configuration
>> language was confusing, it had confusing semantics for stopping/starting
>> jobs, and it didn't log output at all, so you had no idea _why_ a
>> particular process wasn't starting or stopping properly.
>> >
>> > I then switched to runit, which was pretty simple (and good).
>> >
>> > When I upgraded our systems to Ubuntu 12.04 I checked out upstart, and
>> they'd made many improvements since what shipped with 10.04 (including
>> output logs), and I haven't looked back.
>> >
>> >
>> > On Tue, May 7, 2013 at 2:09 PM, Samuel Richardson 
>> wrote:
>> > While I'm enjoying this tangent on unicorn behaviour, I'm also an avid
>> Monit user. What were your problems with it?
>> >
>> > Samuel Richardson
>> > www.richardson.co.nz | 0405 472 748
>> >
>> >
>> > On Tue, May 7, 2013 at 2:08 PM, Michael Pearson 
>> wrote:
>> > Oh, one time?
>> >
>> > My start/stop script got out of whack (protip: monit is terrible, use
>> runit or upstart instead) and so I had to say "that's not working because
>> the system is overrun with rogue unicorns"
>> >
>> > Okay I'm done.
>> >
>> >
>> > On Tue, May 7, 2013 at 12:35 PM, Michael Pearson 
>> wrote:
>> > Unicorn is excellent because you can say things like:
>> >
>> > "are there any unicorns still alive?"
>> > "Oh, crap, we have zombie unicorns"
>> >
>> > and
>> >
>> > "The master unicorn has spawned a new child. Once the new child has
>> spawned all of its new unicorns, and they have grown up, it will kill the
>> older master unicorn, and all of its children will die"
>> >
>> > This is otherwise known as sending it the USR2 signal.
>> >
>> > On Wed, May 1, 2013 at 10:20 AM, Ben Hoskings  wrote:
>> > We run two production rack/sinatra apps at TC. I recommend nginx +
>> unicorn.
>> >
>> > This is how I do it (it's badly named; it's not rails-specific):
>> https://github.com/conversation/babushka-deps/blob/master/rails.rb#L1-L4
>> >
>> > - Ben
>> >
>> >
>> >
>> > On 1 May 2013 10:00, Steve H  wrote:
>> > I've had good luck with Unicorn. I use it with nginx but Apache will
>> work equally well, as you just reverse proxy a port or unix socket.
>> >
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to rails-oceania+unsubscr

Re: [rails-oceania] [BEGINNER] Implicit vs Explicit return values

2013-05-06 Thread Ben Hoskings
My other reason, which I think I value more, is that using return means
thinking in a procedural way. "Right, step one, return the first result of
scanning like this":

  def first_word(text)
return text.scan(/\w+/).first
  end

But without return, it reads declaratively. "the first word is the first
result from scanning like this":

  def first_word(text)
text.scan(/\w+/).first
  end

The method doesn't look like instructions anymore; it just _is_ the first
result of scanning the string. The method just has a certain value because
it's defined that way.

It's a much more functional design: you can think of the method like a
mapping from input to output, like a mathematical function.

Of course, it could well be side-effecting; this is stylistic only. But I
think what arises reads well (these 4 or 5 methods are a set that recurse
together):
https://github.com/benhoskings/babushka/blob/master/lib/babushka/dep.rb#L313

- Ben



On 7 May 2013 14:56, Craig Ambrose  wrote:

>  That's a pretty good question Sam. There's a definite convention amongst
> ruby programmers to rely on the implicit return value. Certainly I never
> use the return keyword unless I'm doing an early exit from a method (which
> is not something I do often). This seemed strange to me for my first few
> weeks using ruby, but now I wouldn't want to do it any other way. It's
> particularly clear if you use small methods, like in your example, and then
> you start to think of the methods almost as logical expressions.
>
> --
> Craig Ambrose
> Atamai Village, Motueka
> Please join us on facebook at http://www.facebook.com/atamaivillage
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] [BEGINNER] Implicit vs Explicit return values

2013-05-06 Thread Ben Hoskings
I strongly favour implicit returns. I see return as a surprise, and I think
the flow of conditional logic is a better way to express return values.

If that logic becomes too complex, I think the answer is to break up the
method, not use 'return'.

The idealised version of ruby in my head doesn't have a 'return' keyword.

- Ben



On 7 May 2013 14:33, Sam Howie  wrote:

> Hi all,
>
> <
> My name is Sam Howie. I am a gameplay programmer looking to diversify into
> the more stable field of web development.
>
> A good friend of mine highly recommended Ruby and Ruby on
> Rails, emphasising that the community is friendly and supportive. I liked
> the sound of that. So, here I am learning the ins and out of Ruby before
> I tackle the Rails framework.
>
> PREAMBLE
>
>
> I have noticed that Ruby functions, like CoffeeScript functions, always 
> return a value. This allows for implicitly returning values like the 
> following:
>
>
> def add(a, b)
>
>   a + b
>
> end
>
>
> However, you can also explicitly return values from function as in the 
> following:
>
>
> def add(a, b)
>
>   return a + b
>
> end
>
>
> Now, I was wondering, is there an established best practice for this in terms 
> of readability?
>
>
> Personally, I come from a background where I would favour explicitly 
> returning values. At first glance it seems that explicitly returning values 
> would allow for quicker code scanning. What does the community think?
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Helping Junior Rubists Find Work

2013-05-03 Thread Ben Taylor
I definitely agree with Steven. I was lucky enough to discover Ruby + Rails via 
a friend and ended up doing freelance and contract work while I was at Uni, but 
many other students aren't in the same boat. Either they never find out about 
the community (does Ruby AU do outreach to universities?) or they don't have 
the time (can you imagine learning Ruby on Rails on the side while also writing 
an Honours thesis and working weekends to cover your expenses?). Big companies 
are very visible and they have obvious grad programs that are easy to sign up 
to.

Some of the best CS students I know have ended up in graduate roles at Banks 
and Consultancy firms. Many of them would love to transition to Ruby on Rails 
work, or Django work, or iOS dev or just about anything that doesn't involve 
three meetings a day and a slew of bland work. But the community just doesn't 
seem to want them. The silly bit is that for many of them getting productive in 
a new language isn't a big deal.

As the others have said, graduate or intern programs could definitely help your 
business (and give back to the community!)

- Ben


On Friday, 3 May 2013 at 5:02 PM, Steven Farlie wrote:

> My anecdotal experience (as a volunteer coach/organiser in OpenTechSchool) is 
> that the talent base for junior programmers is incredibly broad but it is 
> there. There are people with programming knowledge but not domain knowledge 
> (e.g. Python but not web), or domain knowledge without the platform (web but 
> not specifically Ruby/Rails is very common). Lots of people from the sciences 
> (there are no jobs in science!). Aside from the lucky few who fell into the 
> scene outside of their studies they simply don't know where to go. Others go 
> through private courses like Sydney Dev Camp or App Academy. I know there is 
> a supply of raw talent, but it is difficult for employers to find. Not to 
> mention the problem of evaluating. Picking a good hire is a lottery at the 
> best of times.
> 
> If anyone is musing about opening a junior role I would encourage it. It can 
> be immensely rewarding both for the dev and the team. Think of all those bad 
> habits they would never even have the chance to learn! 
> -- 
> Steven
> 
> 
> 
> On 3 May 2013 14:56, Michael Pearson  (mailto:mipear...@gmail.com)> wrote:
> > This isn't consistent with my most recent experiences recruiting: we 
> > advertised at all levels, and received very few applications from junior 
> > developers. You're welcome to search the list and find the job ad I posted.
> > 
> > At the time, we were looking specifically at both ends of the spectrum: 
> > either somebody shit hot to help teach us some cool new tricks (which is 
> > what we got, in the end) or somebody fresh that who could bring in some 
> > optimism and take some of the load off while we worked out how to fix 
> > everything. 
> > 
> > It's also possible that I, being the one who posted the ad, was being 
> > deliberately exclusionary: I only wanted juniors to apply via the mailing 
> > list rather than via recruiters or seek. I wanted somebody who was keen 
> > enough about Ruby to be part of the community (or at least be aware that it 
> > exists), rather than somebody who's just graduated a Java-heavy CS degree 
> > and will now latch on to anything that will help them make rent this month. 
> > 
> > So it's possible that we're not hostile towards juniors - but possibly 
> > we're doubtful of juniors put forward via recruiters, thanks to being 
> > burned before by resume-fiddling and other such nasty things. 
> > 
> > Also - do these several amazing juniors have github accounts, or other 
> > proof of capability? Are they on this list (at least filtered for anything 
> > with [JOB] in the title)? 
> > 
> > 
> > On Fri, May 3, 2013 at 2:26 PM, Ashley Pettit  > (mailto:is_ash_is_g...@hotmail.com)> wrote:
> > > Hi Guys,
> > > 
> > > I've noticed a bit of a problem with the ruby community and I wanted to 
> > > voice my concerns.  
> > > 
> > > Firstly let me say the ruby community is great. Full of passionate people 
> > > who love what they do and 9 times out of 10 something built in ruby is 
> > > better than something not purely because the developers are so passionate 
> > > about creating awesome products. 
> > > 
> > > So where's the problem?
> > > 
> > > Ruby is a language which has been embraced by start-ups and small-medium 
> > > sized businesses. It's not something the larger companies have taken to. 
> > > 
> > > Why is this a problem?
> &g

Re: [rails-oceania] [JOB] Contract/Perm Ruby Dev Roles - Melbourne Based

2013-05-03 Thread Ben Schwarz
Comments on job threads are often better handled off-list (privately) 
Locking this thread. 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] [JOB] Contract/Perm Ruby Dev Roles - Melbourne Based

2013-05-03 Thread Ben Taylor
Daniel, while you may be technically correct it's really not useful to point 
out.

At various points in the past people have attempted to patch the masculine 
version of pronouns to be gender non-specific (see: 
http://en.wikipedia.org/wiki/Gender-neutral_pronoun). This has been widely 
unsuccessful and while "guys" to you may be the equivalent of "people" it 
definitely has gendered tones. The best solution is to try your best to stick 
to gender neutral versions. Saying "Hey everyone" or "Hey rubyists" or "Hello 
there, reader" can all work.

This goes across the board, if you don't have enough information to pin a 
gender, you should try not to. I personally enjoy playing "the gender-neutral 
game" by trying to avoid all references to gender, even when the subject is 
obviously gendered to all parties (see: 
http://en.wikipedia.org/wiki/Wikipedia:Gender-neutral_language).

And now a lesson: When someone expresses they feel like they're being excluded, 
the easiest way to make that worse is to explicitly tell them they're wrong.

I personally believe you had the best of intentions, but I recommend more tact 
in the future.

These conversations can easily flame up - so I'm hoping that we won't have too 
many more replies. Let's all try to keep this list on topic (while still 
allowing people to bring up issues of inequity and unprofessional conduct).  

- Ben


On Friday, 3 May 2013 at 5:33 PM, Daniel Sabados wrote:

>  
> On Fri, May 3, 2013 at 2:49 PM, Alex "Skud" Bayley  (mailto:s...@infotrope.net)> wrote:
> > On 3/05/13 9:17 AM, Brent Thomson wrote:
> > >  
> > > Hi Guys,
> > >  
> > >  
> >  
> >  
> > Just a reminder that not everyone on this mailing list is a guy.
>  
> Just a reminder guys that "guys" refers to either sex.
>  
> http://oxforddictionaries.com/definition/english/guy  
>  
>  (guys) people of either sex:you guys want some coffee?  
> http://www.merriam-webster.com/dictionary/guy
>  
> b : person (http://www.merriam-webster.com/dictionary/person) —used in plural 
> to refer to the members of a group regardless of sex  the guys>  
>  
> Just saying..
>   
> >  
> > A.
> >  
> > -- Alex "Skud" Bayley s...@infotrope.net (mailto:s...@infotrope.net) 
> > http://infotrope.net/  
> >  
> > --  
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania%2bunsubscr...@googlegroups.com).
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >   
> >   
>  
> --  
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>   
>   

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Re: Mid-2013 Melbourne RailsCamp?

2013-05-02 Thread Ben Schwarz
Announce is coming soon, but: 

It'll be June 21—24, in Melbourne. 

Still plenty of time for flights. 

Follow @railscamp_au on Twitter to keep in touch. 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Running rack apps

2013-04-30 Thread Ben Hoskings
Yeah, that's a good idea when they're a small extra piece.

In this case, they're distinct apps with their own DBs (to postgres via
sequel), and so I want each one to have separate DB credentials, to run as
a separate unix user, etc.

- Ben



On 1 May 2013 10:35, Andrew Harvey  wrote:

> I'm a big fan of using config.ru to mount my rack apps next to my rails
> app where it's useful as well.
>
> I've only used it when taking a path and routing to that, so if need to
> work by domain, then a separate unicorn instance is probably the go.
>
> A.
>
> On 30/04/2013, at 5:20 PM, Ben Hoskings  wrote:
>
> We run two production rack/sinatra apps at TC. I recommend nginx + unicorn.
>
> This is how I do it (it's badly named; it's not rails-specific):
> https://github.com/conversation/babushka-deps/blob/master/rails.rb#L1-L4
>
> - Ben
>
>
>
> On 1 May 2013 10:00, Steve H  wrote:
>
>> I've had good luck with Unicorn. I use it with nginx but Apache will work
>> equally well, as you just reverse proxy a port or unix socket.
>>
>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to rails-oceania+unsubscr...@googlegroups.com.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>>
>
>
>
> --
> Cheers
> Ben
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Running rack apps

2013-04-30 Thread Ben Hoskings
We run two production rack/sinatra apps at TC. I recommend nginx + unicorn.

This is how I do it (it's badly named; it's not rails-specific):
https://github.com/conversation/babushka-deps/blob/master/rails.rb#L1-L4

- Ben



On 1 May 2013 10:00, Steve H  wrote:

> I've had good luck with Unicorn. I use it with nginx but Apache will work
> equally well, as you just reverse proxy a port or unix socket.
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Testing before_filters

2013-04-29 Thread Ben Hoskings
I think it makes debugging easier, not harder -- it produces a hard
exception with a complete callstack. A 404 caused by a before_filter can
take a lot of spelunking to track down.

- Ben



On 30 April 2013 09:24, Clifford Heath  wrote:

> On 29/04/2013, at 9:28 PM, William Madden  wrote:
> > Nice approach Ben, that (memoized helpers) is a lot cleaner than before
> filters.
>
> Just beware that this approach delays the "record not found" exception
> until
> you first call the helper. That might be inside some view code, which can
> make
> debugging harder.
>
> Clifford Heath
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>


-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] [OT] Support the Draft Digital Technologies Curriculum

2013-04-29 Thread Ben Taylor
Some of you may have seen me post in the past about a High School camp I help 
tutor for where we teach students Python and general Web Development skills. 
Those involved with running the camp (NCSS, particularly James Curran, Tara 
Murphy and Nicky Ringland) have been part of the Draft process for a new 
Digital Technologies Curriculum which looks very promising, involving students 
in CS topics long before High School. You can support it here:

https://www.change.org/en-AU/petitions/australian-curriculum-assessment-and-reporting-authority-acara-support-the-draft-digital-technologies-curriculum

You may remember your own High School experiences and how significantly lacking 
they were. I remember studying Software Development in year 12 using a textbook 
which was authored before I started primary school. Not much has changed since 
then. NCSS outreach helps many highly motivated students, but those less 
motivated never get the chance to see the fantastic things they could 
potentially create. I personally hope that in the future this won't be the case.

Cheers,
- Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: Testing before_filters

2013-04-28 Thread Ben Hoskings
"AAA" is the response they elicit in me when I see a bunch of them atop a
controller. :)

I assume you mean auth*n? A single before_filter for auth is reasonable, I
think, but I've also designed it without any filter at all, having the
#current_user method lazily auth. That worked really nicely. This is
approximately what it does:

def current_user
  @current_user ||= retrieve_user.tap do |user|
store_session_for(user)
set_time_zone_for(user)
  end
end
helper_method :current_user

def retrieve_user
  retrieve_user_from_session || retrieve_user_from_cookie ||
retrieve_user_from_login_token
end

Which means #before_filter really can be avoided (almost) entirely:
http://d.pr/1Rms (Forgive me for that #skip_before_filter; I wrote that
code in the days when flash was the only way to do multiple file uploads
and the resulting requests don't preserve the session.)

- Ben



On 29 April 2013 12:19, Michael Pearson  wrote:

> That's clever, Ben.
>
> What about the AAA role that before_filters tend to perform?
>
>
> On Mon, Apr 29, 2013 at 12:16 PM, Ben Hoskings  wrote:
>
>> This is my problem with before_filters: they side-effect to do their job.
>> Store-and-call is a huge smell in this situation. It causes awful coupling,
>> and leads to very confusing bugs because the before_filter isn't in the
>> action callstack.
>>
>> They also lead to extensive instance variable use in views, which is also
>> a really bad pattern, since they default to nil and can't be worked with
>> reasonably like a method call can.
>>
>> I think before_filters are best avoided whenever possible (there are a
>> select few cases where they're useful, though). I prefer to use lazy
>> private helpers instead, like:
>>
>>   def post
>> @post ||= Post.from_params!(params[:that_you_want])
>>   end
>>   helper_method :post
>>
>>
>>
>>
>> On 29 April 2013 12:08, Mario Visic  wrote:
>>
>>> Hi Will
>>>
>>> Nice writeup, looks like it's really useful.
>>> One thing to think about is that your before filter is now a public
>>> method on the controller.
>>> Perhaps you should move it to private/protected so that others don't
>>> rely on it.
>>>
>>> The one problem with this approach is that once it's a private method
>>> it's no longer a good idea to test the method directly anymore.
>>> The only other solution then would be to test the side affects of the
>>> method each time which can get cumbersome.
>>>
>>> If only controller testing were easier :)
>>>
>>> Cheers
>>> Mario
>>>
>>> On Saturday, April 27, 2013 11:56:12 PM UTC+10, William Madden wrote:
>>>>
>>>> Hey guys,
>>>>
>>>> I haven't seen a satifactory answer on the web for how to test before
>>>> filters thoroughly and without introducing duplication into my tests so I
>>>> worked out a solution of my own.
>>>>
>>>> The TL;DR is that you test the filter method on its own, then test that
>>>> it's invoked by each action you expect to be covered by it.
>>>>
>>>> There are a few hacks to get everything to behave so I wrote up how I
>>>> did 
>>>> it<http://tech.letsgeddit.com/2013/04/testing-beforefilters-in-isolation.html>
>>>> .
>>>>
>>>> Hope it helps,
>>>> Will
>>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Ruby or Rails Oceania" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to rails-oceania+unsubscr...@googlegroups.com.
>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>>
>>>
>>
>>
>>
>> --
>> Cheers
>> Ben
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Ruby or Rails Oceania" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to rails-oceania+unsubscr...@googlegroups.com.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>> For more options, visit https://groups.google.c

Re: [rails-oceania] Re: Testing before_filters

2013-04-28 Thread Ben Hoskings
This is my problem with before_filters: they side-effect to do their job.
Store-and-call is a huge smell in this situation. It causes awful coupling,
and leads to very confusing bugs because the before_filter isn't in the
action callstack.

They also lead to extensive instance variable use in views, which is also a
really bad pattern, since they default to nil and can't be worked with
reasonably like a method call can.

I think before_filters are best avoided whenever possible (there are a
select few cases where they're useful, though). I prefer to use lazy
private helpers instead, like:

  def post
@post ||= Post.from_params!(params[:that_you_want])
  end
  helper_method :post




On 29 April 2013 12:08, Mario Visic  wrote:

> Hi Will
>
> Nice writeup, looks like it's really useful.
> One thing to think about is that your before filter is now a public method
> on the controller.
> Perhaps you should move it to private/protected so that others don't rely
> on it.
>
> The one problem with this approach is that once it's a private method it's
> no longer a good idea to test the method directly anymore.
> The only other solution then would be to test the side affects of the
> method each time which can get cumbersome.
>
> If only controller testing were easier :)
>
> Cheers
> Mario
>
> On Saturday, April 27, 2013 11:56:12 PM UTC+10, William Madden wrote:
>>
>> Hey guys,
>>
>> I haven't seen a satifactory answer on the web for how to test before
>> filters thoroughly and without introducing duplication into my tests so I
>> worked out a solution of my own.
>>
>> The TL;DR is that you test the filter method on its own, then test that
>> it's invoked by each action you expect to be covered by it.
>>
>> There are a few hacks to get everything to behave so I wrote up how I
>> did 
>> it<http://tech.letsgeddit.com/2013/04/testing-beforefilters-in-isolation.html>
>> .
>>
>> Hope it helps,
>> Will
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Best practices for return values

2013-04-26 Thread Ben Hoskings
It depends on whether you're calling the method for its value, or for a 
side-effect.

If you want the value, then I'd make repeated calls just return the value, so 
the method is memoized (assuming the initial call is expensive).

If it's side-effecting, my feeling is that the method should always do its job 
whenit's called. If that causes an error, then you'll get a legitimate 
exception, which should be handled by the caller.

One exception is a method that explicitly should only run once, like ruby's 
#require. In that case, I think returning false (and true for the initial call 
that does work) makes sense; that's how #require behaves.

- Ben


Sent from my iPhone

On 26/04/2013, at 3:05 PM, Sebastian Porto  wrote:

> (Sorry if this ends as a double post, as I send this using email, but for 
> some reason it doesn't show in the group. So I am posting it again directly 
> on the group page.)
> 
> Hi All
> 
> I'm building a gem and trying to decide what is the best way to provide 
> return values.
> 
> Let's say that my gem add the do_something method to user:
> 
> user.do_something
> 
> But if that something is already done I want to provide meaningful feedback, 
> I can't decide what is a best practice here or what is better, these is what 
> I can think of:
> 
> Option 1. return false
> 
> res = user .do_something
> res //=> false
> user.errors //=> ['already done'] information about the errors, like 
> active record
> 
> Option 2. raise an exception (seems a little drastic)
> 
> begin
> res = user .do_something
> rescue MyGem::AlreadyDoneException => e
> 
> end
> 
> Option 3. return an error code
> 
> res = user.do_something
> res //=> 3 (meaning already done)
> 
> Option 4. return an object
> 
> res = user.do_something
> res.success //=> false
> res.messages //=> ['already done']
> 
> Any recommendations on what is a best practice here?
> 
> Thanks,
> Sebastian
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Using form_for with nested resources in a namespace

2013-04-24 Thread Ben Taylor
The big difference is that you're namespacing your models. Without the model 
namespacing it would "just work".

- Ben


On Wednesday, 24 April 2013 at 5:18 PM, Michael Webb wrote:

> Thanks Pat, will do. It is a bit of a pain when you're using the same form 
> for :new and :edit cause then you're stuck with ternary ifs all up in your 
> form_fors, but, if that's how Rails rolls, who am I to argue?
>  
> It's a bit bewildering as there are several suggestions that this should 
> "just work":
> http://stackoverflow.com/questions/2718059/nested-resources-in-namespace-form-for
>   
> http://stackoverflow.com/questions/4909988/rails-3-nested-resource-route-problem-as-form-for
>   
> https://github.com/rails/rails/issues/9146  
>  
> On Wednesday, April 24, 2013 5:13:16 PM UTC+10, Pat Allan wrote:
> > Ben's suggestions are spot on - if your models are namespaced, then the 
> > namespace is part of the generated route name.
> > You could probably work around this (see ActiveModel::Naming, which is 
> > included in ActiveRecord::Base), but personally I would just specify the 
> > url manually instead - sometimes it's not worth fighting Rails' opinions 
> > (and it could be that changing the model_name class method could result in 
> > complications elsewhere).
> > So:
> >   form_for @charge_rate, :url => 
> > reconciliation_charge_charge_rates_path(@charge, @charge_rate), #…
> > If you find yourself writing it a lot, I guess you could wrap it up in a 
> > helper.
> > --  
> > Pat
> > On 24/04/2013, at 9:00 AM, Ben Taylor wrote:
> > > I don't have a complete understanding here, but from what I'm seeing I'm 
> > > assuming that the way the URL is determined from a form_for takes into 
> > > account the objects type. So you have:
> > >  
> > > [:reconciliation, Reconciliation::Charge, Reconciliation::ChargeRate]
> > >  
> > > which rails is deciding should make a URL that looks like...
> > >  
> > > ["reconciliation", "reconciliation_charge", "reconiciliation_charge_rate"]
> > >  
> > > when what you actually want is
> > >  
> > > ["reconciliation", "charge", "charge_rate"]  
> > >  
> > > I've never namespaced my models, so I've never personally come across 
> > > this. If you are okay with a fix that changes your models, you could 
> > > remove the namespacing from your models and that would fix it.
> > >  
> > > Looking at StackOverflow all I can see is a recommendation to specify the 
> > > URL yourself. 
> > > http://stackoverflow.com/questions/11713427/form-for-with-module-and-namespace
> > >  
> > > Does that help?
> > >  
> > > - Ben
> > >  
> > > On Wednesday, 24 April 2013 at 3:34 PM, Michael Webb wrote:
> > >  
> > >> Hi all,
> > >>  
> > >> I'm building a fairly large Rails app for my current client and am doing 
> > >> a bit of a restructure of the database after a manic few months getting 
> > >> version one up and running.
> > >>  
> > >> I've tried to group tables into namespaces based on functionality and am 
> > >> having some serious difficulty getting form_for to work when it is 
> > >> operating on nested resources within a namespace.
> > >>  
> > >> From routes.rb:
> > >> ...
> > >> namespace :reconciliation do
> > >> resources :charges do
> > >> resources :charge_rates
> > >>  end
> > >> end
> > >> ...
> > >>  
> > >> From the relevant _form.html:
> > >> = form_for [:reconciliation, @charge, @charge_rate], :html => 
> > >> {:multipart => true, :class => "edit_form"} do |f|
> > >> ...
> > >>  
> > >> The line above raises: undefined method 
> > >> `reconciliation_reconciliation_charge_reconciliation_charge_rates_path' 
> > >> for #<#:0x3778080> in polymorphic_url.
> > >>  
> > >> I have verified that both @charge and @charge_rate are not null and are 
> > >> of the appropriate type (Reconciliation::Charge and 
> > >> Reconciliation::ChargeRate).
> > >>  
> > >> rake routes shows that the reconciliation_charge_charge_rates_path 
> > >> exists.
> > &g

Re: [rails-oceania] Using form_for with nested resources in a namespace

2013-04-24 Thread Ben Taylor
I don't have a complete understanding here, but from what I'm seeing I'm 
assuming that the way the URL is determined from a form_for takes into account 
the objects type. So you have:

[:reconciliation, Reconciliation::Charge, Reconciliation::ChargeRate]

which rails is deciding should make a URL that looks like...

["reconciliation", "reconciliation_charge", "reconiciliation_charge_rate"]

when what you actually want is

["reconciliation", "charge", "charge_rate"] 

I've never namespaced my models, so I've never personally come across this. If 
you are okay with a fix that changes your models, you could remove the 
namespacing from your models and that would fix it. 

Looking at StackOverflow all I can see is a recommendation to specify the URL 
yourself. 
http://stackoverflow.com/questions/11713427/form-for-with-module-and-namespace

Does that help?

- Ben


On Wednesday, 24 April 2013 at 3:34 PM, Michael Webb wrote:

> Hi all,
> 
> I'm building a fairly large Rails app for my current client and am doing a 
> bit of a restructure of the database after a manic few months getting version 
> one up and running.
> 
> I've tried to group tables into namespaces based on functionality and am 
> having some serious difficulty getting form_for to work when it is operating 
> on nested resources within a namespace.
> 
> From routes.rb:
> ...
> namespace :reconciliation do
> resources :charges do
> resources :charge_rates
> 
>  end
> end
> ...
> 
> From the relevant _form.html:
> = form_for [:reconciliation, @charge, @charge_rate], :html => {:multipart => 
> true, :class => "edit_form"} do |f|
> ...
> 
> The line above raises: undefined method 
> `reconciliation_reconciliation_charge_reconciliation_charge_rates_path' for 
> #<#:0x3778080> in polymorphic_url.
> 
> I have verified that both @charge and @charge_rate are not null and are of 
> the appropriate type (Reconciliation::Charge and Reconciliation::ChargeRate).
> 
> rake routes shows that the reconciliation_charge_charge_rates_path exists.
> 
> According to every article I could find on Stack Overflow, my _form.html code 
> should work, what am I doing wrong?
> 
> Thanks,
> 
> Mike 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Hacknight

2013-04-11 Thread Ben Taylor
I intend to bring a project which is purely for evil.

- Ben


On Thursday, 11 April 2013 at 5:52 PM, Daryl Manning wrote:

> It's more a guideline, than a hard and fast rule. If it's FOSS that charities 
> *could* use, then sure!... And hey, even then "Hack Freestyle" is the 
> fallback.
> 
> ciao ! 
> Daryl.
>  
> 
> 
> 
> On Thu, Apr 11, 2013 at 5:36 PM, Jon Rowe  (mailto:m...@jonrowe.co.uk)> wrote:
> > If I bring open source to hack on, is that charitable enough :P
> > 
> > (I could be swayed into helping someone else on an actual charity project, 
> > especially if pairing) 
> > 
> > Jon Rowe
> > -
> > m...@jonrowe.co.uk (mailto:m...@jonrowe.co.uk)
> > jonrowe.co.uk (http://jonrowe.co.uk)
> > 
> > 
> > On Thursday, 11 April 2013 at 16:52, Daryl Manning wrote:
> > 
> > > Wiki has been updated with HackNight details. Sign up Rubyists! (um, or 
> > > javascript-ists! We're only banning Haskell users this time... =p ).
> > > 
> > > https://github.com/rails-oceania/roro/wiki/rorosyd-hack-night#do-gooder-and-freestyle-hacknight--the-institute-for-sustainable-futures
> > > 
> > > Please sign up early and especially let people know if you have a 
> > > charitable project that could use some assistance. 
> > > 
> > > thanks !
> > > Daryl.
> > > 
> > > 
> > > 
> > > On Thu, Apr 11, 2013 at 4:34 PM, Daryl Manning  > > (mailto:daryl.mann...@gmail.com)> wrote:
> > > > [Sorry, Andrew, this is probably my fault in not talking about 
> > > > HackNight as I wasn't at RORO. Thanks for the prod.]
> > > > 
> > > > Hack Night for April will take place on 23rd April at the Institute for 
> > > > Sustainable Futures 11th floor of Building 10 at the University of 
> > > > Technology Sydney (to the side of the large tower-y thing) on 235 Jones 
> > > > St. Out good friends at Ninefold cannot host this month. 
> > > > 
> > > > Pizza, cider, beer, non-alcoholic drinks will be provided in our 
> > > > (currently in middle of refurbishment) digs.
> > > > 
> > > > Details for access (Tim and I's phone number) to get into the secure 
> > > > building, will be posted on the wiki.  
> > > > 
> > > > We were hoping to have a "charitable" theme, this month. Find a project 
> > > > or a charity that needs some IT help and hack the hell out of it for a 
> > > > good cause (for example, I'm working on a worldwide Species Assurance 
> > > > database for endangered amphibians... fascinating project actually... 
> > > > ), but if you don't have anything, just come and "Hack As You Are." 
> > > > 
> > > > If you do have a charity project you'd like help with, let it be 
> > > > known... if you want oneand don't have one, ask a smaller charity whose 
> > > > work you like if you can help em out. Trust me, heaps of places in the 
> > > > industry *badly* need help, especially here in Aus. Volunteering is 
> > > > good for you...  
> > > > 
> > > > If you have any questions, let me know. Easiest to ping me @awws on 
> > > > twitter or Tim on @tjmcewan.
> > > > 
> > > > ciao !
> > > > Daryl. 
> > > > 
> > > > 
> > > > On Thu, Apr 11, 2013 at 3:27 PM, Andrew Grimm  > > > (mailto:andrew.j.gr...@gmail.com)> wrote:
> > > > > For the benefit of those not there on Tuesday, there was a hacknight 
> > > > > announced, but the wiki hasn't been updated.
> > > > > 
> > > > > Also, it's been announced that there'll be a monthly series of 
> > > > > installfests, but this month's installfest is booked out. 
> > > > > http://www.meetup.com/Ruby-On-Rails-Oceania-Sydney/events/109188632/ 
> > > > > 
> > > > > Andrew 
> > > > > 
> > > > > -- 
> > > > > You received this message because you are subscribed to the Google 
> > > > > Groups "Ruby or Rails Oceania" group.
> > > > > To unsubscribe from this group and stop receiving emails from it, 
> > > > > send an email to rails-oceania+unsubscr...@googlegroups.com 
> > > > > (mailto:rails-oceania%2bunsubscr...@googlegroups.com).
> > > > > To post to this group, send email to rails-oceania@goog

[rails-oceania] Re: Inviting corporate reps to RoRo ...

2013-04-08 Thread Ben Schwarz
I think its best to leave to the discretion of the organiser of said group 
— they do an incredible job to help speakers get their content out… I can't 
remember the last time we had an issue with some nasty commercial talk 
being given… so that seems like its working well already.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Trying to implement per tenant ID's

2013-04-03 Thread Ben Hoskings
Firstly, I'd keep this display ID (maybe "member ID") separate from users.id.
Any non-standard behaviour there is asking for trouble. There's a lot of
convention built up in activerecord around having a single artificial
integer PK, and veering from this standard isn't worth the trouble it
causes. (We used some composite PKs for a time at TC as part of a migration
strategy, and they were very inconvenient to work with.)

I'd recommend having a unique users.id column like normal, and then a
separate member_id that you use for routing, which is unique within each
tenant (enforced in the DB).

I'd add a unique index to the users table on (tenant_id, member_id):

add_index :users, [:tenant_id, :member_id], unique: true

Then I'd add a validation in the model, for reasonable error messages (the
real "validation" is done by the DB's unique index):

validates :member_id, presence: true, uniqueness: {scope: :tenant_id}

Then I'd auto-populate that field before the model's validation happens.

before_validation :assign_member_id_if_required

def assign_member_id_if_required
  self.member_id ||= begin
max_member_id = tenant.users.order('member_id
DESC').limit(1).pluck(:member_id).first
(max_member_id || 0) + 1
  end
end

That will query efficiently:

SELECT "users"."member_id" FROM "users" WHERE "users"."tenant_id" =
12345 ORDER BY member_id DESC LIMIT 1

- Ben


On 3 April 2013 20:29, Rich Buggy  wrote:

> Hi everyone,
>
> I'm building a multi-tenant application and I'd like some of the ID's to
> be per tenant. It's using the path based multi-tenant approach. For example
> - /:account/invoices/:id
>
> I've got the routing working correctly but the ID's are being generated
> automatically so they are unique across the application, not just the
> tenant. This isn't ideal because each tenant should start from 1.
>
> I already store the next id in the tenant table so they can choose to
> start from a number other than 1. This is important as someone with
> existing data may decide to not start from 1. I think there are a number of
> ways I can deal with this.
>
> 1. If I was doing this without rails I'd make the tenant_id + id a
> composite field and set the id manually when creating the record. Is there
> are an easy way to do this with rails?
>
> 2. I could add number field and accept that number != id. This is easy but
> ugly because /demo/invoices/123456 could be invoice 1
>
> 3. I could add a number field and try to muck with the routing so it used
> number instead of id
>
> Does anyone know of a good guide or blog post on how to do this?
>
> Rich
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Re: [Sydney] Introduce myself

2013-04-01 Thread Ben Schwarz
Marcos, 

This is a great place to introduce yourself. 
Keep an eye on this list to watch for the monthly sydney ruby meetup (aka, 
RORO) and also for job postings.

Good luck!

On Monday, 1 April 2013 13:45:53 UTC+11, marcos Bellucci wrote:
>
> Hello guys, i am Marcos a computing engineer from Uruguay ( Latin America 
> ).
> I want to visit Sydney for a few months to improve my english.
> So i would like to get an english scolarship, and at the same time get a 
> ruby job to survive :)
> Can anyone help me to find one?
> Maybe recommending related sites.
>
> (i apologize if this is not the proper comunication way)
>
> best regards!
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: How to calculate an hourly, contractual rate

2013-03-17 Thread Ben Schwarz
Ben, they're two totally different subjects. 
I'm so not getting into one of those "define what you mean" discussion 
threads. 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: How to calculate an hourly, contractual rate

2013-03-17 Thread Ben Taylor
Or we could measure on "how good they are" rather than "how many years they sat 
at a desk".

- Ben


On Monday, 18 March 2013 at 3:39 PM, Ben Schwarz wrote:

> I wouldn't call anyone with less than 10 years experience a senior.  
>  
> In my mind:  
>  
> Junior:   1 – 4 years
> Mid-weight: 5 – 9
> Senior: 10+  
>  
> We're talking not only skill, but mastery of craft and processes.  
>  
>  
> On Monday, 18 March 2013 at 3:35 PM, Michael Pearson wrote:
>  
> > On Mon, Mar 18, 2013 at 3:29 PM, Ashley Pettit  > (mailto:is_ash_is_g...@hotmail.com)> wrote:
> > > $400 day for someone mid level (~2-3 years by my loose definition) is 
> > > pretty rocking stuff in my opinion. Most of my friends are around 24 
> > > years old and I can't quite say any of them earn anything near this! 
> > > (Again disclaimer *you may definitely be worth it* I don't know)  
> >  
> > IMO 2-3 years isn't mid level.
> >  
> > Mid level is (years that you've been working in the industry) / 2.
> >  
> > Junior is (years ..) / 3
> >  
> > Senior is max( (years ...) - 1, 3)
> >  
> > --  
> > Michael Pearson
> >  
> > --  
> > You received this message because you are subscribed to a topic in the 
> > Google Groups "Ruby or Rails Oceania" group.
> > To unsubscribe from this topic, visit 
> > https://groups.google.com/d/topic/rails-oceania/aJUEhoE89mo/unsubscribe?hl=en.
> > To unsubscribe from this group and all its topics, send an email to 
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >   
> >   
>  
> --  
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>   
>   

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: How to calculate an hourly, contractual rate

2013-03-17 Thread Ben Schwarz
I wouldn't call anyone with less than 10 years experience a senior.  

In my mind:  

Junior:   1 – 4 years
Mid-weight: 5 – 9
Senior: 10+  

We're talking not only skill, but mastery of craft and processes.  


On Monday, 18 March 2013 at 3:35 PM, Michael Pearson wrote:

> On Mon, Mar 18, 2013 at 3:29 PM, Ashley Pettit  (mailto:is_ash_is_g...@hotmail.com)> wrote:
> > $400 day for someone mid level (~2-3 years by my loose definition) is 
> > pretty rocking stuff in my opinion. Most of my friends are around 24 years 
> > old and I can't quite say any of them earn anything near this! (Again 
> > disclaimer *you may definitely be worth it* I don't know)  
>  
> IMO 2-3 years isn't mid level.
>  
> Mid level is (years that you've been working in the industry) / 2.
>  
> Junior is (years ..) / 3
>  
> Senior is max( (years ...) - 1, 3)
>  
> --  
> Michael Pearson
>  
> --  
> You received this message because you are subscribed to a topic in the Google 
> Groups "Ruby or Rails Oceania" group.
> To unsubscribe from this topic, visit 
> https://groups.google.com/d/topic/rails-oceania/aJUEhoE89mo/unsubscribe?hl=en.
> To unsubscribe from this group and all its topics, send an email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>   
>   

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] RedDotRubyConf 2013

2013-03-16 Thread Ben Caldwell
Nearly missed the early bird! Thanks for the reminder :)

On Thursday, March 14, 2013 12:51:20 PM UTC+8, Winston Teo wrote:
>
> Hi Guys,
>
> Just want to let you all know that RedDotRubyConf early bird is going to 
> end soon. Have you bought your tix? http://www.reddotrubyconf.com
>
> Hope to see you guys in June!
>
> Thank you!
>
> Cheers,
> Winston
>
> On Thursday, 21 February 2013 00:28:26 UTC+8, Winston Teo wrote:
>>
>> Hi Daryl,
>>
>> Warren gave a pretty good answer. Ibis Bencoolen was the hotel of choice 
>> for the last two years but we didn't get any preferential rates for that. 
>>
>> We will be approaching hotels soon to arrange for lodging for our invited 
>> speakers and I'll update if we manage to get any bulk discount rates.
>>
>> Thank you for your support!
>>
>> Cheers,
>> Winston
>>
>>
>> On Wednesday, 20 February 2013 08:08:07 UTC+8, Daryl wrote:
>>>
>>> Actually, the Ibis looks like a pretty solid choice from TripAdvisor etc 
>>> (also if you book 30 days ahead you can get a 30% discount if you book 
>>> direct with Ibis on 
>>> http://www.accorhotels.com/gb/booking/rates.shtml?packId=58910310737which 
>>> lowers the cost a titch.).
>>>
>>> thanks Warren!
>>> Daryl.
>>>
>>>
>>>
>>> On Wed, Feb 20, 2013 at 10:44 AM, Warren Seen wrote:
>>>
 It's probably easiest to stay somewhere in the city close to one of the 
 MRT stations on the city or east/west lines, you'll have a wider choice of 
 hotels and easier access to the city itself then.

 The Ibis on Bencoolen is a good option based on my experience, and has 
 free wifi. Looks like it's around AU$130/night at the time the conference 
 is on, but Singapore seems to have a hotel for every budget :) 
 http://wego.com.au has a pretty good search engine for hotels there.

 On 20/02/2013, at 9:58 AM, Daryl Manning  wrote:

 Hey Winston!

 (Already signed up!). 

 I was wondering whether there is any recommended hotel or such nearby 
 for the conference for attendees. Especially if R.R negotiated conference 
 rates and for those whose first time it is in Singapore, it would be very 
 helpful logistically.

 thanks !
 Daryl.


 On Wed, Feb 20, 2013 at 12:59 AM, Winston Teo wrote:

> Hi Guys!
>
> I am Winston, organizer of RedDotRubyConf 2013. You might be more 
> familiar with Andy Croll who ran the last two RDRC, but he's currently 
> back 
> in UK waiting for the arrival of his twins. So.. I (and a few others) 
> volunteered ourselves for RDRC this year.
>
> RedDotRubyConf is the annual Ruby conference of Singapore and we are 
> in our third edition. It will be on 7-8 June 2013 at Matrix (Biopolis). 
> Please refer to http://reddotrubyconf.com for more details.
>
> We have a great list of speakers already lined up:
>  
> - Jim Weirich
> - Josè Valim
> - Aaron Patterson
> - Steve Klabnik
> - Ola Bini
> - Akira Matsuda
> - Prem Sichanugrist (not yet up on the website)
>  
> So.. Get your tickets early, like now (
> http://reddotrubyconf.com/registrations/new)! 
>  
> Or, if you have a great idea to share, you can submit a talk to our 
> CFP too (http://reddotrubyconf.com/call_for_proposals).
>  
> Drop me an email if you have any questions - win...@neo.com and 
> follow @reddotrubyconf for more updates.
>  
> Thank you! Hope to see you guys in SG!
>  
> Cheers,
> Winston
>
> -- 
> You received this message because you are subscribed to the Google 
> Groups "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send 
> an email to rails-oceani...@googlegroups.com.
> To post to this group, send email to rails-...@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en
> .
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  
>


 -- 
 You received this message because you are subscribed to the Google 
 Groups "Ruby or Rails Oceania" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to rails-oceani...@googlegroups.com.
 To post to this group, send email to rails-...@googlegroups.com.
 Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
 For more options, visit https://groups.google.com/groups/opt_out.
  
  


  -- 
 You received this message because you are subscribed to the Google 
 Groups "Ruby or Rails Oceania" group.
 To unsubscribe from this group and stop receiving emails from it, send 
 an email to rails-oceani...@googlegroups.com.
 To post to this group, send email to rails-...@googlegroups.com.
 Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
 For more options, visit https://group

Re: [rails-oceania] Re: How to calculate an hourly, contractual rate

2013-03-14 Thread Ben Taylor
These aren't abnormal positions (AFAIK). A Ph. D would get higher. From 
discreet conversations with friends who took graduate roles between 4 years ago 
until now the going rate is around 60-80k. All have Degrees from the Group of 8 
in either Computer Science, Engineering or IT and are working in either 
consulting or development roles. Example companies:

 * IBM
 * Google

 * Deloitte Digital
 * Macquarie Bank
 * Atlassian
 * Commonwealth Bank
 * NAB

FYI the ones I know who were super capable (PhDs and such) often got taken by 
American companies for >$100K graduate positions. 

- Ben


On Friday, 15 March 2013 at 4:27 PM, Michael Pearson wrote:

> On Fri, Mar 15, 2013 at 4:17 PM, Ben Taylor  (mailto:m...@taybenlor.com)> wrote:
> > Sorry, I meant before tax. But yeah $70k before tax is what I've seen 
> > recent CS graduates go into.
> > 
>  
> That's how I first read it, and my response is still the same.
> 
> Did they have Ph.Ds? Had they developed a popular JavaScript framework from 
> scratch? Was the hiring company desperate for hires because they'd sullied 
> their name in the local community? Did the graduate have a specialist skill? 
> Were they a short-lived, burn-brightly-then-flip overfunded startup? Can I 
> have my salary for the first five or six years of my career in IT 
> retro-actively adjusted to this new entry rate, pretty please? 
> 
> -- 
> Michael Pearson
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Re: How to calculate an hourly, contractual rate

2013-03-14 Thread Ben Taylor
You also need to take into account lack of holiday pay, sick leave and job 
security.

$70k after tax is what you would expect from a graduate IT position. And with 
contracting you don't get the perks of a normal job.

- Ben


On Friday, 15 March 2013 at 3:59 PM, Dan Cheail wrote:

> Nicholas: 
> 
> How do you figure? $50 / hour for a 40 hour week comes out to a gross of 
> $104,000. Less  11% super contribution, that's still a gross of ~$95k, (~$70k 
> after tax)
> 
> -- 
> Dan Cheail, Geek
> 0402 114 697
> 
> 
> On Friday, 15 March 2013 at 3:31 PM, Nicholas Faiz wrote:
> 
> > Ashley, 
> > 
> > Those rates are too low. The idea of the post was to let people know how to 
> > fairly identify a rate of pay.
> > 
> > Using the original calculation for an hourly rate (see the original post), 
> > that's saying a mid level developer would be charging $50 an hour, which 
> > maps to earning about 50 k (super included) per annum in a full-time role. 
> > I don't think you'd see any full-time mid level Rails roles offered for 
> > that.
> > 
> > Nicholas
> > 
> > On Friday, March 15, 2013 2:36:03 PM UTC+11, Ashley Pettit wrote:
> > > Hey guys,
> > > 
> > > People are often just plainly asking me what they should charge.
> > > 
> > > Here's my two cents for contracts > 3 months and 40 hrs /week. 
> > > 
> > > Mid-level developer ~$400 day.
> > > 
> > > Senior-level ~$600 day.
> > > 
> > > As Nick said if you want more you need to have to really think about the 
> > > business. How to improve it. Invest in the business and give suggestions 
> > > on how they can be more profitable.
> > > 
> > > Also you need to value your service and have connections with people who 
> > > really value what you do. 
> > > 
> > > Chaio,
> > > 
> > > Ash 
> > 
> > -- 
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >  
> >  
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Re: Recommendation for a distributed CI service

2013-03-13 Thread Ben Schwarz
You know, I reckon if you asked Konstantin or Josh super nicely, you might 
get access to Travis-CI private.




On Sunday, 27 May 2012 22:51:28 UTC+10, Trung LE wrote:
>
> Hi all
>
> I am looking for a free/paid online CI service that is similar to Travis 
> CI but support private GitHub repo for my company. I really appreciate if 
> someone could share me a recommendation.
>
> Many thanks
>
> Trung
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Ruby/Rails in the Bay Area

2013-02-28 Thread ben wiseley
Andrew,

I moved to SF in Nov.  The company I work for causes.com has parties fairly
often in our office (we're about 60 people) that are attended by many Ruby
guys (we're a Rails shop).  (We're also hiring... we've got 3 Aussies
working for us and sponsor visas).  21st floor, down town, tons of booze,
open balcony... pretty fun.

I haven't been to their meetup yet but the local Ruby group is
http://www.sfruby.info/

Drop me a line and we'll take you out while you're here.  You're welcome to
come hang out at the office too if you want a desk for the day.

-ben
415-405-5410


On Thu, Feb 28, 2013 at 12:49 AM, Andrew Grimm wrote:

> I tried meetup.com for Ruby in Sydney, and RORO wasn't listed.
> Likewise, when I tried for Sendai, or Sapporo, or Osaka, I didn't get
> Tohoku on Rails, Ruby Sapporo, or Minami.rb . The only hit I did get
> was when trying for Ruby in Tokyo, and that got me Tokyo Rails, but
> not Asakusa.rb
>
> So it's not bulletproof.
>
> Another site to check is http://rubyusergroups.org/
>
> Incidentally, when I searched for Ruby in Sydney with meetup.com , I
> came across Sydney on Rails http://www.meetup.com/Sydney-on-Rails/ -
> anyone know what that group's like?
>
> Andrew
>
> On Thu, Feb 28, 2013 at 12:50 PM, Craig Read 
> wrote:
> > Andrew,
> >
> > I asked a friend who lives (and codes) in the bay area.
> > He sent me this link.  I'm somewhat surprised he didn't send me a link to
> > http://lmgtfy.com/.
> >
> > Craig...
> >
> >
> > On Thu, Feb 28, 2013 at 11:18 AM, Andrew Harvey 
> wrote:
> >>
> >> I've just found out that I'm going to be in the bay area for a couple of
> >> days in mid-march, and was looking to connect a bit with the ruby/rails
> >> communities there.
> >>
> >> Does anyone have suggestions for meet ups or events to go to or people
> to
> >> meet?
> >>
> >> Feel free to contact me off list if you prefer :)
> >>
> >> Andrew
> >>
> >> --
> >> You received this message because you are subscribed to the Google
> Groups
> >> "Ruby or Rails Oceania" group.
> >> To unsubscribe from this group and stop receiving emails from it, send
> an
> >> email to rails-oceania+unsubscr...@googlegroups.com.
> >> To post to this group, send email to rails-oceania@googlegroups.com.
> >> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> >> For more options, visit https://groups.google.com/groups/opt_out.
> >>
> >>
> >
> >
> >
> > --
> > Craig Read
> >
> > @Catharz
> > https://github.com/Catharz
> > http://stackoverflow.com/users/158893/catharz
> >
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Ruby or Rails Oceania" group.
> > To unsubscribe from this group and stop receiving emails from it, send an
> > email to rails-oceania+unsubscr...@googlegroups.com.
> > To post to this group, send email to rails-oceania@googlegroups.com.
> > Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> > For more options, visit https://groups.google.com/groups/opt_out.
> >
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Help send Konstantin to Magma conf

2013-02-24 Thread Ben Schwarz
Now we've established that the form is secure, and that Konstantin is a 
baller—send some bucks. 


On Sunday, 24 February 2013 19:51:44 UTC+11, pythonic wrote:
>
>
> Nah, the form's submitted via https, served by Stripe.
>
>
> You are assuming the form action is not modified by a MITM.
>
> Thanks,
>
> Nicholas
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Help send Konstantin to Magma conf

2013-02-23 Thread Ben Schwarz
Good point Alex, David already kinda covered it, but—
Konstantin flew all the way from Berlin to speak at Rubyconf in Melbourne 
last week, where he gave a great talk. 

Magmaconf is a community run event, and seeing as we just had such a 
fantastic community run event locally, I figured we should share the love. 

On Sunday, February 24, 2013 6:15:50 PM UTC+11, Alex Bayley wrote:
>
> On 24/02/13 6:11 PM, Ben Schwarz wrote: 
> > Our Mexican ruby buddies run a conference called Magma conf, they've 
> > been trying to get Konstantin to Mexico since the conference started 3 
> > years ago. 
> > So, after all the love of Rubyconf in Australia, why not donate some 
> > bucks to help make another community run event absolutely rad? 
>
> Who is Konstantin and why would I want to do this?  As a relative newbie 
> I have no idea why I would want to give money to this, and the website 
> doesn't tell me anything. 
>
> A. 
>
>
> -- 
> Alex "Skud" Bayley 
> sk...@growstuff.org  
> http://growstuff.org/ 
> For personal stuff, please use sk...@infotrope.net  
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] Help send Konstantin to Magma conf

2013-02-23 Thread Ben Schwarz
Our Mexican ruby buddies run a conference called Magma conf, they've been 
trying to get Konstantin to Mexico since the conference started 3 years 
ago. 
So, after all the love of Rubyconf in Australia, why not donate some bucks 
to help make another community run event absolutely rad? 

http://bring-konstantin-to.magmaconf.com

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] More vulnerabilities today: rails & json need updates

2013-02-11 Thread Ben Hoskings
(But then, most popular gems would end up flagged as "unsafe". :) For a
start, every version of rails before 3.2.12 would be "unsafe" as of today.)


On 12 February 2013 11:25, Ben Hoskings  wrote:

> I think it's always best to not yank the gem, but I like the idea of
> having some sort of annotation. Bundler could then exclude them by default,
> with an --include-unsafe option to pull them in when required.
>
> - Ben
>
>
>
> On 12 February 2013 11:21, Simon Russell  wrote:
>
>> That situation actually makes me wonder whether it wouldn't be good if
>> RubyGems warned you if you were installing a version of a gem that had
>> known security problems.  (Or perhaps in serious situations, the gem
>> publisher could yank them...)
>>
>> I'd certainly find it useful if bundler would tell me it was knowingly
>> installing an old version of a gem because of a dependency.
>>
>>
>> On Tue, Feb 12, 2013 at 11:16 AM, Ben Hoskings  wrote:
>>
>>> That's a good option too.
>>>
>>> My intent with the version constraint isn't to lock it, so much as to
>>> make it explicit that the gem shouldn't be rolled back in the future. That
>>> is, that there's a specific reason it's at that version, aside from that
>>> being the latest version at the time it was incorporated.
>>>
>>> - Ben
>>>
>>>
>>>
>>> On 12 February 2013 09:48, Jon Rowe  wrote:
>>>
>>>> If you feel the need to lock to a specific version rather than just
>>>> `bundle update json` then ~> is safer than >= as it will only allow patch
>>>> version updates.
>>>>
>>>> Jon Rowe
>>>> -
>>>> m...@jonrowe.co.uk
>>>> jonrowe.co.uk
>>>>
>>>> On Tuesday, 12 February 2013 at 09:38, Ben Hoskings wrote:
>>>>
>>>> There are three. Here they are with tl-dr.
>>>>
>>>> 1)
>>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/AFBKNY7VSH8
>>>> #attr_protected can be circumvented in controllers.
>>>> Fixed in rails 3.2.12, 3.1.11, 2.3.17.
>>>>
>>>> 2)
>>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/KtmwSbEpzrU
>>>> #serialize calls in models can be exploited to execute remote code.
>>>> 3.1.0 and newer are not affected.
>>>> Fixed in rails 2.3.17. There is no release for 3.0.x because of policy:
>>>> you'll have to manually apply the patch.
>>>>
>>>> 3)
>>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/4_YvCpLzL58
>>>> There's a denial of service and unsafe object creation bug using
>>>> 'json_class' in json.gem.
>>>> Fixed in json 1.7.7, 1.6.8, 1.5.5.
>>>> N.B. You have to update json.gem separately to rails to ensure you're
>>>> safe.
>>>>
>>>>
>>>> For anyone unsure, the easiest way to update is to lock out the old
>>>> versions in your gemfile and then `bundle update`. For example:
>>>>
>>>> 1) Check Gemfile.lock for 'json' and note the version. (e.g. say you
>>>> had json-1.7.6, as we did.)
>>>> 2) Add or update the 'json' entry in your Gemfile to the safe version
>>>> corresponding to your minor version, as follows:
>>>> gem 'json', '>= 1.7.7'
>>>> 3) Run `bundle update json`
>>>> 4) Run specs
>>>> 5) SHIP IT
>>>>
>>>>
>>>> Cheers
>>>> Ben
>>>>
>>>>  --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Ruby or Rails Oceania" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to rails-oceania+unsubscr...@googlegroups.com.
>>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>>
>>>>
>>>>
>>>>
>>>>  --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Ruby or Rails Oceania" group.
>>>> To unsubscribe from this group and

Re: [rails-oceania] More vulnerabilities today: rails & json need updates

2013-02-11 Thread Ben Hoskings
I think it's always best to not yank the gem, but I like the idea of having
some sort of annotation. Bundler could then exclude them by default, with
an --include-unsafe option to pull them in when required.

- Ben



On 12 February 2013 11:21, Simon Russell  wrote:

> That situation actually makes me wonder whether it wouldn't be good if
> RubyGems warned you if you were installing a version of a gem that had
> known security problems.  (Or perhaps in serious situations, the gem
> publisher could yank them...)
>
> I'd certainly find it useful if bundler would tell me it was knowingly
> installing an old version of a gem because of a dependency.
>
>
> On Tue, Feb 12, 2013 at 11:16 AM, Ben Hoskings  wrote:
>
>> That's a good option too.
>>
>> My intent with the version constraint isn't to lock it, so much as to
>> make it explicit that the gem shouldn't be rolled back in the future. That
>> is, that there's a specific reason it's at that version, aside from that
>> being the latest version at the time it was incorporated.
>>
>> - Ben
>>
>>
>>
>> On 12 February 2013 09:48, Jon Rowe  wrote:
>>
>>> If you feel the need to lock to a specific version rather than just
>>> `bundle update json` then ~> is safer than >= as it will only allow patch
>>> version updates.
>>>
>>> Jon Rowe
>>> -
>>> m...@jonrowe.co.uk
>>> jonrowe.co.uk
>>>
>>> On Tuesday, 12 February 2013 at 09:38, Ben Hoskings wrote:
>>>
>>> There are three. Here they are with tl-dr.
>>>
>>> 1)
>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/AFBKNY7VSH8
>>> #attr_protected can be circumvented in controllers.
>>> Fixed in rails 3.2.12, 3.1.11, 2.3.17.
>>>
>>> 2)
>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/KtmwSbEpzrU
>>> #serialize calls in models can be exploited to execute remote code.
>>> 3.1.0 and newer are not affected.
>>> Fixed in rails 2.3.17. There is no release for 3.0.x because of policy:
>>> you'll have to manually apply the patch.
>>>
>>> 3)
>>> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/4_YvCpLzL58
>>> There's a denial of service and unsafe object creation bug using
>>> 'json_class' in json.gem.
>>> Fixed in json 1.7.7, 1.6.8, 1.5.5.
>>> N.B. You have to update json.gem separately to rails to ensure you're
>>> safe.
>>>
>>>
>>> For anyone unsure, the easiest way to update is to lock out the old
>>> versions in your gemfile and then `bundle update`. For example:
>>>
>>> 1) Check Gemfile.lock for 'json' and note the version. (e.g. say you had
>>> json-1.7.6, as we did.)
>>> 2) Add or update the 'json' entry in your Gemfile to the safe version
>>> corresponding to your minor version, as follows:
>>> gem 'json', '>= 1.7.7'
>>> 3) Run `bundle update json`
>>> 4) Run specs
>>> 5) SHIP IT
>>>
>>>
>>> Cheers
>>> Ben
>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Ruby or Rails Oceania" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to rails-oceania+unsubscr...@googlegroups.com.
>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>>
>>>
>>>
>>>  --
>>> You received this message because you are subscribed to the Google
>>> Groups "Ruby or Rails Oceania" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to rails-oceania+unsubscr...@googlegroups.com.
>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
>>> For more options, visit https://groups.google.com/groups/opt_out.
>>>
>>>
>>>
>>
>>
>>
>> --
>> Cheers
>> Ben
>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Ruby or Rails Oceania" group.
>> 

Re: [rails-oceania] More vulnerabilities today: rails & json need updates

2013-02-11 Thread Ben Hoskings
That's a good option too.

My intent with the version constraint isn't to lock it, so much as to make
it explicit that the gem shouldn't be rolled back in the future. That is,
that there's a specific reason it's at that version, aside from that being
the latest version at the time it was incorporated.

- Ben



On 12 February 2013 09:48, Jon Rowe  wrote:

> If you feel the need to lock to a specific version rather than just
> `bundle update json` then ~> is safer than >= as it will only allow patch
> version updates.
>
> Jon Rowe
> -
> m...@jonrowe.co.uk
> jonrowe.co.uk
>
> On Tuesday, 12 February 2013 at 09:38, Ben Hoskings wrote:
>
> There are three. Here they are with tl-dr.
>
> 1)
> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/AFBKNY7VSH8
> #attr_protected can be circumvented in controllers.
> Fixed in rails 3.2.12, 3.1.11, 2.3.17.
>
> 2)
> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/KtmwSbEpzrU
> #serialize calls in models can be exploited to execute remote code.
> 3.1.0 and newer are not affected.
> Fixed in rails 2.3.17. There is no release for 3.0.x because of policy:
> you'll have to manually apply the patch.
>
> 3)
> https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/4_YvCpLzL58
> There's a denial of service and unsafe object creation bug using
> 'json_class' in json.gem.
> Fixed in json 1.7.7, 1.6.8, 1.5.5.
> N.B. You have to update json.gem separately to rails to ensure you're safe.
>
>
> For anyone unsure, the easiest way to update is to lock out the old
> versions in your gemfile and then `bundle update`. For example:
>
> 1) Check Gemfile.lock for 'json' and note the version. (e.g. say you had
> json-1.7.6, as we did.)
> 2) Add or update the 'json' entry in your Gemfile to the safe version
> corresponding to your minor version, as follows:
> gem 'json', '>= 1.7.7'
> 3) Run `bundle update json`
> 4) Run specs
> 5) SHIP IT
>
>
> Cheers
> Ben
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] More vulnerabilities today: rails & json need updates

2013-02-11 Thread Ben Hoskings
Good call.

I commit with `git add --patch` (`gap`) and `git commit -v` (`gc`) so I
always see the diffs I'm committing, and that stuff can't slip through.

- Ben



On 12 February 2013 09:53, Michael Pearson  wrote:

> On Tue, Feb 12, 2013 at 9:38 AM, Ben Hoskings  wrote:
>
>>
>> 1) Check Gemfile.lock for 'json' and note the version. (e.g. say you had
>> json-1.7.6, as we did.)
>> 2) Add or update the 'json' entry in your Gemfile to the safe version
>> corresponding to your minor version, as follows:
>> gem 'json', '>= 1.7.7'
>> 3) Run `bundle update json`
>> 4) Run specs
>>
>
> 4.5) Run 'git diff Gemfile.lock' to ensure that only the things that you
> thought should update updated (I've run 'bundle update' when I meant to run
> 'bundle update gemname' before)
>
>
>> 5) SHIP IT
>>
>>
>
> --
> Michael Pearson
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




[rails-oceania] More vulnerabilities today: rails & json need updates

2013-02-11 Thread Ben Hoskings
There are three. Here they are with tl-dr.

1)
https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/AFBKNY7VSH8
#attr_protected can be circumvented in controllers.
Fixed in rails 3.2.12, 3.1.11, 2.3.17.

2)
https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/KtmwSbEpzrU
#serialize calls in models can be exploited to execute remote code.
3.1.0 and newer are not affected.
Fixed in rails 2.3.17. There is no release for 3.0.x because of policy:
you'll have to manually apply the patch.

3)
https://groups.google.com/forum/?hl=en&fromgroups=#!topic/rubyonrails-security/4_YvCpLzL58
There's a denial of service and unsafe object creation bug using
'json_class' in json.gem.
Fixed in json 1.7.7, 1.6.8, 1.5.5.
N.B. You have to update json.gem separately to rails to ensure you're safe.


For anyone unsure, the easiest way to update is to lock out the old
versions in your gemfile and then `bundle update`. For example:

1) Check Gemfile.lock for 'json' and note the version. (e.g. say you had
json-1.7.6, as we did.)
2) Add or update the 'json' entry in your Gemfile to the safe version
corresponding to your minor version, as follows:
gem 'json', '>= 1.7.7'
3) Run `bundle update json`
4) Run specs
5) SHIP IT


Cheers
Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Understanding Brixen's comments about Ruby security

2013-02-08 Thread Ben Hoskings
I think the difference is that in ruby land, "YAML.load" is a pretty standard 
thing to do. Operating in the normal way, it's an unsafe operation on 
non-trusted input. That's not true of a language like Haskell, where you have 
to explicitly turn on cowboy mode before anything unsafe can happen. Any harm 
it could do would be a side-effect, which the compiler has guaranteed will not 
happen.

I strongly agree with Mark's point about not doing any more than is necessary 
at any point. Gemspecs should be a literal-data-only subset of YAML (i.e. they 
should be JSON); marshaling things shouldn't have any connection to param 
parsing; models shouldn't be able to see the request; the user account on 
rubygems that processes incoming gemspecs shouldn't have read access to 
./config/, and so on.

Whether it's in code or in ops or overall design, the good solutions arise 
through forcing separation. It's good design anyway, because a decoupled system 
is more testable.

In ruby this separation has to be achieved by convention, not the compiler, but 
I think there's still a lot we can do. In separating concerns and pushing hard 
in the direction of 'lo-fi', you shrink the attackable surface.

- Ben


Sent from my iPhone

On 09/02/2013, at 4:36 PM, Nicholas Jefferson  wrote:

>> in the context I mentioned
> 
> The relevant context here has web developers who thought nothing of calling 
> "YAML.load", and would think nothing of calling "eval" from a function with 
> an IO annotation. In this context an arbitrary code execution vulnerability 
> in any Haskell web framework is only a few lines of code away.
> 
> Thanks,
> 
> Nicholas
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
> 
> 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Understanding Brixen's comments about Ruby security

2013-02-08 Thread Ben Hoskings
No, he doesn't mean that (if I'm interpreting him right). I think he means ruby 
the ecosystem and community, not ruby the language.

When a flaw that huge is found in rails it reflects on ruby the ecosystem and 
community as a whole, whether that's fair or not.

The implication is that the flaw existed and went unpatched for so long because 
the ruby community is culturally too relaxed with security. Again, whether 
that's fair or not is another question.

But I think he's right that it only adds to existing criticisms (that we're 
cavalier, and value glitz over rigour).

- Ben


Sent from my iPhone

On 08/02/2013, at 9:32 PM, Andrew Grimm  wrote:

> In the latest Ruby Rogues podcast, @Brixen (formerly Brian Ford, now
> Brian Shirai) said
> 
>> But I caution people who think, “It’s working okay. Let’s just do more of 
>> this.” I caution that, that is not necessarily going to be
>> sufficient. And I will point to a couple things. What I’ve seen is talents 
>> bleed away from Ruby to other languages because Ruby
>> couldn’t do things like concurrency well. These recent exploits in Rails and 
>> stuff are of great concern. We already have strikes
>> against us as a Ruby language for a bunch of reasons and what we really 
>> don’t need is big companies who pay developers to say,
>> “You know what? We’re not using Ruby. There’s no Ruby going to be on my 
>> server because I’m not having someone exploit my
>> servers.” Point and click, and you have a remote shell, right?
> 
> Would I be correct in interpreting him as saying that the recent YAML
> exploits with Rails indicate a problem with Ruby, rather than just
> Rails? That in a more secure programming language, even if the web
> development framework stuffed up, the hackers wouldn't be able to
> execute arbitrary shell code?
> 
> Andrew
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to rails-oceania+unsubscr...@googlegroups.com.
> To post to this group, send email to rails-oceania@googlegroups.com.
> Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
> 
> 

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rails-oceania+unsubscr...@googlegroups.com.
To post to this group, send email to rails-oceania@googlegroups.com.
Visit this group at http://groups.google.com/group/rails-oceania?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: [rails-oceania] Rails Security Vulnerability

2013-01-08 Thread Ben Hoskings
Thanks for posting this, John.

All: note well that unlike the fix in 3.2.10 which turned out to have a limited 
impact, this one (CVE-2013-0156) is serious business.

Bumping production to 3.2.11 (or turning off the XML params parser in an 
initializer) should be priority #1 for everyone today :)

- Ben


Sent from my iPhone

On 09/01/2013, at 9:26 AM, Jon Rowe  wrote:

> Hey Rubyists
> 
> In case you've missed this mornings "news", there's a *new* Rails 
> vulnerability which requires patching:
> 
> https://groups.google.com/forum/#!topic/rubyonrails-security/61bkgvnSGTQ/discussion
> 
> Just FYI you know...
> 
> Jon Rowe
> -
> m...@jonrowe.co.uk
> jonrowe.co.uk
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



[rails-oceania] Fwd: SQL Injection Vulnerability in Ruby on Rails (CVE-2012-5664)

2013-01-02 Thread Ben Hoskings
Hi all, forwarding for those who aren't on the security list.

This vulnerability looks potentially serious―using finders in this way is 
pretty standard. (I haven't looked into it further than the announcement.)

Cheers
Ben


Begin forwarded message:

> From: Aaron Patterson 
> Date: 3 January 2013 7:22:22 AM AEST
> To: rubyonrails-secur...@googlegroups.com, oss-secur...@lists.openwall.com
> Subject: SQL Injection Vulnerability in Ruby on Rails (CVE-2012-5664)
> Reply-To: rubyonrails-secur...@googlegroups.com
> 
> SQL Injection Vulnerability in Ruby on Rails
> 
> There is a SQL injection vulnerability in Active Record in ALL versions. This 
> vulnerability has been assigned the CVE identifier CVE-2012-5664.
> 
> Versions Affected:  All.
> Not affected:   NONE.
> Fixed Versions: 3.2.10, 3.1.9, 3.0.18
> 
> Impact 
> -- 
> Due to the way dynamic finders in Active Record extract options from method 
> parameters, a method parameter can mistakenly be used as a scope.  Carefully 
> crafted requests can use the scope to inject arbitrary SQL.
> 
> All users running an affected release should either upgrade or use one of the 
> work arounds immediately. 
> 
> Impacted code passes user provided data to a dynamic finder like this:
> 
>  Post.find_by_id(params[:id])
> 
> Releases 
>  
> The  3.2.10, 3.1.9 & 3.0.18 releases are available at the normal locations. 
> 
> Workarounds 
> --- 
> The issue can be mitigated by explicitly converting the parameter to an 
> expected value.  For example, change this:
> 
>  Post.find_by_id(params[:id])
> 
> to this:
> 
>  Post.find_by_id(params[:id].to_s)
> 
> 
> Patches 
> --- 
> To aid users who aren't able to upgrade immediately we have provided patches 
> for the two supported release series and two unsupported versions.  They are 
> in git-am format and consist of a single changeset. 
> 
> * 3-2-dynamic_finder_injection.patch - Patch for 3.2 series
> * 3-1-dynamic_finder_injection.patch - Patch for 3.1 series
> * 3-0-dynamic_finder_injection.patch - Patch for 3.0 series
> * 2-3-dynamic_finder_injection.patch - Patch for 2.3 series
> 
> Please note that only the 3.1.x and 3.2.x series are supported at present.  
> Users of earlier unsupported releases are advised to upgrade as soon as 
> possible as we cannot guarantee the continued availability of security fixes 
> for unsupported releases.
> 
> -- 
> Aaron Patterson
> http://tenderlovemaking.com/
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby on Rails: Security" group.
> To post to this group, send email to rubyonrails-secur...@googlegroups.com.
> To unsubscribe from this group, send email to 
> rubyonrails-security+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rubyonrails-security?hl=en.
> 
From 9de9b359d0d24f70f0f6c5c58a7ad8750684d456 Mon Sep 17 00:00:00 2001
From: Aaron Patterson 
Date: Sun, 23 Dec 2012 11:07:07 -0800
Subject: [PATCH] CVE-2012-5664 options hashes should only be extracted if
 there are extra parameters

---
 activerecord/lib/active_record/base.rb |6 +-
 activerecord/test/cases/finder_test.rb |   12 
 2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/activerecord/lib/active_record/base.rb 
b/activerecord/lib/active_record/base.rb
index 461007f..809a38c 100755
--- a/activerecord/lib/active_record/base.rb
+++ b/activerecord/lib/active_record/base.rb
@@ -1897,7 +1897,11 @@ module ActiveRecord #:nodoc:
   # end
   self.class_eval <<-EOS, __FILE__, __LINE__ + 1
 def self.#{method_id}(*args)
-  options = args.extract_options!
+  options = if args.length > #{attribute_names.size}
+  args.extract_options!
+else
+  {}
+end
   attributes = construct_attributes_from_arguments(
 [:#{attribute_names.join(',:')}],
 args
diff --git a/activerecord/test/cases/finder_test.rb 
b/activerecord/test/cases/finder_test.rb
index c779a69..9e3ab92 100644
--- a/activerecord/test/cases/finder_test.rb
+++ b/activerecord/test/cases/finder_test.rb
@@ -66,6 +66,18 @@ end
 class FinderTest < ActiveRecord::TestCase
   fixtures :companies, :topics, :entrants, :developers, :developers_projects, 
:posts, :comments, :accounts, :authors, :customers
 
+  def test_find_by_id_with_hash
+assert_raises(ActiveRecord::StatementInvalid) do
+  Post.find_by_id(:limit => 1)
+end
+  end
+
+  def test_find_by_title_and_id_with_hash
+assert_raises(ActiveRecord::Statemen

Re: [rails-oceania] Is there a way to reuse scopes in a has-many-through association?

2012-12-17 Thread Ben Hoskings
Good catch. The rule is that the #joins call is responsible for naming all the 
tables that the conditions in the merges will reference.

- Ben



On 18/12/2012, at 3:35 PM, Michael Gall  wrote:

> I've been working with this a bit lately, and the 1 point that's kinda 
> brushed over in Ben's post is in this line:
>  Figure.joins(:article => :collaborations
> ).
>   merge(
> Article.drafting)
> 
> 
> If Article.drafting references the Collaborations, then you must use the 
> hashrocket/through notation in the join. It's a bit of a trick because the 
> error message doesn't really help you to fix it.
> 
> Cheers,
> 
> Michael
> 
> 
> 
> On Tue, Dec 18, 2012 at 2:31 PM, Ben Hoskings  wrote:
> >
> > There is indeed, in fact I wrote a post on this very thing a little while 
> > ago :)
> >
> > http://benhoskin.gs/2012/07/04/arel-merge-a-hidden-gem
> >
> > - Ben
> >
> >
> >
> > On 18/12/2012, at 2:17 PM, Iain Beeston  wrote:
> >
> > > I've had an activerecord problem that's been bugging me for a while. If 
> > > you have a has-many-through association, and have scopes defined on the 
> > > "through" model, is it possible to re-use the scopes in the definition of 
> > > the has-many-through? (without copying the where clause of the scope in 
> > > the has-many-through)
> > >
> > > eg.
> > >   • a -> b -> c
> > >   • there is a "blah" scope on b
> > >   • you'd like to define "a has many c's through b, where b.c"
> > >
> > > I've already posted this on stackoverflow with a more full explanation 
> > > and example (but it's had a pretty lukewarm response)
> > >
> > > http://stackoverflow.com/questions/13696045/reusing-activerecord-scopes-on-has-many-through-associations
> > >
> > >
> > > Does anyone have any good suggestions about how to do this in a "DRY" way?
> > >
> > >
> > > Iain
> > >
> > >
> > > --
> > > You received this message because you are subscribed to the Google Groups 
> > > "Ruby or Rails Oceania" group.
> > > To post to this group, send email to rails-oceania@googlegroups.com.
> > > To unsubscribe from this group, send email to 
> > > rails-oceania+unsubscr...@googlegroups.com.
> > > For more options, visit this group at 
> > > http://groups.google.com/group/rails-oceania?hl=en.
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com.
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com.
> > For more options, visit this group at 
> > http://groups.google.com/group/rails-oceania?hl=en.
> >
> 
> 
> 
> --
> Checkout my new website: http://myachinghead.net
> http://wakeless.net
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Is there a way to reuse scopes in a has-many-through association?

2012-12-17 Thread Ben Hoskings
There is indeed, in fact I wrote a post on this very thing a little while ago :)

http://benhoskin.gs/2012/07/04/arel-merge-a-hidden-gem

- Ben



On 18/12/2012, at 2:17 PM, Iain Beeston  wrote:

> I've had an activerecord problem that's been bugging me for a while. If you 
> have a has-many-through association, and have scopes defined on the "through" 
> model, is it possible to re-use the scopes in the definition of the 
> has-many-through? (without copying the where clause of the scope in the 
> has-many-through)
> 
> eg.
>   • a -> b -> c
>   • there is a "blah" scope on b
>   • you'd like to define "a has many c's through b, where b.c"
> 
> I've already posted this on stackoverflow with a more full explanation and 
> example (but it's had a pretty lukewarm response)
> 
> http://stackoverflow.com/questions/13696045/reusing-activerecord-scopes-on-has-many-through-associations
> 
> 
> Does anyone have any good suggestions about how to do this in a "DRY" way?
> 
> 
> Iain
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] RoRo Talks

2012-12-10 Thread Ben Taylor
All presentations must be accompanied with typewriter noises and each letter 
entering one by one. 

 - Ben


On Tuesday, 11 December 2012 at 11:11 AM, Julio Cesar Ody wrote:

> What do you mean "no transitions"? Where's the fun in that?
> 
> 
> 
> On Tue, Dec 11, 2012 at 11:07 AM, Steven Ringo  (mailto:goo...@stevenringo.com)> wrote:
> > Whatever you feel is appropriate.
> > 
> > On Tuesday, 11 December 2012 at 9:38 AM, Jon Rowe wrote:
> > 
> > Hey Rubyists,
> > 
> > Does anyone know if the "no transitions" guidelines for RoRo presentations
> > include bullet points appearing one by one? Is it a technical limitation or
> > one of style? (If I output to pdf this will look the same, but be a tonne
> > more slides ;) )
> > 
> > Cheers
> > Jon
> > -
> > m...@jonrowe.co.uk (mailto:m...@jonrowe.co.uk)
> > jonrowe.co.uk (http://jonrowe.co.uk)
> > 
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > To unsubscribe from this group, send email to
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > For more options, visit this group at
> > http://groups.google.com/group/rails-oceania?hl=en.
> > 
> > 
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > To unsubscribe from this group, send email to
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > For more options, visit this group at
> > http://groups.google.com/group/rails-oceania?hl=en.
> > 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Hung server processes in rails

2012-12-05 Thread Ben Taylor
Does Heroku forcefully timeout requests that go beyond 30 seconds? 

I've had success using Unicorn and changing my timeout time to be 60+ seconds 
(hack to avoid switching to direct-to-s3 uploads). 

 - Ben


On Thursday, 6 December 2012 at 3:00 PM, Iain Beeston wrote:

> Thanks Pat. Heroku also suggested we use rack-timeout. I hadn't thought about 
> using the stacktrace to track down the cause of the problem though, good idea!
> 
> 
> 
> Iain
> 
> 
> On 6 December 2012 14:25, Pat Allan  (mailto:p...@freelancing-gods.com)> wrote:
> > One thing I've found tremendously helpful for increasing awareness of 
> > timeouts - and then hunting down the cause - is rack-timeout. It'll ensure 
> > those timeouts get raised as exceptions (and thus, you get stack traces, 
> > and I think New Relic gets visibility too).
> > 
> > https://github.com/kch/rack-timeout
> > 
> > If you do change the default time limit (15 seconds), make sure you keep it 
> > below 30 seconds when on Heroku (as that's when they'll consider a request 
> > has timed out).
> > 
> > --
> > Pat
> > 
> > On 06/12/2012, at 2:17 PM, Iain Beeston wrote:
> > 
> > > Thanks Chris. We're not using papertrail but we are using logentries, 
> > > which I believe has similar features. There's really nothing to go on in 
> > > the logs other than where the timeouts are happening (we've increased the 
> > > amount of logging but it hasn't helped us find the problem yet). Rather 
> > > than rely on the logs for monitoring the app we use pingdom to hit the 
> > > site periodically, but the end result is similar.
> > >
> > >
> > >
> > > Iain
> > >
> > >
> > >
> > > On 6 December 2012 13:46, Chris Aitchison  > > (mailto:cmaitchi...@gmail.com)> wrote:
> > > Add the Papertrail add-on to your app and you'll have a lot more logging 
> > > information to work with. It can even send you an email when a log entry 
> > > that matches a particular regex occurs, which sounds like it could be 
> > > helpful here (assuming the logs indicate some sort of issue). And it 
> > > could be free.
> > >
> > > Without more information, it would only be a guess to whether the issue 
> > > lies in Heroku or the app code. If you only have one dyno, it will sleep 
> > > after a few minutes of inaction, but I get the impression you are running 
> > > more than one dyno so this shouldn't happen - and besides, the single 
> > > dyno is still supposed to wake up.
> > >
> > > I think the log data is vital, even if you have to crank up the logging 
> > > level until you find the culprit.
> > >
> > > Chris
> > >
> > >
> > >
> > >
> > > On 06/12/2012, at 13:03, Iain Beeston  > > (mailto:iain.bees...@gmail.com)> wrote:
> > >
> > >> Lately we've had problems with the web-server processes in our rails 3.1 
> > >> app intermittently stop responding. We haven't been able to work out why 
> > >> (no exceptions, high cpu or memory usage or networking calls) - it just 
> > >> seems like every few days one them just randomly hangs and never 
> > >> recovers. The process is still there, but not responding to requests and 
> > >> everything sent to it times out. We're using heroku so our logging 
> > >> options are limited.
> > >>
> > >> So, I was wondering - what do people use to keep their servers 
> > >> responsive? (Especially on "hands-off" platforms like heroku) How common 
> > >> is it to routinely restart processes? (Sounds like the wrong solution to 
> > >> me, but some people recommend it)
> > >>
> > >>
> > >> Iain Beeston
> > >>
> > >>
> > >> --
> > >> You received this message because you are subscribed to the Google 
> > >> Groups "Ruby or Rails Oceania" group.
> > >> To post to this group, send email to rails-oceania@googlegroups.com 
> > >> (mailto:rails-oceania@googlegroups.com).
> > >> To unsubscribe from this group, send email to 
> > >> rails-oceania+unsubscr...@googlegroups.com 
> > >> (mailto:rails-oceania%2bunsubscr...@googlegroups.com).
> > >> For more options, visit this group at 
> > >> http://groups.google.com/group/rails-oceania?hl=en.
> > >
> > > --
> > > You received this message 

Re: [rails-oceania] Ruby and Sockets ...

2012-11-27 Thread Ben Hoskings
Thirded, it's a very good book. Unix is a beautiful thing.

- Ben



On 28/11/2012, at 8:51 AM, jamesl  wrote:

> If you are interested in Ruby and Sockets then you might want to sign up for 
> a new eBook by Jesse Storimer
> I have subscribed to
> 
> Working with TcpSockets 
> 
> And the content is really good. You can sign up here:
> 
> http://workingwithtcpsockets.com or http://workingwithunixprocesses.com.
> 
> - James.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/rails-oceania/-/RI8KEPvDs_oJ.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Call for Speakers @ Melbourne Meetup

2012-11-26 Thread Ben Hoskings
If there's interest, I'd like to talk about postgres replication, how to set it 
up securely and simply, and how to monitor it.

- Ben



On 27/11/2012, at 9:25 AM, David Goodlad  wrote:

> Hi all
> 
> We've had a couple of people pull out for speaking this month at the 
> Melbourne meetup this Thursday. Is anyone interested in doing a short talk 
> about something that you're passionate about? Full talk, lighting talk, you 
> name your game :)
> 
> If you're in, please let us know asap!
> 
> Cheers
> Dave & Justin

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] How to run CI tests in parallel

2012-11-25 Thread Ben Hoskings
Mm, vagrant is great for this sort of stuff.

FYI this isn't a problem any more: there's a master build that triggers the 6 
(now 7) parallel builds, and it only passes if all the sub-builds pass.

The one bit of extra work is that to find each failure, you have to check 
multiple build logs, but in practice it hasn't been an issue.

- Ben



On 26/11/2012, at 9:28 AM, James Healy  wrote:

> A previous project I worked on used Jenkins with a vagrant plugin to run 
> concurrent tests in isolated VMs.
> 
> It took a bit of setting up, but once it got going it was amazing and dropped 
> our build time from >20 minutes to <5 minutes.
> 
> The downside was that it became tricker to understand the "state of the 
> build" at a glance. Instead of checking 1 project, you had to check 6 (unit 
> tests, acceptance tests 1, acceptance tests 2, etc).
> 
> We also tried parallel_tests for a while and it mostly worked, but we ran 
> into a few issues with parallel acceptance specs stepping on each others toes.
> 
> James
> 
> 
> On 22 November 2012 13:12, Sebastian Porto  wrote:
> Hi Guys
> 
> There was a discussion the other day about CI server and it was mention 
> several times how good it is to run the tests in parallel. I am intrigued by 
> this and will like to implement this. But I don't know where to start. 
> 
> What is your approach for running CI test in parallel? We are using TeamCity 
> at the moment, were using Jenkins before. And Rspec.
> 
> Thanks
> Sebastian
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/rails-oceania/-/HqhReVKyNx0J.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Multi-tenancy book

2012-11-22 Thread Ben Schwarz
Is the book going to be published by you? Or someone else? 
Paper? Ebook? Both? 

Pricing is hard, but there are many questions to answer before then. 
A couple of people who have self published (and written incredible books) 
are: 

* Mathias Meyer, http://riakhandbook.com/
* Marc-André Cournoyer, http://createyourproglang.com/

Maybe they're worth reaching out to, or mimicking :-)

Best of luck.

On Thursday, 22 November 2012 16:06:03 UTC+11, Ryan Bigg wrote:
>
> You're right. It's a Rails engine that will allow features to be scoped 
> underneath an account.
>
>
> On 22 November 2012 15:52, Robert Gravina 
> > wrote:
>
>>
>>
>>
>> On 22 November 2012 13:45, Robert Gravina 
>> > wrote:
>>
>>> Excuse my ignorance, but does multi-tenancy simply mean multi-user, or 
>>> is there more to it than that?
>>
>>
>> OK I did a bit of googling and think I know what it is now - one Rails 
>> application with content/features scoped by user, company etc.
>>
>> Robert
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To post to this group, send email to rails-...@googlegroups.com
>> .
>> To unsubscribe from this group, send email to 
>> rails-oceani...@googlegroups.com .
>> For more options, visit this group at 
>> http://groups.google.com/group/rails-oceania?hl=en.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/rails-oceania/-/IislBqduUosJ.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Recommendations for AJAX buttons & actions in Rails 3.2

2012-11-21 Thread Ben Taylor
Something I use a lot is AJAX'd modals. So I have a little bit of JS that looks 
like:  

$ ->
  $(document).on 'click', '[data-load-modal]', ->
url = $(this).attr('data-load-modal')
Modal.open(url)


  $(document).on 'click', '[data-close-modal]', Modal.close  

window.Modal =  
  close: ->
$overlay.addClass "hidden"
$modal.addClass "hidden"

  open: (url) ->
$overlay.removeClass "hidden"

extras =  
  modal: true

 # this should be done by a URL parser
if /\?/.exec(url)
  for pair in url.split('?')[1].split('&')
a = pair.split("=")[0]
b = pair.split("=")[1]
extras[a] = b

$.ajax
  url: url
  data: extras
  dataType: 'html'
  success: (result) => $modal.html(result)
  error: (xhr, string, errorThrown) ->
  direError "There was an error contacting the server"


You could potentially follow this pattern and do something like:

<%= link_to "More", articles_path(offset: @offset + @step), :remote => true, 
"data-append-to" => "#articles" %>

$(document).on "ajax:success", "[data-append-to]", (event, result) ->
  selector = $(event.target).attr("data-append-to")
  $(selector).append(result)

Then add others, like data-replace and data-prepend-to. This way you don't have 
to write a lot of JS and get something similar to the 2.3 behaviour.

 - Ben


On Wednesday, 21 November 2012 at 11:54 PM, Dave Perrett wrote:

> Interesting, thanks Adam - I've been meaning to have a look at angular. This 
> is the kind of thing I've been doing in backbone -> 
> https://gist.github.com/4124680 . Any thoughts?  
>  
> Adam Boas wrote:  
> > The real nub is defining what 'better' would mean.  
> > Simplest? Most Re-usable? Easiest to maintain? Least amount of effort?
> >  
> > Its always going to be a trade off. And the 'best' approach is going to be 
> > more to do with where you app is already at, what the skill set is of the 
> > developers, and where the app is going in terms of features and 
> > functionality.  
> >  
> > I tend to lean toward the simplest solution I can manage, particularly on 
> > pre-existing, large apps. If you already have controllers shipping HTML 
> > there is nothing wrong with leveraging that and sprinkling a little AJAX 
> > pixie dust to make the app seem more responsive. To me the only absolute is 
> > to keep the pixie dust out of the templates and make it clean and readable. 
> >  
> >  
> > I personally really like Backbone for building an app with significant rich 
> > client behaviour, but would never introduce it to an existing full page 
> > post application just to get a little bit of responsive behaviour in some 
> > forms. It introduces significant complexity that just doesn't make any 
> > sense for the kind of thing you have mentioned. And if you are not routing 
> > or changing views, and have no significant model(s) it really adds very 
> > little value.  
> >  
> > Angular is a framework I have been playing with a bit recently and it does 
> > seem to offer a nice, lighter weight alternative to just writing Jquery 
> > plugins for this kind of thing. Its binding behaviour can make responding 
> > to your posts nice and simple. I can definitely recommend having a bit of a 
> > look at if as an alternative, particularly if you want to play with the new 
> > shiny :-)  
> >  
> > Adam Boas
> > e: adam.b...@gmail.com (mailto:adam.b...@gmail.com)
> > m: +61 457 741 117
> >  
> >  
> >  
> > On 21/11/2012, at 8:41 PM, Michael Pearson  > (mailto:mipear...@gmail.com)> wrote:
> > > On Wed, Nov 21, 2012 at 8:10 PM, Adam Boas  > > (mailto:adam.b...@gmail.com)> wrote:
> > > > Hi Michael,
> > > >  
> > > > The bad news is that link_to_remote still exists. It has just changed 
> > > > syntax: link_to(…, remote: true)
> > > >  
> > > > This functionality would be trivial to write in JS or Coffee to attach 
> > > > to the button and form and post it via ajax. I definitely wouldn't 
> > > > inline it in the link_to though. Write a JQuery plugin and attach it in 
> > > > dom-ready. I would probably write it fairly generically, since this 
> > > > form/button/ response HTML/text pattern is pretty common.   
> > > >  
> > > You'll see I'm already using the new :remote => true syntax in my 
> > > exampl

Re: [rails-oceania] Rails Necromancy - Getting a 2.3.4 app running

2012-11-20 Thread Ben Taylor
Looks like the migration to Bamboo has gone smoothly. Pity Heroku didn't 
mention this was an option in any of their communications. I would have been 
pulling my hair out all week.  

 - Ben


On Tuesday, 20 November 2012 at 11:28 PM, Ben Taylor wrote:

> > heroku stack:migrate bamboo-ree-1.8.7
> >  
> > It just worked for me.  
> Ahh, I tried to create a new app on Bamboo and got denied (because they are 
> forcing everyone over to cedar). Will try migrating.  
>  
>  
>  - Ben
>  
>  
> On Tuesday, 20 November 2012 at 11:27 PM, Phil Oye wrote:
>  
> > I was in a similar situation but I gave up going to Cedar. Instead, I 
> > migrated to Bamboo and all was well without any code changes.  
> >  
> > heroku stack:migrate bamboo-ree-1.8.7
> >  
> > It just worked for me.  
> >  
> > Cheers,
> > p.
> >  
> >  
> > On 20/11/2012, at 10:36 PM, Ben Taylor  > (mailto:m...@taybenlor.com)> wrote:
> >  
> > > Hi RoRo,  
> > >  
> > > At work we have a very old app running on Heroku (yes, 2.3 is very old 
> > > now). It's on Aspen and I've been trying to migrate it over to Cedar, 
> > > unfortunately the original developer no longer works here. As part of 
> > > migrating it I've switched it over to using bundler and upgraded it to 
> > > 2.3.14 (though still on ruby 1.8.7). Of course I haven't been able to get 
> > > it running locally.
> > >  
> > > We're running out of time to get it running on Cedar (Aspen will be 
> > > sunsetted in a few days) so I'm starting to get desperate.
> > >  
> > > I've been banging my head against the wall for two days now and not 
> > > really getting anywhere. I've managed to figure out what versions of 
> > > everything it used to run on, but it won't run now. The culprit at the 
> > > moment is Devise.
> > >  
> > > I don't really understand the issue, but I'll give you a stack trace.
> > >  
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:611:in
> > >  `to_constant_name': Anonymous modules have no name to be referenced by 
> > > (ArgumentError)
> > > from 
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:417:in
> > >  `qualified_name_for'
> > > from 
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:130:in
> > >  `const_missing'
> > > from 
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:55:in
> > >  `mailer_sender='
> > > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:21
> > > from 
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:45:in
> > >  `setup'
> > > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:5
> > >  
> > > …
> > >  
> > > The particular method it's calling is
> > >  
> > > module Devise
> > > def self.mailer_sender=(value)
> > >   DeviseMailer.sender = value
> > > end
> > >  
> > > end
> > >  
> > > The version of Devise is very old, but that's the one it's been running 
> > > on. I've tried it on devise up to 0.7 but still get the same errors. I'm 
> > > wary of going too far forwards as there were a bunch of breaking changes. 
> > >  
> > >  
> > > There seems to be some problem loading Devise's modules. If I work around 
> > > this particular Devise call, it later on stalls at:
> > >  
> > > class User < ActiveRecord::Base
> > > devise :all
> > > end
> > >  
> > > With
> > >  
> > > Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activerecord-2.3.4/lib/active_record/base.rb:1959:in
> > >  `method_missing_without_paginate': undefined method `devise' for 
> > > # (NoMethodError)
> > > from 
> > > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/will_paginate-2.3.16/lib/will_paginate/finder.rb:170:in
> > >  `method_missing'
> > > from /Users/ben/Dropbox/dev/redacted/app/models/user.rb:6
> > >  
> > >  
> > >  
> > > Would be amazing if anyone could point me at anything. I've been googling 
> > > all around, changing versions and diving into the Devise source, but I 
> > > feel 

Re: [rails-oceania] Rails Necromancy - Getting a 2.3.4 app running

2012-11-20 Thread Ben Taylor
> heroku stack:migrate bamboo-ree-1.8.7
>  
> It just worked for me.  
Ahh, I tried to create a new app on Bamboo and got denied (because they are 
forcing everyone over to cedar). Will try migrating.  


 - Ben


On Tuesday, 20 November 2012 at 11:27 PM, Phil Oye wrote:

> I was in a similar situation but I gave up going to Cedar. Instead, I 
> migrated to Bamboo and all was well without any code changes.  
>  
> heroku stack:migrate bamboo-ree-1.8.7
>  
> It just worked for me.  
>  
> Cheers,
> p.
>  
>  
> On 20/11/2012, at 10:36 PM, Ben Taylor  (mailto:m...@taybenlor.com)> wrote:
>  
> > Hi RoRo,  
> >  
> > At work we have a very old app running on Heroku (yes, 2.3 is very old 
> > now). It's on Aspen and I've been trying to migrate it over to Cedar, 
> > unfortunately the original developer no longer works here. As part of 
> > migrating it I've switched it over to using bundler and upgraded it to 
> > 2.3.14 (though still on ruby 1.8.7). Of course I haven't been able to get 
> > it running locally.
> >  
> > We're running out of time to get it running on Cedar (Aspen will be 
> > sunsetted in a few days) so I'm starting to get desperate.
> >  
> > I've been banging my head against the wall for two days now and not really 
> > getting anywhere. I've managed to figure out what versions of everything it 
> > used to run on, but it won't run now. The culprit at the moment is Devise.
> >  
> > I don't really understand the issue, but I'll give you a stack trace.
> >  
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:611:in
> >  `to_constant_name': Anonymous modules have no name to be referenced by 
> > (ArgumentError)
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:417:in
> >  `qualified_name_for'
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:130:in
> >  `const_missing'
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:55:in 
> > `mailer_sender='
> > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:21
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:45:in 
> > `setup'
> > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:5
> >  
> > …
> >  
> > The particular method it's calling is
> >  
> > module Devise
> > def self.mailer_sender=(value)
> >   DeviseMailer.sender = value
> > end
> >  
> > end
> >  
> > The version of Devise is very old, but that's the one it's been running on. 
> > I've tried it on devise up to 0.7 but still get the same errors. I'm wary 
> > of going too far forwards as there were a bunch of breaking changes.  
> >  
> > There seems to be some problem loading Devise's modules. If I work around 
> > this particular Devise call, it later on stalls at:
> >  
> > class User < ActiveRecord::Base
> > devise :all
> > end
> >  
> > With
> >  
> > Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activerecord-2.3.4/lib/active_record/base.rb:1959:in
> >  `method_missing_without_paginate': undefined method `devise' for 
> > # (NoMethodError)
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/will_paginate-2.3.16/lib/will_paginate/finder.rb:170:in
> >  `method_missing'
> > from /Users/ben/Dropbox/dev/redacted/app/models/user.rb:6
> >  
> >  
> >  
> > Would be amazing if anyone could point me at anything. I've been googling 
> > all around, changing versions and diving into the Devise source, but I feel 
> > like there's much too much going on here for me to understand every 
> > possibility. It also doesn't help that the app is quite old.
> >  
> > Cheers,
> >  - Ben
> >  
> > --  
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > For more options, visit this group at 
> > http://groups.google.com/group/rails-oceania?hl=en.
> --  
> You rece

Re: [rails-oceania] Rails Necromancy - Getting a 2.3.4 app running

2012-11-20 Thread Ben Taylor
Ahh, of course.  

It's  

Devise.mailer_sender = "nore...@redacted.com"


 - Ben


On Tuesday, 20 November 2012 at 11:25 PM, Pat Allan wrote:

> Ben, what's line 21 of your devise.rb initialiser?
>  
> On 20/11/2012, at 10:36 PM, Ben Taylor wrote:
>  
> > Hi RoRo,
> >  
> > At work we have a very old app running on Heroku (yes, 2.3 is very old 
> > now). It's on Aspen and I've been trying to migrate it over to Cedar, 
> > unfortunately the original developer no longer works here. As part of 
> > migrating it I've switched it over to using bundler and upgraded it to 
> > 2.3.14 (though still on ruby 1.8.7). Of course I haven't been able to get 
> > it running locally.
> >  
> > We're running out of time to get it running on Cedar (Aspen will be 
> > sunsetted in a few days) so I'm starting to get desperate.
> >  
> > I've been banging my head against the wall for two days now and not really 
> > getting anywhere. I've managed to figure out what versions of everything it 
> > used to run on, but it won't run now. The culprit at the moment is Devise.
> >  
> > I don't really understand the issue, but I'll give you a stack trace.
> >  
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:611:in
> >  `to_constant_name': Anonymous modules have no name to be referenced by 
> > (ArgumentError)
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:417:in
> >  `qualified_name_for'
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:130:in
> >  `const_missing'
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:55:in 
> > `mailer_sender='
> > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:21
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:45:in 
> > `setup'
> > from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:5
> > …
> >  
> > The particular method it's calling is
> >  
> > module Devise
> > def self.mailer_sender=(value)
> > DeviseMailer.sender = value
> > end
> > end
> >  
> > The version of Devise is very old, but that's the one it's been running on. 
> > I've tried it on devise up to 0.7 but still get the same errors. I'm wary 
> > of going too far forwards as there were a bunch of breaking changes.  
> >  
> > There seems to be some problem loading Devise's modules. If I work around 
> > this particular Devise call, it later on stalls at:
> >  
> > class User < ActiveRecord::Base
> > devise :all
> > end
> >  
> > With
> >  
> > Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activerecord-2.3.4/lib/active_record/base.rb:1959:in
> >  `method_missing_without_paginate': undefined method `devise' for 
> > # (NoMethodError)
> > from 
> > /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/will_paginate-2.3.16/lib/will_paginate/finder.rb:170:in
> >  `method_missing'
> > from /Users/ben/Dropbox/dev/redacted/app/models/user.rb:6
> >  
> >  
> > Would be amazing if anyone could point me at anything. I've been googling 
> > all around, changing versions and diving into the Devise source, but I feel 
> > like there's much too much going on here for me to understand every 
> > possibility. It also doesn't help that the app is quite old.
> >  
> > Cheers,
> > - Ben
> >  
> >  
> > --  
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > For more options, visit this group at 
> > http://groups.google.com/group/rails-oceania?hl=en.
> >  
>  
>  
>  
> --  
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.
>  
>  


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



[rails-oceania] Rails Necromancy - Getting a 2.3.4 app running

2012-11-20 Thread Ben Taylor
Hi RoRo,  

At work we have a very old app running on Heroku (yes, 2.3 is very old now). 
It's on Aspen and I've been trying to migrate it over to Cedar, unfortunately 
the original developer no longer works here. As part of migrating it I've 
switched it over to using bundler and upgraded it to 2.3.14 (though still on 
ruby 1.8.7). Of course I haven't been able to get it running locally.

We're running out of time to get it running on Cedar (Aspen will be sunsetted 
in a few days) so I'm starting to get desperate.

I've been banging my head against the wall for two days now and not really 
getting anywhere. I've managed to figure out what versions of everything it 
used to run on, but it won't run now. The culprit at the moment is Devise.

I don't really understand the issue, but I'll give you a stack trace.

/Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:611:in
 `to_constant_name': Anonymous modules have no name to be referenced by 
(ArgumentError)
from 
/Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:417:in
 `qualified_name_for'
from 
/Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:130:in
 `const_missing'
from /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:55:in 
`mailer_sender='
from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:21
from /Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/devise-0.4.3/lib/devise.rb:45:in 
`setup'
from /Users/ben/Dropbox/dev/redacted/config/initializers/devise.rb:5

…

The particular method it's calling is

module Devise
def self.mailer_sender=(value)
  DeviseMailer.sender = value
end

end

The version of Devise is very old, but that's the one it's been running on. 
I've tried it on devise up to 0.7 but still get the same errors. I'm wary of 
going too far forwards as there were a bunch of breaking changes.  

There seems to be some problem loading Devise's modules. If I work around this 
particular Devise call, it later on stalls at:

class User < ActiveRecord::Base
devise :all
end

With

Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/activerecord-2.3.4/lib/active_record/base.rb:1959:in
 `method_missing_without_paginate': undefined method `devise' for 
# (NoMethodError)
from 
/Users/ben/.rvm/gems/ruby-1.8.7-p371/gems/will_paginate-2.3.16/lib/will_paginate/finder.rb:170:in
 `method_missing'
from /Users/ben/Dropbox/dev/redacted/app/models/user.rb:6



Would be amazing if anyone could point me at anything. I've been googling all 
around, changing versions and diving into the Devise source, but I feel like 
there's much too much going on here for me to understand every possibility. It 
also doesn't help that the app is quite old.

Cheers,
 - Ben

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] [OT] Railscamp Tassie and boardgames

2012-11-12 Thread Ben Taylor
I've got some Cards Against Humanity I was thinking of bringing. Might bring a 
couple of Magic Decks (lol) and if I can fit it - Bang! Settlers is fun as 
well, I think I'll have the version on my iPad (much more portable than the 
full game). Oh, and munchkin. I'll bring that. I have a lot of card games :P

 - Ben


On Monday, 12 November 2012 at 6:50 PM, Daryl Manning wrote:

> One of the things I really love about Railscamp evenings is the fact that 
> more than a few game geeks drag some of their faves along to play in the 
> evenings. It's where I discovered Werewolf with which I now have a deeply 
> unhealthy relationship (and encourage you to play if you've never done so 
> before...).
> 
> So, just wondering if people are thinking of bringing some interesting 
> boardgames along this time (Cataan, G Annihilation, Zombies: LNOE etc)? 
> Anything @DefectiveYeti has ever endorsed really is probably something I'd be 
> interested in playing if you're on the fence about throwing something in your 
> luggage.
> 
> I'm  planning on bringing my poker set since I've already been called out so 
> if people are interested in a single table tourney like last time I'll be 
> running one so just trying to gauge interest  (... we'll need someone to 
> bring another set if we want say, a two table tourney etc).  
> 
> And I'll have a werewolf pack with me... As I'm sure will many others... 
> (@pat, @ryanbigg etc). I imagine Durak will also be in full swing if you want 
> to give a hand at that.
> 
> ciao !
> Daryl
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] automated webpage to PDF creation

2012-11-06 Thread Ben Bruscella
http://railscasts.com/episodes/220-pdfkit ?

On Wed, Nov 7, 2012 at 5:14 PM, Tim McEwan  wrote:

>  Hi all,
>
> I want to automate the creation of around 100 PDFs with user data and
> graphics generated by JS (charts mostly, but maybe some Raphael).  Each PDF
> is an energy bill.  The whole environment can be controlled, so it doesn't
> need to be client-side cross-platform or anything.  However, we'd like to
> be able to package it up and have others use it, so the simpler the better.
>
> I've looked at Prawn, but I'd rather not have to draw everything from
> first principles.  It seems wkhtmltopdf is a better bet so I tested it on
> highcharts.com.  It does a good job , but not
> as good as straight Safari .  So I thought
> perhaps I'd automate a browser instead, but that may not be so 
> simple
> .
>
> Has anyone got any tips on the best way to go?
>
> Thanks,
> Tim
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/rails-oceania?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] automated webpage to PDF creation

2012-11-06 Thread Ben Taylor
I've done something similar with wkhtmltopdf, although I never needed to do 
charts or JS. I found it was quick to get something 80% there, but needed lots 
of fiddling to get it *right*.

Automating Safari is an interesting path, but sounds like it could become a 
massive pain very quickly. 

 - Ben


On Wednesday, 7 November 2012 at 5:14 PM, Tim McEwan wrote:

> Hi all, 
> 
> I want to automate the creation of around 100 PDFs with user data and 
> graphics generated by JS (charts mostly, but maybe some Raphael).  Each PDF 
> is an energy bill.  The whole environment can be controlled, so it doesn't 
> need to be client-side cross-platform or anything.  However, we'd like to be 
> able to package it up and have others use it, so the simpler the better.
> 
> I've looked at Prawn, but I'd rather not have to draw everything from first 
> principles.  It seems wkhtmltopdf is a better bet so I tested it on 
> highcharts.com (http://highcharts.com).  It does a good job 
> (http://cl.ly/2l1c3C083u3N), but not as good as straight Safari 
> (http://cl.ly/2Q0F0J0C022a).  So I thought perhaps I'd automate a browser 
> instead, but that may not be so simple 
> (http://stackoverflow.com/questions/11537103/how-to-handle-print-dialog-in-selenium).
> 
> Has anyone got any tips on the best way to go?
> 
> Thanks,
> Tim
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] Continuous Integration Server

2012-10-30 Thread Ben Hoskings
Yep, parallelised builds are a huge win. We run parallel across 7 vagrant VMs 
on an 8-core (4 w/HT) box and the whole build takes around 8 minutes, vs. 30-40 
minutes on my macbook. (I usually still run the unit specs locally though, 
because those only take about 2 minutes.)

Our build is split into 7 chunks: unit, jasmine, and 5x integration (grouped 
arbitrarily to take roughly the same amount of time each).

The VMs are headless and we run selenium specs via xvfb, which isn't a problem 
in practise. The build server is just there to say red/green as fast as 
possible, and then i diagnose specific specs locally (zeus zeus zeus).

- Ben



On 31/10/2012, at 11:39 AM, Jack Chen  wrote:

> +1 on good CPU. Also, consider parallelising your build if you haven't 
> already. Our build would take 2 hours 51 minutes if ran in serial, but in 
> parallel over 2 servers (56 logical CPUs), it runs in just under 7 minutes.
> On Wednesday, 31 October 2012 at 11:25 AM, Jon Rowe wrote:
> 
>> Don't be tempted by something with a duff CPU, I've been down that route, 
>> tests take so long it not worth it. Maybe consider a chunky (desktop 
>> replacement style) laptop if portability is an issue. 
>> 
>> Software wise Jenkins works well (is available by apt on Ubuntu).
>> 
>> Have you considered travis-ci?
>> 
>> Cheers
>> Jon
>> 
>> On 30 Oct 2012, at 23:56, William Madden  wrote:
>> 
>>> Hey guys,
>>> 
>>> I need a CI server. I've been thinking about this for a little while and 
>>> I'm leaning towards hosting my own CI server rather than using somebody 
>>> else's service - primarily because I don't want to pay someone else for 
>>> something I can maintain and because they tend to be slow. With regard to 
>>> maintaining my own CI server, here are the conclusions I've come to:
>>> • Headless servers are extremely frustrating to debug 
>>> • I want to be able to plug in a screen to set everything up, 
>>> and to debug it when it (inevitably) breaks
>>> • Remote servers tend to be slow
>>> • E.g. Amazon EC2
>>> • Also they cost money I don't have
>>> • Maintaining my own hardware is fine, but I'm going to be travelling 
>>> between countries a lot in the next few months and I need to be able to 
>>> take it with me
>>> • So smaller is better
>>> My app is pretty straightforward, a Rails server and HTML/JS frontend 
>>> tested with RSpec, Jasmine and Cucumber. Running the full suite of tests 
>>> takes about 2 minutes on my MBP.
>>> 
>>> I've been thinking about getting a mini-pc/nettop/>> "small computer">. Anybody have any recommendations - either for small 
>>> portable hardware or for a hosted service that will perform adequately and 
>>> not cost too much?
>>> 
>>> Cheers,
>>> 
>>> Will
>>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "Ruby or Rails Oceania" group.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msg/rails-oceania/-/DhOUxQRvcH8J.
>>> To post to this group, send email to rails-oceania@googlegroups.com.
>>> To unsubscribe from this group, send email to 
>>> rails-oceania+unsubscr...@googlegroups.com.
>>> For more options, visit this group at 
>>> http://groups.google.com/group/rails-oceania?hl=en.
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> To unsubscribe from this group, send email to 
>> rails-oceania+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] [OT] Anybody have one of the new retina MBP 13" models? Care to share your experiences?

2012-10-29 Thread Ben Hoskings
Yep, I've been driving a 27" from my 11" Air for a year now and it's great. The 
Air doesn't struggle at all.

(There are always going to be intensive things like a complex fullscreen webgl 
that aren't totally smooth, but you can't have it all.)

- Ben



On 30/10/2012, at 10:01 AM, Adam Boas  wrote:

> The rMBP 13" has the same graphics chip as the new MBA with more RAM and a 
> faster chip. I have seen plenty of people drive a 27" screen with their MBA
> On Tuesday, 30 October 2012 at 9:57 AM, Michael Pearson wrote:
> 
>> On Tue, Oct 30, 2012 at 9:52 AM, Tim McEwan  wrote:
>>> That's a great point; thanks for that.  I'm not sure I want to get a 13" 
>>> rMBP now.  (I need to use an external a fair bit.)
>> 
>> I don't think he was saying that using an external display was a bad idea - 
>> just that the native screen is much better.
>> 
>> Personally, I spend about two hours a day on the train with the laptop open 
>> (hence preference for the 13") and the rest of the time plugged in to a Dell 
>> 27" at home or work.
>> 
>> Preferring retina as it's 500g lighter than the non-retina model, and the 
>> price of the non-retina model is near to the retina once you add in the 
>> 256GB SSD.
>> 
>> -- 
>> Michael Pearson
>> 
>> 
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Ruby or Rails Oceania" group.
>> To post to this group, send email to rails-oceania@googlegroups.com.
>> To unsubscribe from this group, send email to 
>> rails-oceania+unsubscr...@googlegroups.com.
>> For more options, visit this group at 
>> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



[rails-oceania] Re: RubyConf Australia 2013 Update

2012-10-28 Thread Ben Schwarz
Keith, I've been seeing a lot of people +1ing the pull requests on Github… 
this could simply be seen as a popularity contest for trying to get your 
talk to become selected.
Does this hold any baring on the talks that are selected? 

Disclaimer: I do not have a talk submission for RubyConf Australia.

--

On Friday, 26 October 2012 13:41:41 UTC+11, Keith Pitty wrote:
>
> For those of you who are interested in RubyConf Australia 2013 but are not 
> on the mailing list or following @rubyconf_au on Twitter, here's an update.
>
> Talks CFP
> ===
>
> The deadline for talk proposals is fast approaching.  We have received 
> many excellent proposals so far and, if you're considering submitting 
> yours, please head over to Github (
> https://github.com/rubyaustralia/rubyconfau-2013-cfp) now and follow the 
> instructions.  You have until October 31 to submit your pull request.  We 
> will be aiming to select talks by mid-November.
>
> Workshops
> 
>
> As announced earlier, Dave Thomas will be running an Advanced Ruby 
> workshop on Wednesday, February 20.  Also on that day, thanks to the 
> initiative of Robert Postill, we are delighted to announce that a 
> RailsGirls event will be held.
>
> We expect to be able to make further announcements soon about other 
> workshops.  If you have a full or half-day workshop that you would like to 
> run, please submit your proposal via Github (
> https://github.com/rubyaustralia/rubyconfau-2013-tutorials-cfp).
>
> Also, we are keen to hear about content you would like included in a 
> workshop.  Please let us know (
> http://rubyconfau.wufoo.com/forms/rubyconf-australia-workshop-proposals/).
>
> Early Bird Tickets
> =
>
> Tickets for RubyConf Australia 2013 will be very reasonably priced.  If 
> you're keen to maximise your bang for buck, you will be pleased to know 
> that early bird tickets will go on sale in the first week of November. 
>  Stay tuned for further details!
>
> Cheers,
> Keith Pitty
> on behalf of the RubyConf AU 2013 team
> http://rubyconf.org.au
>
>

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/rails-oceania/-/ZN8QaPsbj60J.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] MacBook Air for development

2012-10-24 Thread Ben Hoskings
Let's not go down the Mac-vs-PC path :) No one's going to convince anyone of 
anything.

I'm sure the ultrabook is a great machine. It's all down to personal 
preference: e.g. for me, my priority is that I want to run OS X, and I like 
using hardware that it's been tested to run on. Whether I'm paying a premium 
for that or not, I don't mind.

- Ben



On 25/10/2012, at 12:35 PM, Richard McGain  wrote:

> I'm going to pipe up here with a counter argument.
> 
> Buy an ultrabook. Just as light and portable as a mac, just as easy to 
> develop on. Battery life is great and even with 8gb, it's going to be cheaper 
> than a mac. 
> 
> Richard 
> 
> 
> 
> On Wed, Oct 24, 2012 at 8:58 PM, Ben Hoskings  wrote:
> It depends on what you're running.
> 
> I often head down the road to my local and do a battery's worth of hacking. 
> If I left all my apps open I doubt I'd get that much, but if I quit the stuff 
> I'm not using (leaving just sublime/terminal/safari) and make sure the 
> brightness isn't too high then yeah, I'll get 3.5-4 hours out of it.
> 
> There are a bunch of apps (Apple Mail is one) that use non-trivial CPU in the 
> background. That makes a big difference because CPU (along with antennas and 
> display backlighting) make up the bulk of the device's power drain.
> 
> Also depends on the kind of dev work I'm doing. Working on a big rails app, 
> you're going to burn the battery running specs and loading pages, no way 
> around it. But if I'm hacking on babushka, which is pure ruby, then there's 
> no app or spec boot time, so the battery goes a lot further.
> 
> - Ben
> 
> 
> 
> On 25/10/2012, at 11:43 AM, Daryl Manning  wrote:
> 
> > Funnily enough, my only beef with the older MBA I had was the battery life. 
> > I'd be lucky to get 3 hours out of the thing, and I really felt like I need 
> > something that can hit 7-8 hours (enough for the majority of a long haul 
> > flight). Especially with an Ipad topping 10 hours, it drives me nuts when a 
> > plane doesn't have plugs for power when I'm out and about.
> >
> > You could really get 3-4 hours out of the 11"?
> >
> > Can anyone comment on the latest time-to-dead for typical dev load on the 
> > newer 13" MBAs vs say, the new 13" retina MBP? Curious... (and real time to 
> > dead, not apple claimed...).
> >
> > ciao !
> > Daryl.
> >
> >
> > On Thu, Oct 25, 2012 at 11:39 AM, Ben Hoskings  wrote:
> > Hi Rich,
> >
> > My only machine is an 11" Air (one revision old, i.e. 1.8GHz i7, 4GB RAM). 
> > I'd fully recommend it as a primary development box.
> >
> > In particular, 4GB is plenty for my workload (multiple Sublime projects & 
> > shells, browsers, mail, and the rest). This is what my RAM profile looks 
> > like after a week of uptime: http://d.pr/qtmH
> >
> > It's a wonderful machine to cart around (it's not much heavier than an 
> > iPad) and the battery life is very good (if you watch the brightness, 3-4 
> > hours).
> >
> > - Ben
> >
> >
> >
> > On 25/10/2012, at 10:26 AM, Rich Buggy  wrote:
> >
> > > Hi everyone
> > >
> > > I'm planning to switch my development machine from Windows to Macintosh. 
> > > Is a MacBook Air (with 4GB memory) sufficient for Rails development? The 
> > > tech specs are better than my current Windows laptop, which works fine 
> > > for me, but I've never developed on a Mac so I'm not sure if should be 
> > > spending the extra on MacBook Pro. Any advice is appreciated.
> > >
> > > Rich
> > >
> > > --
> > > You received this message because you are subscribed to the Google Groups 
> > > "Ruby or Rails Oceania" group.
> > > To view this discussion on the web visit 
> > > https://groups.google.com/d/msg/rails-oceania/-/B7UIq0vYIZsJ.
> > > To post to this group, send email to rails-oceania@googlegroups.com.
> > > To unsubscribe from this group, send email to 
> > > rails-oceania+unsubscr...@googlegroups.com.
> > > For more options, visit this group at 
> > > http://groups.google.com/group/rails-oceania?hl=en.
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To post to this group, send email to rails-oceania@googlegroups.com.
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com.
>

Re: [rails-oceania] MacBook Air for development

2012-10-24 Thread Ben Hoskings
It depends on what you're running.

I often head down the road to my local and do a battery's worth of hacking. If 
I left all my apps open I doubt I'd get that much, but if I quit the stuff I'm 
not using (leaving just sublime/terminal/safari) and make sure the brightness 
isn't too high then yeah, I'll get 3.5-4 hours out of it.

There are a bunch of apps (Apple Mail is one) that use non-trivial CPU in the 
background. That makes a big difference because CPU (along with antennas and 
display backlighting) make up the bulk of the device's power drain.

Also depends on the kind of dev work I'm doing. Working on a big rails app, 
you're going to burn the battery running specs and loading pages, no way around 
it. But if I'm hacking on babushka, which is pure ruby, then there's no app or 
spec boot time, so the battery goes a lot further.

- Ben



On 25/10/2012, at 11:43 AM, Daryl Manning  wrote:

> Funnily enough, my only beef with the older MBA I had was the battery life. 
> I'd be lucky to get 3 hours out of the thing, and I really felt like I need 
> something that can hit 7-8 hours (enough for the majority of a long haul 
> flight). Especially with an Ipad topping 10 hours, it drives me nuts when a 
> plane doesn't have plugs for power when I'm out and about.
> 
> You could really get 3-4 hours out of the 11"?
> 
> Can anyone comment on the latest time-to-dead for typical dev load on the 
> newer 13" MBAs vs say, the new 13" retina MBP? Curious... (and real time to 
> dead, not apple claimed...).
> 
> ciao !
> Daryl.
> 
> 
> On Thu, Oct 25, 2012 at 11:39 AM, Ben Hoskings  wrote:
> Hi Rich,
> 
> My only machine is an 11" Air (one revision old, i.e. 1.8GHz i7, 4GB RAM). 
> I'd fully recommend it as a primary development box.
> 
> In particular, 4GB is plenty for my workload (multiple Sublime projects & 
> shells, browsers, mail, and the rest). This is what my RAM profile looks like 
> after a week of uptime: http://d.pr/qtmH
> 
> It's a wonderful machine to cart around (it's not much heavier than an iPad) 
> and the battery life is very good (if you watch the brightness, 3-4 hours).
> 
> - Ben
> 
> 
> 
> On 25/10/2012, at 10:26 AM, Rich Buggy  wrote:
> 
> > Hi everyone
> >
> > I'm planning to switch my development machine from Windows to Macintosh. Is 
> > a MacBook Air (with 4GB memory) sufficient for Rails development? The tech 
> > specs are better than my current Windows laptop, which works fine for me, 
> > but I've never developed on a Mac so I'm not sure if should be spending the 
> > extra on MacBook Pro. Any advice is appreciated.
> >
> > Rich
> >
> > --
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msg/rails-oceania/-/B7UIq0vYIZsJ.
> > To post to this group, send email to rails-oceania@googlegroups.com.
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com.
> > For more options, visit this group at 
> > http://groups.google.com/group/rails-oceania?hl=en.
> 
> --
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com.
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com.
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



Re: [rails-oceania] MacBook Air for development

2012-10-24 Thread Ben Taylor
I run a 3 year old MBP 13" and am upgrading soon. But this machine is still 
going strong. 

I'd beware of settling for low RAM. RAM is one of the easiest ways to keep a 
machine alive after years of use. While mine isn't snappy, I happily chug away 
with:
  * 2-3 Browsers
  * Virtual Machine
  * Photoshop
  * Sublime
  * IM
  * Terminal, multiple tabs, zeus, (all my ruby instances are using about 500mb 
of ram)
  * Spotify
  * iTunes

The only way I'm able to pull that off is to with the 8gb of RAM I installed 
after the first year of use. I basically never experience paging (yay!).

With modern Apple MacBooks being entirely non-upgradeable I'd want to make sure 
I have the most RAM possible from the start. Unless you intend to upgrade every 
year (not unreasonable). 

 - Ben


On Thursday, 25 October 2012 at 11:39 AM, Ben Hoskings wrote:

> Hi Rich,
> 
> My only machine is an 11" Air (one revision old, i.e. 1.8GHz i7, 4GB RAM). 
> I'd fully recommend it as a primary development box.
> 
> In particular, 4GB is plenty for my workload (multiple Sublime projects & 
> shells, browsers, mail, and the rest). This is what my RAM profile looks like 
> after a week of uptime: http://d.pr/qtmH
> 
> It's a wonderful machine to cart around (it's not much heavier than an iPad) 
> and the battery life is very good (if you watch the brightness, 3-4 hours).
> 
> - Ben
> 
> 
> 
> On 25/10/2012, at 10:26 AM, Rich Buggy  (mailto:r...@zoombugmedia.com)> wrote:
> 
> > Hi everyone
> > 
> > I'm planning to switch my development machine from Windows to Macintosh. Is 
> > a MacBook Air (with 4GB memory) sufficient for Rails development? The tech 
> > specs are better than my current Windows laptop, which works fine for me, 
> > but I've never developed on a Mac so I'm not sure if should be spending the 
> > extra on MacBook Pro. Any advice is appreciated.
> > 
> > Rich
> > 
> > -- 
> > You received this message because you are subscribed to the Google Groups 
> > "Ruby or Rails Oceania" group.
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msg/rails-oceania/-/B7UIq0vYIZsJ.
> > To post to this group, send email to rails-oceania@googlegroups.com 
> > (mailto:rails-oceania@googlegroups.com).
> > To unsubscribe from this group, send email to 
> > rails-oceania+unsubscr...@googlegroups.com 
> > (mailto:rails-oceania+unsubscr...@googlegroups.com).
> > For more options, visit this group at 
> > http://groups.google.com/group/rails-oceania?hl=en.
> > 
> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Ruby or Rails Oceania" group.
> To post to this group, send email to rails-oceania@googlegroups.com 
> (mailto:rails-oceania@googlegroups.com).
> To unsubscribe from this group, send email to 
> rails-oceania+unsubscr...@googlegroups.com 
> (mailto:rails-oceania+unsubscr...@googlegroups.com).
> For more options, visit this group at 
> http://groups.google.com/group/rails-oceania?hl=en.
> 
> 


-- 
You received this message because you are subscribed to the Google Groups "Ruby 
or Rails Oceania" group.
To post to this group, send email to rails-oceania@googlegroups.com.
To unsubscribe from this group, send email to 
rails-oceania+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rails-oceania?hl=en.



  1   2   3   4   5   6   7   8   >