Debugging Kubernetes

23 Jul 2024

Helpful tips for debugging applications running in k8s

build/k8s.png

Handling multiple errors in Rust iterator adapters

17 Dec 2023

Approaches for handling multiple errors within iterator adapters

build/rust.png

Better FastAPI Background Jobs

29 Aug 2022

A more featureful background task runner for Async apps like FastAPI or Discord bots

build/fastapi_logo.png

Useful Linux Examples

21 Dec 2021

A plethora of helpful tips for working in Linux

build/bash_logo.png
Continue to all blog posts

Pandas Slow Install

TLDR: Pandas hadn’t yet provided a Wheel for python 3.9

I happened to be starting a new project and so thought I would use the new version of Python (3.9.0) installed via pyenv

$ pip install pandas
Collecting pandas
  Downloading pandas-1.1.3.tar.gz (5.2 MB)
     |████████████████████████████████| 5.2 MB 483 kB/s eta 0:00:01
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Requirement already satisfied: python-dateutil>=2.7.3 in /home/chris/.pyenv/versions/3.9.0/envs/kaggle_supermarket_sales/lib/python3.9/site-packages (from pandas) (2.8.1)
Collecting numpy>=1.15.4
  Downloading numpy-1.19.2.zip (7.3 MB)
     |████████████████████████████████| 7.3 MB 492 kB/s eta 0:00:01
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Collecting pytz>=2017.2
  Using cached pytz-2020.1-py2.py3-none-any.whl (510 kB)
Requirement already satisfied: six>=1.5 in /home/chris/.pyenv/versions/3.9.0/envs/kaggle_supermarket_sales/lib/python3.9/site-packages (from python-dateutil>=2.7.3->pandas) (1.15.0)
Building wheels for collected packages: pandas, numpy
  Building wheel for pandas (PEP 517) ... done

I got stuck here for quite a while and so wondered what was up (as I was use to relatively fast install times)

A quick google found a useful article from Real Python which jogged my memory and reminded me what Wheels were for. (Originally I had heard about them on the Python Bytes Podcast)

So I took a look at pandas on pypi and couldn’t see a “File type” == “Wheel” with “Python version” == cp39

Looking back at the console, the key sign to look for is that the Download Downloading pandas-* was not downloading a .whl file but instead the source .tar.gz

So if you live life on the bleeding edge, then you can expect to be slowed down installing new packages