mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-04-05 03:26:53 +00:00
Merge pull request #251 from benwebber/fix/check-builtin-literals-attributes
check-builtin-literals: Ignore function attribute calls
This commit is contained in:
commit
f3ff3316a3
4 changed files with 24 additions and 1 deletions
|
|
@ -34,6 +34,7 @@ Add this to your `.pre-commit-config.yaml`
|
|||
- `check-ast` - Simply check whether files parse as valid python.
|
||||
- `check-builtin-literals` - Require literal syntax when initializing empty or zero Python builtin types.
|
||||
- Allows calling constructors with positional arguments (e.g., `list('abc')`).
|
||||
- Allows calling constructors from the `builtins` (`__builtin__`) namespace (`builtins.list()`).
|
||||
- Ignore this requirement for specific builtin types with `--ignore=type1,type2,…`.
|
||||
- Forbid `dict` keyword syntax with `--no-allow-dict-kwargs`.
|
||||
- `check-byte-order-marker` - Forbid files which have a UTF-8 byte-order marker
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue