I work in Python every day. Most Python projects I setup the dev environment, then start tinkering with whatever I’m working on, learning the project standards and framework as I go.
In the nearly dozen or so times now that I have tried to fix bugs or add features in HA, every time I try and setup the dev environment it fails. Or the pre-commit is broken. So then I burn a some hours hacking it up until it works well enough for whatever I’m trying to work on.
Sometimes I succeed. Often I run out of energy/spoons/focus before it’s working.
But this hackup leaves it inconsistent with whatever ya’all are running. So I try to revert that stuff and go clean next time I open it up. Or maybe ya’all have done some big refactoring that touches on what I’m working on, so I want to make sure and rebase it before continuing work. But then nothing works. And shortly I’m out of energy/spoons/focus.
The fact that I’ve never successfully, even once, been able to follow your instructions and get a working development environment means that I’m fighting this huge barrier to entry of up to a dozen hours hacking up the dependencies and venv setup to get it working. And this isn’t because my development environment is odd in any way. It works for EVERY other project I work on, and the problems I have homeassistant-core can be replicated on a brand new out of the box Mac with just Homebrew and Python installed.
A couple of very simple ideas that are kindof basic, starting point for every CI project I work on:
- Don’t allow merges to
dev
branch that fail to run the basic setup script successfully - Don’t allow merges to
dev
that break the pre-commit script (another common failure point)
Or if these goals are not workable somehow, automate a floating tag that updates for whatever commit on HEAD last had both of these working, and change the docs to recommend starting with that tag.