Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ __pycache__
*.egg-info/

# ipynb
.ipynb_checkpoints/
.ipynb_checkpoints/
43 changes: 22 additions & 21 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
exclude: 'site/.*'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
Expand All @@ -16,12 +16,12 @@ repos:
- id: check-toml
- id: debug-statements
- repo: https://github.com/asottile/add-trailing-comma
rev: v3.1.0
rev: v3.2.0
hooks:
- id: add-trailing-comma
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.8.2
rev: v0.13.2
hooks:
# Run the linter.
- id: ruff
Expand All @@ -31,22 +31,20 @@ repos:
types_or: [python, pyi]
# options: ignore one line things [E701]
- repo: https://github.com/adrienverge/yamllint
rev: v1.35.1
rev: v1.37.1
hooks:
- id: yamllint
name: yamllint
description: This hook runs yamllint.
entry: yamllint
language: python
types: [file, yaml]
args: ['-d', "{\
extends: default,\
rules: {\
colons: { max-spaces-after: -1 }\
}\
}"]
args: [
'-d',
"{ extends: default, rules: { colons: { max-spaces-after: -1 } } }",
]
- repo: https://github.com/rhysd/actionlint
rev: v1.7.4
rev: v1.7.7
hooks:
- id: actionlint
name: Lint GitHub Actions workflow files
Expand All @@ -67,18 +65,9 @@ repos:
args: [--staged, --msg-filename]
stages: [commit-msg]
- repo: https://github.com/crate-ci/typos
rev: v1.28.2
rev: v1
hooks:
- id: typos
- repo: https://github.com/markdownlint/markdownlint
rev: v0.13.0
hooks:
- id: markdownlint
name: Markdownlint
description: Run markdownlint on your Markdown files
entry: mdl --style .markdown.rb
language: ruby
files: \.(md|mdown|markdown)$
- repo: https://github.com/Yelp/detect-secrets
rev: v1.5.0
hooks:
Expand All @@ -87,3 +76,15 @@ repos:
language: python
entry: detect-secrets-hook
args: ['']
- repo: https://github.com/rvben/rumdl-pre-commit
rev: v0.0.151 # Use the latest release tag
hooks:
- id: rumdl
# To only check (default):
# args: []
# To automatically fix issues:
# args: [--fix]
- repo: https://github.com/RobertCraigie/pyright-python
rev: v1.1.405 # pin a tag; latest as of 2025-10-01
hooks:
- id: pyright
5 changes: 3 additions & 2 deletions TECH_NOTE.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,13 @@ In simple usage, usually only the root logger has a handler.

* Changing the format mid-program means finding all the (relevant?) handlers
in the tree. `pytest` for example attaches other handlers so it can capture
logging. Our `better_config()` will set our format on the root logger's handlers.
logging. Our `better_config()` will set our format on the root logger's
handlers.

* You cannot attach two formatters to a handler
* Two handlers cannot access the same file

Having both those be true simultaneously presents problems.

For our process logger, where a lot of context is erronenous,
For our process logger, where a lot of context is erroneous,
we strip useless data from the process logger by using a filter.