The Ruby and Rails community linklog
Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!
Submit a post
Note: Only the first pargraph is shown on the front page and overly long paragraphs may be broken up.
Ruby 2.6 will be released with support for a new syntax denoting an endless, infinite range: https://medium.com/square-corner-blog/rubys-new-infinite-range-syntax-0-97777cf06270
Have you ever tried to pull the information from the social profile using given URL? Configuring the API access may be a time-consuming and difficult thing to do. On the other hand, scraping a profile may be not as easy as it seems to be. To solve that kind of problems I created the Hawker gem. READ MORE
I personally prefer small classes, short, single purpose methods over the one big piece of code. Having said that I have to admit that this approach has a significant downside - methods are short quite often because internally they call other methods, which call other methods, which call other methods… Let’s look at another approach to writing your Service Objects https://bpohoriletz.github.io/2018/04/20/two-levels-deep-service-objects.html
Learn about patterns that can help you use factories more effectively with examples based on Ruby’s FactoryBot: https://semaphoreci.com/community/tutorials/working-effectively-with-data-factories-using-factorybot
want to get into machine learning? Follow along in this short post on how to implement linear regression in ruby. Expect some math, a few terminators and most importantly, ruby code: https://medium.com/@oem_83498/linear-regression-in-ruby-a170f9a892e5?source=linkShare-c59519c86fc7-1524163748
We’ve compiled a list of the top 10 errors from more than 1000 Ruby on Rails projects in production. We’re going to show you what causes them and how to prevent them from happening. If you avoid these “gotchas,” it’ll make you a better developer. [more inside]
NameError is raised when you reference a constant or a variable which isn’t defined in the current context. See code examples and learn how Ruby 2.3+ helps you debug NameError.
Turns out running a company isn’t just about money, fame or even cool products and happy customers. We have a social responsibility towards our employees and society at large: https://blog.phusion.nl/2018/04/19/whos-responsible-for-the-software-we-build/
There are a few articles out there about how to find memory leaks. But do you know what a memory leak looks like? http://www.rubyguides.com/2018/04/ruby-memory-leak/
Great talk from Jeremy Evans at Isle of Ruby this last week: https://www.youtube.com/watch?v=2Rm7wLNmsco
Useful for accessing Python standard libraries, and re-using code already written in Python without having to port it to Ruby: https://readysteadycode.com/howto-execute-python-code-with-ruby
In this interview with Julien Lemoine of Algolia, he discusses how his team uses microservices to provide product teams with the resources & tools they need to create fast, relevant search using a powerful hosted search engine API.
Threads are hard to work because when they die then , by default, we don’t get much info. This new feature in ruby 2.5 would provide us more info when threads die due to an uncaught exception. Originally this feature was discussed 6 years ago. Read on to see why it took so long. [more inside]
The first part of a quick guide how to build a full-stack app in Sinatra from Rails developer’s perspective: READ MORE
Several of the Isle of Ruby talks were sneakily recorded unofficially by yours truly - the first here is my talk (intro starts at 1:50) https://www.youtube.com/watch?v=Qf0S29bJbPg
Want your Rails performance KPIs (response time, throughput, error rate, time-in-queue, etc) in your DogStatsD-compatible metric system with almost zero effort? Try the
scout_dogstatsd automatically instruments your web + background jobs, sending metrics to systems that support the DogStatsD protocol (like DataDog).