roadkeep 0.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. roadkeep/__init__.py +79 -0
  2. roadkeep/adopting.py +2347 -0
  3. roadkeep/attesting.py +293 -0
  4. roadkeep/authoring.py +2117 -0
  5. roadkeep/backlog.py +767 -0
  6. roadkeep/blocking.py +1622 -0
  7. roadkeep/briefing.py +970 -0
  8. roadkeep/budgeting.py +2056 -0
  9. roadkeep/capturing.py +1699 -0
  10. roadkeep/claiming.py +1019 -0
  11. roadkeep/cli.py +638 -0
  12. roadkeep/commanding.py +487 -0
  13. roadkeep/config.py +1832 -0
  14. roadkeep/counting.py +376 -0
  15. roadkeep/criteria.py +933 -0
  16. roadkeep/deferring.py +708 -0
  17. roadkeep/describing.py +568 -0
  18. roadkeep/exporting.py +808 -0
  19. roadkeep/fixing.py +629 -0
  20. roadkeep/governing.py +934 -0
  21. roadkeep/graph.py +395 -0
  22. roadkeep/guarding.py +1028 -0
  23. roadkeep/history.py +2403 -0
  24. roadkeep/ids.py +301 -0
  25. roadkeep/installing.py +2145 -0
  26. roadkeep/kernel/__init__.py +24 -0
  27. roadkeep/kernel/document.py +1719 -0
  28. roadkeep/kernel/schema.py +2308 -0
  29. roadkeep/linting.py +4420 -0
  30. roadkeep/locking.py +209 -0
  31. roadkeep/markers.py +172 -0
  32. roadkeep/merging.py +1159 -0
  33. roadkeep/picking.py +772 -0
  34. roadkeep/provenance.py +789 -0
  35. roadkeep/queueing.py +752 -0
  36. roadkeep/ranking.py +139 -0
  37. roadkeep/referring.py +231 -0
  38. roadkeep/remaining.py +336 -0
  39. roadkeep/remedying.py +1989 -0
  40. roadkeep/rendering.py +1601 -0
  41. roadkeep/renumbering.py +503 -0
  42. roadkeep/repairing.py +295 -0
  43. roadkeep/reverting.py +144 -0
  44. roadkeep/scoping.py +708 -0
  45. roadkeep/screening.py +196 -0
  46. roadkeep/sections.py +4121 -0
  47. roadkeep/serving.py +2909 -0
  48. roadkeep/shipping.py +3993 -0
  49. roadkeep/showing.py +613 -0
  50. roadkeep/storing.py +224 -0
  51. roadkeep/verbs/__init__.py +26 -0
  52. roadkeep/verbs/adopting.py +974 -0
  53. roadkeep/verbs/authoring.py +566 -0
  54. roadkeep/verbs/declaring.py +335 -0
  55. roadkeep/verbs/linting.py +645 -0
  56. roadkeep/verbs/querying.py +2138 -0
  57. roadkeep/verbs/reading.py +307 -0
  58. roadkeep/verbs/refusing.py +146 -0
  59. roadkeep/verbs/sections.py +1433 -0
  60. roadkeep/verbs/shipping.py +819 -0
  61. roadkeep/weighing.py +380 -0
  62. roadkeep-0.2.0.dist-info/METADATA +453 -0
  63. roadkeep-0.2.0.dist-info/RECORD +67 -0
  64. roadkeep-0.2.0.dist-info/WHEEL +5 -0
  65. roadkeep-0.2.0.dist-info/entry_points.txt +2 -0
  66. roadkeep-0.2.0.dist-info/licenses/LICENSE +202 -0
  67. roadkeep-0.2.0.dist-info/top_level.txt +1 -0
