claude-mpm 5.4.100__py3-none-any.whl → 5.4.101__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.
- claude_mpm/VERSION +1 -1
- claude_mpm/cli/commands/autotodos.py +23 -3
- claude_mpm/hooks/claude_hooks/__pycache__/event_handlers.cpython-311.pyc +0 -0
- claude_mpm/hooks/claude_hooks/event_handlers.py +10 -1
- claude_mpm/services/event_log.py +8 -0
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/METADATA +1 -1
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/RECORD +12 -12
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/WHEEL +0 -0
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/entry_points.txt +0 -0
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/licenses/LICENSE +0 -0
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/licenses/LICENSE-FAQ.md +0 -0
- {claude_mpm-5.4.100.dist-info → claude_mpm-5.4.101.dist-info}/top_level.txt +0 -0
claude_mpm/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
5.4.
|
|
1
|
+
5.4.101
|
|
@@ -16,7 +16,7 @@ DESIGN DECISION: Event-driven architecture
|
|
|
16
16
|
import json
|
|
17
17
|
from datetime import datetime, timezone
|
|
18
18
|
from pathlib import Path
|
|
19
|
-
from typing import Any, Dict, List
|
|
19
|
+
from typing import Any, Dict, List, Optional
|
|
20
20
|
|
|
21
21
|
import click
|
|
22
22
|
|
|
@@ -129,7 +129,9 @@ def get_autotodos(max_todos: int = 100) -> List[Dict[str, Any]]:
|
|
|
129
129
|
return todos
|
|
130
130
|
|
|
131
131
|
|
|
132
|
-
def get_pending_todos(
|
|
132
|
+
def get_pending_todos(
|
|
133
|
+
max_todos: int = 10, working_dir: Optional[Path] = None
|
|
134
|
+
) -> List[Dict[str, Any]]:
|
|
133
135
|
"""Get pending autotodo errors for injection.
|
|
134
136
|
|
|
135
137
|
WHY this function exists:
|
|
@@ -139,11 +141,29 @@ def get_pending_todos(max_todos: int = 10) -> List[Dict[str, Any]]:
|
|
|
139
141
|
|
|
140
142
|
Args:
|
|
141
143
|
max_todos: Maximum number of todos to return (default: 10)
|
|
144
|
+
working_dir: Working directory to use for event log path (default: Path.cwd())
|
|
142
145
|
|
|
143
146
|
Returns:
|
|
144
147
|
List of todo dicts with content, activeForm, status, metadata
|
|
145
148
|
"""
|
|
146
|
-
|
|
149
|
+
# Construct log file path from working_dir if provided
|
|
150
|
+
log_file = None
|
|
151
|
+
if working_dir:
|
|
152
|
+
log_file = Path(working_dir) / ".claude-mpm" / "event_log.json"
|
|
153
|
+
|
|
154
|
+
event_log = get_event_log(log_file)
|
|
155
|
+
todos = []
|
|
156
|
+
|
|
157
|
+
# Get all pending autotodo.error events (script failures)
|
|
158
|
+
pending_error_events = event_log.list_events(
|
|
159
|
+
event_type="autotodo.error", status="pending"
|
|
160
|
+
)
|
|
161
|
+
|
|
162
|
+
for event in pending_error_events[:max_todos]:
|
|
163
|
+
todo = format_error_event_as_todo(event)
|
|
164
|
+
todos.append(todo)
|
|
165
|
+
|
|
166
|
+
return todos
|
|
147
167
|
|
|
148
168
|
|
|
149
169
|
@click.group(name="autotodos")
|
|
Binary file
|
|
@@ -965,6 +965,8 @@ class EventHandlers:
|
|
|
965
965
|
|
|
966
966
|
# Auto-inject pending autotodos if enabled
|
|
967
967
|
try:
|
|
968
|
+
from pathlib import Path
|
|
969
|
+
|
|
968
970
|
from claude_mpm.cli.commands.autotodos import get_pending_todos
|
|
969
971
|
from claude_mpm.core.config import Config
|
|
970
972
|
|
|
@@ -973,7 +975,14 @@ class EventHandlers:
|
|
|
973
975
|
max_todos = config.get("autotodos.max_todos_per_session", 10)
|
|
974
976
|
|
|
975
977
|
if auto_inject_enabled:
|
|
976
|
-
|
|
978
|
+
# Pass working directory from event to avoid Path.cwd() issues
|
|
979
|
+
working_dir_param = None
|
|
980
|
+
if working_dir:
|
|
981
|
+
working_dir_param = Path(working_dir)
|
|
982
|
+
|
|
983
|
+
pending_todos = get_pending_todos(
|
|
984
|
+
max_todos=max_todos, working_dir=working_dir_param
|
|
985
|
+
)
|
|
977
986
|
if pending_todos:
|
|
978
987
|
session_start_data["pending_autotodos"] = pending_todos
|
|
979
988
|
session_start_data["autotodos_count"] = len(pending_todos)
|
claude_mpm/services/event_log.py
CHANGED
|
@@ -310,8 +310,16 @@ def get_event_log(log_file: Optional[Path] = None) -> EventLog:
|
|
|
310
310
|
|
|
311
311
|
Returns:
|
|
312
312
|
EventLog instance
|
|
313
|
+
|
|
314
|
+
Note:
|
|
315
|
+
If log_file is provided and differs from the current instance,
|
|
316
|
+
a new EventLog is created and replaces the global instance.
|
|
317
|
+
This allows hooks to use project-specific event logs.
|
|
313
318
|
"""
|
|
314
319
|
global _event_log
|
|
315
320
|
if _event_log is None:
|
|
316
321
|
_event_log = EventLog(log_file)
|
|
322
|
+
elif log_file is not None and _event_log.log_file != log_file:
|
|
323
|
+
# Create new instance if log file differs from current
|
|
324
|
+
_event_log = EventLog(log_file)
|
|
317
325
|
return _event_log
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
claude_mpm/BUILD_NUMBER,sha256=9JfxhnDtr-8l3kCP2U5TVXSErptHoga8m7XA8zqgGOc,4
|
|
2
|
-
claude_mpm/VERSION,sha256=
|
|
2
|
+
claude_mpm/VERSION,sha256=7uiIfp7M7ZlTKcn8sVbkpSxsQFNScL0dijhJ4CJP95s,8
|
|
3
3
|
claude_mpm/__init__.py,sha256=AGfh00BHKvLYD-UVFw7qbKtl7NMRIzRXOWw7vEuZ-h4,2214
|
|
4
4
|
claude_mpm/__main__.py,sha256=Ro5UBWBoQaSAIoSqWAr7zkbLyvi4sSy28WShqAhKJG0,723
|
|
5
5
|
claude_mpm/constants.py,sha256=pz3lTrZZR5HhV3eZzYtIbtBwWo7iM6pkBHP_ixxmI6Y,6827
|
|
@@ -58,7 +58,7 @@ claude_mpm/cli/commands/aggregate.py,sha256=v5JzzoWf6Omc4DaWfx_3gm5EWiUmUp6ps3Bd
|
|
|
58
58
|
claude_mpm/cli/commands/analyze.py,sha256=NuSreG9PINgf_1_41adMT_sOXz-z695Zqjwef4OEc9w,19162
|
|
59
59
|
claude_mpm/cli/commands/analyze_code.py,sha256=5FAoubjZbEO_GlErj3xNgNbJXBjhtqSOWE2FkhAzTaM,17256
|
|
60
60
|
claude_mpm/cli/commands/auto_configure.py,sha256=0Suzil6O0SBNeHUCwHOkt2q7gfuXRTyUu2UC99cCG4Y,40567
|
|
61
|
-
claude_mpm/cli/commands/autotodos.py,sha256=
|
|
61
|
+
claude_mpm/cli/commands/autotodos.py,sha256=mm2R6dIfHOjAMCgFkjfjBzdFQ-ou19b_R3Lo0Vi8vCI,19428
|
|
62
62
|
claude_mpm/cli/commands/cleanup.py,sha256=RQikOGLuLFWXzjeoHArdr5FA4Pf7tSK9w2NXL4vCrok,19769
|
|
63
63
|
claude_mpm/cli/commands/cleanup_orphaned_agents.py,sha256=JR8crvgrz7Sa6d-SI-gKywok5S9rwc_DzDVk_h85sVs,4467
|
|
64
64
|
claude_mpm/cli/commands/config.py,sha256=2M9VUPYcQkBUCIyyB-v1qTL3xYvao9YI2l_JGBUDauA,23374
|
|
@@ -336,7 +336,7 @@ claude_mpm/hooks/claude_hooks/__init__.py,sha256=b4mud_g3S-3itHY_Dzpbb_SmdMEcJwt
|
|
|
336
336
|
claude_mpm/hooks/claude_hooks/auto_pause_handler.py,sha256=xDAQZ33I5OhGvtWvA9mxwVSoir9tM-aCvrWkSRdnVmU,17465
|
|
337
337
|
claude_mpm/hooks/claude_hooks/connection_pool.py,sha256=vpi-XbVf61GWhh85tHBzubbOgbJly_I-5-QmsleND2M,8658
|
|
338
338
|
claude_mpm/hooks/claude_hooks/correlation_manager.py,sha256=3n-RxzqE8egG4max_NcpJgL9gzrBY6Ti529LrjleI1g,2033
|
|
339
|
-
claude_mpm/hooks/claude_hooks/event_handlers.py,sha256=
|
|
339
|
+
claude_mpm/hooks/claude_hooks/event_handlers.py,sha256=_GUOe9urO9RVIaOWSNXv2F_di4D7SaePjxONyd37das,47019
|
|
340
340
|
claude_mpm/hooks/claude_hooks/hook_handler.py,sha256=R2RhUoRvI0q_EGu-d5L9bH7cGg5_OLDskQoNrl3JsU0,28504
|
|
341
341
|
claude_mpm/hooks/claude_hooks/hook_wrapper.sh,sha256=4lG3TlLVoVfTJipPj1X_ICUlS-KpnkbUp1U3oSq80Bw,2476
|
|
342
342
|
claude_mpm/hooks/claude_hooks/installer.py,sha256=VbvVGMcrmCXQB3Pf9zOdjeGET2AFqbUDMHDy5KXuvz0,30463
|
|
@@ -346,7 +346,7 @@ claude_mpm/hooks/claude_hooks/tool_analysis.py,sha256=3_o2PP9D7wEMwLriCtIBOw0cj2
|
|
|
346
346
|
claude_mpm/hooks/claude_hooks/__pycache__/__init__.cpython-311.pyc,sha256=EGpgXqhPM0iRRZtCqHaLVQ6wDH42OH_M7Gt5GiFLyro,346
|
|
347
347
|
claude_mpm/hooks/claude_hooks/__pycache__/auto_pause_handler.cpython-311.pyc,sha256=X7A8O4KPXkuDaLDFbF7Izi1qVDyS0tQjHVo1xy_HzNQ,21172
|
|
348
348
|
claude_mpm/hooks/claude_hooks/__pycache__/correlation_manager.cpython-311.pyc,sha256=SQX5iiP9bQZkLL-cj_2tlGH7lpAzarO0mYal7btj3tc,3521
|
|
349
|
-
claude_mpm/hooks/claude_hooks/__pycache__/event_handlers.cpython-311.pyc,sha256=
|
|
349
|
+
claude_mpm/hooks/claude_hooks/__pycache__/event_handlers.cpython-311.pyc,sha256=76VtByCuOr7L1_snjeHo1iWDyD2QyvoMpAj1hrSq4-Q,45735
|
|
350
350
|
claude_mpm/hooks/claude_hooks/__pycache__/hook_handler.cpython-311.pyc,sha256=ehLm68zhDmqOwzr1Di6xYjGuE9SRg0mvKePQfepuuQ4,30577
|
|
351
351
|
claude_mpm/hooks/claude_hooks/__pycache__/installer.cpython-311.pyc,sha256=9mpAKY4gNcbU5VvZ5tGbf2UM0uIEWdreKSUvVr_BKcM,33917
|
|
352
352
|
claude_mpm/hooks/claude_hooks/__pycache__/memory_integration.cpython-311.pyc,sha256=YbwauQDKSGvXkT1972faalJLuxwyvq328DYQhkCnel0,10513
|
|
@@ -390,7 +390,7 @@ claude_mpm/services/command_deployment_service.py,sha256=GgSxRehQY-PR-yeztz9WP8w
|
|
|
390
390
|
claude_mpm/services/command_handler_service.py,sha256=8iru6eRdQloXrGiE75E1zoUbD_Ajldu3sw17Yx772Lw,7280
|
|
391
391
|
claude_mpm/services/delegation_detector.py,sha256=ZpElqjhTbuEeeTjTMUsl-G1lHMJ9m1g-6orM3t7wNfM,6168
|
|
392
392
|
claude_mpm/services/event_aggregator.py,sha256=V_5Wln1RzozLMDZawIPl5gSjIN5KHniNPaaSP11Lihc,20251
|
|
393
|
-
claude_mpm/services/event_log.py,sha256=
|
|
393
|
+
claude_mpm/services/event_log.py,sha256=pMKc8p2lXRoRi_cvVxaU1uNuUCNrGc0EXqBv8TeueyI,10043
|
|
394
394
|
claude_mpm/services/exceptions.py,sha256=5lVZETr_6-xk0ItH7BTfYUiX5RlckS1e8ah_UalYG9c,26475
|
|
395
395
|
claude_mpm/services/hook_installer_service.py,sha256=x3H3bFVlmhK4Ue1K279f44lwMEw3W1p3zoETGfjIH_w,19708
|
|
396
396
|
claude_mpm/services/hook_service.py,sha256=I6JILbackBsdvrDNQ9TeGSB7XNqozNRP26T4E9_ROtU,15693
|
|
@@ -998,10 +998,10 @@ claude_mpm/utils/subprocess_utils.py,sha256=D0izRT8anjiUb_JG72zlJR_JAw1cDkb7kalN
|
|
|
998
998
|
claude_mpm/validation/__init__.py,sha256=YZhwE3mhit-lslvRLuwfX82xJ_k4haZeKmh4IWaVwtk,156
|
|
999
999
|
claude_mpm/validation/agent_validator.py,sha256=GprtAvu80VyMXcKGsK_VhYiXWA6BjKHv7O6HKx0AB9w,20917
|
|
1000
1000
|
claude_mpm/validation/frontmatter_validator.py,sha256=YpJlYNNYcV8u6hIOi3_jaRsDnzhbcQpjCBE6eyBKaFY,7076
|
|
1001
|
-
claude_mpm-5.4.
|
|
1002
|
-
claude_mpm-5.4.
|
|
1003
|
-
claude_mpm-5.4.
|
|
1004
|
-
claude_mpm-5.4.
|
|
1005
|
-
claude_mpm-5.4.
|
|
1006
|
-
claude_mpm-5.4.
|
|
1007
|
-
claude_mpm-5.4.
|
|
1001
|
+
claude_mpm-5.4.101.dist-info/licenses/LICENSE,sha256=ca3y_Rk4aPrbF6f62z8Ht5MJM9OAvbGlHvEDcj9vUQ4,3867
|
|
1002
|
+
claude_mpm-5.4.101.dist-info/licenses/LICENSE-FAQ.md,sha256=TxfEkXVCK98RzDOer09puc7JVCP_q_bN4dHtZKHCMcM,5104
|
|
1003
|
+
claude_mpm-5.4.101.dist-info/METADATA,sha256=EcAf5IvBn4Rh-1LQeXukAQkwnYbxaMJAVrRuXE5LD6c,14350
|
|
1004
|
+
claude_mpm-5.4.101.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
1005
|
+
claude_mpm-5.4.101.dist-info/entry_points.txt,sha256=n-Uk4vwHPpuvu-g_I7-GHORzTnN_m6iyOsoLveKKD0E,228
|
|
1006
|
+
claude_mpm-5.4.101.dist-info/top_level.txt,sha256=1nUg3FEaBySgm8t-s54jK5zoPnu3_eY6EP6IOlekyHA,11
|
|
1007
|
+
claude_mpm-5.4.101.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|