-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
6526245
commit 3047a9d
Showing
22 changed files
with
186 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
|
||
line-length = 120 | ||
indent-width = 4 | ||
|
||
target-version = "py38" | ||
src = ["src", "test"] | ||
|
||
# https://docs.astral.sh/ruff/settings/#ignore-init-module-imports | ||
ignore-init-module-imports = true | ||
|
||
extend-exclude = ["__init__.py"] | ||
|
||
select = [ | ||
"E", "W", # https://docs.astral.sh/ruff/rules/#pycodestyle-e-w | ||
"I", # https://docs.astral.sh/ruff/rules/#isort-i | ||
"UP", # https://docs.astral.sh/ruff/rules/#pyupgrade-up | ||
|
||
"A", # https://docs.astral.sh/ruff/rules/#flake8-builtins-a | ||
"ASYNC", # https://docs.astral.sh/ruff/rules/#flake8-async-async | ||
"C4", # https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4 | ||
"EM", # https://docs.astral.sh/ruff/rules/#flake8-errmsg-em | ||
"FIX", # https://docs.astral.sh/ruff/rules/#flake8-fixme-fix | ||
"INP", # https://docs.astral.sh/ruff/rules/#flake8-no-pep420-inp | ||
"ISC", # https://docs.astral.sh/ruff/rules/#flake8-implicit-str-concat-isc | ||
"PIE", # https://docs.astral.sh/ruff/rules/#flake8-pie-pie | ||
"PT", # https://docs.astral.sh/ruff/rules/#flake8-pytest-style-pt | ||
"PTH", # https://docs.astral.sh/ruff/rules/#flake8-use-pathlib-pth | ||
"RET", # https://docs.astral.sh/ruff/rules/#flake8-return-ret | ||
"SIM", # https://docs.astral.sh/ruff/rules/#flake8-simplify-sim | ||
"SLOT", # https://docs.astral.sh/ruff/rules/#flake8-slots-slot | ||
"T10", # https://docs.astral.sh/ruff/rules/#flake8-debugger-t10 | ||
"TCH", # https://docs.astral.sh/ruff/rules/#flake8-type-checking-tch | ||
"TD", # https://docs.astral.sh/ruff/rules/#flake8-todos-td | ||
|
||
"TRY", # https://docs.astral.sh/ruff/rules/#tryceratops-try | ||
"FLY", # https://docs.astral.sh/ruff/rules/#flynt-fly | ||
"PERF", # https://docs.astral.sh/ruff/rules/#perflint-perf | ||
"RUF", # https://docs.astral.sh/ruff/rules/#ruff-specific-rules-ruf | ||
|
||
"PL", # https://docs.astral.sh/ruff/rules/#pylint-pl | ||
] | ||
|
||
ignore = [ | ||
"RET501", # https://docs.astral.sh/ruff/rules/unnecessary-return-none/#unnecessary-return-none-ret501 | ||
"TRY400", # https://docs.astral.sh/ruff/rules/error-instead-of-exception/ | ||
|
||
"A003", # https://docs.astral.sh/ruff/rules/builtin-attribute-shadowing/ | ||
] | ||
|
||
|
||
[format] | ||
# Use single quotes for non-triple-quoted strings. | ||
quote-style = "single" | ||
|
||
|
||
|
||
[lint.per-file-ignores] | ||
"doc/*" = [ | ||
"A001", # A001 Variable `copyright` is shadowing a Python builtin | ||
"E402", # E402 Module level import not at top of file | ||
"INP001", # INP001 File `FILE_NAME` is part of an implicit namespace package. Add an `__init__.py`. | ||
"PTH100", # PTH100 `os.path.abspath()` should be replaced by `Path.resolve()` | ||
"PTH118", # PTH118 `os.path.join()` should be replaced by `Path` with `/` operator | ||
] | ||
|
||
"tests/*" = [ | ||
"INP001", # INP001 File `FILE_NAME` is part of an implicit namespace package. Add an `__init__.py`. | ||
"ISC002", # ISC002 Implicitly concatenated string literals over multiple lines | ||
] | ||
|
||
"setup.py" = ["PTH123"] | ||
|
||
"src/sphinx_exec_code/code_exec_error.py" = [ | ||
"PERF401", # PERF401 Use a list comprehension to create a transformed list | ||
"PLW2901", # PLW2901 `for` loop variable `tb_line` overwritten by assignment target | ||
] | ||
|
||
|
||
[lint.isort] | ||
# https://docs.astral.sh/ruff/settings/#isort-lines-after-imports | ||
lines-after-imports = 2 | ||
|
||
|
||
[lint.pylint] | ||
max-args = 6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
pytest >= 7.2, < 7.3 | ||
pre-commit >= 3.0, < 3.1 | ||
pytest == 7.4.4 | ||
pre-commit == 3.6.0 | ||
|
||
sphinx >= 6.1, < 6.2 | ||
sphinx-rtd-theme >= 1.2, <1.3 | ||
ruff == 0.1.11 | ||
|
||
sphinx == 7.2.6 | ||
sphinx-rtd-theme == 2.0.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
from sphinx.util import logging | ||
|
||
|
||
log = logging.getLogger('sphinx-exec-code') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = '0.10' | ||
__version__ = '0.11' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.