Published

All published posts

2604 posts latest post 2026-08-19 simple view
Publishing rhythm
Aug 2026 | 30 posts
Check out terminal by microsoft. It’s a well-crafted project with great potential. The new Windows Terminal and the original Windows console host, all in the same place!

Clean up Your Data Science with Named Tuples

If you are a regular listener of TalkPython or PythonBytes you have hear Michael Kennedy talk about Named Tuples many times, but what are they and how do they fit into my data science workflow. Example # As you graduate your scripts into modules and libraries you might start to notice that you need to pass a lot of data around to all of the functions that you have created. For example if you are running some analysis utilizing,, and data. You may need to calculate total revenue, inventory on hand. You may need to pass these data sets into various models to drive production or pricing based on predicted volumes. Load data # Here we setup functions that can load data from the sales database. Assume that we also have similar functions to and. Create Metrics # Here we create our first function to calculate some metrics. There are likely many of these functions that repeat a similar pattern. They use similar data and have their own custom logic for calculations and joins. Furthermore these…

Background Tasks in Python for Data Science

This post is intended as an extension/update from background tasks in python. I started using the week that Kenneth Reitz released it. It takes away so much boilerplate from running background tasks that I use it in more places than I probably should. After taking a look at that post today, I wanted to put a better data science example in here to help folks get started. This post is intended as an extension/update from background tasks in python. I started using the week that Kenneth Reitz released it. It takes away so much boilerplate from running background tasks that I use it in more places than I probably should. After taking a look at that post today, I wanted to put a better data science example in here to help folks get started. I use it in more places than I probably should Before we get into it, I want to make a shout out to Kenneth Reitz for making this so easy. Kenneth is a python God for all that he has given to the community in so many ways, especially with his ideas in bu…
If you’re into interesting projects, don’t miss out on starship, created by starship. ☄🌌️ The minimal, blazing-fast, and infinitely customizable prompt for any shell!
alttch has done a fantastic job with rapidtables. Highly recommend taking a look. Super fast list of dicts to pre-formatted tables conversion library for Python 2/3

📝 Bash Notes

Bash is super powerful. File System Full # Show Remaining Space on Drives show largest files in current directory Move files then symlink them Fuzzy One Liners # edit in vim cat a file bash execute git add git reset Kill a process Finding things # Files # fd-find is amazing for finding files, it even respects your file 😲. Install with. ++Vanilla Bonus Content # ** show matching text ** ++Vanilla Bonus ** show file names only ** ++Vanilla Bonus Recursively Replace text # ++Vanilla Bonus Extending or There are so many options inside of,, and that you could many an enormous amount of these if you really wanted to, but I like to keep it simple. These cover 90% of my usage. If I wanted to change something in the second half I would just paste in this command and edit it. More often though I want to limit the input, say only replace word1 to word2 inside of markdown files. Limited Scope ++Vanilla Bonus Large Refactor At The Command Line I use these replace commands heavily when doing large r…

Autoreload in Ipython

I have used for several years now with great success and 🔥 rapid reloads. It allows me to move super fast when developing libraries and modules. They have made some great updates this year that allows class modules to be automatically be updated. What I like about autoreload # 🔥 Blazing Fast 💥 Keeps me in the comfort of my text editor 👏 Allows me to use Jupyter when I need 👟 Extremely Reliable One of the biggest benefits that I find is that it shortens the distance between my module/library code and test code inside of a terminal/notebook. Now I primarily use jupyter notebooks for the presentation aspect. I develop code from the comfort of my editor with all of the tools I have setup, and run the functions in a notebook to get the output. From there I might do some aggregations or plots, but the 🥩 meat of development is done outside of jupyter. Now I primarily use jupyter notebooks for the presentation aspect. Enabling Autoreload # 📐 config This is a short script that I use to setup ip…
3 min read
If you’re into interesting projects, don’t miss out on psutil, created by giampaolo. Cross-platform lib for process and system monitoring in Python
Check out watchtower by kislyuk. It’s a well-crafted project with great potential. Python CloudWatch Logging: Log Analytics and Application Intelligence
I recently discovered arrow by apache, and it’s truly impressive. Apache Arrow is the universal columnar format and multi-language toolbox for fast data interchange and in-memory analytics

Keyboard Driven VSCode

Throw that mouse Away its time to setup some keyboard shortcuts. These sortcuts were the baseline for switching from tmux/vim to vscode. Most folks posts I was able to find gave great tips on replacing vim, but very few have focused on the hackability of tmux. tmux allows me to rapidly fire up a workspace, create new windows and splits. Then When I switch tasks I can leave that workspace open and and jump right back in later exactly where I left off. There is nothing quite like it. The shortcuts listed here make the transition a bit better. The worst thing I found when using vscode at first was no way to switch between the terminal and editor without the mouse. This first set of keybindings solve that issue. The worst thing I found when using vscode at first was no way to switch between the terminal and editor without the mouse.!!! see-also I have an updated article in my tmux workflow How I navigate tmux in 2021 Alt+[hjkl] # navigation ⬅ jump to left split alt+h ⬇ jump to terminal fro…
tarpas has done a fantastic job with pytest-testmon. Highly recommend taking a look. Selects tests affected by changed files. Executes the right tests first. Continuous test runner when used with pytest-watch.
If you’re into interesting projects, don’t miss out on vim-flog, created by rbong. A blazingly fast, stunningly beautiful, exceptionally powerful git branch viewer for Vim/Neovim.

Realistic Git Workflow

My git workflow based on real life. Its not always clean and simple. sometimes things get messy The Clean Path # pull 👉 branch 👉 format 👉 work👉 add 👉 commit 👉 pull 👉 rebase 👉 push Pull # As complicated as that seems it is pretty straight forward. When you sit down to work the first thing you do is to pull down the teams latest working “develop” branch from git. Branch # Next create a new branch with a name that will remind you of what you are working on. For your own sanity choose something descriptive. It is easy to get too many similar branches going and forget which branch is which. Format # If you know which files in existance that you will be editing before you start work it is a good idea to format them in a commit early on to keep your working commits separate from formatting. This will make it easier for reviewers to distinguish from your changes and formatting fixes. If your team agrees to a consistent formatting logic, sticks to it and always remembers to run the linting/fixi…
7 min read