SSL/TLS - Typical problems and how to debug them

Common TLS failures can block secure connections and are often hard to diagnose. Typical symptoms point to certificate, protocol, or handshake issues and debugging clues help narrow them down.

RSpec < 2.11: ActiveRecord scopes must be loaded before using the "=~" matcher

ActiveRecord scopes must be converted to arrays before using RSpec =~, or array comparison can fail. match_array and contain_exactly are preferred in RSpec 2.11 and later.

Default Arguments and Memoized

Memoizing methods with default or keyword arguments can freeze evaluated defaults and treat omitted arguments differently from explicit default values.

Using multiple MySQL versions on the same linux machine using docker

Run several MySQL releases on one Linux host with Docker instead of mysql-sandbox, and connect Rails to each instance through a separate TCP port.

CarrierWave: When your uploader generates filenames dynamically, use model.save! instead of uploader.recreate_versions!

Dynamically generated CarrierWave filenames can leave versions out of sync; uploader.recreate_versions! does not persist the stored name, so model.save! is needed.

CSS: How to force background images to scale to the container, ignoring aspect ratio

Background images can fill a container without preserving aspect ratio by setting background-size: 100% 100%. SVG viewBox can still lock proportions.

Setting SASS variables as value for CSS custom properties

SASS variables can be interpolated into CSS custom properties with #{...}; otherwise the literal variable name is emitted. meta.inspect() preserves quotes for string values such as font stacks.

Headless Chrome: Changing the Accept-Language header is not possible

Headless Chrome on Ubuntu cannot reliably change Accept-Language through Selenium options; test code can override the header in Rails instead.

Selenium: Network throttling via Chromedriver

Throttle headless Chrome network conditions in Selenium to debug flaky integration tests and simulate slow page loads.

List of Chromium Command Line Switches « Peter Beverloo

Extensive Chrome startup options help build custom browser drivers and automate testing with Capybara.

Yarn: if integrity check won't let you start rails console

Yarn integrity warnings can block rails console even when packages are current; stale Spring cache may keep the error until spring stop clears it.

Ruby: required keyword arguments in the pre-2.1 era

Required named parameters were not available in Ruby 1.8; a hash-based fallback can enforce mandatory options before Ruby 2.1 keyword arguments.

How to avoid raising RestClient exceptions for 4xx or 5xx results

RestClient raises on expected 4xx and 5xx responses, but a block can return the RestClient::Response instead of throwing exceptions.

Die Grenzen von SEO: was Suchmaschinenoptimierung nicht ist

Suchmaschinenoptimierung ist eine Querschnittsfunktion mit Einfluss aus vielen Abteilungen; entscheidend ist die Abgrenzung, welche Aufgaben wirklich zu SEO gehören und welche nicht.

Don't use migrations to seed default data

Seeding rows in a Rails migration breaks tests that expect an empty database and creates maintenance pain. Use db/seed.rb or a script in lib/scripts for default application data.

GitHub Actions: Manually running a workflow

Manual workflow runs in GitHub Actions require workflow_dispatch; eligible workflows then appear in the Actions tab with a Run Workflow button.

GitHub Actions: Retrying a failing step

Flaky commands in GitHub Actions can fail intermittently; nick-invision/retry reruns them with a timeout and limited attempts.

Find an ActiveRecord by any column (useful for Cucumber steps)

Finds a record by any string or number across columns, making Cucumber step definitions more flexible. The bang variant raises ActiveRecord::NotFound when nothing matches.

Undefined method log for Selenium::WebDriver::Remote::W3C::Bridge

Integration tests can fail with undefined method log on Selenium::WebDriver::Remote::W3C::Bridge after enabling Selenium W3C mode; upgrading Capybara restores browser log access.

Upgrading Capybara with deprecated Integer selectors

Capybara warns when selector locators are integers instead of strings or symbols, often in pagination links and numbered clicks.

Geordi 6.0.0 released

Geordi 6.0.0 keeps geordi commit running when some projects are inaccessible and drops VNC browser support and @solo serial execution.

Chromedriver: Disabling the w3c option might break your integration tests with Chrome 91

Chrome 91 can break Selenium integration tests when w3c is disabled, changing input values to nil and causing unexpected assertion failures.

RubyMine / IntelliJ: How to increase UI and fonts for presentations

Larger fonts and scaled UI make coding readable during presentations on smaller screens or low-quality connections. RubyMine supports Presentation Mode and manual zoom settings.

Capistrano: Speeding up asset compile during deploy

Reducing Capistrano deploy time by persisting asset compiler caches across releases can skip repeated Sprockets or Webpacker work. esbuild has no comparable cache directory.