e8f3ec854c425cc36565a40adbf00d22a2febeec
Marco Ricci Import initial project files

Marco Ricci authored 6 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 2 months ago

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

Marco Ricci authored 6 months ago

10) license = "MIT"
11) keywords = []
12) authors = [
Marco Ricci Change the author e-mail ad...

Marco Ricci authored 2 months ago

13)   { name = "Marco Ricci", email = "software@the13thletter.info" },
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

14) ]
15) classifiers = [
16)   "Development Status :: 4 - Beta",
17)   "Environment :: Console",
Marco Ricci Fix misspelt project settings

Marco Ricci authored 4 months ago

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

Marco Ricci authored 6 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 6 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 2 months 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 3 months ago

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

Marco Ricci authored 5 months ago

34) ]
Marco Ricci Release 0.1.3

Marco Ricci authored 3 months ago

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

Marco Ricci authored 5 months ago

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

Marco Ricci authored 2 months 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 Add dependency on cryptogra...

Marco Ricci authored 2 months ago

43) export = [
44)   # The vault configuration exporter relies on cryptography.  Version 38 was
45)   # the first to include the `algorithms.AES256` interface, instead of only
46)   # the `algorithms.AES` interface.
47)   "cryptography >= 38.0.0",
48) ]
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

50) [project.scripts]
51) derivepassphrase = "derivepassphrase.cli:derivepassphrase"
Marco Ricci Merge topic branch 'clean-u...

Marco Ricci authored 2 months ago

52) derivepassphrase_export = "derivepassphrase.exporter:derivepassphrase_export"
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

53) 
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

62) [tool.coverage.paths]
63) src = ["src"]
64) tests = ["tests"]
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

66) [tool.coverage.report]
67) skip_covered = false
68) skip_empty = true
69) precision = 3
70) partial_branches = [
71)     'pragma: no branch',
72) ]
73) exclude_also = [
74)   "if __name__ == .__main__.:",
75)   'if (?:typing\.)?TYPE_CHECKING:',
76)   "raise AssertionError",
77)   "raise NotImplementedError",
78)   'assert False',
Marco Ricci Merge topic branch 'clean-u...

Marco Ricci authored 2 months ago

79)   '(?:typing\.)?assert_never\(',
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

80) ]
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

82) [tool.coverage.run]
83) source_pkgs = ["derivepassphrase", "tests"]
84) branch = true
85) parallel = true
86) omit = [
87)   "__main__.py",
88) ]
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 3 months ago

