Ask HN: Should I or Why should I bother continuing with rails
The things I like about RoR is that due to the structure and expectations of rails, I suspect it is much quicker to get new people up to speed on a project because theoretically, the structure is already laid out.
I also in theory like the way it handles migrations, though I haven't actually used it in a production environment yet.
The things I'm HATING is that every little bit of code I write doesn't work!
I'm moving like molasses here, and have very little to show for nearly 3 weeks of messing with this language.
As you can see from my stackoverflow account http://stackoverflow.com/users/48067/pedalpete, if you care to look, I'm spending hours doing minor little things like making a link to delete a database entry and it just doesn't work!
Has anybody been in the same situation? I'm following guides, watching the railscasts, etc. etc. but I'm absolutely not getting it and extremely frustrated.
Maybe I just don't remember being this frustrated with PHP, but I seem to recall with PHP i was getting into some much deeper stuff when I was still learning and I don't remember it being nearly this painful.
Has anybody else had the same experience?
Is there some magic bullet that is all of a sudden going to make this better?
I can't believe that all the hype around RoR is really applicable to everybody but me, so there must be something I'm missing.
Note that if you are using Rails 3, most of the tutorials out there are for Rails 2. This is going to be a rough next year and a half or so.
For Rails 3, check this out if you haven't already. Personally I'm not into watching videos of someone else coding, but maybe you are: http://railscasts.com/ transcriptions here: http://asciicasts.com/
Here comes the frustrating part. Unlike PhP, Java, etc. where just looking up stuff online is enough, unless you participate in the various local Ruby get-togethers or have some others nearby that do, you're likely to find yourself in the dark more than you're used to being. I'm somewhat of an introvert, and have a family where I can't be going to these things nor do I want to, but not going to the meetups definitely hurts it seems. Maybe I've bought into the hype too much about how much the meetups help though, and I've heard from someone that some meetups are more hype than help, so if you don't like one group, try another.
Basically, here are the pain points I can think of:
If you relied on it in the past, lack of static typing hurts in the beginning, but not so much after a year or so with the exception of lack of good method/etc. completion due to the dynamic nature of Ruby.
Having wierd bugs because the gem/plugin you are using is incompatible with the version of Rails, etc. is no fun. Read the docs associated with the gem/plugin. Submit a ticket/contact the developer(s) some other way to find out what they use. This doesn't bite as much as you'd think.
Trying to track down what in the heck is going on in Rails, Active Record, etc. can be a pain when something isn't working. I've not gotten good enough to feel totally comfortable with this, but I know people after working several years with it are more at home with this.
Upgrading Rails can suck.
You'll read suggestions that say if you don't write test first, you'll not be able to handle bugs/issues that well. That is probably true, however the team I'm on doesn't pay attention to testing as much as they should, and we get by mostly ok (some tough issues here and there).
Overall, Rails is ok, and Ruby is pretty cool. Also check out Sinatra, etc. Maybe you don't need Rails for what you are doing.
I would suggest nobody 'needs' rails, i can get along very well with php, but I thought I'd see what all the hype was about. I suspect I'll go back to my php land. Unfortunately feeling a bit defeated.
PhP is for general-purpose web application development, but somewhat targeted at building "higher traffic dynamic webpages", although it is much more than that. It's widely used, and it's been around a good while. It isn't going away, and I'm not trying to convince you to stop using it.
Ruby by itself is a fascinating language that developers should get familiar with. Why? IMO, primarily because of this: http://scotland-on-rails.s3.amazonaws.com/2A04_DaveThomas-SO...
But Ruby on its own is a bit like Java, Perl, etc. It isn't really web-oriented. Rails however is a framework that uses Ruby and bundles code that makes working with/storing data, web forms, etc. easier. On the surface, unlike PhP, Rails seems to have a mindset of its own, attempting to get you to use conventions that try to put webapps more into a box, so you can develop faster once you learn the box, whereas PhP alone is more wide-open. However, almost immediately you learn that box is almost entirely imagined. Ruby is even more wide-open than PhP, so Rails is also.
It might be hard to get a picture of the sheer amount of functionality available for Ruby on (and off) Rails via http://rubygems.org/ and http://github.com/ but trust me- there is a lot! The same can be said for PhP as well, but it isn't packaged up quite the same.
RoR tries (notice I said tries) to make things simple. So developers get pulled in and make rookie mistakes because the details are glossed over that aren't glossed over in Java, etc. as much. I've seen and been told of PhP developed by those that didn't know what they were doing that is the same way, though.
I agree that nobody "needs" Rails, but spend some more time with it, and you'll find you'll use it more than PhP for some applications.
Also, if it's Rails that's giving you trouble, have you considered starting with a smaller framework like Camping or Sinatra? That feeling of none of your code working can be frustrating, but maybe it's because you missed some of the beginning steps with Ruby and it's making things more difficult than they should be!
Plus, hacking in Ruby can be a lot of fun. There are a lot of really neat tricks you can use to do really cool things.
This resolved a huge issue I was having with my Ruby, but I find this to be a really poor way to write a language. Maybe it will just take more getting used to.
We hear people say that English is so difficult to learn because of these 'rules and exceptions', so maybe I just need to get that mentality and realize that just because something worked in one instance, it won't in another.
I will spend more time focusing on learning Ruby. i was always thinking the problems I was having was due to rails.
Originally I was working with a whole bunch of Gems to learn mongo and do some more interesting stuff, but with all the gem issues, I decided to just stick to the basics and am building what should be a fairly simple app.
There is backward compatibility, and I am learning the rails3 way as much as possible, looking to the rails3 documentation rather than the older stuff.