"AkitaOnRails" Advises A Young Ruby Beginner

Fabio AkitaFabio Akita is a Brazilian Rails enthusiast, also known online as “AkitaOnRails”. He regularly write posts on his own blog and had published the very first book tailored for the Brazilian audience called “Repensando a Web com Rails”. He is now a full-time Ruby on Rails developer working as Brazil Rails Practice Manager for the Utah company Surgeworks LLC.

Paresh MathurParesh Mathur aka “Rick”, is a 16 year young participant – ceek (cool geek) – at the ‘Free Online Ruby Programming Course‘. ‘Rick’ is a student in XII grade at the Kendriya Vidyalaya Cantonment School in Ahmedabad, India. He’s an open source fan, loves programming and is very active in the course forums. If not studying, Paresh is tinkering on his computer and helping out friends.

Paresh felt that a pro like Fabio should write an article on what one should do after the ‘Free Online Ruby Programming Course’. He was not aware whether such an article existed and if it did, it would be of great help to him.

Paresh had two questions for Fabio and Fabio was kind enough to answer and also give his invaluable advice.

Paresh>> Further Studies: What to do next? Can you recommend things to study after the course, including different frameworks and external libraries? If a free course like Satish’s is in your mind please do share.

Fabio>> The question is very broad in nature, so I can’t pinpoint a direct answer.

Satish has an excellent free online Ruby course at rubylearning.org. Satish’s approach should be replicated more, that’s for sure, and he is doing a great contribution to the community. So, no, I don’t know by heart any other online free course comparable to Satish’s. That said, there are a number of good online resources. One that should be on anyone’s RSS reader is Ryan Bates’ “Railscasts“, where he publishes several small screencasts with tips and best practices using Rails. The other great resource is Peepcode’s series of screencasts. Those are not free but are much more elaborate and complete.

I think these are the ‘usual suspects’. But there is so much more. And on the other hand you have to ask yourself “at what level am I?

Most screencasts, tutorials, articles on the internet assume that you’re at least a reasonably educated programmer. By that I mean, you:

The field of Computer Science is very very broad; it is an enormous and ever growing body of knowledge and it is impossible to know everything. That’s why it is so important to at least focus on the foundations, so you can build your way up on your own. The best programmers learn by themselves the required skills for our craft. Programming is basically a craftsmanship. The same way no one can teach you how to become a Leonardo Da Vinci; it is obviously difficult to come up with a recipe to become the next Donald Knuth.

That said, you don’t and you shouldn’t try to learn every single bullet point, I mentioned above, in deep detail. Remember: I said it is impossible to know the whole. Each bullet point above is a vast and complex body of knowledge by itself. Don’t try to learn every bit at once, it is time consuming and not valuable.

Instead, educate yourself to at least get to know the basics on each. You don’t have to become Linus Torvalds to be able to understand the basics on operating systems. Install any Linux distro, read the several tutorials, try to do something useful with it. Then try to solve problems, tweak it, try to make it do different things than what was offered to you out-of-the-box. Try to make it crash and understand why it does so. Trying and error is the best learning process if you are a beginner.

There is absolutely no set of a fixed number of items that can be listed for you to learn, so you can consider yourself a good programmer. Programming is an art that requires commitment and gives you nothing back: meaning that it never ends. Techniques get obsolete fast, new techniques arise all the time and it is your job, as a programmer, to get to know them.

Read good books, but never consider them absolute truths. Many books have a lot of mistakes and things that can be misinterpreted. Like the classic Gang of Four book: it is more of a guideline than a defined set of authoritative techniques that you must use all the time. Different people make different implementations of the same design pattern.

Considering that you already know all this and I am wasting my time :-) Let’s get straight to the Ruby specific topic: you are already an experienced programmer and you just got initial knowledge about Ruby’s way. What to do next?

Find yourself an itch to scratch. Meaning: find yourself a computer problem for which you may not have a good answer, just yet. You want some new desktop client to better manage your Twitter activities. You want something to hold together all passwords from all your dozen or so social network accounts. Choose whatever you want. It can even be something that already exists but that you think you could do better.

It shouldn’t be something too big “I want to write the next MySpace in Ruby.” Less ambition. You’re just getting started. Type in your first “Hello World”, see it running and set the stage for more code to come.

Once you do that, you will probably find yourself either doing a lot of code for something that was supposed to be simple, by Ruby standards, and chances are that you are reinventing the wheel. Define the specific problem you are coding right now and research to see if an alternative library doesn’t exist already. Or you will try to code something and get stuck at some problem you don’t even know how to start (“how do I authenticate into a Twitter account?“).

In all cases you have several answers: Google for general research. IRC channels. Google Groups discussion lists. Web-based forums. The Blogosphere. Suit yourself, there is a ton of information available for just about any kind of computer problem. If you are having trouble, chances are someone else has already solved it and was kind enough to document and make it available online. It is just a matter of spending a few minutes researching for it.

Without a small problem to solve, you won’t be able to warm yourself up quick enough. Reading books is fine, but kind of pointless without real usage. Experience is the best way to learn something. You can read hundreds of books on how to ride a bicycle, but you won’t learn it until you actually try the real thing and fall down for the first time. Only then you start to appreciate the learning process.

