fix: prevent hermes-agent cli module conflict in aitbc-cli
Some checks failed
Cross-Node Transaction Testing / transaction-test (push) Has been cancelled
Deploy to Testnet / deploy-testnet (push) Has been cancelled
Multi-Node Stress Testing / stress-test (push) Has been cancelled
CLI Tests / test-cli (push) Has been cancelled
Security Scanning / security-scan (push) Has been cancelled
Some checks failed
Cross-Node Transaction Testing / transaction-test (push) Has been cancelled
Deploy to Testnet / deploy-testnet (push) Has been cancelled
Multi-Node Stress Testing / stress-test (push) Has been cancelled
CLI Tests / test-cli (push) Has been cancelled
Security Scanning / security-scan (push) Has been cancelled
- Remove /usr/local/lib/hermes-agent from sys.path in aitbc-cli wrapper - Prevents python -m cli.core.main from resolving to hermes-agent's cli module - Ensures AITBC CLI loads from correct module path - Fixes hermes agent stumble when CLI picks up wrong module
This commit is contained in:
@@ -13,6 +13,11 @@ CLI_DIR = Path(__file__).resolve().parent
|
||||
sys.path.insert(0, str(REPO_ROOT))
|
||||
sys.path.insert(0, str(CLI_DIR))
|
||||
|
||||
# Ensure we don't pick up hermes-agent's cli module
|
||||
hermes_cli_path = "/usr/local/lib/hermes-agent"
|
||||
if hermes_cli_path in sys.path:
|
||||
sys.path.remove(hermes_cli_path)
|
||||
|
||||
from aitbc.constants import BLOCKCHAIN_RPC_PORT
|
||||
|
||||
DEFAULT_RPC_URL = f"http://localhost:{BLOCKCHAIN_RPC_PORT}"
|
||||
|
||||
Reference in New Issue
Block a user