e109f3ac7c5c09b89816405e3ebc9dd195685024
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

1) [build-system]
2) requires = ["hatchling"]
3) build-backend = "hatchling.build"
4) 
5) [project]
6) name = "derivepassphrase"
7) description = "An almost faithful Python reimplementation of James Coglan's vault."
8) readme = "README.md"
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

9) requires-python = ">= 3.10"
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

10) license = "MIT"
11) keywords = []
12) authors = [
13)   { name = "Marco Ricci", email = "m@the13thletter.info" },
14) ]
15) classifiers = [
16)   "Development Status :: 4 - Beta",
17)   "Environment :: Console",
Marco Ricci Fix misspelt project settings

Marco Ricci authored 2 months ago

18)   "License :: OSI Approved :: MIT License",
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

19)   "Programming Language :: Python :: 3",
Marco Ricci Support Python 3.10 and PyP...

Marco Ricci authored 2 months ago

20)   "Programming Language :: Python :: 3.10",
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

21)   "Programming Language :: Python :: 3.11",
22)   "Programming Language :: Python :: 3.12",
23)   "Programming Language :: Python :: Implementation :: CPython",
24)   "Programming Language :: Python :: Implementation :: PyPy",
25) ]
26) dependencies = [
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

27)   # We use click for the command-line interface.  We require version 8.1.0
28)   # or higher due to click issue #1985.
29)   "click >= 8.1",
30)   # We include type annotations, and use facilities that are not readily
31)   # available in older Pythons (such as typing.Self).  These are loaded from
32)   # typing_extensions, instead of using explicit version guards.
Marco Ricci Support Python 3.10 and PyP...

Marco Ricci authored 2 months ago

33)   "typing_extensions",
Marco Ricci Overhaul dependency and env...

Marco Ricci authored 3 months ago

34) ]
Marco Ricci Release 0.1.3

Marco Ricci authored 1 month ago

35) version = "0.1.3"
Marco Ricci Overhaul dependency and env...

Marco Ricci authored 3 months ago

36) 
37) [project.optional-dependencies]
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

38) dev = [
39)   # Development uses the hatch build system, to isolate all tools in their
40)   # own virtual environment.
41)   "hatch ~= 1.10",
42) ]
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

43) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

44) [project.scripts]
45) derivepassphrase = "derivepassphrase.cli:derivepassphrase"
46) 
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

47) [project.urls]
Marco Ricci Set up a web host for the d...

Marco Ricci authored 2 months ago

48) Documentation = "https://the13thletter.info/derivepassphrase/"
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

49) Issues = "https://github.com/the-13th-letter/derivepassphrase/issues"
50) Source = "https://github.com/the-13th-letter/derivepassphrase"
51) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

52) [tool.coverage.html]
53) directory = "html/coverage"
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

54) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

55) [tool.coverage.paths]
56) src = ["src"]
57) tests = ["tests"]
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

58) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

59) [tool.coverage.report]
60) skip_covered = false
61) skip_empty = true
62) precision = 3
63) partial_branches = [
64)     'pragma: no branch',
65) ]
66) exclude_also = [
67)   "if __name__ == .__main__.:",
68)   'if (?:typing\.)?TYPE_CHECKING:',
69)   "raise AssertionError",
70)   "raise NotImplementedError",
71)   'assert False',
72) ]
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

73) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

74) [tool.coverage.run]
75) source_pkgs = ["derivepassphrase", "tests"]
76) branch = true
77) parallel = true
78) omit = [
79)   "__main__.py",
80) ]
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

81) 
Marco Ricci Fix Python package build co...

Marco Ricci authored 1 month ago

