Rails upgrades can be done in many different ways. Depending on the application that you want to upgrade, some ways make more sense than others. There are factors that determine which Rails upgrade strategy is the best for your case, like how big your application is, or how frequently changes are pushed to the master branch. In this article I’ll be covering two common Rails Upgrade strategies so you can decide which one is the best for your application.
Read moreWe all know testing is important. We have our unit tests and integration tests to make sure everything is working as expected. At OmbuLabs, we use Capybara for our integration tests so that we can interact with the app as a real user would.
This is the process we used to replace the capybara-webkit
gem in a legacy project with a more modern approach that uses the webdrivers
gem and a headless browser.
Churn vs. Complexity analysis is a great way to find insights about the maintainability of a project. Two of my favorite authors have written great articles about the Churn vs. Complexity graph:
- Getting Empirical about Refactoring by Michael Feathers
- Breaking up the Beheamoth by Sandi Metz
This two-dimensional graph can be very useful in finding the files that are the hardest to maintain in your application. In this article I will explain:
- How you can calculate these metrics and use them in your legacy project
- How code coverage metrics can guide your technical debt’s collection efforts
Deprecation warnings are a common thing in our industry. They are warnings that notify us that a specific feature (e.g. a method) will be removed soon (usually in the next minor or major version) and should be replaced with something else. Features are deprecated rather than immediately removed, in order to provide backward compatibility (a solution that works in both the current and the future version), and to give programmers time to implement the code in a way that follows the new standard.
In this guide we’ll show you what the workflow is that we use at FastRuby.io to address deprecation warnings when we upgrade Rails applications.
Read moreWe know that there are many challenges involved in a Rails upgrade project. Depending on how big your application is, how old your Rails version is and how well structured your code is, it can be difficult to perform that job and keep your sanity. If you don’t find a reliable and trustable process to guide you from version X to version Y, you can end-up in a nightmare.
The good news is that here at OmbuLabs, we have been upgrading Rails applications for over 10 years now and this gave us a know-how to define a process that has proven to be very effective. And today I want to share Our Rails Upgrade Process with you.
Read moreThere are some really great guides for starting a new open source projects, yet when it comes to dealing with a possibly abandoned, unmaintained project, there is no definitive guide for users, contributors, or maintainers.
I hope that this can be a useful guide for our community.
Problem
When do you declare that an open source project has been abandoned? How many
days have to go by until you start maintaining your own fork? What’s the
standard for communicating with maintainers, contributors, and users? How do
you avoid n
competing OSS forks of popular projects? How do you avoid
duplicated work by people who want to maintain popular, but unmaintained OSS
projects? What’s the best way to find that one fork everybody is using?
Right before my talk at RubyConf Australia,
I worked on a way to make it easy for anyone to run skunk
in their Ruby projects. In order to do that I decided to use GitHub Actions.
It’s a powerful service by GitHub and it’s quite easy to set up.
This article is about the process that I followed and how you can use it in your own application.
Read moreAt OmbuLabs we like to follow a style guide to drive our own products. A style guide is a document that provides guidelines for the way your brand should be presented from both a graphic and language perspective. You can see FastRuby.io’s style guide at this link.
Since we have a few applications in place and it’s important to make sure that they all use the same style, we need to ensure that they will all inherit the same CSS files. One way to do this is to copy the above style guide and paste it inside all of our apps, but this would end up causing a lot of duplicated code. If we decided to change the font-style, for example, we would need to change it in all apps individually.
Something else we are super fans of at OmbuLabs is to follow good code and development practices. One of our favorites is the DRY (Don’t Repeat Yourself) principle, which states that duplication in logic should be eliminated via abstraction. So to avoid the duplicated code here, we decided to create a gem to encapsulate our style guide and to be bundled in all of our products.
In this article, I’ll show you how we did it!
Read moreTechnology evolves quickly. When you first created your Rails application, it’s likely you did it using the latest version of Rails. As time passes, however, new Rails versions come out and your application becomes more and more out of touch with the latest version. But why is this important? Why does it matter?
There are several different reasons to upgrade your Rails application. In this article, I’ll list what we consider to be the most important ones.
Read moreMigrating from Protected Attributes
to Strong Parameters
in a Rails project can be a huge step of the upgrade process. Especially when we are upgrading a large application. This guide is meant to help you tackle that step faster and with a lot less pain.
This year I had the honor to speak at RubyConf in Nashville.
It was my second time attending the conference and first time as a speaker. I
talked about skunk
, a gem to calculate the SkunkScore
of a module or set of modules.
Since its inception, skunk
has changed quite a bit based on real usage in
our productized service for Rails upgrades. As a matter
of fact, the night before my talk I realized there was a BIG error in our
formula.
Here is a description of the problem and solution.
Read moreAs part of our Roadmap service at FastRuby.io, we analyze the test suite of the application we are auditing to give a proper estimate on how long it will take us to upgrade. One of the tools we use for this is SimpleCov.
Often times our clients use parallelization in their continuous integration tools. SimpleCov generates multiple .resultset.json
files for the same codebase. However, our goal is to have a single .resultset.json
for the whole application. In this blog post we are going to show you how we solved the problem.
We recently collaborated with Amitree on a Rails upgrade for their application which “is an AI assistant for email, integrated deeply within Google and Microsoft’s products and is in heavy use by real estate professionals” and were able to speak to them about their experience with OmbuLabs.
Read moreTwo weeks ago I had the opportunity to speak at Solidus Conf 2019. I presented Escaping the Tar Pit for the first time and I got to talk about a few metrics that we can use to quickly assess code quality in any Ruby project.
In this article I’d like to talk about Skunk: A SkunkScore Calculator! I’ll explain why we need it, how it works, and the roadmap for this new tool.
Read moreEvery time we evaluate a new project we follow a well-defined process to decide whether we take it or not. We analyze its dependencies; its code coverage; and its code quality to determine the amount of tech debt in a project. We have been using CodeClimate to assess code quality and SimpleCov to assess code coverage.
In my previous article I wrote about free and open source Ruby gems we can use to assess code quality for any Ruby or
Rails project. After writing that article, I found that RubyCritic
was really interesting and its community quite active, so I thought it was a good
idea to add SimpleCov
support to it: https://github.com/whitesmith/rubycritic/pull/319