Toucan2 uses a derive-based hook system rather than explicit method implementations. You declare behavior by deriving your model from special hook keywords.
Investigated suspected memory leak in metabase.util.malli.registry/cache
atom. Initial reports suggested unbounded memory growth during test runs.
The real issue wasn't a memory leak, but fundamentally broken caching for function schemas. With the original schema-cache-key implementation, schemas containing function objects generated unstable cache keys because:
(fn [x] ...)
creates new function objects each time
Function objects have different identity even with identical code
This caused cache misses for functionally identical schemas
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns mage.escherize.analyze-cache-misses | |
(:require | |
[clojure.edn :as edn] | |
[clojure.java.io :as io] | |
[clojure.string :as str] | |
[mage.util :as util])) | |
(defn read-log [log-file] | |
(map second (edn/read-string (str "[" (slurp log-file) "]")))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://gist.github.com/escherize/24e99c1ad6bd6bab2971d520093c2470 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns src.dev.nocommit.malli-match | |
(:require | |
[malli.core :as mc] | |
[clojure.set :as set] | |
[clojure.string :as str] | |
[clojure.walk :as walk])) | |
(defn underive-children [tag] | |
"Remove all children of the given tag." | |
(let [children (descendants tag)] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
brew install --cask google-chrome zoom spotify vlc libreoffice iterm2 visual-studio-code && \ | |
brew install git curl htop zsh-autosuggestions neofetch && \ | |
RUNZSH=no KEEP_ZSHRC=yes sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
env MB_FUZZ=1 yarn test-unit frontend/src/metabase/querying/expressions/fuzz.compiler.unit.spec.ts | |
yarn run v1.22.22 | |
warning ../package.json: No license field | |
$ yarn build:cljs && jest --maxWorkers=4 frontend/src/metabase/querying/expressions/fuzz.compiler.unit.spec.ts | |
warning ../package.json: No license field | |
$ yarn && yarn build-pure:cljs | |
warning ../package.json: No license field | |
$ echo $npm_execpath | grep -q yarn || echo '\033[0;33mSorry, npm is not supported. Please use Yarn (https://yarnpkg.com/).\033[0m' | |
[1/5] 🔍 Validating package.json... | |
[2/5] 🔍 Resolving packages... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns mage.color | |
(:require | |
[clojure.string :as str] | |
[clojure.walk :as w])) | |
(def ^:dynamic *disable-colors* | |
"If set to true, all color functions will return the input string as is." | |
false) | |
(def ^:private reset |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name GitHub Rerun Failed Jobs (Manual Trigger + Watcher) @escherize | |
// @namespace http://tampermonkey.net/ | |
// @version 0.7 | |
// @description Manually trigger a watcher to auto re-run failed GitHub Actions jobs | |
// @match https://github.com/*/*/actions/runs/** | |
// @grant none | |
// ==/UserScript== | |
(function () { |
We can't make this file beautiful and searchable because it's too large.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
key,value | |
T_z91R4pacr4kSSydTsXo,41wkQWuMn5EBP6k6hWhKB | |
JArUob2NhnNa-4Jv9_bRy,C4Z-dJvHread0V5c8N7hg | |
KfzzjB8rw7cLLOuvVxHzX,Hspx2RfhJaiHxBQlGHZuE | |
j56IhWzlfqt09KgDeTeuD,rN23PO0V7XzT1_l68Gzsw | |
0GQKgaGekPIycszgx-nZ-,-rHxNeFn0lG_6M5UDL50F | |
yDJ5XrWefj9cL5d_t5mc3,R2DrTvbQNpW_Ws_mUQRfA | |
T5RmeXxDNbUq7pQRSbm4Z,1zx-2ZnIbu_QBw6eIo9y8 | |
WvELUjxO-rSMBe7nTWXUX,_TFhw1iLSj_xzfNnpZ63z | |
eFB8Dk-5wDY1OWZzJk2NS,6KszXL2RTn-MjwE4T28EX |
NewerOlder