How to contribute to Ruby on Rails

A Ruby on Rails open source contribution guide for beginners. A summary from Open Source Thursdays Expert Session with Rafael França.

This post is a summary of the Open Source Thursdays - Expert Session with Rafael França. Learn how to get started, how to fix a bug, navigate the Ruby on Rails codebase and contribute to Open Source projects as a beginner.

Are you looking for an opportunity to get more experience as a Ruby on Rails developer? Make meaningful connections with the community? Learn the best practices on how to maintain a large codebase?

What if you could get that experience by contributing to an open source project like Ruby on Rails?

If that sounds scary, don’t worry! We can help you!

By the end of this post, you’ll learn 5 ways to become a new Rails contributor, even if you are a beginner in Ruby. Plus, you will find answers to the some questions you probably have.

Are you ready? Let’s go!

5 ways to contribute to Ruby on Rails as a beginner

1 - Find issues labeled as “good first issue”

These are labeled as Good First Issue. There’s not a lot of them and they can get closed pretty fast! They might not be simple for beginners in Rails. Note that you can always ask for help in the issue comments or in the Rails forum.

2 - Pick an issue labeled as “With reproduction steps”

Issues labeled as With reproduction steps candidates because you have a way to check that the bug really exists. You can fix the bug and use the reproduction steps to check your work.

By following this method, we were able to get our second PR merged. It works!

What if the issue cannot be reproduced?

Sometimes, the issue cannot be reproduced by other people. If you’re able to confirm it, explain why and let the maintainers know. That’s another great way to contribute to the project, as it may show that it’s not a bug on the Ruby on Rails codebase, but something unrelated.

To give you an example, one of our readers (Aish) found out that this issue could not be reproduced, created a video, and shared this information as a comment on the issue. This contribution helped the maintainers close it.

3 - Fix the bugs you find yourself (“your bug”)

When you’re working on a Ruby on Rails app, you might run into a framework bug. That’s good, now you can fix the bug yourself! This can happen when you’re using the latest version of the framework, or using one of its newer features.

4 - Add reproduction steps to new issues

You can pick an issue that does not have reproduction steps. Try to understand what’s going on, and then add the reproduction steps yourself. This way, you can help the Rails core team by checking if a new issue is valid. Great way to build your debugging skills!

5 - I’m ready to contribute to Ruby on Rails!

You can always pick any open issue (that no one else is working on) and try to figure things out as you go. That’s cool too! Just pick one and get to work. Have fun!

Get the PDF with all the steps 👈

5 ways to contribute to Ruby on Rails as a beginner

5 ways to contribute to Ruby on Rails as a beginner

Highlights from the Open Source Thursdays Session with Rafael França

Rafael França is a Rails Core team member and he shared some tips for people that want to contribute to Ruby on Rails.

Do you want to know how Rafael became a Ruby on Rails expert and one of the top Rails contributors? You can learn all about his strategies on Get to Senior. You will also get exercises to practice your skills!

Below, you can find his answers to some of the questions asked by the community during the live stream.

Would love to get started contributing to the Rails project but don’t know where to start?

Question: [at 8:13] Would love to get started contributing to the Rails project but I don’t know how. How should I do it?

Don’t know how to suggest a new feature? Open an issue in the Rails repository or post a topic on the Rails forum?

Question: [at 19:23] If I want to suggest a feature, should I open an issue in the Rails repository or post a topic on the Rails forum?

How can we get feedback on ongoing issues and Pull Requests more quickly?

Question: [at 54:58] Often getting a response for a contribution takes weeks. How can we effectively get feedback on ongoing issues or Pull Requests?

Rails is maintained by volunteers and most of them work on it during their free time. So it might take some time. Ask or comment on the issue or PR to get an answer.

If it’s a Pull Request, you can post the link on Rails Forum to bring attention.

Before you ask for feedback or code reviews, it’s a good idea to make sure that:

  • tests are passing
  • documentation is updated
  • if it’s an bug/issue, can you try to fix it yourself?
  • if you don’t know how to fix the code, can you write a Reproduction Script or create Reproduction Steps?
  • make it easier for people to accept your PR: give them the code, Reproduction Steps, that the code consists of a small number of code changes
  • explain and add details so reviewers can understand the impact of your changes: does it affect all Rails applications or only some of them?

The whole point is to make it easier for reviewers to accept your changes.

Issues and PRs that follow these guidelines grab more attention than the ones that don’t have a lot of feedback, no comments, tests are broken, and the Rails team doesn’t know if the concept is good or not.

Which part of the Ruby on Rails project is the best for a beginner to get started with? Changing the Rails Guides or Documentation, Active Record, or something else?

Question: [at 59:15] Which part of the project should I work on first: Rails Guides & Documentation, Active Record, Action Mailer, or something else?

What if there is someone else already working on the issue?

Question: [at 1:04:36] How can I know if there is someone else already working on the issue, and what should I do if that happens?

How do you know if you should run all tests or just some of them?

Question: [at 1:07:39] How do I know if I need to run all Rails tests or just some of them?

Download our FREE How to contribute to Ruby on Rails Guide for getting started today

If you’re ready to commit to your RailsConf resolution – for real, this time! – just drop your email address in the box below:

The lessons are tips from our experience with contributing to Ruby on Rails for the first time on the Open Source Thursdays sessions. And our sessions with Rails experts, such as Rafael França, Aaron Patterson (tenderlove), and Chris Oliver.

Grab your copy to get started with actionable strategies that you can follow – in less than 2 hours per week.