summaryrefslogtreecommitdiff
path: root/pyproject.toml
diff options
context:
space:
mode:
authorBen Sima <ben@bsima.me>2024-05-20 22:06:34 -0400
committerBen Sima <ben@bsima.me>2024-05-20 23:15:31 -0400
commit3d4d36e5b4b61cbbee93032425c822f2f478449c (patch)
treef77a70c8191c60a0d3188f1523a43f430355f5e7 /pyproject.toml
parent70c293597d0ad25a87008cd136ee63798aba8e53 (diff)
Greatly expand Repl.py
This adds a few things I found from [this gist][1], but cleaned up quite a bit I think, and designed a bit closer to the ghci user experience. Along the way I figured out what ruff settings will autoformat my imports in one alphabetized section, rather than splitting it into multiple sections for builtins and external deps. So I made that change in the whole repo, but there weren't too many changes. [1]: https://gist.github.com/aliles/1153926
Diffstat (limited to 'pyproject.toml')
-rw-r--r--pyproject.toml33
1 files changed, 21 insertions, 12 deletions
diff --git a/pyproject.toml b/pyproject.toml
index 62eebf4..025e630 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -7,6 +7,7 @@ exclude = ["_", ".git"]
line-length = 80
indent-width = 4
target-version = "py310"
+unsafe-fixes = true
[tool.ruff.format]
preview = true
@@ -20,16 +21,24 @@ preview = true
select = ["ALL"]
fixable = ["ALL"]
ignore = [
- "ANN401", # any-type, we allow typing.Any, although we shouldn't
- "CPY001", # missing-copyright-notice
- "D203", # no-blank-line-before-class
- "D212", # multi-line-summary-first-line
- "E203", # whitespace-before-punctuation, doesn't work with ruff format
- "INP001", # implicit-namespace-package
- "N999", # invalid-module-name
- "PT009", # pytest-unittest-assertion, conflicts with assert (S101)
- "S310", # suspicious-url-open-usage, doesn't work in 0.1.5
- "S404", # suspicious-subprocess-import, not stable
- "S603", # subprocess-without-shell-equals-true, false positives
- "S607", # start-process-with-partial-path
+ "ANN401", # any-type, we allow typing.Any, although we shouldn't
+ "CPY001", # missing-copyright-notice
+ "D203", # no-blank-line-before-class
+ "D212", # multi-line-summary-first-line
+ "E203", # whitespace-before-punctuation, doesn't work with ruff format
+ "INP001", # implicit-namespace-package
+ "N999", # invalid-module-name
+ "PLR0402", # manual-from-import, prefer imports like Haskell
+ "PT009", # pytest-unittest-assertion, conflicts with assert (S101)
+ "S310", # suspicious-url-open-usage, doesn't work in 0.1.5
+ "S404", # suspicious-subprocess-import, not stable
+ "S603", # subprocess-without-shell-equals-true, false positives
+ "S607", # start-process-with-partial-path
+ "TD002", # missing-todo-author, just don't allow todos
+ "TD003", # missing-todo-link, just don't allow todos
]
+
+[tool.ruff.lint.isort]
+no-sections = true
+force-single-line = true
+