First GitHub Repository

I’ve been hacking code for many years now but have never considered myself to be a real software developer, despite having built apps in a variety of languages. Over the last couple of years I’ve enjoyed hacking away at Python and have created many websites, apps, and scripts but never really published them.

I just published my first GitHub repository with a Python script to retrieve the latest spot price from the Flick website for our account. Flick have been promising to release an API for years but have yet to deliver anything, so my script uses Requests and BeautifulSoup to scrape the spot price from the Flick dashboard.

When first run, the script prompts for your credentials and saves them to a file on your disk so that the script can be run without interaction in the future. And when you first successfully authenticate it will save your cookies to a file to avoid having to reauthenticate each time it runs. The spot price on the Flick website is updated every half hour, so the script will save the current spot price to disk as well as the end date time which indicates when the next website update will be. Then the script can be run as often as you like but it will only ever go to the website once while that price is valid.

I created the script so that I could retrieve the spot price and integrate it into my HomeAssistant installation. I plan to do further automation based on the current spot price but for now I’m just sending myself a Telegram notification when the price changes.


A short history of airport security

A short history of airport security: We screen for guns and bombs, so the terrorists use box cutters. We confiscate box cutters and corkscrews, so they put explosives in their sneakers. We screen footwear, so they try to use liquids. We confiscate liquids, so they put PETN bombs in their underwear. We roll out full-body scanners, even though they wouldn’t have caught the Underwear Bomber, so they put a bomb in a printer cartridge. We ban printer cartridges over 16 ounces — the level of magical thinking here is amazing — and they’re going to do something else.

Bruce Schneir via A Waste of Money and Time – Room for Debate –