Skip to content

Conversation

@Wanbogang
Copy link
Collaborator

@Wanbogang Wanbogang commented Feb 11, 2026

Related Issue

#984

Description

Implements selective hot-reload functionality using watchdog library for real-time configuration file monitoring, replacing the previous polling-based approach.

Changes

Hot-Reload Implementation

  • Add watchdog dependency for real-time file monitoring
  • Create ConfigFileWatcher for config file monitoring with debouncing
  • Create HotReloadManager for selective configuration updates
  • Support 3 reload strategies:
    • HOT_RELOAD — apply changes without restart
    • VALIDATE_FIRST — validate before applying
    • RESTART_REQUIRED — requires full system restart
  • Register hot-reloadable fields: system prompts, LLM parameters
  • Mark critical fields (model, provider, api_key) as restart-required
  • Refactor CortexRuntime to use watchdog instead of polling
  • Maintain backward compatibility with check_interval parameter
  • Add comprehensive unit tests for config_watcher module
  • Update ActionOrchestrator to support config propagation via update_config() method

Bug Fixes (found during development)

  • Fix dependency conflict: update om1-modules to commit eedbb2be (resolves missing AudioOutputLiveStream import)
  • Relax vulture constraint from ==2.10 to >=2.10 (resolves conflict with om1-modules requirement for vulture >=2.14)
  • Update hot-reload tests to match new implementation using ConfigFileWatcher

These dependency fixes resolve existing CI/CD failures that were blocking all PRs.

@Wanbogang Wanbogang requested review from a team as code owners February 11, 2026 14:39
@github-actions github-actions bot added dependencies Pull requests that update a dependency file robotics Robotics code changes python Python code tests Test files config Configuration files labels Feb 11, 2026
Wanbogang and others added 4 commits February 11, 2026 22:14
- Update om1-modules to commit eedbb2be (fixes missing AudioOutputLiveStream)
- Relax vulture constraint from ==2.10 to >=2.10 (allows vulture 2.14+ required by om1-modules)
- These changes fix CI/CD test failures unrelated to hot-reload feature
- Update test_reload_config_success to use ConfigChange with proper parameters
- Update test_run_with_hot_reload_enabled to mock ConfigFileWatcher instead of polling
- Update test_run_handles_none_cortex_loop_task_on_reload to handle CancelledError
- Remove AsyncMock warning by using regular Mock for non-async start method
@OpenMind OpenMind deleted a comment from codecov bot Feb 12, 2026
@OpenMind OpenMind deleted a comment from codecov bot Feb 12, 2026
@codecov
Copy link

codecov bot commented Feb 12, 2026

Codecov Report

❌ Patch coverage is 95.06494% with 19 lines in your changes missing coverage. Please review.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
src/runtime/single_mode/cortex.py 93.58% 10 Missing ⚠️
src/actions/orchestrator.py 12.50% 7 Missing ⚠️
src/runtime/single_mode/config.py 66.66% 1 Missing ⚠️
src/utils/config_watcher.py 98.80% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

config Configuration files dependencies Pull requests that update a dependency file python Python code robotics Robotics code changes tests Test files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant