Some things I read in the first half of 2023

I read and Consumed™️ a number of things the first half of 2023. Let me detail some of them:

  • Braiding Sweetgrass by Robin Wall Kimmerer helped me reconcile disillusionment and frustration I had with academic science, and to help me appreciate different philosophies of thought.
  • The Magicians by Lev Grossman is a grounded examination of the fantasy genre within a well-fleshed fantasy world. If "Houlden Caulfield seeks Narnia but goes to Hogwarts" sounds interesting, then check this out.
  • This is How You Lose the Time War by Amal El-Mohtar and Max Gladstone is a short story about star-crossed lovers from two advanced, warring, timeline-hopping scifi empires. I didn't like it that much, but it was 200 pages and fun to read.
  • The Before Me podcast series is a well-constructed narrative built around interviews with the narrators mother, who arrived to America fleeing the Khmer Rouge in Cambodia. It's worth a listen.
Read more  ↩︎

❖◈◆◈❖

❖◈◈❖

Caddy: How to Opt out of Chrome Topics API

TLDR: Set the following in your caddyfile for each site: header Permissions-Policy "interest-cohort=(),browsing-topics=()". This disable both the old FLoC and the new Topics.

Here is an abbreviated version of my Caddyfile, showing how I set the header directive in my Caddyfile for lynndotpy.xyz:

lynndotpy.xyz {
  header {
    Permissions-Policy "interest-cohort=(),browsing-topics=()"
  }
}

To confirm the header is set, you can use a Firefox or Chrome's devtools, open the networking tab, and look for the Permissions-Policy response header. More context below the cut.

Read more  ↩︎

❖◈◆◈❖

❖◈◈❖

If BlueSky takes off, Bitcoin will too

TLDR: BlueSky is intended to eventually integrate with Bitcoin. If BlueSky becomes widely adopted, Bitcoin will too. I don't like Bitcoin, so I don't want BlueSky to become popular.

Here's why I believe this: In 2019, Jack Dorsey was an early adopter of Bitcoin Lightning network. After helping kickstart the Lightning network, Jack announced BlueSky, emphasized the importance of blockchain protocols, and later promised to integrate BlueSky into the Bitcoin Lightning network.

Jack Dorsey's "BlueSky" platform is taking off. Unfortunately, not only is Jack Dorsey a bonkers man who endorses the belief that Jimmy Carter cried when he learned that aliens made up all the religions^1 and is on a big pro-RFK Jr^2 streak, but he also is a longtime Bitcoin believer.

Read more  ↩︎

❖◈◆◈❖

❖◈◈❖

protip.py: the main-main pattern

TLDR: Your Python program will be better if you define a main() function separate from the __main__ block.

Consider a Python program leftpad.py, which takes an input string (say, trans rights), and pads it to the left (so, python leftpad.py -s 'trans rights' -n 16 prints ' trans rights'.)

This is a great way to structure it:

# leftpad.py
import argparse

# leftpad function in global scope can be imported
def leftpad(string, num_chars):
    if len(string) >= num_chars:
        return string
    else:
        pad = ' ' * (num_chars - len(string))
        return pad + string

parser = argparse.ArgumentParser()
parser.add_argument("--string", "-s", type=str, nargs=1)
parser.add_argument("--num","-n", type=int)

if __name__ == '__main__':
    args = parser.parse_args()
    print(leftpad(args.string[0], args.num))

The main functionality and the parser can be imported as leftpad.leftpad(...) and leftpad.parser. These could not be imported if __main__ had the definition for leftpad and the instantiation of parser.

Here's a template you can use for your Python scripts:

import sys

def main():
    try:
        return 1
    except:
        return 0

if __name__ == '__main__':
    sys.exit(main())

Let me explain why this is good, how it could be worse, and how it could be better.

Read more  ↩︎

❖◈◆◈❖

❖◈◈❖

Opt out of Discord's arbitration clause by sending a quick email. (Template included)

TLDR: Send an email to arbitration-opt-out@discord.com using the email associated with your Discord account. For good measure, add your username. Template below!

(btw, i'm not a lawyer and i'm not your representative)


Update: Want to opt out of arbitration for more services? I'm building a collection of arbitration opt-out templates here: github.com/lynnpepin/arbitration-opt-out-templates. Check them out and let me know what you think.


You can opt out of Discord's arbitration clause by sending them an email

Send an email to arbitration-opt-out@discord.com, from the email address you use for your account, stating you wish to opt out of the arbitration clause. For good measure, I recommend adding your account ID!

Read more  ↩︎

❖◈◆◈❖

❖◈◈❖