82) [tool.hatch.build.targets.sdist]
83) exclude = [
84)     'towncrier.d/[0123456789+]*.md',
85) ]
86) 
87) [tool.hatch.build.targets.wheel]
Marco Ricci Move `sequin` and `ssh_agen...

Marco Ricci authored 1 month ago

88) packages = ['src/derivepassphrase']
Marco Ricci Fix Python package build co...

Marco Ricci authored 1 month ago

89) 
Marco Ricci Overhaul dependency and env...

Marco Ricci authored 3 months ago

90) [tool.hatch.env]
91) requires = [
92)   "hatch-mkdocs",
93) ]
94) 
95) [tool.hatch.env.collectors.mkdocs.docs]
96) path = "mkdocs.yml"
97) 
Marco Ricci Fill out README and documen...

Marco Ricci authored 2 months ago

98) [tool.hatch.envs.docs]
99) extra-dependencies = [
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

100)   # Our documentation uses the Material theme.  It also uses
101)   # `mkdocstrings[python]`, but `hatch-mkdocs` is apparently smart
102)   # enough to pick *that* one up from the MkDocs configuration, but not
103)   # the selected theme...
104)   "mkdocs-material",
105)   # Our documentation uses formatted function signatures (i.e. with
106)   # formatted type annotations), which requires `black`.
Marco Ricci Fill out README and documen...

Marco Ricci authored 2 months ago

107)   "black",
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

108)   # Our documentation is generated in multiple versions, orchestrated by
109)   # `mike`.
Marco Ricci Deploy versioned documentat...

Marco Ricci authored 1 month ago

110)   "mike",
Marco Ricci Fill out README and documen...

Marco Ricci authored 2 months ago

111) ]
112) detached = false
113) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

114) [tool.hatch.envs.hatch-static-analysis]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

115) config-path = "/dev/null"
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

116) dependencies = [
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

117)   "ruff ~= 0.6.0",
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

118) ]
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

119) 
120) [tool.hatch.envs.hatch-test]
121) default-args = ['src', 'tests']
122) 
123) [[tool.hatch.envs.hatch-test.matrix]]
124) python = ["3.10", "3.11", "3.12", "pypy3.10"]
125) 
126) [tool.hatch.envs.release]
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

127) extra-dependencies = [
128)   "towncrier >= 23.11"
129) ]
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

130) 
131) [tool.hatch.envs.release.scripts]
132) 
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

133) [tool.hatch.envs.types]
134) extra-dependencies = [
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

135)   "mypy ~= 1.0",
Marco Ricci Undo single-child hatch env...

Marco Ricci authored 3 weeks ago

136)   "pytest ~= 8.1",
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

137) ]
Marco Ricci Specify project dependencie...

Marco Ricci authored 1 month ago

138) 
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

139) [tool.hatch.envs.types.scripts]
140) check = "mypy --install-types --non-interactive {args:src/derivepassphrase tests}"
141) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

142) [tool.hatch.version]
143) path = "src/derivepassphrase/__init__.py"
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

144) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

145) [tool.mypy]
146) files = ['src/**/*.py', 'tests/**/*.py']
147) mypy_path = '$MYPY_CONFIG_FILE_DIR/src'
148) explicit_package_bases = true
149) implicit_reexport = false
150) sqlite_cache = true
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

151) enable_error_code = ['ignore-without-code']
Marco Ricci Import initial project files

Marco Ricci authored 4 months ago

152) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

153) [tool.pytest.ini_options]
154) addopts = '--doctest-modules'
155) pythonpath = ['src']
156) testpaths = ['src', 'tests']
157) xfail_strict = true
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 2 months ago

158) 
159) [tool.ruff]
160) line-length = 79
161) src = ["src"]
162) 
163) [tool.ruff.format]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

164) docstring-code-format = true
Marco Ricci Reformat everything with ruff

Marco Ricci authored 1 month ago

165) docstring-code-line-length = "dynamic"
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

166) preview = true
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

167) quote-style = 'single'
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

168) 
169) [tool.ruff.lint]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

170) ignore = [
171)     # Suggested ignore by ruff when also using ruff to format.  We *do*
172)     # check for E501, because this usually only happens when there is a text
173)     # string that should be manually broken.
174)     'W191', 'E111', 'E114', 'E117', 'D206', 'D300', 'Q000', 'Q001', 'Q002',
175)     'Q003', 'COM812', 'COM819', 'ISC001', 'ISC002',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

176)     # We use `assert` regularly to appease the type checker, and because
177)     # it is the right language tool for this job.
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

178)     'S101',
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

179)     # The formatter takes care of trailing commas and docstring code
180)     # automatically.
181)     'COM812', 'W505',
182)     # We document transitive exceptions as well (if we feel they would be
183)     # surprising to the user otherwise).
184)     'DOC502',
185)     # We currently don't have issues for every TODO.  Forcing an issue also
186)     # goes against the philosophy of TODOs as low-overhead markers for
187)     # future work; see
188)     # https://gist.github.com/dmnd/ed5d8ef8de2e4cfea174bd5dafcda382 .
189)     'TD003',
190)     # We somewhat regularly use loops where each iteration needs a separate
191)     # try-except block.
192)     'PERF203',
193)     # We catch type-ignore comments without specific code via the mypy
194)     # configuration, not via ruff.
195)     'PGH003',
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

196) ]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

197) preview = true
198) # We select here in the order of presentation on the ruff documentation
199) # website.  ruff default selection (v0.6.2) is merely E4, E7, E9 and F.
200) select = [
201)     'F', 'E', 'W', 'C90', 'I', 'N', 'D', 'UP', 'YTT',
202)     'ANN', 'ASYNC', 'S', 'BLE', 'FBT', 'B', 'A', 'COM',
203)     'CPY', 'C4', 'DTZ', 'T10', 'DJ', 'EM', 'EXE', 'FA',
204)     'ISC', 'ICN', 'LOG', 'G', 'INP', 'PIE', 'T20', 'PYI',
205)     'PT', 'Q', 'RET', 'SLF', 'SLOT', 'SIM', 'TID', 'TCH',
206)     'INT', 'ARG',
207)     # We currently do not use pathlib. Disable 'PTH'.
208)     'TD',
209)     # We use TODOs and FIXMEs as notes for later, and don't want the linter
210)     # to nag about every occurrence.  Disable 'FIX'.
211)     #
212)     # The "eradicate" rule is prone to a lot of false positives, and it is
213)     # unclear to me, and probably confusing to read, where to apply a noqa
214)     # marker.  Instead, disable 'ERA', and if necessary, specify it on the
215)     # command-line.
216)     'PD', 'PGH', 'PL', 'TRY', 'FLY', 'NPY', 'FAST',
217)     'AIR', 'PERF', 'FURB', 'DOC', 'RUF',
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

218) ]
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 2 months ago

219) 
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

220) [tool.ruff.lint.per-file-ignores]
221) "**/scripts/*" = [
222)   # Suggested by hatch.
223)   'INP',
224)   # Suggested by hatch.
225)   'T20',
226) ]
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

227) "**/tests/**/*" = [
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

228)   # Suggested by hatch, assumingly because it may be important to verify
229)   # that the value is exactly the empty string, and not just any falsy
230)   # value.
231)   'PLC1901',
232)   # Suggested by hatch, assumingly because tests may use "magic values".
233)   'PLR2004',
234)   # Suggested by hatch, because tests are typically organized as classes and
235)   # instance methods but may not really be using the `self` argument.
236)   'PLR6301',
237)   # Suggested by hatch, because these warnings may be precisely what the
238)   # tests are supposed to test.
239)   'S',
240)   # Suggested by hatch, because pytest-style tests conventionally import
241)   # code from each other via relative imports.
242)   'TID252',
243)   # Our tests regularly use arguments named `input` to store an input
244)   # (text-/byte-)string.
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

245)   'A002',
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

246)   # We regularly annotate pytest fixtures like monkeypatch as `Any`.
247)   'ANN401',
248)   # Our tests generally don't contain docstrings.
249)   'D', 'DOC',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

250)   # Our tests are regularly parametrized with booleans, for benign
251)   # purposes.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

252)   'FBT',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

253)   # One of our standard modules is called `derivepassphrase._types`.
254)   # Importing this from the tests directory would then automatically
255)   # trigger `PLC2701`.
Marco Ricci Consolidate `types` submodu...

Marco Ricci authored 1 month ago

256)   'PLC2701',
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

257)   # Too many public methods/arguments/returns/branches/locals doesn't really
258)   # apply here.
259)   'PLR0904', 'PLR0911', 'PLR0912', 'PLR0913', 'PLR0914', 'PLR0915',
260)   'PLR0916', 'PLR0917',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 1 month ago

261)   # To fully test the `derivepassphrase.cli` module (and a couple other
262)   # things), we need to call and to mock several internal functions,
263)   # which would automatically trigger `SLF001`.
Marco Ricci Consolidate `types` submodu...

Marco Ricci authored 1 month ago

264)   'SLF001',
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 1 month ago

265) ]
266) 
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

267) [tool.ruff.lint.flake8-copyright]
268) # Include hatch-enforced SPDX-FileCopyrightText in check.
269) notice-rgx = '(?i)(?:Copyright\s+((?:\(C\)|©)\s+)?|SPDX-FileCopyrightText:\s+)\d{4}((-|,\s)\d{4})*'
270) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

271) [tool.ruff.lint.flake8-pytest-style]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

272) fixture-parentheses = false
273) mark-parentheses = false
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

274) parametrize-names-type = 'list'
Marco Ricci Add a changelog and support...

Marco Ricci authored 1 month ago

275) 
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 weeks ago

276) [tool.ruff.lint.flake8-tidy-imports]
277) ban-relative-imports = "all"
278) 
279) [tool.ruff.lint.isort]
280) known-first-party = ["derivepassphrase"]
281) 
282) [tool.ruff.lint.pycodestyle]
283) ignore-overlong-task-comments = true  # for E501
284) max-doc-length = 72  # for W505
285) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 1 month ago

286) [tool.ruff.lint.pydocstyle]
287) convention = 'google'