ruby-lang.org

Ruby 3.0 introduced a breaking change in how it treats keyword arguments. There is an excellent blog post on the...

github.com

When handling nested hashes the RSpec output is often hard to read. Here the gem super_diff could help.

We had a card that described how to install multiple mysql versions using mysql-sandbox. Nowadays with the wide adoption...

...the puppetdb_query feature. This can result in more complex code but has several benefits: you can use more complex puppetdb queries to get the resources you want than with...

makandra dev
github.com

...large number of ActiveRecord objects only to collect its ID. Edge Rider has a better way. Your relations gain a method #collect_ids that will fetch all IDs in a...

...number of ActiveRecord objects only to collect its column value. Edge Rider has a better way. Your relations gain a method #collect_column that will fetch all column values in...

makandra dev
tpgi.com

These are the top ten accessibility errors as researched by TPGi, a company focusing on accessibility. See the linked article...

When using Chrome for Selenium tests, the chromedriver binary will be used to control Chrome. To debug problems that stem...

In Capistrano 3, your Capfile requires 'capistrano/rails/migrations', which brings two Capistrano tasks: deploy:migrate and deploy:migrating. The former checks...

DirectUpload allows you to upload files to your file storage without having to wait for the form to submit. It...

makandra Curriculum

We've already learned how to integrate user-provided images uploads to our application in 205 basic file uploads and...

docs.gitlab.com

The owner of a scheduled CI/CD pipeline in GitLab will always be notified if the pipeline fails. Follow these steps...

makandra dev

...installation supports YJIT, by running: $ ruby --yjit -v ruby 3.3.4 (2024-07-09 revision be1089c8ec) +YJIT [x86_64-linux] If YJIT is not available, the output of this command will...

...time of queries. While they serve similar purposes they do have some differences in behavior and implementation. PostgreSQL Timeout Type: statement_timeout Scope: Applies to all types of SQL statements...

...INSERT, UPDATE, DELETE). Units: Can be specified in various time units (milliseconds, seconds, minutes). Behavior: If any statement exceeds the specified timeout, PostgreSQL raises an error indicating the statement was...

If you use third party APT sources you might end up with unmaintained packages after removing the external source or...

When you don't only have a favicon.ico in your project but also PNGs of different sizes and backgrounds, you...

...use version 5.2.0 or newer to ensure you can deploy via Capistrano. It's best to use the latest version, as there were multiple issues between 5.2.0 and 7.3.0.

blog.saeloun.com

Rails' fragment caching caches subtrees of an HTML document tree. While constructing that tree though, it can be really hard...

If your app does not need to support IE11, you can use most ES6 features without a build step. Just...

makandra Curriculum

How to write an issue Issue format Read the card Project management best practices: Issues. Gatekeeping Get familiar with our Gatekeeping process. In particular you should understand the...

...you obviously do not want to duplicate it and your tests might very well benefit from this approach. Use it with care, however -- doing this more than a few times...

...making the test impossible to read). An alternative is also to hide that functionality behind other steps that do more complex things differently...

By default subscript ( ) and superscript ( ) tags are styled with vertical-align: sub, respectively vertical-align: super by most browsers.

When you find similar groups of expect calls in your tests, you can improve readability by extracting the group into...

...intensive for large files Other ways to solve this problem Other solutions might work better and make more sense depending on what you are trying to achieve. These alternatives could...

makandra dev

Knowing when to refactor Just feeling like refactoring is not a good reason to do it. Make an educated decision...