90) [tool.hatch.build.targets.sdist]
91) exclude = [
92)     'towncrier.d/[0123456789+]*.md',
93) ]
94) 
95) [tool.hatch.build.targets.wheel]
Marco Ricci Move `sequin` and `ssh_agen...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

97) 
Marco Ricci Overhaul dependency and env...

Marco Ricci authored 5 months ago

98) [tool.hatch.env]
99) requires = [
100)   "hatch-mkdocs",
101) ]
102) 
103) [tool.hatch.env.collectors.mkdocs.docs]
104) path = "mkdocs.yml"
105) 
Marco Ricci Fill out README and documen...

Marco Ricci authored 4 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 4 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 4 months ago

119) ]
120) detached = false
121) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

127) 
128) [tool.hatch.envs.hatch-test]
129) default-args = ['src', 'tests']
130) 
131) [[tool.hatch.envs.hatch-test.matrix]]
132) python = ["3.10", "3.11", "3.12", "pypy3.10"]
133) 
Marco Ricci Merge topic branch 'clean-u...

Marco Ricci authored 2 months ago

134) [[tool.hatch.envs.hatch-test.matrix]]
135) python = ["3.10", "3.11", "3.12", "pypy3.10"]
136) feature = ["export"]
137) 
138) [tool.hatch.envs.hatch-test.overrides]
139) matrix.feature.features = [
140)     { value = "export", if = ["export"] },
141) ]
142) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

143) [tool.hatch.envs.release]
Marco Ricci Specify project dependencie...

Marco Ricci authored 2 months ago

144) extra-dependencies = [
145)   "towncrier >= 23.11"
146) ]
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

147) 
148) [tool.hatch.envs.release.scripts]
149) 
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 6 months ago

154) ]
Marco Ricci Add command-line interface...

Marco Ricci authored 2 months ago

155) features = [
156)     "export",
157) ]
158) 
Marco Ricci Import initial project files

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

165) [tool.mypy]
166) files = ['src/**/*.py', 'tests/**/*.py']
167) mypy_path = '$MYPY_CONFIG_FILE_DIR/src'
168) explicit_package_bases = true
169) implicit_reexport = false
170) sqlite_cache = true
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

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

Marco Ricci authored 6 months ago

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

Marco Ricci authored 2 months ago

173) [tool.pytest.ini_options]
174) addopts = '--doctest-modules'
175) pythonpath = ['src']
176) testpaths = ['src', 'tests']
177) xfail_strict = true
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 3 months ago

178) 
179) [tool.ruff]
180) line-length = 79
181) src = ["src"]
182) 
183) [tool.ruff.format]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 3 months ago

188) 
189) [tool.ruff.lint]
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

190) ignore = [
191)     # Suggested ignore by ruff when also using ruff to format.  We *do*
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

192)     # check for E501, because this usually only happens when there is
193)     # a text string that should be manually broken.
194)     'W191', 'E111', 'E114', 'E117', 'D206', 'D300', 'Q000', 'Q001',
195)     'Q002', 'Q003', 'COM812', 'COM819', 'ISC001', 'ISC002',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

199)     # The formatter takes care of trailing commas and docstring code
200)     # automatically.
201)     'COM812', 'W505',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

202)     # We document transitive exceptions as well (if we feel they would
203)     # be surprising to the user otherwise).
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

204)     'DOC502',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

205)     # We currently don't have issues for every TODO.  Forcing an issue
206)     # also goes against the philosophy of TODOs as low-overhead markers
207)     # for future work; see
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

208)     # https://gist.github.com/dmnd/ed5d8ef8de2e4cfea174bd5dafcda382 .
209)     'TD003',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

210)     # We somewhat regularly use loops where each iteration needs
211)     # a separate try-except block.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

212)     'PERF203',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

213)     # We do not currently use pathlib.  The PTH rules are unselected,
214)     # but FURB includes several pathlib-related rules.
215)     'FURB101', 'FURB103',
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

216)     # We catch type-ignore comments without specific code via the mypy
217)     # configuration, not via ruff.
218)     'PGH003',
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

220) preview = true
221) # We select here in the order of presentation on the ruff documentation
222) # website.  ruff default selection (v0.6.2) is merely E4, E7, E9 and F.
223) select = [
224)     'F', 'E', 'W', 'C90', 'I', 'N', 'D', 'UP', 'YTT',
225)     'ANN', 'ASYNC', 'S', 'BLE', 'FBT', 'B', 'A', 'COM',
226)     'CPY', 'C4', 'DTZ', 'T10', 'DJ', 'EM', 'EXE', 'FA',
227)     'ISC', 'ICN', 'LOG', 'G', 'INP', 'PIE', 'T20', 'PYI',
228)     'PT', 'Q', 'RET', 'SLF', 'SLOT', 'SIM', 'TID', 'TCH',
229)     'INT', 'ARG',
230)     # We currently do not use pathlib. Disable 'PTH'.
231)     'TD',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

232)     # We use TODOs and FIXMEs as notes for later, and don't want the
233)     # linter to nag about every occurrence.  Disable 'FIX'.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

234)     #
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

235)     # The "eradicate" rule is prone to a lot of false positives, and it
236)     # is unclear to me, and probably confusing to read, where to apply
237)     # a noqa marker.  Instead, disable 'ERA', and if necessary, specify
238)     # it on the command-line.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

239)     'PD', 'PGH', 'PL', 'TRY', 'FLY', 'NPY', 'FAST',
240)     'AIR', 'PERF', 'FURB', 'DOC', 'RUF',
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

243) [tool.ruff.lint.per-file-ignores]
244) "**/scripts/*" = [
245)   # Suggested by hatch.
246)   'INP',
247)   # Suggested by hatch.
248)   'T20',
249) ]
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

251)   # Suggested by hatch, assumingly because it may be important to verify
252)   # that the value is exactly the empty string, and not just any falsy
253)   # value.
254)   'PLC1901',
255)   # Suggested by hatch, assumingly because tests may use "magic values".
256)   'PLR2004',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

257)   # Suggested by hatch, because tests are typically organized as classes
258)   # and instance methods but may not really be using the `self`
259)   # argument.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

260)   'PLR6301',
261)   # Suggested by hatch, because these warnings may be precisely what the
262)   # tests are supposed to test.
263)   'S',
264)   # Suggested by hatch, because pytest-style tests conventionally import
265)   # code from each other via relative imports.
266)   'TID252',
267)   # Our tests regularly use arguments named `input` to store an input
268)   # (text-/byte-)string.
Marco Ricci Fix style issues with ruff...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

270)   # We regularly annotate pytest fixtures like monkeypatch as `Any`.
271)   'ANN401',
272)   # Our tests generally don't contain docstrings.
273)   'D', 'DOC',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

280)   'PLC2701',
Marco Ricci Apply new ruff ruleset to c...

Marco Ricci authored 2 months ago

281)   # Too many public methods/arguments/returns/branches/locals doesn't
282)   # really apply here.
Marco Ricci Upgrade ruff to 0.6, and re...

Marco Ricci authored 2 months ago

283)   'PLR0904', 'PLR0911', 'PLR0912', 'PLR0913', 'PLR0914', 'PLR0915',
284)   'PLR0916', 'PLR0917',
Marco Ricci Annotate settings and selec...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

291) [tool.ruff.lint.flake8-copyright]
292) # Include hatch-enforced SPDX-FileCopyrightText in check.
293) notice-rgx = '(?i)(?:Copyright\s+((?:\(C\)|©)\s+)?|SPDX-FileCopyrightText:\s+)\d{4}((-|,\s)\d{4})*'
Marco Ricci Add a changelog and support...

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

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

Marco Ricci authored 2 months ago

296) fixture-parentheses = false
297) mark-parentheses = false
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

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

Marco Ricci authored 3 months ago

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

Marco Ricci authored 2 months ago

300) [tool.ruff.lint.flake8-tidy-imports]
301) ban-relative-imports = "all"
302) 
303) [tool.ruff.lint.isort]
304) known-first-party = ["derivepassphrase"]
305) 
306) [tool.ruff.lint.pycodestyle]
307) ignore-overlong-task-comments = true  # for E501
308) max-doc-length = 72  # for W505
309) 
Marco Ricci Sort sections in pyproject....

Marco Ricci authored 2 months ago

310) [tool.ruff.lint.pydocstyle]
311) convention = 'google'