roadkeep/__init__.py ADDED
@@ -0,0 +1,79 @@
1
+ """roadkeep — the roadmap format as a schema, enforced where the text is created.
2
+
3
+ The names below are `schema`'s, re-exported so a reader importing the package gets the
4
+ format's vocabulary without knowing which module holds it. They are resolved **on first
5
+ access** rather than at import (RK199), because a package `__init__` runs before any module
6
+ in it does and there is no entry point that can decline it.
7
+
8
+ Measured, the eager version cost 23ms of the 43ms floor RK176 spent a whole task reaching:
9
+ `import roadkeep.screening` — a module whose entire argument is that it imports nothing but
10
+ the standard library — loaded `schema`, and through it `dataclasses`, `inspect`, `re` and
11
+ `enum`. Counted across `src/`, **no module in the package reaches a name through here**:
12
+ every `from roadkeep import …` in the tree names a submodule or `__version__`. The
13
+ re-export list exists for readers, and readers are not who was paying for it.
14
+
15
+ PEP 562 and not a shorter list, because dropping the names would churn what `dir(roadkeep)`
16
+ answers for a saving laziness gets anyway. Each name is bound into the module on first use, so
17
+ the cost is paid once and only where somebody asks.
18
+
19
+ **This list is a convenience and not a promise** (RK205). RK199 dropped a `TYPE_CHECKING`
20
+ block arguing no external checker reads this package, which is true — and true of the other
21
+ thirty-five modules, which made it a fact about the distribution rather than a licence. The
22
+ question that settles it is whether `from roadkeep import Schema` is a surface this project
23
+ supports, and the answer is in the roadmap's non-goals: it is not. So no `py.typed` ships, the
24
+ annotations here serve this repository's own reading, and the surfaces that *are* promised are
25
+ the CLI, the MCP tools and the plugin. `tests/test_packaging.py` holds both halves.
26
+ """
27
+
28
+ from __future__ import annotations
29
+
30
+ __all__ = [
31
+ "ARROW",
32
+ "DESIGNED",
33
+ "EM_DASH",
34
+ "IDEA",
35
+ "IN_PROGRESS",
36
+ "NO_DEPS",
37
+ "OPEN_MARKERS",
38
+ "PARTIAL",
39
+ "SHIPPED",
40
+ "Dep",
41
+ "Id",
42
+ "Schema",
43
+ "SchemaError",
44
+ "Task",
45
+ "Violation",
46
+ ]
47
+ #: The one place the version is written (RK19). `pyproject.toml` declares it `dynamic` and
48
+ #: reads this literal, so a release cannot ship a number the package disagrees with — which
49
+ #: is also why it stays eager: a build backend parses this file, it does not import it.
50
+ __version__ = "0.2.0"
51
+
52
+
53
+ #: What the names above are, resolved once each. A frozenset and not a `TYPE_CHECKING`
54
+ #: import of them: the conventional block would pull `typing` into every startup — 5.6ms,
55
+ #: measured, and 90% of what is left of this file — to serve a checker that may not read this
56
+ #: package, which ships no `py.typed` by decision and not by omission (PEP 561, RK205). What
57
+ #: the surface promises is held by `tests/test_packaging.py` instead, which is a stronger
58
+ #: claim than an annotation.
59
+ _EXPORTED = frozenset(__all__)
60
+
61
+
62
+ def __getattr__(name: str) -> object:
63
+ """Resolve a re-exported name out of `schema`, once (PEP 562).
64
+
65
+ Bound into `globals()` on the way out, so the second access is the dict lookup an eager
66
+ import would have given — the laziness is about the import, not about every read.
67
+ """
68
+ if name not in _EXPORTED:
69
+ raise AttributeError(f"module 'roadkeep' has no attribute {name!r}")
70
+ from roadkeep.kernel import schema
71
+
72
+ value = getattr(schema, name)
73
+ globals()[name] = value
74
+ return value
75
+
76
+
77
+ def __dir__() -> list[str]:
78
+ """The re-exports included, so `dir(roadkeep)` answers what `__all__` promises."""
79
+ return sorted(_EXPORTED | set(globals()))