Repository navigation
Tags
Tags
fix(logging): routine planning and execution lines at DEBUG (#110) * fix(logging): routine planning and execution lines at DEBUG "Planning for goal", "Plan found", "Replanning (replan #n)", the MultiGoal sub-goal rounds, the CSP pipeline's validation and selection lines and the executors' per-step lines fire on every round or step. They were INFO and are emitted inside the planner's timed span, so a host that configures an expensive handler on the root logger at INFO (mcp's MCPServer installs a rich one) saw its rendering counted in duration_ms. They are DEBUG now; the lines that report an event (stuck handler, blacklist fallback, an infeasible primary plan, early termination, a rejected approval or form) stay at INFO. Tests: a routine run on either executor emits nothing from langgoap at INFO; the lines are still there at DEBUG; a sleeping INFO handler on the root logger leaves the planner's duration_ms untouched, with the control that at DEBUG the same handler does land inside the span. Fixes #109 * release: 0.3.2
fix(graph): waits look once per resume; cache the tracer hook signatu… …re lookup - A wait looped on interrupt() inside one task, and LangGraph replays a resumed task from its first line: after N idle notifications the next one ran on_resume and the sensors N+1 times. A wait now looks once per resume; when nothing it watches changed it raises StillWaiting, the executor returns no step and no record, and the wait pauses again in a fresh task. The new state key prepared_wait tells that task the wait's execute has run already; it is cleared when the wait ends and by every new plan. Measured: per idle notification 1 on_resume and 1 sensor pass (was N), execute twice in total (start and LangGraph's one replay). - The thread_id keyword filtering called inspect.signature on every hook call: 42 us per call on on_search_expand, which fires per A* expansion. The accepted keyword names are remembered per hook function and current_thread_id() is consulted only for hooks that take thread_id: 3.4 us per call. - waiting_action returns None, not the string "None", when a payload hides the action name; one interrupt_payload helper serves GoapResult.interrupt and GoapGraph.waiting; GoapGraph.compiled compiles under the mailbox lock so two OS threads starting at once compile once.
test(checkpointing): skip docker-backed tests when daemon unreachable GitHub macOS runners ship the 'docker' Python package (pulled in via testcontainers) but not the docker daemon, so the existing 'pytest.importorskip' on testcontainers does not protect the TestPostgresSaver / TestRedisSaver classes from failing with DockerException at fixture setup. Probe 'docker.from_env().ping()' at module load time and skip the rest of the module the same way the existing importorskip pattern does for a missing extra. Behaves correctly on three configurations: * docker daemon reachable -> all 8 tests collected * docker package missing -> existing importorskip skips * docker package present, no daemon -> new probe skips