From 60943e96a6a6a9fe6e8d368f9db2bf9aedf1a6bc Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Sat, 7 Mar 2026 11:28:56 -0600 Subject: chore: update calibre, mimeapps, authinfo, add outbox items Calibre window geometry and scheduler updates. Add Signal URI handlers. Move processed inbox items to outbox. --- assets/outbox/pyright-and-django-stubs.txt | 48 ++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 assets/outbox/pyright-and-django-stubs.txt (limited to 'assets/outbox/pyright-and-django-stubs.txt') diff --git a/assets/outbox/pyright-and-django-stubs.txt b/assets/outbox/pyright-and-django-stubs.txt new file mode 100644 index 0000000..a9fcd90 --- /dev/null +++ b/assets/outbox/pyright-and-django-stubs.txt @@ -0,0 +1,48 @@ +pyright and django-stubs +======================== + +WHY +--- +Emacs is configured to use pyright as the Python LSP server (via lsp-pyright) +instead of pylsp. Pyright has significantly better type inference, especially +for Django's dynamic attributes (model fields, querysets, managers). With +django-stubs, pyright understands the Django ORM well enough to provide +accurate completions and type checking on QuerySets, Model.objects, request +objects, etc. + +PYRIGHT (language server - system-wide tool) +-------------------------------------------- +Install via pacman, NOT pip: + + sudo pacman -S pyright + +Pyright is already in the Arch extra repo. Do not use pip or pipx for this — +pacman keeps it updated with the rest of the system. + +DJANGO-STUBS (per-project, in the project venv) +------------------------------------------------ +django-stubs provides type stubs for Django so pyright understands Django's +dynamic attributes. Install inside each Django project's virtual environment: + + pip install django-stubs + +This must be installed per-project (not globally) because it needs to match +the Django version in use. Also add to requirements-dev.txt or pyproject.toml +so other developers get it automatically. + +Also requires a pyrightconfig.json at the project root with: + + { + "plugins": ["django-stubs"] + } + +Or if using pyright's djangoStubs setting directly: + + { + "djangoStubs": true + } + +SUMMARY +------- +- pyright: pacman (system tool, installed once) +- django-stubs: pip in venv (per Django project) -- cgit v1.2.3