📝 Docker's "failed to register layer" error on macOS/OrbStack.
failed to register layer: rename /var/lib/docker/image/overlay2/layerdb/tmp/write-set-xxx /var/lib/docker/image/overlay2/layerdb/sha256 /<sha>: file exists
Nesting APIs and ReaderT environments in Haskell's Servant
Environments, from parent to child (or base to extended):
App (ReaderT AppEnv IO):
HasLogFunc envHasDatabase envHasTracing envAppAuthenticated (ReaderT AppAuthenticatedEnv IO):HasApp env (everything from App)| {-# LANGUAGE GHC2021, FunctionalDependencies, AllowAmbiguousTypes, OverloadedRecordDot, BlockArguments #-} | |
| module Lib where | |
| -- Code accompanying https://prophetlabs.de/posts/insttypes.html | |
| import qualified Data.Map as Map | |
| import Unsafe.Coerce | |
| import Data.Proxy |
| trait Interp { | |
| type Repr<T>; | |
| fn lit(i: i32) -> Self::Repr<i32>; | |
| fn add(a: Self::Repr<i32>, b: Self::Repr<i32>) -> Self::Repr<i32>; | |
| } | |
| struct Eval; | |
| impl Interp for Eval { |
| {-# language FlexibleInstances #-} | |
| {-# language TypeFamilies #-} | |
| {-# language FlexibleContexts #-} | |
| module Main where | |
| import Streamly | |
| import qualified Streamly.Prelude as S | |
| import Control.Applicative | |
| import Control.Monad.Logic | |
| import Data.Foldable |
blah blah blah more things here
From my experience fundraising in Haskell, companies who use it all seem to have suffered from the same two flavors of problem:
A rockstar comes in, dumps mindblowing code everywhere that dazzles the rest of the team and fools the product leads with pseudo-productivity until the rockstar leaves or finally wakes up. Cue the rest of the team death-marching for the next year or few years as the team attempts to juggle feature additions with excising or unraveling the impenetrable yarn-tangle of semantic misdirection.
An especially productive senior or team lead spends their time on refactoring and generally spinning their wheels with respect to product delivery, and then fails to deliver on time, or at all. Cue the rest of the team struggling to keep up with the refactors. The team's knowledge of the state of the product suffers, confusion about goals sets in, the senior/lead effectively becomes an anti-team player, throwing curveballs at the rest o
This recipe is a work in progress and has never been run as-is.
| #!/bin/bash | |
| # Copyright © 2017 Google Inc. | |
| # Licensed under the Apache License, Version 2.0 (the "License"); | |
| # you may not use this file except in compliance with the License. | |
| # You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 | |
| # | |
| # Unless required by applicable law or agreed to in writing, software |
| {-# LANGUAGE DataKinds #-} | |
| -- | My database API. | |
| module DBAPI where | |
| import Data.Defaults | |
| data ConnSpec p = ConnSpec | |
| { username :: !(Required p String) |