Paresh>> Hands on: Most people, like me, would like to contribute our time, skills and expertise to a project but invariably are unaware of where and how to do so. Fabio, could you suggest some?

Fabio>> This is another thing that has no real answer. Being very arrogant the short answer is: “if you don’t know how to contribute, you shouldn’t be thinking about it just yet.”

Let me reason why is that: contributing to an open source software is far more complex than writing half a dozen lines of code, submitting it and expecting that it will be used. The process is a lot more complex than that.

Understand that open source projects are community-driven. It means that first of all you should start becoming part of a community. It also assumes that you already know of some project you want to participate in. For that, you can’t be an internet illiterate.

One project that you know about is Ruby. Fine, you can start by joining the Ruby Core Group. You can start by downloading Ruby’s source code (which is in C, mind you). You will quickly find out that each open source group has a lot going on: bug fixes, feature request, politics. Yes, even politics. You have to be nice to your neighbors in order to gain respect. Simply shouting “I want my code in!” will lead you no-where.

You don’t contribute for recognition, you contribute because you think some project is valuable to you and, once you get experience and knowledge about its inner gears and general community culture, you think you are able to help in some way: fixing bugs, completing documentation, answering other newbie questions at the forums, giving in new ideas. It is the same thing as joining any social group in real life: don’t think that just because you’re in everybody has to pay attention on you. Worse: don’t even think that your solution is better than anyone else. Chances are that your requests are not new, they were already discussed and decisions were already made. Read the CHANGELOGs, read the discussion lists archives. It is very annoying when newbies sign in and start asking random request that are already buried.

Also, make sure you understand the Philosophy around open source software. It is not as trivial as one could think. Understand open source Licenses. Chances are, if you are a beginner, that you never read any of those documents. All of them being published in the open, it is not an excuse to not know all of them.

Again, let’s assume that you already are a programmer well aware of all the culture and what’s going on around open source projects. You just want to know how to contribute to the Ruby community.

  • Ruby 1.8 is in maintenance mode. There are bugs to be fixed, documentation to be completed. Join the Ruby list and see what they are discussing.
  • Ruby on Windows needs some love. Luis Lavena would love to have more help on testing, debugging, Windows internal specifics (if you are a Windows system specialist), documentation, packaging, distribution and so on.
  • Maybe you are a web developer and you learned Ruby because of Rails. So show Rails some love and start digging through Rails bug list. Follow the discussions and read what people are already doing.
  • RubyForge is one of the main sources of Ruby projects. Check it out for projects that you like and join their communities.
  • GitHub is the new kid on the block but it is already hosting several high profile projects. Bear in mind that popular projects means lots of people to deal with, you don’t want to attract attention without need.

You did realize that the first step for contributing to any open source project is to join their communities, right? It is not enough to download the source code, change a few bits and expect it to show up in the official repository. Open source means commitment to a community. It is totally driven by mutual respect, open discussions.

If you are a beginner it is good enough to just join the community and follow what’s going on, passively, until you get a grip on how things work and start posting questions and asking directions. This is socializing-101. There actually is a Netiquete that you really should follow.

As I said before, look for an ‘itch to scratch’. No one wakes up one day and decides ‘I will help some project’. It is not how it works. The more usual use case is that you’re using something from somebody else and you get yourself stuck with it. “It may be a bug!” But it may not! First thing: you Google over it. You research the discussion forums and mailing lists. You research the bug tracker site (if the project has one). Then, after a lot of researching you realized that it is an undocumented bug. Second step, you make sure it is a bug and are not using the product in the wrong way. You build tests. You debug it. You think twice.

Once you have done all that and know it is a bug, you go to step three and see if it is something you think you’re able to fix. Either way, you ask the community about it, if no one knows anything about it, you file in a bug ticket. Now you can wait for a fix or, if you really want to contribute, you post all details about the bug, all your debug information and, hopefully either fix it yourself or ask for someone else, more experienced, to fix it.

It’s a very organic process and it become second nature to every non-passive programmer reasonably fast. The important thing is to understand that no good programmer lives in isolation: the internet is a living and breathing world-wide community that you must be a part of, in order to become a respectable and good programmer.


So, you are a beginner programmer. Welcome to the Programming field. There are lots of exciting new things for you to explore and learn. It is even more exciting because it has no defined goal, no finish line, no end at all. You will never get bored because it is ever changing. You can learn at the very least, one new thing every single day.

You can and should socialize with other experienced programmers. Join communities. Read good books. This is a wonderful craft that can be very rewarding once you get yourself really started.

Understand that there is no such thing as a ‘perfect software’ or ‘bug free software’. You will make mistakes, lot’s of them. And that is okay as far as you recognize them and learn from your mistakes. It is not how many mistakes you make, it is how many of them do you repeat over and over. It is how prepared you are to handle mistakes. There is no such a thing as a ‘perfect painting’. An artist is always tweaking his own skills. That’s what we do.

Good luck, Paresh.

Thank you Fabio. In case you have any queries, questions on this article, kindly post your questions here and Fabio would be glad to answer.

Update: Participate in the discussion at DZone.

Technorati Tags: , , , ,

comments powered by Disqus