Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 16 additions & 8 deletions backend/core/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,20 @@
- AgenticDaemonSystem: Autonomous background processing and system evolution
"""

from .cognitive_manager import CognitiveManager, get_cognitive_manager
from .agentic_daemon_system import AgenticDaemonSystem, get_agentic_daemon_system
import logging as _logging

__all__ = [
"CognitiveManager",
"get_cognitive_manager",
"AgenticDaemonSystem",
"get_agentic_daemon_system"
]
try:
from .cognitive_manager import CognitiveManager, get_cognitive_manager
from .agentic_daemon_system import AgenticDaemonSystem, get_agentic_daemon_system

__all__ = [
"CognitiveManager",
"get_cognitive_manager",
"AgenticDaemonSystem",
"get_agentic_daemon_system",
]
except ImportError as _exc:
_logging.getLogger(__name__).warning(
"Core architecture imports unavailable (optional dependency missing): %s", _exc
)
__all__ = []
Comment on lines +11 to +25
Copy link

Copilot AI Mar 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

backend.core.__init__ now swallows any ImportError from these imports and silently exposes an empty __all__, which can mask real bugs (not just optional deps) and make failures harder to diagnose. Consider logging the exception (or re-raising unless the missing module is one of the known-optional deps), so broken imports don’t fail silently.

Copilot uses AI. Check for mistakes.
Loading