arkaos 2.16.1 → 2.17.0

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 (36) hide show
  1. package/VERSION +1 -1
  2. package/config/agent-allowlists/_base.yaml +7 -0
  3. package/config/agent-allowlists/laravel.yaml +9 -0
  4. package/config/agent-allowlists/node.yaml +7 -0
  5. package/config/agent-allowlists/nuxt.yaml +7 -0
  6. package/config/agent-allowlists/python.yaml +7 -0
  7. package/config/hooks/agent-provision.sh +135 -0
  8. package/config/mcp-policy.yaml +36 -0
  9. package/config/settings-template.json +12 -0
  10. package/config/standards/claude-md-overlays/laravel.md +8 -0
  11. package/config/standards/claude-md-overlays/node.md +7 -0
  12. package/config/standards/claude-md-overlays/nuxt.md +8 -0
  13. package/config/standards/claude-md-overlays/python.md +8 -0
  14. package/core/sync/__pycache__/agent_provisioner.cpython-313.pyc +0 -0
  15. package/core/sync/__pycache__/ai_mcp_decider.cpython-313.pyc +0 -0
  16. package/core/sync/__pycache__/content_merger.cpython-313.pyc +0 -0
  17. package/core/sync/__pycache__/content_syncer.cpython-313.pyc +0 -0
  18. package/core/sync/__pycache__/descriptor_syncer.cpython-313.pyc +0 -0
  19. package/core/sync/__pycache__/engine.cpython-313.pyc +0 -0
  20. package/core/sync/__pycache__/mcp_optimizer.cpython-313.pyc +0 -0
  21. package/core/sync/__pycache__/policy_loader.cpython-313.pyc +0 -0
  22. package/core/sync/__pycache__/reporter.cpython-313.pyc +0 -0
  23. package/core/sync/__pycache__/schema.cpython-313.pyc +0 -0
  24. package/core/sync/__pycache__/self_healing.cpython-313.pyc +0 -0
  25. package/core/sync/agent_provisioner.py +150 -0
  26. package/core/sync/ai_mcp_decider.py +86 -0
  27. package/core/sync/content_merger.py +100 -0
  28. package/core/sync/content_syncer.py +167 -0
  29. package/core/sync/engine.py +20 -0
  30. package/core/sync/mcp_optimizer.py +187 -0
  31. package/core/sync/policy_loader.py +94 -0
  32. package/core/sync/reporter.py +49 -1
  33. package/core/sync/schema.py +37 -0
  34. package/core/sync/self_healing.py +47 -0
  35. package/package.json +1 -1
  36. package/pyproject.toml +1 -1
@@ -0,0 +1,47 @@
1
+ """Retry wrapper for sync engine phases.
2
+
3
+ Wraps phase callables with exponential backoff. Errors are surfaced as
4
+ RetryExhausted after max attempts so the orchestrator can convert them
5
+ into structured SyncError entries on the report.
6
+ """
7
+
8
+ from __future__ import annotations
9
+
10
+ import time
11
+ from typing import Callable, TypeVar
12
+
13
+ T = TypeVar("T")
14
+
15
+
16
+ class RetryExhausted(RuntimeError):
17
+ def __init__(self, message: str, last_exception: BaseException | None = None):
18
+ super().__init__(message)
19
+ self.last_exception = last_exception
20
+
21
+
22
+ def run_with_retry(
23
+ fn: Callable[[], T],
24
+ max_retries: int = 3,
25
+ base_delay: float = 0.1,
26
+ backoff: float = 2.0,
27
+ ) -> T:
28
+ """Call fn with exponential backoff; raise RetryExhausted after max_retries.
29
+
30
+ max_retries=0 means a single attempt (no retries).
31
+ """
32
+ attempt = 0
33
+ last_exc: BaseException | None = None
34
+ while attempt <= max_retries:
35
+ try:
36
+ return fn()
37
+ except Exception as exc: # noqa: BLE001
38
+ last_exc = exc
39
+ if attempt == max_retries:
40
+ break
41
+ time.sleep(base_delay * (backoff ** attempt))
42
+ attempt += 1
43
+
44
+ raise RetryExhausted(
45
+ f"exhausted {max_retries} retries: {last_exc}",
46
+ last_exception=last_exc,
47
+ )
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "arkaos",
3
- "version": "2.16.1",
3
+ "version": "2.17.0",
4
4
  "description": "The Operating System for AI Agent Teams",
5
5
  "type": "module",
6
6
  "bin": {
package/pyproject.toml CHANGED
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "arkaos-core"
3
- version = "2.16.1"
3
+ version = "2.17.0"
4
4
  description = "Core engine for ArkaOS — The Operating System for AI Agent Teams"
5
5
  readme = "README.md"
6
6
  license = {text = "MIT"}