Tested on macOS Sonoma Developer beta 2 (23A5276g)
- Download openssh-portable source code, install
libcrypto
,libfido2
; - Configure openssh-portable build system by
./configure # [options]
.
myMac.domain.com
sudo scutil --set HostName <new host name>
package main | |
import ( | |
"crypto/tls" | |
"encoding/json" | |
"fmt" | |
"log" | |
"net" | |
"net/http" | |
) |
#!/usr/bin/env bash | |
# Colours picked from https://robinpowered.com/blog/best-practice-system-for-organizing-and-tagging-github-issues/ | |
### | |
# Label definitions | |
### | |
declare -A LABELS | |
# Platform |
My largest Sidekiq application had a memory leak and I was able to find and fix it in just few hours spent on analyzing Ruby's heap. In this post I'll show my profiling setup.
As you might know Ruby 2.1 introduced a few great changes to ObjectSpace, so now it's much easier to find a line of code that is allocating too many objects. Here is great post explaining how it's working.
I was too lazy to set up some seeding and run it locally, so I checked that test suite passes when profiling is enabled and pushed debugging to production. Production environment also suited me better since my jobs data can't be fully random generated.
So, in order to profile your worker, add this to your Sidekiq configuration:
if ENV["PROFILE"]
#!/usr/bin/env python | |
import sys | |
import urllib | |
import urlparse | |
import base64 | |
import mimetypes | |
import cgi | |
from os import path |
This is what we did to setup a few dashboards at platanus
# assuming your subject is the UsersController with a method user_params | |
describe UsersController do | |
describe "params" do | |
# per default the matcher extracts the subject and params method | |
it { should permit_params(:email, :name, :role) } | |
# to overwrite the params method use explicit .params_method() | |
it { should permit_params(:first_name, :last_name).params_method(:other_user_params) } | |
defmodule Life do | |
def run(board) when is_binary(board) do | |
board |> parse_board |> run | |
end | |
def run(board) do | |
IO.write("\e[H\e[2J") | |
Life.print_board board | |
:timer.sleep 1000 | |
board = next_board(board) |