Journal: Intuitive Python - The spacemacs setup

My overall initial first impressions of this book are very good.

I will document my local spacemacs setup to as I work through the book.


Nice one Robert - I’ll look forward to seeing how you get on :+1:


Corresponding tweet for this thread:

Share link for this tweet.

1 Like

Spacemacs notes wrt Python dev

From the develop branch of spacemacs we have the Python Layer.

A layer in Spacemacss configuration block that pulls in a set of emacs packages and allows you to configure those packages.

The Python layer brings in a lot of features many of which intersect with the tooling described in the book.


I have set the backend to lsp as I have that already installed, but the layer by default uses anaconda and I wonder if that is because it is tested better there.

Well yes there is a note that lsp is slated to be replaced with a new language server for python called pyright. So I’ll try that to see if it “reduces cpu cooler fan noise”

Installed it using

npm install -g pyright

SPC h d python python backend
TAB to config.el and edit python-lsp-server there using instructions in the var descriptions

Static code checkers

Spoiled for choice, notes for each

In spacemacs SPC e is the chord that brings up options for flycheck mode which presents errors reported by static code checkers.

Ideally I would like to run all the checks all the time - i.e. I would like to chain static code checkers

SPC e s allows you to select a static checker
entering python filters the available checkers

To see the errors found as a list SPC e l


I installed this on the local machine as per Python layer

I set the checker using SPC e s then selecting python-flake8


TODO Chain mypy on to list of flycheck / lsp static code checkers

Need to move on to other tasks will revisit this …