graphcoding 0.2.0__py3-none-any.whl → 0.3.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.
- graphcoding/__init__.py +1 -1
- graphcoding/cli.py +2 -1
- graphcoding/store.py +12 -11
- {graphcoding-0.2.0.dist-info → graphcoding-0.3.0.dist-info}/METADATA +1 -1
- graphcoding-0.3.0.dist-info/RECORD +14 -0
- graphcoding-0.2.0.dist-info/RECORD +0 -14
- {graphcoding-0.2.0.dist-info → graphcoding-0.3.0.dist-info}/WHEEL +0 -0
- {graphcoding-0.2.0.dist-info → graphcoding-0.3.0.dist-info}/entry_points.txt +0 -0
- {graphcoding-0.2.0.dist-info → graphcoding-0.3.0.dist-info}/licenses/LICENSE +0 -0
- {graphcoding-0.2.0.dist-info → graphcoding-0.3.0.dist-info}/top_level.txt +0 -0
graphcoding/__init__.py
CHANGED
graphcoding/cli.py
CHANGED
|
@@ -326,7 +326,8 @@ def build_parser() -> argparse.ArgumentParser:
|
|
|
326
326
|
s.add_argument("name", help="repo-relative path, path::Symbol, or an external "
|
|
327
327
|
"name like db:orders / api:stripe (see external_prefixes)")
|
|
328
328
|
s.add_argument("--summary", "-s", help="one line: what it will do")
|
|
329
|
-
s.add_argument("--type", "-t", default="CodeFile",
|
|
329
|
+
s.add_argument("--type", "-t", default="CodeFile",
|
|
330
|
+
help=f"free-form; common: {', '.join(NODE_TYPES)}")
|
|
330
331
|
s.add_argument("--edge", "-e", action="append",
|
|
331
332
|
help="TYPE:target (repeatable), e.g. -e IMPORTS:src/db.py")
|
|
332
333
|
s.add_argument("--existing", action="store_true",
|
graphcoding/store.py
CHANGED
|
@@ -21,6 +21,7 @@ from __future__ import annotations
|
|
|
21
21
|
|
|
22
22
|
import json
|
|
23
23
|
import os
|
|
24
|
+
import re
|
|
24
25
|
from dataclasses import dataclass, field
|
|
25
26
|
|
|
26
27
|
NODE_TYPES = [
|
|
@@ -52,20 +53,20 @@ DEFAULT_CONFIG = {
|
|
|
52
53
|
],
|
|
53
54
|
"ignore_tests": True,
|
|
54
55
|
"scan_symbols": False,
|
|
55
|
-
# nodes whose names start with these prefixes describe architecture that
|
|
56
|
-
# is not a repo file — drift never expects one on disk:
|
|
57
|
-
# db: database objects (db:orders, db:settings::llm_provider)
|
|
58
|
-
# mcp: MCP servers and their tools (mcp:router::get_blast_radius)
|
|
59
|
-
# svc: deployed services / processes (svc:api-gateway)
|
|
60
|
-
# queue: queues / topics (queue:invoice-events)
|
|
61
|
-
# api: third-party APIs (api:stripe::charges)
|
|
62
|
-
# ext: anything else outside the repo
|
|
63
|
-
"external_prefixes": ["db:", "mcp:", "svc:", "queue:", "api:", "ext:"],
|
|
64
56
|
}
|
|
65
57
|
|
|
58
|
+
# The classification is OPEN and binary: a node is either CODE (a repo-relative
|
|
59
|
+
# file path — scanned, drift-gated) or ANOTHER SYSTEM (any "scheme:" name —
|
|
60
|
+
# declared, never expected on disk). Invent whatever schemes fit your world:
|
|
61
|
+
# db:orders, mcp:router::search, svc:gateway, erp:sap::orders, team:payments,
|
|
62
|
+
# sensor:plant-7. The scheme is yours; the lifecycle and edges are the same.
|
|
63
|
+
_SCHEME = re.compile(r"^[A-Za-z][A-Za-z0-9_.+-]*:(?!//)")
|
|
66
64
|
|
|
67
|
-
|
|
68
|
-
|
|
65
|
+
|
|
66
|
+
def is_external(name: str, cfg: dict | None = None) -> bool:
|
|
67
|
+
"""True for 'scheme:...' names (non-file architecture). File paths never
|
|
68
|
+
carry a scheme; URLs (scheme://) are also treated as external."""
|
|
69
|
+
return bool(_SCHEME.match(name)) or "://" in name
|
|
69
70
|
|
|
70
71
|
|
|
71
72
|
@dataclass
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: graphcoding
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: Draw the graph of the system you want — then code until the repo matches. Future files and scheduled deletions are graph data; a drift gate blocks commits until code and declared design converge.
|
|
5
5
|
Author: Mosab Sayyed
|
|
6
6
|
License: MIT
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
graphcoding/__init__.py,sha256=2Un0LJlhLKHo0ngdGC_ftGO_44Yj6bfIFTdbTo3cYfk,188
|
|
2
|
+
graphcoding/cli.py,sha256=0rcKvNwh-ItRL9qc6IFMXYrtqz0uKPPfUYdyU55tUQI,15184
|
|
3
|
+
graphcoding/drift.py,sha256=1_zkh62IfPbX3QCeRhp-L61hl4xv3mkG1ecPfRnklrs,3296
|
|
4
|
+
graphcoding/health.py,sha256=OSWHaDrGpQAJSny7RcYVDDNhvCp6aiJtCYihFtB-qPU,4363
|
|
5
|
+
graphcoding/hooks.py,sha256=wEHJ8INcVMWe-0PpDJ62VyYqUjMiGncSDivqPUBXk-I,2292
|
|
6
|
+
graphcoding/scan.py,sha256=AuMQBeBCwZA-bp59vk07DDuq0iHWvAxWip6IJ4RD6w8,10369
|
|
7
|
+
graphcoding/store.py,sha256=bjkve6qwKQSe1K3X90ubN4PgKuFOJPnMvzrYhSOo8is,7796
|
|
8
|
+
graphcoding/sync.py,sha256=OGSf8VRRLN4eGHF4vW-TZgXhj_ygVzh-bzmn0sB5dw0,3725
|
|
9
|
+
graphcoding-0.3.0.dist-info/licenses/LICENSE,sha256=9VWwPkJqBxrM7dlZAvZWYdGWpopJjb32Rhw2m2ZPTKA,1069
|
|
10
|
+
graphcoding-0.3.0.dist-info/METADATA,sha256=LPvvI-shx6HfZaCGvehkuXhV7LC-unLvtMi6qjBcrGs,15268
|
|
11
|
+
graphcoding-0.3.0.dist-info/WHEEL,sha256=K260EYznzXsJYBQGqmI8VTxEdiZYNvDZwW9cBh9-_MA,91
|
|
12
|
+
graphcoding-0.3.0.dist-info/entry_points.txt,sha256=zZ4131jyo5mgfwZZieX7vIknBWpProjLRQMZryBI98w,53
|
|
13
|
+
graphcoding-0.3.0.dist-info/top_level.txt,sha256=WHrV5TVG3R9VZ2QV0fMy0FJBLu2x069m9tjNil6Py-A,12
|
|
14
|
+
graphcoding-0.3.0.dist-info/RECORD,,
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
graphcoding/__init__.py,sha256=4ExzunGDa5dr2srv_86pgA2sDovF8q5e_XtOsEJQk6Q,188
|
|
2
|
-
graphcoding/cli.py,sha256=-YN-LnhU2Z0EyRb5DuiG6aFWsS3BJfGbDyjO4D61R5I,15133
|
|
3
|
-
graphcoding/drift.py,sha256=1_zkh62IfPbX3QCeRhp-L61hl4xv3mkG1ecPfRnklrs,3296
|
|
4
|
-
graphcoding/health.py,sha256=OSWHaDrGpQAJSny7RcYVDDNhvCp6aiJtCYihFtB-qPU,4363
|
|
5
|
-
graphcoding/hooks.py,sha256=wEHJ8INcVMWe-0PpDJ62VyYqUjMiGncSDivqPUBXk-I,2292
|
|
6
|
-
graphcoding/scan.py,sha256=AuMQBeBCwZA-bp59vk07DDuq0iHWvAxWip6IJ4RD6w8,10369
|
|
7
|
-
graphcoding/store.py,sha256=psVzkUWtAWlpzk_S-QVfRgsFXE_EkXME94VuKyg-nsk,7780
|
|
8
|
-
graphcoding/sync.py,sha256=OGSf8VRRLN4eGHF4vW-TZgXhj_ygVzh-bzmn0sB5dw0,3725
|
|
9
|
-
graphcoding-0.2.0.dist-info/licenses/LICENSE,sha256=9VWwPkJqBxrM7dlZAvZWYdGWpopJjb32Rhw2m2ZPTKA,1069
|
|
10
|
-
graphcoding-0.2.0.dist-info/METADATA,sha256=rifsj0ibjh5VRWbE6Iq9BXnBfhaAHoWex7cg_KuIkRc,15268
|
|
11
|
-
graphcoding-0.2.0.dist-info/WHEEL,sha256=K260EYznzXsJYBQGqmI8VTxEdiZYNvDZwW9cBh9-_MA,91
|
|
12
|
-
graphcoding-0.2.0.dist-info/entry_points.txt,sha256=zZ4131jyo5mgfwZZieX7vIknBWpProjLRQMZryBI98w,53
|
|
13
|
-
graphcoding-0.2.0.dist-info/top_level.txt,sha256=WHrV5TVG3R9VZ2QV0fMy0FJBLu2x069m9tjNil6Py-A,12
|
|
14
|
-
graphcoding-0.2.0.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|