I'm currently working on a self-hostable wish list app using FastAPI so we can finally drop Amazon forever. (The lists funcionality has been super handy for sharing holiday gift ideas with the famj!) FastAPI FastAPI is an amazing framework for quick ... read more →
I just started using FastAPI for a home project and needed to pass back a dynamic number of values from a form rendered with jinja... Dynamic Values The jinja templating for rendering HTML based on something like a python iterable is nice and easy ... read more →
If you use vim-plug for managing your vim plugins, do yourself a favor and snapshot your plugins before upgrading! :PlugSnapshot creates a vim.snapshot file that you can use to restore your plugin versions with vim -S snapshot.vim The snapshot file ... read more →
TODO title = "my Title" eval('"my" in title') >>> True print("hello, world"); print("formatting") read more →
TODO import os import boto3 import pytest from moto import mock_s3 MY_BUCKET = "bucket" # BAD PREFIX MY_PREFIX = "bucket/project/data/layer/dataset/" @pytest.fixture(scope="function") def aws_credentials(): &qu ... read more →
Pandas pandas.DataFrames are pretty sweet data structures in Python. I do a lot of work with tabular data and one thing I have incorporated into some of that work is automatic data summary reports by throwing the first few, or several relevant, rows ... read more →
I wrote up a little on exporting DataFrames to markdown and html here But I've been playing with a web app for with lists and while I'm toying around I learned you can actually give your tables some style with some simple css classes! To HTML Remind ... read more →
Amazon has crossed the line with me just one too many times now so we are looking to drop them like every other Big Tech provider.... However, one key feature of Amazon that has been so useful for us is Lists... We can just maintain a list for each ... read more →
I try to commit a lot, and I also try to write useful tests appropriate for the scope of work I'm focusing on, but sometimes I drop the ball... Whether by laziness, ignorance, or accepted tech debt I don't always code perfectly and recently I was do ... read more →
TL;DR pandas.Series.str.contains accepts regular expressions and this is turned on by default! Use case We often need to filter pandas DataFrames based on several string values in a Series. Notice that sweet pyflyby import 😁! sandbox main via 3 ... read more →