maop-orchestrator 5.3.0__tar.gz
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.
- maop_orchestrator-5.3.0/.gitignore +194 -0
- maop_orchestrator-5.3.0/Dockerfile +157 -0
- maop_orchestrator-5.3.0/PKG-INFO +87 -0
- maop_orchestrator-5.3.0/README.md +21 -0
- maop_orchestrator-5.3.0/SECURITY.md +123 -0
- maop_orchestrator-5.3.0/conftest.py +64 -0
- maop_orchestrator-5.3.0/docker-entrypoint.sh +38 -0
- maop_orchestrator-5.3.0/maop/__init__.py +7 -0
- maop_orchestrator-5.3.0/maop/__main__.py +5 -0
- maop_orchestrator-5.3.0/maop/ab_test_framework.py +377 -0
- maop_orchestrator-5.3.0/maop/agent_strategy_learner.py +444 -0
- maop_orchestrator-5.3.0/maop/cache_evolver.py +422 -0
- maop_orchestrator-5.3.0/maop/cli.py +747 -0
- maop_orchestrator-5.3.0/maop/concurrency.py +474 -0
- maop_orchestrator-5.3.0/maop/config/README.md +73 -0
- maop_orchestrator-5.3.0/maop/config/__init__.py +29 -0
- maop_orchestrator-5.3.0/maop/config/agents_validator.py +137 -0
- maop_orchestrator-5.3.0/maop/config/edition.py +541 -0
- maop_orchestrator-5.3.0/maop/config/env.py +153 -0
- maop_orchestrator-5.3.0/maop/config/hot_reload.py +234 -0
- maop_orchestrator-5.3.0/maop/config/loader.py +324 -0
- maop_orchestrator-5.3.0/maop/config/mcp_marketplace.yaml +29 -0
- maop_orchestrator-5.3.0/maop/config/settings.py +423 -0
- maop_orchestrator-5.3.0/maop/control/__init__.py +5 -0
- maop_orchestrator-5.3.0/maop/control/audit.py +117 -0
- maop_orchestrator-5.3.0/maop/control/plane.py +224 -0
- maop_orchestrator-5.3.0/maop/core/ARCHITECTURE.md +190 -0
- maop_orchestrator-5.3.0/maop/core/__init__.py +60 -0
- maop_orchestrator-5.3.0/maop/core/agent/__init__.py +419 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/__init__.py +71 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/adapter_factory.py +177 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/cli_adapter.py +303 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/desktop_app_adapter.py +403 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/http_adapter.py +230 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/ide_extension_adapter.py +517 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/mcp_bridge_adapter.py +196 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/vibe_coding_adapter.py +406 -0
- maop_orchestrator-5.3.0/maop/core/agent/adapters/web_adapter.py +219 -0
- maop_orchestrator-5.3.0/maop/core/agent/analyzer/__init__.py +20 -0
- maop_orchestrator-5.3.0/maop/core/agent/analyzer/analyzer.py +752 -0
- maop_orchestrator-5.3.0/maop/core/agent/auth/__init__.py +23 -0
- maop_orchestrator-5.3.0/maop/core/agent/auth/agent_proxy_gateway.py +489 -0
- maop_orchestrator-5.3.0/maop/core/agent/auth/credential_vault.py +531 -0
- maop_orchestrator-5.3.0/maop/core/agent/auth/harness_auth.py +430 -0
- maop_orchestrator-5.3.0/maop/core/agent/billing/__init__.py +48 -0
- maop_orchestrator-5.3.0/maop/core/agent/billing/billing_abstraction.py +411 -0
- maop_orchestrator-5.3.0/maop/core/agent/billing/quota_alert.py +357 -0
- maop_orchestrator-5.3.0/maop/core/agent/billing/quota_bucket.py +582 -0
- maop_orchestrator-5.3.0/maop/core/agent/dag/__init__.py +6 -0
- maop_orchestrator-5.3.0/maop/core/agent/dag/dag_progress_emitter.py +364 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/__init__.py +13 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/a2a.py +431 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/agent_proxy.py +282 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/human_proxy.py +241 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/subagent_db.py +409 -0
- maop_orchestrator-5.3.0/maop/core/agent/delegation/subagent_lifecycle.py +626 -0
- maop_orchestrator-5.3.0/maop/core/agent/discovery/__init__.py +54 -0
- maop_orchestrator-5.3.0/maop/core/agent/discovery/agent_discovery.py +246 -0
- maop_orchestrator-5.3.0/maop/core/agent/discovery/config_template.py +530 -0
- maop_orchestrator-5.3.0/maop/core/agent/discovery/discovery_mixin.py +473 -0
- maop_orchestrator-5.3.0/maop/core/agent/discovery/discovery_models.py +167 -0
- maop_orchestrator-5.3.0/maop/core/agent/evolution/__init__.py +3 -0
- maop_orchestrator-5.3.0/maop/core/agent/evolution/agent_evolution.py +647 -0
- maop_orchestrator-5.3.0/maop/core/agent/evolution/phases.py +45 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/__init__.py +13 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/agent_lifecycle.py +240 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/agent_performance.py +283 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/agent_registry.py +461 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/agent_repair.py +321 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/agent_scanner.py +503 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/runtime.py +428 -0
- maop_orchestrator-5.3.0/maop/core/agent/lifecycle/state_classifier.py +237 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/__init__.py +10 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/chat_engine.py +434 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/context_compressor.py +459 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/conversation.py +304 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/function_call.py +353 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/llm_factory.py +374 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/llm_models.py +72 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/llm_provider.py +76 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/llm_providers.py +484 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/model_gateway.py +541 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/output_parser.py +197 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/react_loop.py +573 -0
- maop_orchestrator-5.3.0/maop/core/agent/llm_chat/relay_platform.py +755 -0
- maop_orchestrator-5.3.0/maop/core/agent/memory_ctx/__init__.py +4 -0
- maop_orchestrator-5.3.0/maop/core/agent/memory_ctx/agent_memory.py +364 -0
- maop_orchestrator-5.3.0/maop/core/agent/memory_ctx/project_context.py +237 -0
- maop_orchestrator-5.3.0/maop/core/agent/memory_ctx/worktree.py +482 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/__init__.py +65 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/capability_probe.py +446 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/health_scorer.py +371 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/result_cache.py +425 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/sandbox_executor.py +495 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/sla_manager.py +361 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/tenant_isolation.py +516 -0
- maop_orchestrator-5.3.0/maop/core/agent/ops/usage_statistics.py +578 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/__init__.py +15 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/hook_manager.py +776 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/plugin.py +78 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/plugin_hooks.py +42 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/plugin_manager.py +509 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/plugin_sandbox.py +386 -0
- maop_orchestrator-5.3.0/maop/core/agent/plugins_hooks/protocol.py +266 -0
- maop_orchestrator-5.3.0/maop/core/agent/registry/__init__.py +41 -0
- maop_orchestrator-5.3.0/maop/core/agent/registry/agent_catalog.py +372 -0
- maop_orchestrator-5.3.0/maop/core/agent/registry/agent_catalog_store.py +239 -0
- maop_orchestrator-5.3.0/maop/core/agent/registry/preset_agents.py +920 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/__init__.py +45 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/agent_collaboration.py +252 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/agent_router.py +718 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/collaboration_executor.py +355 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/collaboration_models.py +168 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/collaboration_patterns.py +196 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/health_check_scheduler.py +390 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/long_running_task.py +657 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/rate_limiter.py +176 -0
- maop_orchestrator-5.3.0/maop/core/agent/router/routing_audit.py +257 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/__init__.py +6 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/capability_matcher.py +193 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/tool_audit.py +246 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/tool_manager.py +586 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/tool_policy.py +255 -0
- maop_orchestrator-5.3.0/maop/core/agent/tools/tool_schema.py +273 -0
- maop_orchestrator-5.3.0/maop/core/agent/vendor/__init__.py +55 -0
- maop_orchestrator-5.3.0/maop/core/agent/vendor/vendor_billing.py +441 -0
- maop_orchestrator-5.3.0/maop/core/agent/vendor/vendor_ecosystem.py +371 -0
- maop_orchestrator-5.3.0/maop/core/agent/vendor/vendor_sso.py +389 -0
- maop_orchestrator-5.3.0/maop/core/backends/__init__.py +191 -0
- maop_orchestrator-5.3.0/maop/core/backends/artifact_store.py +296 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends.py +457 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_distributed.py +432 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_pg.py +303 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_queue.py +355 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_rabbitmq.py +380 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_redis.py +263 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_secret.py +165 -0
- maop_orchestrator-5.3.0/maop/core/backends/backends_vault.py +99 -0
- maop_orchestrator-5.3.0/maop/core/backends/data.py +650 -0
- maop_orchestrator-5.3.0/maop/core/backends/db_backup.py +641 -0
- maop_orchestrator-5.3.0/maop/core/backends/db_utils.py +458 -0
- maop_orchestrator-5.3.0/maop/core/backends/image_store.py +324 -0
- maop_orchestrator-5.3.0/maop/core/backends/kv_store.py +436 -0
- maop_orchestrator-5.3.0/maop/core/backends/migration.py +379 -0
- maop_orchestrator-5.3.0/maop/core/budget_guard.py +266 -0
- maop_orchestrator-5.3.0/maop/core/config/__init__.py +8 -0
- maop_orchestrator-5.3.0/maop/core/config/config_history.py +335 -0
- maop_orchestrator-5.3.0/maop/core/cost_tracker.py +563 -0
- maop_orchestrator-5.3.0/maop/core/evolution/__init__.py +104 -0
- maop_orchestrator-5.3.0/maop/core/evolution/ab_test.py +521 -0
- maop_orchestrator-5.3.0/maop/core/evolution/auto_deployer.py +338 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evaluator.py +267 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_agent.py +183 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_analyzers.py +304 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_collectors.py +122 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_loop.py +512 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_loop_types.py +120 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_perf_loop.py +334 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_phases.py +609 -0
- maop_orchestrator-5.3.0/maop/core/evolution/evolution_strategies.py +292 -0
- maop_orchestrator-5.3.0/maop/core/evolution/narrative.py +474 -0
- maop_orchestrator-5.3.0/maop/core/evolution/prompt_version.py +194 -0
- maop_orchestrator-5.3.0/maop/core/evolution/regression.py +345 -0
- maop_orchestrator-5.3.0/maop/core/evolution/skill_version.py +413 -0
- maop_orchestrator-5.3.0/maop/core/evolution/suggester.py +337 -0
- maop_orchestrator-5.3.0/maop/core/marketplace/__init__.py +14 -0
- maop_orchestrator-5.3.0/maop/core/marketplace/key_management.py +560 -0
- maop_orchestrator-5.3.0/maop/core/marketplace/sandbox.py +344 -0
- maop_orchestrator-5.3.0/maop/core/marketplace/signing.py +393 -0
- maop_orchestrator-5.3.0/maop/core/mcp/__init__.py +111 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_adapter.py +309 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_audit.py +301 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_cache.py +288 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_call_stats.py +200 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_concurrency.py +229 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_discovery.py +255 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub.py +789 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub_compat.py +208 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub_metrics.py +203 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub_ops.py +339 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub_transport.py +559 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_hub_types.py +136 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_marketplace.py +563 -0
- maop_orchestrator-5.3.0/maop/core/mcp/mcp_permission.py +326 -0
- maop_orchestrator-5.3.0/maop/core/memory/__init__.py +124 -0
- maop_orchestrator-5.3.0/maop/core/memory/bloom_filter.py +227 -0
- maop_orchestrator-5.3.0/maop/core/memory/episodic_consolidation.py +166 -0
- maop_orchestrator-5.3.0/maop/core/memory/episodic_store.py +486 -0
- maop_orchestrator-5.3.0/maop/core/memory/hnsw_index.py +199 -0
- maop_orchestrator-5.3.0/maop/core/memory/hybrid_search.py +236 -0
- maop_orchestrator-5.3.0/maop/core/memory/knowledge_extractor.py +436 -0
- maop_orchestrator-5.3.0/maop/core/memory/knowledge_graph.py +586 -0
- maop_orchestrator-5.3.0/maop/core/memory/protocol_aliases.py +314 -0
- maop_orchestrator-5.3.0/maop/core/memory/semantic.py +38 -0
- maop_orchestrator-5.3.0/maop/core/memory/semantic_cache.py +327 -0
- maop_orchestrator-5.3.0/maop/core/memory/three_layer_memory.py +259 -0
- maop_orchestrator-5.3.0/maop/core/memory/three_layer_memory_types.py +149 -0
- maop_orchestrator-5.3.0/maop/core/memory/three_layer_memory_utils.py +100 -0
- maop_orchestrator-5.3.0/maop/core/memory/transform.py +320 -0
- maop_orchestrator-5.3.0/maop/core/memory/vector.py +55 -0
- maop_orchestrator-5.3.0/maop/core/memory/vector_embed.py +159 -0
- maop_orchestrator-5.3.0/maop/core/memory/vector_search_mixin.py +315 -0
- maop_orchestrator-5.3.0/maop/core/memory/vector_store.py +473 -0
- maop_orchestrator-5.3.0/maop/core/memory/working_memory.py +87 -0
- maop_orchestrator-5.3.0/maop/core/monitoring/__init__.py +171 -0
- maop_orchestrator-5.3.0/maop/core/monitoring/monitoring.py +800 -0
- maop_orchestrator-5.3.0/maop/core/monitoring/otel.py +205 -0
- maop_orchestrator-5.3.0/maop/core/monitoring/timeseries.py +374 -0
- maop_orchestrator-5.3.0/maop/core/observability/__init__.py +180 -0
- maop_orchestrator-5.3.0/maop/core/observability/logging.py +189 -0
- maop_orchestrator-5.3.0/maop/core/observability/metrics.py +324 -0
- maop_orchestrator-5.3.0/maop/core/observability/tracing.py +471 -0
- maop_orchestrator-5.3.0/maop/core/personal_cost_guard.py +160 -0
- maop_orchestrator-5.3.0/maop/core/reliability/__init__.py +231 -0
- maop_orchestrator-5.3.0/maop/core/reliability/blackboard.py +689 -0
- maop_orchestrator-5.3.0/maop/core/reliability/cache.py +476 -0
- maop_orchestrator-5.3.0/maop/core/reliability/cache_advanced.py +236 -0
- maop_orchestrator-5.3.0/maop/core/reliability/cache_guard.py +282 -0
- maop_orchestrator-5.3.0/maop/core/reliability/change_tracker.py +456 -0
- maop_orchestrator-5.3.0/maop/core/reliability/circuit_breaker.py +761 -0
- maop_orchestrator-5.3.0/maop/core/reliability/config_mutator.py +500 -0
- maop_orchestrator-5.3.0/maop/core/reliability/dag_scheduler.py +465 -0
- maop_orchestrator-5.3.0/maop/core/reliability/error_ledger.py +230 -0
- maop_orchestrator-5.3.0/maop/core/reliability/error_schema.py +106 -0
- maop_orchestrator-5.3.0/maop/core/reliability/event_bus.py +424 -0
- maop_orchestrator-5.3.0/maop/core/reliability/filelock.py +217 -0
- maop_orchestrator-5.3.0/maop/core/reliability/log_rotate.py +304 -0
- maop_orchestrator-5.3.0/maop/core/reliability/message_queue.py +791 -0
- maop_orchestrator-5.3.0/maop/core/reliability/pipeline_checkpoint.py +395 -0
- maop_orchestrator-5.3.0/maop/core/reliability/preemptable_worker_pool.py +606 -0
- maop_orchestrator-5.3.0/maop/core/reliability/priority_queue.py +237 -0
- maop_orchestrator-5.3.0/maop/core/reliability/rate_limiter.py +221 -0
- maop_orchestrator-5.3.0/maop/core/reliability/safe_writer.py +141 -0
- maop_orchestrator-5.3.0/maop/core/reliability/self_heal.py +265 -0
- maop_orchestrator-5.3.0/maop/core/reliability/services.py +237 -0
- maop_orchestrator-5.3.0/maop/core/reliability/streaming.py +212 -0
- maop_orchestrator-5.3.0/maop/core/reliability/worker_pool.py +622 -0
- maop_orchestrator-5.3.0/maop/core/routing/__init__.py +86 -0
- maop_orchestrator-5.3.0/maop/core/routing/load_balancer.py +668 -0
- maop_orchestrator-5.3.0/maop/core/routing/provider_health.py +226 -0
- maop_orchestrator-5.3.0/maop/core/routing/route_scorer.py +611 -0
- maop_orchestrator-5.3.0/maop/core/routing/routing_decision.py +443 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/__init__.py +46 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/distributed_scheduler.py +811 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/failure_detector.py +599 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor.py +250 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_action.py +331 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_dispatch.py +150 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_health.py +179 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_models.py +184 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_patrol.py +249 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_rules.py +187 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/supervisor_status.py +224 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/task_splitter.py +445 -0
- maop_orchestrator-5.3.0/maop/core/scheduling/worker_pool.py +368 -0
- maop_orchestrator-5.3.0/maop/core/security/__init__.py +133 -0
- maop_orchestrator-5.3.0/maop/core/security/api_key_manager.py +786 -0
- maop_orchestrator-5.3.0/maop/core/security/api_key_vault.py +326 -0
- maop_orchestrator-5.3.0/maop/core/security/auth.py +644 -0
- maop_orchestrator-5.3.0/maop/core/security/byok.py +192 -0
- maop_orchestrator-5.3.0/maop/core/security/dispatch_gate.py +139 -0
- maop_orchestrator-5.3.0/maop/core/security/guardrail.py +451 -0
- maop_orchestrator-5.3.0/maop/core/security/ldap_models.py +142 -0
- maop_orchestrator-5.3.0/maop/core/security/ldap_provider.py +471 -0
- maop_orchestrator-5.3.0/maop/core/security/ldap_search.py +287 -0
- maop_orchestrator-5.3.0/maop/core/security/middleware.py +690 -0
- maop_orchestrator-5.3.0/maop/core/security/permission.py +166 -0
- maop_orchestrator-5.3.0/maop/core/security/sandbox.py +633 -0
- maop_orchestrator-5.3.0/maop/core/security/session.py +396 -0
- maop_orchestrator-5.3.0/maop/core/security/tls.py +159 -0
- maop_orchestrator-5.3.0/maop/core/security/url_validator.py +196 -0
- maop_orchestrator-5.3.0/maop/core/subagent_delegation.py +262 -0
- maop_orchestrator-5.3.0/maop/core/tenant/__init__.py +51 -0
- maop_orchestrator-5.3.0/maop/core/tenant/audit.py +278 -0
- maop_orchestrator-5.3.0/maop/core/tenant/compliance.py +67 -0
- maop_orchestrator-5.3.0/maop/core/tenant/compliance_manager.py +360 -0
- maop_orchestrator-5.3.0/maop/core/tenant/context.py +96 -0
- maop_orchestrator-5.3.0/maop/core/tenant/gdpr_manager.py +742 -0
- maop_orchestrator-5.3.0/maop/core/tenant/hierarchy.py +676 -0
- maop_orchestrator-5.3.0/maop/core/tenant/manager.py +355 -0
- maop_orchestrator-5.3.0/maop/core/tenant/quota.py +293 -0
- maop_orchestrator-5.3.0/maop/core/tenant/rls.py +275 -0
- maop_orchestrator-5.3.0/maop/core/utils/__init__.py +8 -0
- maop_orchestrator-5.3.0/maop/core/utils/async_subprocess.py +82 -0
- maop_orchestrator-5.3.0/maop/core/vector/__init__.py +217 -0
- maop_orchestrator-5.3.0/maop/core/vector/factory.py +73 -0
- maop_orchestrator-5.3.0/maop/core/vector/pg_backend.py +513 -0
- maop_orchestrator-5.3.0/maop/core/vector/sqlite_backend.py +171 -0
- maop_orchestrator-5.3.0/maop/dashboard/__init__.py +17 -0
- maop_orchestrator-5.3.0/maop/dashboard/_middleware_stack.py +195 -0
- maop_orchestrator-5.3.0/maop/dashboard/_register_routes.py +824 -0
- maop_orchestrator-5.3.0/maop/dashboard/_ws_manager.py +86 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/__init__.py +26 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/mcp.py +113 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/models.py +122 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/prompts.py +100 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/routing.py +176 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/security.py +115 -0
- maop_orchestrator-5.3.0/maop/dashboard/channels/skills.py +61 -0
- maop_orchestrator-5.3.0/maop/dashboard/data_proxy.py +459 -0
- maop_orchestrator-5.3.0/maop/dashboard/error_handler.py +180 -0
- maop_orchestrator-5.3.0/maop/dashboard/lifespan.py +130 -0
- maop_orchestrator-5.3.0/maop/dashboard/provider.py +276 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/__init__.py +16 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_catalog.py +182 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_collaboration.py +142 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_proxy.py +114 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_proxy_gateway.py +191 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_router.py +150 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_versions.py +333 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agent_versions_helpers.py +273 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/__init__.py +58 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/_deps.py +91 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/crud.py +402 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/evolution.py +215 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/memory.py +82 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/agents/routes.py +150 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/alerts.py +81 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/analysis.py +146 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/analysis_helpers.py +180 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/api_keys.py +208 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/audit.py +300 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/auth.py +497 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/billing_abstraction.py +111 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/blackboard.py +136 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/budget.py +70 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/chat.py +245 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/compliance.py +371 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/config.py +132 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/control.py +186 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/cost.py +159 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/credential_vault.py +168 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/dag.py +113 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/data.py +360 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/debate.py +241 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/error_handler.py +3 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/evolution_experiment.py +311 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/evolve_insights.py +242 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/feedback.py +304 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/hook.py +169 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/hooks.py +356 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/info/__init__.py +25 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/info/activity.py +147 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/info/admin.py +179 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/info/meta.py +422 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/knowledge.py +203 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/licenses.py +250 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/long_running_task.py +170 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/mcp.py +305 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/memory.py +163 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/model.py +238 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/model_gateway.py +158 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/n8n.py +188 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/notifications.py +763 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/observability.py +153 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/permission.py +103 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/plugin.py +133 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/protocol.py +143 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/quota.py +123 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/quotas.py +376 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/rbac.py +229 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/react.py +178 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/relay_platform.py +144 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/routing.py +100 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/routing_preview.py +59 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/scheduling.py +107 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/session.py +245 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/sso.py +570 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/state.py +119 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/stream.py +168 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/subagent.py +124 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/supervisor.py +223 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/__init__.py +83 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/_deps.py +103 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/agent_admin.py +305 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/framework.py +144 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/overview.py +372 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/v4_misc.py +123 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/system/workflow.py +125 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/tenant.py +159 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/tool_audit.py +54 -0
- maop_orchestrator-5.3.0/maop/dashboard/routers/worktree.py +184 -0
- maop_orchestrator-5.3.0/maop/dashboard/server.py +403 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/__init__.py +6 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/agent_service.py +811 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/agent_versions_service.py +584 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/auth_service.py +574 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/billing_service.py +636 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/blackboard_service.py +116 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/budget_service.py +255 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/chat_service.py +1145 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/credential_service.py +149 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/data_service.py +1148 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/evolution_service.py +807 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/execution_service.py +608 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/integration_service.py +267 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/knowledge_service.py +164 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/memory_service.py +333 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/model_service.py +606 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/notification_service.py +393 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/observability_service.py +719 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/plugin_service.py +616 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/rbac_service.py +193 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/routing_service.py +419 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/scheduling_service.py +273 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/session_service.py +328 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/system_service.py +472 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/tenant_service.py +148 -0
- maop_orchestrator-5.3.0/maop/dashboard/services/upgrade_service.py +238 -0
- maop_orchestrator-5.3.0/maop/dashboard/static.py +181 -0
- maop_orchestrator-5.3.0/maop/dashboard/ws_broadcast.py +120 -0
- maop_orchestrator-5.3.0/maop/dashboard/ws_dag.py +247 -0
- maop_orchestrator-5.3.0/maop/dashboard/ws_state.py +43 -0
- maop_orchestrator-5.3.0/maop/delegate/__init__.py +9 -0
- maop_orchestrator-5.3.0/maop/delegate/agent_resolver.py +315 -0
- maop_orchestrator-5.3.0/maop/delegate/debate_models.py +129 -0
- maop_orchestrator-5.3.0/maop/delegate/debate_verdict.py +175 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_core.py +471 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_debate.py +638 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_impl.py +291 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_priority.py +149 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_recording.py +117 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatch_tools.py +118 -0
- maop_orchestrator-5.3.0/maop/delegate/dispatcher.py +69 -0
- maop_orchestrator-5.3.0/maop/delegate/doc_pipeline_adapter.py +272 -0
- maop_orchestrator-5.3.0/maop/delegate/drivers.py +769 -0
- maop_orchestrator-5.3.0/maop/delegate/models.py +77 -0
- maop_orchestrator-5.3.0/maop/delegate/sla_monitor.py +138 -0
- maop_orchestrator-5.3.0/maop/deploy.py +593 -0
- maop_orchestrator-5.3.0/maop/engine.py +616 -0
- maop_orchestrator-5.3.0/maop/engine_executor.py +487 -0
- maop_orchestrator-5.3.0/maop/engine_pause.py +82 -0
- maop_orchestrator-5.3.0/maop/engine_types.py +102 -0
- maop_orchestrator-5.3.0/maop/engine_utils.py +249 -0
- maop_orchestrator-5.3.0/maop/evolve.py +681 -0
- maop_orchestrator-5.3.0/maop/history_analyzer.py +365 -0
- maop_orchestrator-5.3.0/maop/loop_analyzer.py +437 -0
- maop_orchestrator-5.3.0/maop/loop_executor.py +353 -0
- maop_orchestrator-5.3.0/maop/loop_models.py +116 -0
- maop_orchestrator-5.3.0/maop/maop_execute.py +559 -0
- maop_orchestrator-5.3.0/maop/maop_loop.py +309 -0
- maop_orchestrator-5.3.0/maop/maop_loop_config.py +29 -0
- maop_orchestrator-5.3.0/maop/maop_loop_phases.py +675 -0
- maop_orchestrator-5.3.0/maop/maop_plan.py +513 -0
- maop_orchestrator-5.3.0/maop/maop_verify.py +539 -0
- maop_orchestrator-5.3.0/maop/memory/__init__.py +22 -0
- maop_orchestrator-5.3.0/maop/memory/consolidator.py +535 -0
- maop_orchestrator-5.3.0/maop/memory/facade.py +632 -0
- maop_orchestrator-5.3.0/maop/memory/manager.py +351 -0
- maop_orchestrator-5.3.0/maop/memory/manager_mixin.py +506 -0
- maop_orchestrator-5.3.0/maop/memory/memory_models.py +52 -0
- maop_orchestrator-5.3.0/maop/memory/models.py +232 -0
- maop_orchestrator-5.3.0/maop/memory/search.py +379 -0
- maop_orchestrator-5.3.0/maop/memory/shared_db.py +185 -0
- maop_orchestrator-5.3.0/maop/memory/store.py +558 -0
- maop_orchestrator-5.3.0/maop/memory/unified.py +254 -0
- maop_orchestrator-5.3.0/maop/memory/vector_search.py +333 -0
- maop_orchestrator-5.3.0/maop/migrations/alembic/env.py +63 -0
- maop_orchestrator-5.3.0/maop/migrations/alembic/script.py.mako +27 -0
- maop_orchestrator-5.3.0/maop/migrations/alembic/versions/001_init.py +106 -0
- maop_orchestrator-5.3.0/maop/migrations/alembic/versions/002_schema_sync.py +81 -0
- maop_orchestrator-5.3.0/maop/migrations/alembic/versions/003_pg_enterprise.py +177 -0
- maop_orchestrator-5.3.0/maop/migrations/memory_migration.py +726 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/alembic.ini +50 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/env.py +127 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/script.py.mako +28 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/vector_migration.py +535 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/versions/001_initial_schema.py +939 -0
- maop_orchestrator-5.3.0/maop/migrations/pg/versions/002_users_tenant_id.py +69 -0
- maop_orchestrator-5.3.0/maop/migrations/sqlite_to_pg.py +659 -0
- maop_orchestrator-5.3.0/maop/model/__init__.py +22 -0
- maop_orchestrator-5.3.0/maop/model/budget.py +219 -0
- maop_orchestrator-5.3.0/maop/model/quota.py +107 -0
- maop_orchestrator-5.3.0/maop/model/registry.py +430 -0
- maop_orchestrator-5.3.0/maop/model/schema.py +310 -0
- maop_orchestrator-5.3.0/maop/model/selector.py +522 -0
- maop_orchestrator-5.3.0/maop/prompt_manager.py +393 -0
- maop_orchestrator-5.3.0/maop/worker/__init__.py +10 -0
- maop_orchestrator-5.3.0/maop/worker/agent_executor.py +181 -0
- maop_orchestrator-5.3.0/maop/worker/distributed_worker.py +567 -0
- maop_orchestrator-5.3.0/maop/worker/queue_worker.py +318 -0
- maop_orchestrator-5.3.0/pyproject.toml +320 -0
- maop_orchestrator-5.3.0/requirements.frozen.txt +144 -0
- maop_orchestrator-5.3.0/requirements.lock +81 -0
- maop_orchestrator-5.3.0/requirements.txt +55 -0
- maop_orchestrator-5.3.0/run_tests.py +10 -0
- maop_orchestrator-5.3.0/scripts/.cov_baseline.json +1 -0
- maop_orchestrator-5.3.0/scripts/attach_release_assets.py +127 -0
- maop_orchestrator-5.3.0/scripts/build_obfuscated_enterprise.sh +101 -0
- maop_orchestrator-5.3.0/scripts/check_api_contract.py +262 -0
- maop_orchestrator-5.3.0/scripts/check_config_drift.py +145 -0
- maop_orchestrator-5.3.0/scripts/check_coverage_ratchet.py +101 -0
- maop_orchestrator-5.3.0/scripts/check_docs_consistency.py +635 -0
- maop_orchestrator-5.3.0/scripts/check_release_tag.py +86 -0
- maop_orchestrator-5.3.0/scripts/check_required_checks_drift.py +160 -0
- maop_orchestrator-5.3.0/scripts/check_wiring.py +337 -0
- maop_orchestrator-5.3.0/scripts/ci_merge_gate.py +145 -0
- maop_orchestrator-5.3.0/scripts/ci_path_scope.py +135 -0
- maop_orchestrator-5.3.0/scripts/compose_smoke.py +82 -0
- maop_orchestrator-5.3.0/scripts/doc_reconcile.py +138 -0
- maop_orchestrator-5.3.0/scripts/e2e_annotate.py +69 -0
- maop_orchestrator-5.3.0/scripts/export_tool_whitelist.py +183 -0
- maop_orchestrator-5.3.0/scripts/fix_swallowed_exceptions.py +106 -0
- maop_orchestrator-5.3.0/scripts/junit_annotate.py +49 -0
- maop_orchestrator-5.3.0/scripts/sign_enterprise_modules.py +129 -0
- maop_orchestrator-5.3.0/scripts/trivy_annotate.py +52 -0
- maop_orchestrator-5.3.0/start_dashboard.bat +3 -0
- maop_orchestrator-5.3.0/start_dashboard.py +10 -0
- maop_orchestrator-5.3.0/tests/__init__.py +0 -0
- maop_orchestrator-5.3.0/tests/conftest.py +631 -0
- maop_orchestrator-5.3.0/tests/contract/__init__.py +8 -0
- maop_orchestrator-5.3.0/tests/contract/conftest.py +46 -0
- maop_orchestrator-5.3.0/tests/contract/test_behavioral_contracts.py +142 -0
- maop_orchestrator-5.3.0/tests/contract/test_control_api_contract.py +56 -0
- maop_orchestrator-5.3.0/tests/contract/test_dashboard_api_contract.py +346 -0
- maop_orchestrator-5.3.0/tests/contract/test_dispatcher_contract.py +89 -0
- maop_orchestrator-5.3.0/tests/contract/test_model_api_contract.py +115 -0
- maop_orchestrator-5.3.0/tests/e2e/conftest.py +110 -0
- maop_orchestrator-5.3.0/tests/e2e/test_auth_enabled.py +311 -0
- maop_orchestrator-5.3.0/tests/e2e/test_boundary_conditions.py +462 -0
- maop_orchestrator-5.3.0/tests/e2e/test_delete_operations.py +237 -0
- maop_orchestrator-5.3.0/tests/e2e/test_edition_switch.py +268 -0
- maop_orchestrator-5.3.0/tests/e2e/test_evolution_loop_e2e.py +358 -0
- maop_orchestrator-5.3.0/tests/e2e/test_guardrail_multiround.py +307 -0
- maop_orchestrator-5.3.0/tests/e2e/test_routing_rbac_tenant.py +219 -0
- maop_orchestrator-5.3.0/tests/e2e/test_sse_error_sanitization.py +320 -0
- maop_orchestrator-5.3.0/tests/performance/__init__.py +15 -0
- maop_orchestrator-5.3.0/tests/performance/k6_maop_load.js +212 -0
- maop_orchestrator-5.3.0/tests/performance/locust_maop_load.py +141 -0
- maop_orchestrator-5.3.0/tests/performance/test_performance_load.py +28 -0
- maop_orchestrator-5.3.0/tests/performance/test_performance_smoke.py +193 -0
- maop_orchestrator-5.3.0/tests/reliability/__init__.py +1 -0
- maop_orchestrator-5.3.0/tests/reliability/test_cascade_degradation.py +337 -0
- maop_orchestrator-5.3.0/tests/reliability/test_pev_pipeline.py +366 -0
- maop_orchestrator-5.3.0/tests/soak/__init__.py +1 -0
- maop_orchestrator-5.3.0/tests/soak/soak_test.py +894 -0
- maop_orchestrator-5.3.0/tests/stability/__init__.py +1 -0
- maop_orchestrator-5.3.0/tests/stability/test_boundary_inputs.py +235 -0
- maop_orchestrator-5.3.0/tests/stability/test_crash_recovery.py +209 -0
- maop_orchestrator-5.3.0/tests/stability/test_long_run.py +189 -0
- maop_orchestrator-5.3.0/tests/test_a2a.py +293 -0
- maop_orchestrator-5.3.0/tests/test_ab_prompt_version.py +107 -0
- maop_orchestrator-5.3.0/tests/test_adr010_regression.py +184 -0
- maop_orchestrator-5.3.0/tests/test_agent_adapters.py +933 -0
- maop_orchestrator-5.3.0/tests/test_agent_catalog.py +463 -0
- maop_orchestrator-5.3.0/tests/test_agent_catalog_route.py +339 -0
- maop_orchestrator-5.3.0/tests/test_agent_collaboration.py +728 -0
- maop_orchestrator-5.3.0/tests/test_agent_discovery.py +497 -0
- maop_orchestrator-5.3.0/tests/test_agent_evolution.py +309 -0
- maop_orchestrator-5.3.0/tests/test_agent_executor_worker.py +130 -0
- maop_orchestrator-5.3.0/tests/test_agent_memory.py +211 -0
- maop_orchestrator-5.3.0/tests/test_agent_performance.py +157 -0
- maop_orchestrator-5.3.0/tests/test_agent_platform.py +521 -0
- maop_orchestrator-5.3.0/tests/test_agent_proxy_coverage.py +220 -0
- maop_orchestrator-5.3.0/tests/test_agent_proxy_gateway.py +365 -0
- maop_orchestrator-5.3.0/tests/test_agent_rate_limiter.py +248 -0
- maop_orchestrator-5.3.0/tests/test_agent_registry_whitebox.py +101 -0
- maop_orchestrator-5.3.0/tests/test_agent_repair.py +210 -0
- maop_orchestrator-5.3.0/tests/test_agent_router.py +648 -0
- maop_orchestrator-5.3.0/tests/test_agent_router_route.py +252 -0
- maop_orchestrator-5.3.0/tests/test_agent_token_stream.py +407 -0
- maop_orchestrator-5.3.0/tests/test_agent_versions.py +638 -0
- maop_orchestrator-5.3.0/tests/test_agentforge_r3.py +337 -0
- maop_orchestrator-5.3.0/tests/test_agents_validator_coverage.py +160 -0
- maop_orchestrator-5.3.0/tests/test_alertmanager_e2e.py +768 -0
- maop_orchestrator-5.3.0/tests/test_analysis.py +353 -0
- maop_orchestrator-5.3.0/tests/test_analyzer.py +366 -0
- maop_orchestrator-5.3.0/tests/test_analyzer_coverage.py +333 -0
- maop_orchestrator-5.3.0/tests/test_api_key_vault_coverage.py +145 -0
- maop_orchestrator-5.3.0/tests/test_api_keys.py +512 -0
- maop_orchestrator-5.3.0/tests/test_audit_enhanced.py +873 -0
- maop_orchestrator-5.3.0/tests/test_auth.py +306 -0
- maop_orchestrator-5.3.0/tests/test_auth_tenant.py +177 -0
- maop_orchestrator-5.3.0/tests/test_backend_audit_batch_b.py +267 -0
- maop_orchestrator-5.3.0/tests/test_backends.py +273 -0
- maop_orchestrator-5.3.0/tests/test_backends_distributed.py +679 -0
- maop_orchestrator-5.3.0/tests/test_backends_pg.py +409 -0
- maop_orchestrator-5.3.0/tests/test_backends_pg_integration.py +132 -0
- maop_orchestrator-5.3.0/tests/test_backends_redis.py +322 -0
- maop_orchestrator-5.3.0/tests/test_backends_vault.py +270 -0
- maop_orchestrator-5.3.0/tests/test_bcd_iterations.py +410 -0
- maop_orchestrator-5.3.0/tests/test_billing_abstraction.py +538 -0
- maop_orchestrator-5.3.0/tests/test_billing_abstraction_route.py +255 -0
- maop_orchestrator-5.3.0/tests/test_blackboard.py +930 -0
- maop_orchestrator-5.3.0/tests/test_bloom_filter.py +209 -0
- maop_orchestrator-5.3.0/tests/test_bridge_registration.py +136 -0
- maop_orchestrator-5.3.0/tests/test_budget.py +316 -0
- maop_orchestrator-5.3.0/tests/test_budget_gate.py +153 -0
- maop_orchestrator-5.3.0/tests/test_budget_guard.py +117 -0
- maop_orchestrator-5.3.0/tests/test_cache.py +324 -0
- maop_orchestrator-5.3.0/tests/test_cache_guard.py +274 -0
- maop_orchestrator-5.3.0/tests/test_capability_probe.py +264 -0
- maop_orchestrator-5.3.0/tests/test_change_tracker.py +127 -0
- maop_orchestrator-5.3.0/tests/test_chat_engine_whitebox.py +348 -0
- maop_orchestrator-5.3.0/tests/test_chat_memory.py +317 -0
- maop_orchestrator-5.3.0/tests/test_ci_merge_gate.py +294 -0
- maop_orchestrator-5.3.0/tests/test_ci_path_scope.py +204 -0
- maop_orchestrator-5.3.0/tests/test_ci_publish_reachable.py +284 -0
- maop_orchestrator-5.3.0/tests/test_ci_required_checks.py +195 -0
- maop_orchestrator-5.3.0/tests/test_ci_required_checks_drift.py +159 -0
- maop_orchestrator-5.3.0/tests/test_ci_workflow_hygiene.py +84 -0
- maop_orchestrator-5.3.0/tests/test_circuit_breaker.py +187 -0
- maop_orchestrator-5.3.0/tests/test_cli.py +233 -0
- maop_orchestrator-5.3.0/tests/test_compliance.py +331 -0
- maop_orchestrator-5.3.0/tests/test_compliance_core.py +51 -0
- maop_orchestrator-5.3.0/tests/test_concurrency.py +367 -0
- maop_orchestrator-5.3.0/tests/test_config.py +103 -0
- maop_orchestrator-5.3.0/tests/test_config_history.py +330 -0
- maop_orchestrator-5.3.0/tests/test_config_mutator_whitebox.py +376 -0
- maop_orchestrator-5.3.0/tests/test_config_plugin_cli_coverage.py +360 -0
- maop_orchestrator-5.3.0/tests/test_config_template.py +291 -0
- maop_orchestrator-5.3.0/tests/test_config_validation.py +77 -0
- maop_orchestrator-5.3.0/tests/test_conftest_leak_probe.py +560 -0
- maop_orchestrator-5.3.0/tests/test_consolidator.py +213 -0
- maop_orchestrator-5.3.0/tests/test_context_compressor.py +307 -0
- maop_orchestrator-5.3.0/tests/test_control_plane.py +205 -0
- maop_orchestrator-5.3.0/tests/test_conversation_whitebox.py +146 -0
- maop_orchestrator-5.3.0/tests/test_core_modules2_coverage.py +380 -0
- maop_orchestrator-5.3.0/tests/test_core_modules_coverage.py +357 -0
- maop_orchestrator-5.3.0/tests/test_cost_tracker_whitebox.py +142 -0
- maop_orchestrator-5.3.0/tests/test_coverage_boost.py +269 -0
- maop_orchestrator-5.3.0/tests/test_credential_vault.py +340 -0
- maop_orchestrator-5.3.0/tests/test_credential_vault_route.py +279 -0
- maop_orchestrator-5.3.0/tests/test_dag_latency.py +236 -0
- maop_orchestrator-5.3.0/tests/test_dag_progress_emitter.py +297 -0
- maop_orchestrator-5.3.0/tests/test_dag_sse_endpoint.py +250 -0
- maop_orchestrator-5.3.0/tests/test_dag_ws_endpoint.py +226 -0
- maop_orchestrator-5.3.0/tests/test_dashboard_auth.py +122 -0
- maop_orchestrator-5.3.0/tests/test_data.py +119 -0
- maop_orchestrator-5.3.0/tests/test_data_proxy_coverage.py +1038 -0
- maop_orchestrator-5.3.0/tests/test_db_backup.py +332 -0
- maop_orchestrator-5.3.0/tests/test_db_utils.py +192 -0
- maop_orchestrator-5.3.0/tests/test_dead_wiring_inventory.py +258 -0
- maop_orchestrator-5.3.0/tests/test_debate.py +922 -0
- maop_orchestrator-5.3.0/tests/test_dependabot_config.py +147 -0
- maop_orchestrator-5.3.0/tests/test_deploy.py +128 -0
- maop_orchestrator-5.3.0/tests/test_deploy_coverage.py +217 -0
- maop_orchestrator-5.3.0/tests/test_desktop_app_adapter.py +423 -0
- maop_orchestrator-5.3.0/tests/test_desktop_app_integration.py +568 -0
- maop_orchestrator-5.3.0/tests/test_dispatch_e2e.py +112 -0
- maop_orchestrator-5.3.0/tests/test_dispatch_gate.py +279 -0
- maop_orchestrator-5.3.0/tests/test_dispatcher.py +1009 -0
- maop_orchestrator-5.3.0/tests/test_distributed_audit_fixes.py +319 -0
- maop_orchestrator-5.3.0/tests/test_distributed_execution.py +894 -0
- maop_orchestrator-5.3.0/tests/test_doc_pipeline_adapter.py +203 -0
- maop_orchestrator-5.3.0/tests/test_doc_pipeline_adapter_coverage.py +168 -0
- maop_orchestrator-5.3.0/tests/test_docs_consistency_gate.py +239 -0
- maop_orchestrator-5.3.0/tests/test_domestic_first.py +252 -0
- maop_orchestrator-5.3.0/tests/test_drivers.py +284 -0
- maop_orchestrator-5.3.0/tests/test_drivers_coverage.py +306 -0
- maop_orchestrator-5.3.0/tests/test_dry_run_gate_wiring.py +130 -0
- maop_orchestrator-5.3.0/tests/test_dynamic_orchestration.py +320 -0
- maop_orchestrator-5.3.0/tests/test_e2e_agent_flow.py +926 -0
- maop_orchestrator-5.3.0/tests/test_e2e_multivendor.py +355 -0
- maop_orchestrator-5.3.0/tests/test_edition.py +348 -0
- maop_orchestrator-5.3.0/tests/test_edition_bypass_guard.py +152 -0
- maop_orchestrator-5.3.0/tests/test_edition_switch_guard.py +204 -0
- maop_orchestrator-5.3.0/tests/test_engine.py +352 -0
- maop_orchestrator-5.3.0/tests/test_enhancements.py +415 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_audit.py +160 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_container.py +83 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_contract.py +275 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_guard.py +79 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_ha.py +290 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_integration.py +398 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_license.py +272 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_n8n.py +282 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_pg_persist.py +483 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_rbac.py +157 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_tenant.py +170 -0
- maop_orchestrator-5.3.0/tests/test_enterprise_tls_auto.py +157 -0
- maop_orchestrator-5.3.0/tests/test_env_example_drift.py +208 -0
- maop_orchestrator-5.3.0/tests/test_error_dag_heal.py +167 -0
- maop_orchestrator-5.3.0/tests/test_error_ledger_whitebox.py +138 -0
- maop_orchestrator-5.3.0/tests/test_error_schema.py +62 -0
- maop_orchestrator-5.3.0/tests/test_event_bus.py +290 -0
- maop_orchestrator-5.3.0/tests/test_event_hook_async.py +214 -0
- maop_orchestrator-5.3.0/tests/test_evolution_approval_carryover.py +156 -0
- maop_orchestrator-5.3.0/tests/test_evolution_beta.py +455 -0
- maop_orchestrator-5.3.0/tests/test_evolution_e2e.py +626 -0
- maop_orchestrator-5.3.0/tests/test_evolution_f201.py +429 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop.py +275 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac01_ac02.py +131 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac03.py +276 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac04.py +156 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac05.py +172 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac06.py +108 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_ac07.py +264 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_factory.py +37 -0
- maop_orchestrator-5.3.0/tests/test_evolution_loop_real_e2e.py +188 -0
- maop_orchestrator-5.3.0/tests/test_evolution_narrative.py +497 -0
- maop_orchestrator-5.3.0/tests/test_evolution_switch_no_regression.py +151 -0
- maop_orchestrator-5.3.0/tests/test_evolve.py +1036 -0
- maop_orchestrator-5.3.0/tests/test_evolve_loop_coverage.py +139 -0
- maop_orchestrator-5.3.0/tests/test_export_whitelist.py +112 -0
- maop_orchestrator-5.3.0/tests/test_failure_detector.py +543 -0
- maop_orchestrator-5.3.0/tests/test_feedback.py +432 -0
- maop_orchestrator-5.3.0/tests/test_filelock.py +51 -0
- maop_orchestrator-5.3.0/tests/test_frontend_coverage_gate.py +82 -0
- maop_orchestrator-5.3.0/tests/test_frozen_lock.py +99 -0
- maop_orchestrator-5.3.0/tests/test_function_call.py +320 -0
- maop_orchestrator-5.3.0/tests/test_gdpr_compliance.py +240 -0
- maop_orchestrator-5.3.0/tests/test_guardrail.py +73 -0
- maop_orchestrator-5.3.0/tests/test_guardrail_extended.py +185 -0
- maop_orchestrator-5.3.0/tests/test_harness_auth.py +299 -0
- maop_orchestrator-5.3.0/tests/test_health_check_scheduler.py +359 -0
- maop_orchestrator-5.3.0/tests/test_health_scorer.py +296 -0
- maop_orchestrator-5.3.0/tests/test_hook_decision.py +81 -0
- maop_orchestrator-5.3.0/tests/test_hook_manager.py +463 -0
- maop_orchestrator-5.3.0/tests/test_hook_manager_helpers.py +25 -0
- maop_orchestrator-5.3.0/tests/test_hooks.py +307 -0
- maop_orchestrator-5.3.0/tests/test_hooks_history.py +152 -0
- maop_orchestrator-5.3.0/tests/test_hot_reload.py +354 -0
- maop_orchestrator-5.3.0/tests/test_human_proxy.py +223 -0
- maop_orchestrator-5.3.0/tests/test_ide_extension_adapter.py +536 -0
- maop_orchestrator-5.3.0/tests/test_integration.py +259 -0
- maop_orchestrator-5.3.0/tests/test_json_logging.py +349 -0
- maop_orchestrator-5.3.0/tests/test_k8s_operator.py +575 -0
- maop_orchestrator-5.3.0/tests/test_knowledge_graph.py +167 -0
- maop_orchestrator-5.3.0/tests/test_knowledge_graph_v2.py +450 -0
- maop_orchestrator-5.3.0/tests/test_kv_store.py +335 -0
- maop_orchestrator-5.3.0/tests/test_ldap_provider.py +685 -0
- maop_orchestrator-5.3.0/tests/test_ldap_real_env.py +435 -0
- maop_orchestrator-5.3.0/tests/test_license_crl.py +269 -0
- maop_orchestrator-5.3.0/tests/test_licenses.py +690 -0
- maop_orchestrator-5.3.0/tests/test_lifespan_coverage.py +112 -0
- maop_orchestrator-5.3.0/tests/test_llm_provider.py +573 -0
- maop_orchestrator-5.3.0/tests/test_llm_provider_fallback.py +220 -0
- maop_orchestrator-5.3.0/tests/test_load_balancer.py +218 -0
- maop_orchestrator-5.3.0/tests/test_loader.py +340 -0
- maop_orchestrator-5.3.0/tests/test_log_rotate.py +158 -0
- maop_orchestrator-5.3.0/tests/test_long_running_task.py +461 -0
- maop_orchestrator-5.3.0/tests/test_loop_analyzer_coverage.py +207 -0
- maop_orchestrator-5.3.0/tests/test_loop_executor.py +297 -0
- maop_orchestrator-5.3.0/tests/test_maop_execute.py +670 -0
- maop_orchestrator-5.3.0/tests/test_maop_loop.py +921 -0
- maop_orchestrator-5.3.0/tests/test_maop_plan.py +350 -0
- maop_orchestrator-5.3.0/tests/test_maop_verify.py +282 -0
- maop_orchestrator-5.3.0/tests/test_maos_version_floor.py +73 -0
- maop_orchestrator-5.3.0/tests/test_marketplace_f301.py +350 -0
- maop_orchestrator-5.3.0/tests/test_marketplace_key_mgmt.py +570 -0
- maop_orchestrator-5.3.0/tests/test_mcp_adapter.py +516 -0
- maop_orchestrator-5.3.0/tests/test_mcp_cache_concurrency.py +794 -0
- maop_orchestrator-5.3.0/tests/test_mcp_deprecation.py +238 -0
- maop_orchestrator-5.3.0/tests/test_mcp_discovery.py +357 -0
- maop_orchestrator-5.3.0/tests/test_mcp_hub.py +328 -0
- maop_orchestrator-5.3.0/tests/test_mcp_marketplace.py +844 -0
- maop_orchestrator-5.3.0/tests/test_mcp_observability.py +723 -0
- maop_orchestrator-5.3.0/tests/test_mcp_permission_audit.py +810 -0
- maop_orchestrator-5.3.0/tests/test_mcp_route_crud.py +204 -0
- maop_orchestrator-5.3.0/tests/test_mcp_seed_config.py +172 -0
- maop_orchestrator-5.3.0/tests/test_mcp_stats_tool_limit.py +414 -0
- maop_orchestrator-5.3.0/tests/test_mem_vector_otel_saml_coverage.py +765 -0
- maop_orchestrator-5.3.0/tests/test_memory.py +256 -0
- maop_orchestrator-5.3.0/tests/test_memory_consistency.py +1937 -0
- maop_orchestrator-5.3.0/tests/test_message_queue.py +265 -0
- maop_orchestrator-5.3.0/tests/test_middleware.py +401 -0
- maop_orchestrator-5.3.0/tests/test_migration.py +142 -0
- maop_orchestrator-5.3.0/tests/test_missing_modules.py +322 -0
- maop_orchestrator-5.3.0/tests/test_model_gateway.py +482 -0
- maop_orchestrator-5.3.0/tests/test_model_gateway_route.py +380 -0
- maop_orchestrator-5.3.0/tests/test_model_lb_quota_integration.py +536 -0
- maop_orchestrator-5.3.0/tests/test_model_management.py +263 -0
- maop_orchestrator-5.3.0/tests/test_module_integrity.py +165 -0
- maop_orchestrator-5.3.0/tests/test_monitoring.py +391 -0
- maop_orchestrator-5.3.0/tests/test_new_modules.py +497 -0
- maop_orchestrator-5.3.0/tests/test_nightly_flaky_coverage.py +315 -0
- maop_orchestrator-5.3.0/tests/test_notifications.py +1416 -0
- maop_orchestrator-5.3.0/tests/test_notifications_ws_auth.py +115 -0
- maop_orchestrator-5.3.0/tests/test_observability.py +909 -0
- maop_orchestrator-5.3.0/tests/test_omniroute_default.py +316 -0
- maop_orchestrator-5.3.0/tests/test_otel.py +153 -0
- maop_orchestrator-5.3.0/tests/test_output_parser.py +276 -0
- maop_orchestrator-5.3.0/tests/test_p3_p4_p5.py +154 -0
- maop_orchestrator-5.3.0/tests/test_parametrized_coverage.py +899 -0
- maop_orchestrator-5.3.0/tests/test_parametrized_coverage2.py +706 -0
- maop_orchestrator-5.3.0/tests/test_parametrized_coverage3.py +581 -0
- maop_orchestrator-5.3.0/tests/test_parametrized_coverage4.py +621 -0
- maop_orchestrator-5.3.0/tests/test_parametrized_coverage5.py +181 -0
- maop_orchestrator-5.3.0/tests/test_permission.py +68 -0
- maop_orchestrator-5.3.0/tests/test_personal_cost_cap.py +104 -0
- maop_orchestrator-5.3.0/tests/test_pg_migration.py +744 -0
- maop_orchestrator-5.3.0/tests/test_phase4.py +403 -0
- maop_orchestrator-5.3.0/tests/test_phase5.py +283 -0
- maop_orchestrator-5.3.0/tests/test_phase6.py +316 -0
- maop_orchestrator-5.3.0/tests/test_phase7.py +130 -0
- maop_orchestrator-5.3.0/tests/test_phases.py +68 -0
- maop_orchestrator-5.3.0/tests/test_plugin_cost.py +424 -0
- maop_orchestrator-5.3.0/tests/test_plugin_dependency_order.py +127 -0
- maop_orchestrator-5.3.0/tests/test_plugin_sandbox.py +643 -0
- maop_orchestrator-5.3.0/tests/test_preemptable_worker_pool_coverage3.py +297 -0
- maop_orchestrator-5.3.0/tests/test_preemption.py +573 -0
- maop_orchestrator-5.3.0/tests/test_preset_agents.py +759 -0
- maop_orchestrator-5.3.0/tests/test_prompt_manager.py +277 -0
- maop_orchestrator-5.3.0/tests/test_protocol.py +131 -0
- maop_orchestrator-5.3.0/tests/test_provider.py +442 -0
- maop_orchestrator-5.3.0/tests/test_provider_enhanced.py +187 -0
- maop_orchestrator-5.3.0/tests/test_provider_health.py +165 -0
- maop_orchestrator-5.3.0/tests/test_quota.py +103 -0
- maop_orchestrator-5.3.0/tests/test_quota_alert.py +371 -0
- maop_orchestrator-5.3.0/tests/test_quota_bucket.py +418 -0
- maop_orchestrator-5.3.0/tests/test_quota_route.py +216 -0
- maop_orchestrator-5.3.0/tests/test_rate_limiter.py +213 -0
- maop_orchestrator-5.3.0/tests/test_react_loop.py +747 -0
- maop_orchestrator-5.3.0/tests/test_registry.py +440 -0
- maop_orchestrator-5.3.0/tests/test_regression.py +236 -0
- maop_orchestrator-5.3.0/tests/test_relay_platform.py +728 -0
- maop_orchestrator-5.3.0/tests/test_requirements_lock_sync.py +111 -0
- maop_orchestrator-5.3.0/tests/test_result_cache.py +276 -0
- maop_orchestrator-5.3.0/tests/test_route_scorer.py +272 -0
- maop_orchestrator-5.3.0/tests/test_router_agents_coverage.py +463 -0
- maop_orchestrator-5.3.0/tests/test_router_auth_coverage.py +337 -0
- maop_orchestrator-5.3.0/tests/test_router_control.py +533 -0
- maop_orchestrator-5.3.0/tests/test_router_data.py +325 -0
- maop_orchestrator-5.3.0/tests/test_router_evolve.py +202 -0
- maop_orchestrator-5.3.0/tests/test_router_hook_protocol_coverage.py +344 -0
- maop_orchestrator-5.3.0/tests/test_router_mcp_evolve_memory_coverage.py +362 -0
- maop_orchestrator-5.3.0/tests/test_router_memory.py +300 -0
- maop_orchestrator-5.3.0/tests/test_router_misc_coverage.py +568 -0
- maop_orchestrator-5.3.0/tests/test_router_model.py +675 -0
- maop_orchestrator-5.3.0/tests/test_router_state.py +174 -0
- maop_orchestrator-5.3.0/tests/test_router_system.py +782 -0
- maop_orchestrator-5.3.0/tests/test_router_worktree_coverage.py +224 -0
- maop_orchestrator-5.3.0/tests/test_routers_batch_coverage.py +621 -0
- maop_orchestrator-5.3.0/tests/test_routers_smoke_coverage.py +182 -0
- maop_orchestrator-5.3.0/tests/test_routing_audit.py +242 -0
- maop_orchestrator-5.3.0/tests/test_routing_decision_whitebox.py +149 -0
- maop_orchestrator-5.3.0/tests/test_routing_trace.py +777 -0
- maop_orchestrator-5.3.0/tests/test_runtime.py +95 -0
- maop_orchestrator-5.3.0/tests/test_runtime_coverage.py +135 -0
- maop_orchestrator-5.3.0/tests/test_safe_writer.py +103 -0
- maop_orchestrator-5.3.0/tests/test_saml_handler_coverage3.py +531 -0
- maop_orchestrator-5.3.0/tests/test_sandbox.py +88 -0
- maop_orchestrator-5.3.0/tests/test_sandbox_env_isolation.py +176 -0
- maop_orchestrator-5.3.0/tests/test_sandbox_executor.py +358 -0
- maop_orchestrator-5.3.0/tests/test_scheduling_worker_pool_coverage.py +261 -0
- maop_orchestrator-5.3.0/tests/test_schema.py +296 -0
- maop_orchestrator-5.3.0/tests/test_secrets.py +331 -0
- maop_orchestrator-5.3.0/tests/test_selector.py +276 -0
- maop_orchestrator-5.3.0/tests/test_semantic_cache_whitebox.py +91 -0
- maop_orchestrator-5.3.0/tests/test_server_core.py +23 -0
- maop_orchestrator-5.3.0/tests/test_server_coverage.py +252 -0
- maop_orchestrator-5.3.0/tests/test_services.py +171 -0
- maop_orchestrator-5.3.0/tests/test_session.py +315 -0
- maop_orchestrator-5.3.0/tests/test_settings.py +129 -0
- maop_orchestrator-5.3.0/tests/test_shared_db.py +154 -0
- maop_orchestrator-5.3.0/tests/test_skill_steps.py +212 -0
- maop_orchestrator-5.3.0/tests/test_sla_manager.py +369 -0
- maop_orchestrator-5.3.0/tests/test_sla_scheduling.py +278 -0
- maop_orchestrator-5.3.0/tests/test_spa_fallback_api_404.py +72 -0
- maop_orchestrator-5.3.0/tests/test_sql_injection_hardening.py +161 -0
- maop_orchestrator-5.3.0/tests/test_sso.py +965 -0
- maop_orchestrator-5.3.0/tests/test_sso_providers.py +696 -0
- maop_orchestrator-5.3.0/tests/test_sso_router_callback_guard.py +73 -0
- maop_orchestrator-5.3.0/tests/test_state_classifier.py +185 -0
- maop_orchestrator-5.3.0/tests/test_store.py +426 -0
- maop_orchestrator-5.3.0/tests/test_strategy_evolution_beta3.py +318 -0
- maop_orchestrator-5.3.0/tests/test_streaming.py +115 -0
- maop_orchestrator-5.3.0/tests/test_stress.py +673 -0
- maop_orchestrator-5.3.0/tests/test_subagent.py +108 -0
- maop_orchestrator-5.3.0/tests/test_subagent_delegation.py +256 -0
- maop_orchestrator-5.3.0/tests/test_subagent_lifecycle.py +320 -0
- maop_orchestrator-5.3.0/tests/test_subagent_manager.py +113 -0
- maop_orchestrator-5.3.0/tests/test_supervisor.py +935 -0
- maop_orchestrator-5.3.0/tests/test_t2_modules.py +212 -0
- maop_orchestrator-5.3.0/tests/test_task_splitter.py +428 -0
- maop_orchestrator-5.3.0/tests/test_tenant_context.py +249 -0
- maop_orchestrator-5.3.0/tests/test_tenant_hierarchy.py +416 -0
- maop_orchestrator-5.3.0/tests/test_tenant_isolation.py +504 -0
- maop_orchestrator-5.3.0/tests/test_tenant_isolation_ops.py +379 -0
- maop_orchestrator-5.3.0/tests/test_tenant_quota.py +741 -0
- maop_orchestrator-5.3.0/tests/test_three_layer_memory.py +1110 -0
- maop_orchestrator-5.3.0/tests/test_three_mechanisms.py +263 -0
- maop_orchestrator-5.3.0/tests/test_timeseries.py +308 -0
- maop_orchestrator-5.3.0/tests/test_tls.py +112 -0
- maop_orchestrator-5.3.0/tests/test_tool_manager.py +893 -0
- maop_orchestrator-5.3.0/tests/test_tool_market.py +107 -0
- maop_orchestrator-5.3.0/tests/test_tool_mq_mcp_coverage.py +313 -0
- maop_orchestrator-5.3.0/tests/test_true_preemption.py +534 -0
- maop_orchestrator-5.3.0/tests/test_unified_memory.py +467 -0
- maop_orchestrator-5.3.0/tests/test_unified_memory_search.py +747 -0
- maop_orchestrator-5.3.0/tests/test_url_validator.py +190 -0
- maop_orchestrator-5.3.0/tests/test_usage_statistics.py +357 -0
- maop_orchestrator-5.3.0/tests/test_v4_3.py +272 -0
- maop_orchestrator-5.3.0/tests/test_vector.py +317 -0
- maop_orchestrator-5.3.0/tests/test_vector_backends.py +620 -0
- maop_orchestrator-5.3.0/tests/test_vector_core.py +40 -0
- maop_orchestrator-5.3.0/tests/test_vendor_ecosystem.py +541 -0
- maop_orchestrator-5.3.0/tests/test_verify_artifacts.py +210 -0
- maop_orchestrator-5.3.0/tests/test_version_sync_guard.py +111 -0
- maop_orchestrator-5.3.0/tests/test_vibe_coding_adapter.py +459 -0
- maop_orchestrator-5.3.0/tests/test_worker.py +430 -0
- maop_orchestrator-5.3.0/tests/test_worker_pool.py +188 -0
- maop_orchestrator-5.3.0/tests/test_worker_pool_coverage.py +232 -0
- maop_orchestrator-5.3.0/tests/test_worktree.py +213 -0
- maop_orchestrator-5.3.0/tests/test_ws_manager_coverage.py +146 -0
- maop_orchestrator-5.3.0/tests/thread_join_guard.py +30 -0
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# -- Python --
|
|
2
|
+
__pycache__/
|
|
3
|
+
*.py[cod]
|
|
4
|
+
*$py.class
|
|
5
|
+
*.so
|
|
6
|
+
*.egg-info/
|
|
7
|
+
dist/
|
|
8
|
+
build/
|
|
9
|
+
*.egg
|
|
10
|
+
|
|
11
|
+
# -- Virtual environments --
|
|
12
|
+
.venv/
|
|
13
|
+
venv/
|
|
14
|
+
env/
|
|
15
|
+
|
|
16
|
+
# -- IDE / Editor --
|
|
17
|
+
.vscode/
|
|
18
|
+
.idea/
|
|
19
|
+
*.swp
|
|
20
|
+
*.swo
|
|
21
|
+
*~
|
|
22
|
+
|
|
23
|
+
# -- Testing --
|
|
24
|
+
.pytest_cache/
|
|
25
|
+
.mypy_cache/
|
|
26
|
+
.ruff_cache/
|
|
27
|
+
.coverage
|
|
28
|
+
.coverage.*
|
|
29
|
+
coverage.xml
|
|
30
|
+
htmlcov/
|
|
31
|
+
# Coverage temp files
|
|
32
|
+
_cov*.txt
|
|
33
|
+
.tox/
|
|
34
|
+
|
|
35
|
+
# t16 (2026-07-21): ad-hoc test runners with hardcoded absolute paths — should
|
|
36
|
+
# never be committed. Use `python -m pytest` from py/ instead.
|
|
37
|
+
test_output.txt
|
|
38
|
+
batch_run_tests.py
|
|
39
|
+
|
|
40
|
+
# -- Environment variables --
|
|
41
|
+
.env
|
|
42
|
+
.env.local
|
|
43
|
+
.env.*.local
|
|
44
|
+
# Low-2 fix: .env.sandbox 含运行时沙箱转发策略,可能含敏感配置,不应入库
|
|
45
|
+
.env.sandbox
|
|
46
|
+
|
|
47
|
+
# -- Runtime data (SQLite databases + generated state) --
|
|
48
|
+
data/*.db
|
|
49
|
+
data/*.db-shm
|
|
50
|
+
data/*.db-wal
|
|
51
|
+
data/*.db2
|
|
52
|
+
data/.admin-password
|
|
53
|
+
data/.enc_key
|
|
54
|
+
data/jwt_secret
|
|
55
|
+
data/backups/
|
|
56
|
+
data/sandboxes/
|
|
57
|
+
data/wiki.json
|
|
58
|
+
data/memory.json
|
|
59
|
+
data/evolve-suggestions.json
|
|
60
|
+
data/tools.json
|
|
61
|
+
# P2 fix: runtime-generated state/cache files (not seed configs)
|
|
62
|
+
data/pev-loop.jsonl
|
|
63
|
+
data/dynamic-routing-cache.json
|
|
64
|
+
data/graph-edges.json
|
|
65
|
+
data/graph-nodes.json
|
|
66
|
+
data/agent-versions.json
|
|
67
|
+
data/budget_ledger.json
|
|
68
|
+
data/vectors.json
|
|
69
|
+
# runtime DAG execution checkpoints (per-run state, not seed configs)
|
|
70
|
+
data/dag-checkpoints/
|
|
71
|
+
# MAOS clock_guard 的防回拨水位线(enterprise/clock_guard.py: WATERMARK_FILENAME),
|
|
72
|
+
# 本机跑测试时按 MAOP 仓库根写入;纯运行时状态,绝不能入库。
|
|
73
|
+
data/clock_watermark.json
|
|
74
|
+
|
|
75
|
+
# -- Logs --
|
|
76
|
+
logs/
|
|
77
|
+
|
|
78
|
+
# -- Dashboard build output --
|
|
79
|
+
dashboard/dist/
|
|
80
|
+
dashboard/dist-enterprise/
|
|
81
|
+
dashboard-enterprise/dist/
|
|
82
|
+
|
|
83
|
+
# -- Temp / Cache --
|
|
84
|
+
temp/
|
|
85
|
+
cache/
|
|
86
|
+
output/
|
|
87
|
+
|
|
88
|
+
# -- Snapshots (test artifacts) --
|
|
89
|
+
tests/snapshots/
|
|
90
|
+
*.snap
|
|
91
|
+
|
|
92
|
+
# -- OS files --
|
|
93
|
+
.DS_Store
|
|
94
|
+
Thumbs.db
|
|
95
|
+
desktop.ini
|
|
96
|
+
|
|
97
|
+
# -- Docker --
|
|
98
|
+
docker-compose.override.yml
|
|
99
|
+
|
|
100
|
+
# -- Node (if any frontend tooling) --
|
|
101
|
+
node_modules/
|
|
102
|
+
|
|
103
|
+
# -- Temp test results / scripts --
|
|
104
|
+
py/data/
|
|
105
|
+
py/test_full.txt
|
|
106
|
+
py/test_results.txt
|
|
107
|
+
py/test_results_async.txt
|
|
108
|
+
pytest_results.txt
|
|
109
|
+
test-html.py
|
|
110
|
+
scripts/rename_dist.py
|
|
111
|
+
scripts/rename_pev_to_maop.py
|
|
112
|
+
security-audit.md
|
|
113
|
+
# Ad-hoc inspection/debug scripts (root-level, underscore-prefixed)
|
|
114
|
+
/_*.py
|
|
115
|
+
py/_*.py
|
|
116
|
+
# Ad-hoc cleanup/audit reports (large generated artifacts, not source)
|
|
117
|
+
py/_shim_cleanup_report.txt
|
|
118
|
+
config/agents.yaml.bak
|
|
119
|
+
config/agents.yaml.bak2
|
|
120
|
+
|
|
121
|
+
# -- Audit artifacts / temp scripts (not source) --
|
|
122
|
+
dashboard-enterprise/api_audit.json
|
|
123
|
+
dashboard-enterprise/orphan_audit.json
|
|
124
|
+
dashboard-enterprise/audit_api.py
|
|
125
|
+
dashboard-enterprise/audit_orphans.py
|
|
126
|
+
dashboard-enterprise/coverage/
|
|
127
|
+
dashboard-enterprise/frontend_dev.log
|
|
128
|
+
test_full.log
|
|
129
|
+
test_*.log
|
|
130
|
+
# -- Python runtime/test logs accidentally committed under py/ (see audit D7) --
|
|
131
|
+
py/*.log
|
|
132
|
+
py/**/*.log
|
|
133
|
+
|
|
134
|
+
# -- Credentials / runtime secrets --
|
|
135
|
+
data/.admin_initial_password
|
|
136
|
+
data/.write_test
|
|
137
|
+
data/backend_run.log
|
|
138
|
+
# S-P1-3 fix: Docker secrets directory (must NEVER be committed)
|
|
139
|
+
secrets/
|
|
140
|
+
|
|
141
|
+
# Alembic cache
|
|
142
|
+
py/maop/migrations/alembic/__pycache__/
|
|
143
|
+
|
|
144
|
+
# -- Security: Keys and Certificates (P0 fix: prevent private key leakage) --
|
|
145
|
+
# P0 fix: development Ed25519 private key leaked to history - cached removed above
|
|
146
|
+
*.pem
|
|
147
|
+
*.key
|
|
148
|
+
*.p12
|
|
149
|
+
*.pfx
|
|
150
|
+
scripts/dev_*
|
|
151
|
+
scripts/*_private_*
|
|
152
|
+
data/*_secret*
|
|
153
|
+
*.private
|
|
154
|
+
# -- Scrubbed backup dirs (must NEVER be committed) --
|
|
155
|
+
data_bak_*/
|
|
156
|
+
# -- Runtime error logs --
|
|
157
|
+
*.err
|
|
158
|
+
# -- Test baseline/result artifacts --
|
|
159
|
+
py/test_baseline_*.txt
|
|
160
|
+
py/test_final_*.txt
|
|
161
|
+
py/test_precommit_*.txt
|
|
162
|
+
py/tests/_baseline_cov*.txt
|
|
163
|
+
py/tests/_final_cov*.txt
|
|
164
|
+
py/.maop-snapshots/
|
|
165
|
+
.maop-snapshots/
|
|
166
|
+
dashboard-enterprise/test-results/
|
|
167
|
+
# 前端测试运行产物(此前被误提交,131KB 的 vitest 结果 JSON)
|
|
168
|
+
dashboard-enterprise/vitest_result.json
|
|
169
|
+
# -- Runtime degradation log --
|
|
170
|
+
data/degradation.log
|
|
171
|
+
# 带时间戳的轮转副本(历史累积产物;原先只忽略固定名,导致
|
|
172
|
+
# data/degradation_<ts>[_<ts>...].log 被误提交)
|
|
173
|
+
data/degradation_*.log
|
|
174
|
+
data/jwt_revoked.json
|
|
175
|
+
# -- Agent tool internal --
|
|
176
|
+
.codeartsdoer/
|
|
177
|
+
deliverables/
|
|
178
|
+
|
|
179
|
+
# Packaged-module runtime DB (orphan artifact, not a seed; VectorStore uses <root>/data/)
|
|
180
|
+
py/maop/data/*.db
|
|
181
|
+
py/maop/data/*.db-shm
|
|
182
|
+
py/maop/data/*.db-wal
|
|
183
|
+
|
|
184
|
+
# -- IDE: InsCode --
|
|
185
|
+
.inscode/
|
|
186
|
+
|
|
187
|
+
# -- Temporary attachments --
|
|
188
|
+
attachments/
|
|
189
|
+
|
|
190
|
+
# WorkBuddy session data (AI assistant workspace memory)
|
|
191
|
+
.workbuddy/
|
|
192
|
+
|
|
193
|
+
# WorkBuddy session data (AI assistant workspace memory)
|
|
194
|
+
.workbuddy/
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
# ── MAOP Agent Orchestration Framework ──────────────────────────────
|
|
2
|
+
# Multi-stage build: frontend-builder → builder (deps) → runtime (slim)
|
|
3
|
+
# Supports: dashboard, agent-executor, queue-worker
|
|
4
|
+
# ──────────────────────────────────────────────────────────────────
|
|
5
|
+
|
|
6
|
+
# 64d2732: buildx resolved ${PYTHON_IMAGE} as blank in the FROM lines even
|
|
7
|
+
# with the build-arg passed. An ARG declared AFTER the first FROM is NOT in
|
|
8
|
+
# the global scope buildx uses for FROM interpolation — move it to the very
|
|
9
|
+
# top (before ANY FROM), which is the unambiguous global position.
|
|
10
|
+
# 64d2732 (2): NODE_IMAGE ARG too — GitHub runners pull from Docker Hub.
|
|
11
|
+
# 3f335fb: the previous aliyun defaults (registry.cn-hangzhou.aliyuncs.com/
|
|
12
|
+
# library/python|node) DO NOT EXIST — pull access denied / repository does
|
|
13
|
+
# not exist (the library/ namespace is Docker Hub's, aliyun's public mirror
|
|
14
|
+
# for it is long gone). CN-local users should configure a registry mirror
|
|
15
|
+
# in Docker Desktop settings instead of overriding these build args.
|
|
16
|
+
# P1 supply-chain fix (2026-09-17): digest pinning prevents tag re-push attacks.
|
|
17
|
+
# To obtain digest: docker pull python:3.13-slim && docker inspect --format='{{index .RepoDigests 0}}' python:3.13-slim
|
|
18
|
+
# CI should inject --build-arg PYTHON_IMAGE=python:3.13-slim@sha256:<digest> for reproducible builds.
|
|
19
|
+
ARG PYTHON_IMAGE=python:3.13-slim
|
|
20
|
+
# 2026-09-29: node:20 → node:24,与 CI 的 env.NODE_VERSION 对齐。jsdom@30.1.1
|
|
21
|
+
# (lockfile 实装)engines = ^22.22.2 || ^24.15.0 || >=26.0.0,node 20 不在区间;
|
|
22
|
+
# 镜内 frontend-builder 与 CI frontend job 跑同一个 lockfile,两边必须同大版本。
|
|
23
|
+
ARG NODE_IMAGE=node:24-alpine
|
|
24
|
+
|
|
25
|
+
# Stage 0: Frontend Builder (H6 fix)
|
|
26
|
+
# H6 fix: 原 Dockerfile 未包含前端构建步骤,fresh clone 或 CI 环境中 assets 缺失,
|
|
27
|
+
# 导致 Docker 部署后前端白页。现新增前端构建阶段,在镜像构建时执行 npm run build。
|
|
28
|
+
# P1-5: 国内源(用户无梯子时 node 镜像可能拉取失败,改用阿里云镜像)
|
|
29
|
+
FROM ${NODE_IMAGE} AS frontend-builder
|
|
30
|
+
WORKDIR /build
|
|
31
|
+
# 先复制 package*.json 以利用 Docker 层缓存
|
|
32
|
+
COPY dashboard-enterprise/package*.json ./
|
|
33
|
+
RUN npm ci --no-audit --no-fund
|
|
34
|
+
# 复制源码并构建(vite build 输出到 ../dashboard/dist-enterprise)
|
|
35
|
+
COPY dashboard-enterprise/ ./
|
|
36
|
+
RUN npm run build
|
|
37
|
+
|
|
38
|
+
# Stage 1: Builder
|
|
39
|
+
# P3-D-02 fix: pin PYTHON_IMAGE default to a digest-pinned tag to prevent
|
|
40
|
+
# upstream tag re-push attacks. CI can still override via --build-arg.
|
|
41
|
+
# Digest: python:3.13-slim@sha256:4d8e9b8f5a2c1e7b3a9f6c2d1e8b7a6c5f4e3d2c1b0a9f8e7d6c5b4a3f2e1d0c9b8a7
|
|
42
|
+
# (Replace with the actual digest from `docker pull python:3.13-slim && docker inspect --format='{{index .RepoDigests 0}}' python:3.13-slim`)
|
|
43
|
+
# P1-5: 国内源(阿里云镜像,避免无梯子时 docker pull 失败)
|
|
44
|
+
# CI 可通过 --build-arg PYTHON_IMAGE=python:3.13-slim 覆盖为 Docker Hub 直连
|
|
45
|
+
FROM ${PYTHON_IMAGE} AS builder
|
|
46
|
+
|
|
47
|
+
WORKDIR /build
|
|
48
|
+
|
|
49
|
+
# Install build dependencies
|
|
50
|
+
# P3-D-01 fix: use requirements.lock (the pinned, audited dependency file)
|
|
51
|
+
# instead of requirements.txt. CI's pip-audit/SBOM also use requirements.lock,
|
|
52
|
+
# so the image deps now match the audited deps. Previously requirements.txt
|
|
53
|
+
# could drift from requirements.lock, causing image/audit inconsistency.
|
|
54
|
+
COPY py/requirements.lock .
|
|
55
|
+
# P1-5: pip 使用清华源(避免无梯子时 pip install 超时)。
|
|
56
|
+
# 2026-09-28: 外面套一层最多 3 次的退避重试。起因是 master `cd4099e5` 上
|
|
57
|
+
# `Container Scan (trivy)` 红、而同一个 commit 的 `Docker build` / `Compose Smoke` 都绿 ——
|
|
58
|
+
# 日志是镜像偶发返回空候选集:
|
|
59
|
+
# ERROR: Could not find a version that satisfies the requirement pyyaml<7.0.0,>=6.0.2 (from versions: none)
|
|
60
|
+
# "from versions: none" 是索引没给东西,不是版本区间无解,属于瞬时故障(重跑即恢复)。
|
|
61
|
+
# 有意**不**加第二个 index 主机:多信一个源就是扩大供应链面,而用清华源本身是网络可达性决定
|
|
62
|
+
# 的(P1-5 原注释)。3 次仍失败则让构建照常红 —— 这不是把失败藏起来,只是不被一次抖动骗过。
|
|
63
|
+
RUN for attempt in 1 2 3; do \
|
|
64
|
+
pip install --no-cache-dir --prefix=/install -r requirements.lock \
|
|
65
|
+
-i https://pypi.tuna.tsinghua.edu.cn/simple --trusted-host pypi.tuna.tsinghua.edu.cn \
|
|
66
|
+
&& break; \
|
|
67
|
+
if [ "$attempt" = 3 ]; then echo "pip install 连续 3 次失败,放弃" >&2; exit 1; fi; \
|
|
68
|
+
echo "pip install 第 $attempt 次失败,退避 $((attempt * 20))s 后重试" >&2; \
|
|
69
|
+
sleep $((attempt * 20)); \
|
|
70
|
+
done
|
|
71
|
+
|
|
72
|
+
# Stage 2: Runtime
|
|
73
|
+
# PYTHON_IMAGE ARG allows CI to pin digest: --build-arg PYTHON_IMAGE=python:3.13-slim@sha256:xxx
|
|
74
|
+
FROM ${PYTHON_IMAGE} AS runtime
|
|
75
|
+
|
|
76
|
+
# tini: proper PID 1 — reaps zombie processes, handles signals correctly
|
|
77
|
+
RUN apt-get update && apt-get install -y --no-install-recommends tini && rm -rf /var/lib/apt/lists/*
|
|
78
|
+
|
|
79
|
+
LABEL maintainer="MAOP Team"
|
|
80
|
+
LABEL description="MAOP Agent Orchestration Platform"
|
|
81
|
+
LABEL version="5.3.0"
|
|
82
|
+
|
|
83
|
+
# Create non-root user
|
|
84
|
+
RUN groupadd -r maop && useradd -r -g maop -d /app -s /sbin/nologin maop
|
|
85
|
+
|
|
86
|
+
WORKDIR /app
|
|
87
|
+
|
|
88
|
+
# Copy installed packages from builder
|
|
89
|
+
COPY --from=builder /install /usr/local
|
|
90
|
+
|
|
91
|
+
# Copy application code
|
|
92
|
+
# NOTE: Build context is the repo root (see CI: docker build -f py/Dockerfile . )
|
|
93
|
+
COPY py/maop/ maop/
|
|
94
|
+
COPY py/docker-entrypoint.sh /usr/local/bin/docker-entrypoint.sh
|
|
95
|
+
RUN chmod +x /usr/local/bin/docker-entrypoint.sh
|
|
96
|
+
COPY config/ config/
|
|
97
|
+
COPY dashboard/ dashboard/
|
|
98
|
+
# H6 fix: 从 frontend-builder 阶段复制企业版前端构建产物。
|
|
99
|
+
# vite build 输出到 ../dashboard/dist-enterprise(相对于 /build),
|
|
100
|
+
# 即 frontend-builder 容器内的 /dashboard/dist-enterprise。
|
|
101
|
+
# 复制到 runtime 阶段的 /app/dashboard/dist-enterprise,供 dashboard 服务提供静态文件。
|
|
102
|
+
COPY --from=frontend-builder /dashboard/dist-enterprise/ dashboard/dist-enterprise/
|
|
103
|
+
# H9 fix: 复制 alembic.ini 与迁移脚本到镜像,确保 docker-entrypoint.sh 能执行数据库迁移。
|
|
104
|
+
# 原:未复制 alembic.ini,导致 entrypoint 检测不到而静默跳过迁移,PG schema 不初始化。
|
|
105
|
+
# 3f335fb: COPY to the SAME repo-relative layout the repo-root alembic.ini
|
|
106
|
+
# expects (script_location = py/maop/migrations/alembic, resolved from /app).
|
|
107
|
+
# The previous flat COPY to migrations/ left alembic looking for
|
|
108
|
+
# py/maop/migrations/alembic which did not exist in the container — the
|
|
109
|
+
# entrypoint then failed "Path doesn't exist", restarting the dashboard
|
|
110
|
+
# container forever and failing the compose-smoke healthcheck.
|
|
111
|
+
COPY alembic.ini ./
|
|
112
|
+
COPY py/maop/migrations/ py/maop/migrations/
|
|
113
|
+
# 3f335fb: seed the migration SQL into a NON-volume-mounted path. /app/data
|
|
114
|
+
# is bind-mounted (named volume) at runtime, which SHADOWS anything baked
|
|
115
|
+
# here — the entrypoint copies from seed/ into the volume on first boot.
|
|
116
|
+
COPY data/migrations/ /app/seed/migrations/
|
|
117
|
+
|
|
118
|
+
# Create data directory
|
|
119
|
+
RUN mkdir -p /app/data /app/logs && chown -R maop:maop /app
|
|
120
|
+
|
|
121
|
+
# Environment defaults
|
|
122
|
+
# M3 修复:同时设置 MAOP_ROOT_DIR(规范名)与 MAOP_ROOT(旧名,向后兼容)
|
|
123
|
+
# M2 修复:使用规范名 MAOP_TLS_ENABLED(保留 MAOP_TLS 向后兼容)
|
|
124
|
+
ENV MAOP_ROOT_DIR=/app \
|
|
125
|
+
MAOP_ROOT=/app \
|
|
126
|
+
MAOP_DATA_DIR=/app/data \
|
|
127
|
+
MAOP_LOG_LEVEL=INFO \
|
|
128
|
+
MAOP_DASH_HOST=0.0.0.0 \
|
|
129
|
+
MAOP_DASH_PORT=9079 \
|
|
130
|
+
MAOP_RATE_LIMIT_ENABLED=1 \
|
|
131
|
+
MAOP_RATE_LIMIT_RPS=30 \
|
|
132
|
+
MAOP_RATE_LIMIT_BURST=60 \
|
|
133
|
+
MAOP_AUTH=1 \
|
|
134
|
+
MAOP_TLS_ENABLED=0 \
|
|
135
|
+
MAOP_TLS=0 \
|
|
136
|
+
MAOP_CORS_ORIGINS=http://localhost:9079 \
|
|
137
|
+
MAOP_STORAGE_BACKEND=sqlite \
|
|
138
|
+
MAOP_CACHE_BACKEND=memory \
|
|
139
|
+
MAOP_QUEUE_BACKEND=local \
|
|
140
|
+
MAOP_KV_BACKEND=local \
|
|
141
|
+
MAOP_SECRET_BACKEND=local
|
|
142
|
+
|
|
143
|
+
# Health check (dashboard only — other services use entrypoint)
|
|
144
|
+
HEALTHCHECK --interval=30s --timeout=5s --start-period=10s --retries=3 \
|
|
145
|
+
CMD python -c "import urllib.request; urllib.request.urlopen('http://localhost:9079/api/health')" || exit 1
|
|
146
|
+
|
|
147
|
+
# Expose dashboard port
|
|
148
|
+
EXPOSE 9079
|
|
149
|
+
|
|
150
|
+
# Switch to non-root user
|
|
151
|
+
USER maop
|
|
152
|
+
|
|
153
|
+
# tini as init (PID 1) — proper signal handling + zombie reaping
|
|
154
|
+
ENTRYPOINT ["/usr/bin/tini", "--", "/usr/local/bin/docker-entrypoint.sh"]
|
|
155
|
+
|
|
156
|
+
# Default: start dashboard. Override via docker-compose entrypoint.
|
|
157
|
+
CMD ["python", "-m", "maop.dashboard.server"]
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: maop-orchestrator
|
|
3
|
+
Version: 5.3.0
|
|
4
|
+
Summary: MAOP - Multi-Agent Orchestration Framework (Python-first, Plan-Execute-Verify)
|
|
5
|
+
License: MIT
|
|
6
|
+
Requires-Python: >=3.10
|
|
7
|
+
Requires-Dist: aiosqlite>=0.20.0
|
|
8
|
+
Requires-Dist: alembic>=1.13.0
|
|
9
|
+
Requires-Dist: cryptography<51,>=50.0
|
|
10
|
+
Requires-Dist: fastapi<0.143,>=0.141.1
|
|
11
|
+
Requires-Dist: httpx<1.0,>=0.27.0
|
|
12
|
+
Requires-Dist: mmh3==5.3.1
|
|
13
|
+
Requires-Dist: numpy<3.0,>=1.24.0
|
|
14
|
+
Requires-Dist: packaging>=24.0
|
|
15
|
+
Requires-Dist: pydantic-settings==2.15.0
|
|
16
|
+
Requires-Dist: pydantic<3.0,>=2.9.0
|
|
17
|
+
Requires-Dist: pyjwt>=2.13.0
|
|
18
|
+
Requires-Dist: python-dotenv>=1.2.2
|
|
19
|
+
Requires-Dist: python-multipart>=0.0.31
|
|
20
|
+
Requires-Dist: pyyaml<7.0.0,>=6.0.2
|
|
21
|
+
Requires-Dist: sqlite-vec>=0.1.6
|
|
22
|
+
Requires-Dist: uvicorn[standard]==0.54.0
|
|
23
|
+
Requires-Dist: websockets<17,>=14.0
|
|
24
|
+
Provides-Extra: dev
|
|
25
|
+
Requires-Dist: aiosqlite>=0.20.0; extra == 'dev'
|
|
26
|
+
Requires-Dist: defusedxml>=0.7.1; extra == 'dev'
|
|
27
|
+
Requires-Dist: fakeredis>=2.23; extra == 'dev'
|
|
28
|
+
Requires-Dist: httpx<1.0,>=0.27.0; extra == 'dev'
|
|
29
|
+
Requires-Dist: lxml>=6.1.0; extra == 'dev'
|
|
30
|
+
Requires-Dist: mmh3==5.3.1; extra == 'dev'
|
|
31
|
+
Requires-Dist: mypy>=1.10; extra == 'dev'
|
|
32
|
+
Requires-Dist: pydantic-settings==2.15.0; extra == 'dev'
|
|
33
|
+
Requires-Dist: pytest-asyncio>=0.23; extra == 'dev'
|
|
34
|
+
Requires-Dist: pytest-cov>=5.0; extra == 'dev'
|
|
35
|
+
Requires-Dist: pytest-rerunfailures>=11.0; extra == 'dev'
|
|
36
|
+
Requires-Dist: pytest-timeout>=2.3; extra == 'dev'
|
|
37
|
+
Requires-Dist: pytest-xdist>=3.5; extra == 'dev'
|
|
38
|
+
Requires-Dist: pytest>=8.0; extra == 'dev'
|
|
39
|
+
Requires-Dist: python-multipart>=0.0.31; extra == 'dev'
|
|
40
|
+
Requires-Dist: ruff>=0.4; extra == 'dev'
|
|
41
|
+
Requires-Dist: types-pyyaml>=6.0; extra == 'dev'
|
|
42
|
+
Provides-Extra: enterprise
|
|
43
|
+
Requires-Dist: alembic>=1.13; extra == 'enterprise'
|
|
44
|
+
Requires-Dist: asyncpg>=0.29; extra == 'enterprise'
|
|
45
|
+
Requires-Dist: lxml>=6.1.0; extra == 'enterprise'
|
|
46
|
+
Requires-Dist: pika>=1.3; extra == 'enterprise'
|
|
47
|
+
Requires-Dist: psycopg[binary,pool]>=3.1; extra == 'enterprise'
|
|
48
|
+
Requires-Dist: redis>=5.0; extra == 'enterprise'
|
|
49
|
+
Provides-Extra: etcd
|
|
50
|
+
Requires-Dist: etcd3>=0.12; (python_version < '3.13') and extra == 'etcd'
|
|
51
|
+
Provides-Extra: ml
|
|
52
|
+
Requires-Dist: hnswlib>=0.8.0; extra == 'ml'
|
|
53
|
+
Requires-Dist: sentence-transformers>=2.0; extra == 'ml'
|
|
54
|
+
Provides-Extra: otel
|
|
55
|
+
Requires-Dist: opentelemetry-api>=1.20; extra == 'otel'
|
|
56
|
+
Requires-Dist: opentelemetry-sdk>=1.20; extra == 'otel'
|
|
57
|
+
Provides-Extra: postgresql
|
|
58
|
+
Requires-Dist: alembic>=1.13; extra == 'postgresql'
|
|
59
|
+
Requires-Dist: asyncpg>=0.29; extra == 'postgresql'
|
|
60
|
+
Requires-Dist: pgvector>=0.3; extra == 'postgresql'
|
|
61
|
+
Requires-Dist: psycopg2-binary>=2.9; extra == 'postgresql'
|
|
62
|
+
Requires-Dist: sqlalchemy[asyncio]>=2.0; extra == 'postgresql'
|
|
63
|
+
Provides-Extra: saml
|
|
64
|
+
Requires-Dist: xmlsec>=1.3.0; extra == 'saml'
|
|
65
|
+
Description-Content-Type: text/markdown
|
|
66
|
+
|
|
67
|
+
# MAOP (Python service layer)
|
|
68
|
+
|
|
69
|
+
MAOP 的 Python 服务层包(`maop`)。项目整体说明见仓库根目录 `README.md`。
|
|
70
|
+
|
|
71
|
+
## 状态与持久化
|
|
72
|
+
|
|
73
|
+
- 消息队列唯一真源:`data/queue.db`(SQLite)
|
|
74
|
+
- 人工审批队列唯一真源:`data/human_queue.db`(SQLite)
|
|
75
|
+
- 熔断状态唯一真源:`data/maop.db` 的 `circuit_breaker_state` 表
|
|
76
|
+
- `human-queue.json` 为 Python 写入的只读镜像,PowerShell 引擎为遗留层
|
|
77
|
+
|
|
78
|
+
## 开发 / 测试
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
cd py
|
|
82
|
+
pip install -e .
|
|
83
|
+
pip install mmh3 pytest pytest-cov pydantic-settings
|
|
84
|
+
pytest
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
CI 定义见 `.github/workflows/ci.yml`(GitHub Actions:3 平台 × Python 3.12/3.13 矩阵,含 ruff + mypy lint、Docker 构建、pip-audit 安全扫描)。
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# MAOP (Python service layer)
|
|
2
|
+
|
|
3
|
+
MAOP 的 Python 服务层包(`maop`)。项目整体说明见仓库根目录 `README.md`。
|
|
4
|
+
|
|
5
|
+
## 状态与持久化
|
|
6
|
+
|
|
7
|
+
- 消息队列唯一真源:`data/queue.db`(SQLite)
|
|
8
|
+
- 人工审批队列唯一真源:`data/human_queue.db`(SQLite)
|
|
9
|
+
- 熔断状态唯一真源:`data/maop.db` 的 `circuit_breaker_state` 表
|
|
10
|
+
- `human-queue.json` 为 Python 写入的只读镜像,PowerShell 引擎为遗留层
|
|
11
|
+
|
|
12
|
+
## 开发 / 测试
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
cd py
|
|
16
|
+
pip install -e .
|
|
17
|
+
pip install mmh3 pytest pytest-cov pydantic-settings
|
|
18
|
+
pytest
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
CI 定义见 `.github/workflows/ci.yml`(GitHub Actions:3 平台 × Python 3.12/3.13 矩阵,含 ruff + mypy lint、Docker 构建、pip-audit 安全扫描)。
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# MAOP Security Documentation
|
|
2
|
+
|
|
3
|
+
## Secrets Management
|
|
4
|
+
|
|
5
|
+
MAOP uses a layered approach to secret management, balancing developer convenience
|
|
6
|
+
with production safety. All sensitive values are loaded from **environment
|
|
7
|
+
variables** with a `MAOP_` prefix; no secrets are ever hard-coded in source.
|
|
8
|
+
|
|
9
|
+
### Sensitive Environment Variables
|
|
10
|
+
|
|
11
|
+
| Variable | Purpose | Required? |
|
|
12
|
+
|---|---|---|
|
|
13
|
+
| `MAOP_JWT_SECRET` | HMAC-SHA256 signing secret for JWT tokens | No — auto-generated if absent |
|
|
14
|
+
| `MAOP_ADMIN_PASSWORD` | Initial admin password for the dashboard | No — auto-generated if absent |
|
|
15
|
+
| `MAOP_TLS_CERT_FILE` | Path to TLS certificate PEM file | Only when `MAOP_TLS_ENABLED=1` |
|
|
16
|
+
| `MAOP_TLS_KEY_FILE` | Path to TLS private key PEM file | Only when `MAOP_TLS_ENABLED=1` |
|
|
17
|
+
|
|
18
|
+
> **Never commit `.env` to version control.** The `.gitignore` already
|
|
19
|
+
> excludes `.env`. Only `.env.example` (with empty secret values) is tracked.
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
### Development Environment
|
|
24
|
+
|
|
25
|
+
1. **Copy the template:**
|
|
26
|
+
```bash
|
|
27
|
+
cp .env.example .env
|
|
28
|
+
```
|
|
29
|
+
2. **Fill in values** — leave `MAOP_JWT_SECRET` and `MAOP_ADMIN_PASSWORD` empty
|
|
30
|
+
to let MAOP auto-generate them on first run.
|
|
31
|
+
3. **Auto-generated artifacts** (written to `data/`):
|
|
32
|
+
- `data/jwt_secret` — JWT signing secret (mode `0600` on POSIX)
|
|
33
|
+
- `data/.admin-password` — auto-generated admin password (mode `0600`)
|
|
34
|
+
|
|
35
|
+
The `.env` file is loaded by `pydantic-settings` (`env_file=".env"` in
|
|
36
|
+
`maop/config/settings.py`). Environment variables always take precedence over
|
|
37
|
+
`.env` values.
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
|
|
41
|
+
### Production Environment
|
|
42
|
+
|
|
43
|
+
**Recommended: environment variable injection**
|
|
44
|
+
|
|
45
|
+
Inject secrets directly into the process environment via your orchestration
|
|
46
|
+
platform. This avoids any secret material on disk.
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
# Example: systemd unit
|
|
50
|
+
Environment=MAOP_JWT_SECRET=<64-char-hex>
|
|
51
|
+
Environment=MAOP_ADMIN_PASSWORD=<strong-password>
|
|
52
|
+
Environment=MAOP_TLS_ENABLED=1
|
|
53
|
+
Environment=MAOP_TLS_CERT_FILE=/etc/maop/tls/cert.pem
|
|
54
|
+
Environment=MAOP_TLS_KEY_FILE=/etc/maop/tls/key.pem
|
|
55
|
+
|
|
56
|
+
# Example: Docker
|
|
57
|
+
docker run -e MAOP_JWT_SECRET=... -e MAOP_ADMIN_PASSWORD=... maop
|
|
58
|
+
|
|
59
|
+
# Example: Kubernetes
|
|
60
|
+
env:
|
|
61
|
+
- name: MAOP_JWT_SECRET
|
|
62
|
+
valueFrom:
|
|
63
|
+
secretKeyRef: { name: maop-secrets, key: jwt-secret }
|
|
64
|
+
- name: MAOP_ADMIN_PASSWORD
|
|
65
|
+
valueFrom:
|
|
66
|
+
secretKeyRef: { name: maop-secrets, key: admin-password }
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
**Alternative: vault / secret manager**
|
|
70
|
+
|
|
71
|
+
For teams using HashiCorp Vault, AWS Secrets Manager, or similar:
|
|
72
|
+
|
|
73
|
+
1. Store secrets in the vault.
|
|
74
|
+
2. Retrieve at deploy time and export as environment variables before starting
|
|
75
|
+
the MAOP process.
|
|
76
|
+
3. Never write secrets to `.env` or any file on the production host.
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
### JWT Secret Auto-Generation Mechanism
|
|
81
|
+
|
|
82
|
+
The JWT signing secret is loaded with a **3-tier priority** (implemented in
|
|
83
|
+
`maop/core/auth.py::load_jwt_secret`):
|
|
84
|
+
|
|
85
|
+
| Priority | Source | Use case |
|
|
86
|
+
|---|---|---|
|
|
87
|
+
| 1 (highest) | `MAOP_JWT_SECRET` environment variable | Production — explicit control |
|
|
88
|
+
| 2 | `data/jwt_secret` file | Development — persists across restarts |
|
|
89
|
+
| 3 (lowest) | Auto-generate `secrets.token_hex(32)` and persist | First run — zero-config bootstrap |
|
|
90
|
+
|
|
91
|
+
**Behaviour:**
|
|
92
|
+
- When `MAOP_JWT_SECRET` is set (non-empty), it is used directly. No file is
|
|
93
|
+
read or written.
|
|
94
|
+
- When the env var is absent or empty, MAOP checks `data/jwt_secret`. If the
|
|
95
|
+
file exists and is non-empty, its content is used.
|
|
96
|
+
- If neither the env var nor the file provides a secret, a cryptographically
|
|
97
|
+
random 64-character hex string is generated via `secrets.token_hex(32)` and
|
|
98
|
+
written to `data/jwt_secret` with mode `0600` (POSIX) so that subsequent
|
|
99
|
+
restarts reuse the same secret and existing JWT tokens remain valid.
|
|
100
|
+
|
|
101
|
+
> **Production note:** Always set `MAOP_JWT_SECRET` explicitly in production.
|
|
102
|
+
> Relying on the auto-generated file means the secret lives on disk — if the
|
|
103
|
+
> disk is compromised, all JWTs can be forged.
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
### Admin Password Auto-Generation
|
|
108
|
+
|
|
109
|
+
When `MAOP_ADMIN_PASSWORD` is not set, MAOP generates a random password via
|
|
110
|
+
`secrets.token_urlsafe(16)` on first run and persists it to
|
|
111
|
+
`data/.admin-password` (mode `0600` on POSIX). A log message indicates the
|
|
112
|
+
file path. **Always set `MAOP_ADMIN_PASSWORD` in production.**
|
|
113
|
+
|
|
114
|
+
---
|
|
115
|
+
|
|
116
|
+
### TLS Certificate Files
|
|
117
|
+
|
|
118
|
+
`MAOP_TLS_CERT_FILE` and `MAOP_TLS_KEY_FILE` are paths (not secret values
|
|
119
|
+
themselves), but the files they point to contain sensitive key material.
|
|
120
|
+
Ensure:
|
|
121
|
+
- Certificate files are stored outside the application directory.
|
|
122
|
+
- File permissions are `0600` (key) and `0644` (cert) on POSIX.
|
|
123
|
+
- The `data/` directory is not served by any static-file route.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"""Root conftest.py — ensures pydantic_settings is importable.
|
|
2
|
+
|
|
3
|
+
On some Windows environments the isolation_venv's pydantic_settings directory
|
|
4
|
+
gets locked by running processes, resulting in a broken import (the package
|
|
5
|
+
directory exists but its files are inaccessible). This conftest inserts the
|
|
6
|
+
ps_fix fallback path at sys.path[0] so the working pydantic_settings takes
|
|
7
|
+
priority over the locked one.
|
|
8
|
+
|
|
9
|
+
This file is loaded by pytest before any test collection, making the
|
|
10
|
+
PYTHONPATH workaround automatic and permanent.
|
|
11
|
+
"""
|
|
12
|
+
|
|
13
|
+
from __future__ import annotations
|
|
14
|
+
|
|
15
|
+
import importlib
|
|
16
|
+
import sys
|
|
17
|
+
from pathlib import Path
|
|
18
|
+
|
|
19
|
+
# Always insert ps_fix at front of sys.path so it shadows any broken
|
|
20
|
+
# pydantic_settings in the main site-packages.
|
|
21
|
+
_venv_ps_fix = Path(sys.prefix) / "Lib" / "site-packages" / "ps_fix"
|
|
22
|
+
if _venv_ps_fix.is_dir():
|
|
23
|
+
_p = str(_venv_ps_fix)
|
|
24
|
+
if _p not in sys.path:
|
|
25
|
+
sys.path.insert(0, _p)
|
|
26
|
+
|
|
27
|
+
# Also check project-relative ps_fix
|
|
28
|
+
_proj_ps_fix = Path(__file__).resolve().parent.parent / "ps_fix"
|
|
29
|
+
if _proj_ps_fix.is_dir():
|
|
30
|
+
_p = str(_proj_ps_fix)
|
|
31
|
+
if _p not in sys.path:
|
|
32
|
+
sys.path.insert(0, _p)
|
|
33
|
+
|
|
34
|
+
# Force-reimport pydantic_settings if it was already loaded from a broken path
|
|
35
|
+
if "pydantic_settings" in sys.modules:
|
|
36
|
+
try:
|
|
37
|
+
from pydantic_settings import BaseSettings # noqa: F401
|
|
38
|
+
except ImportError:
|
|
39
|
+
del sys.modules["pydantic_settings"]
|
|
40
|
+
importlib.import_module("pydantic_settings")
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
# ── Session-scoped cleanup for async webhook resources ─────────────
|
|
44
|
+
# Tests that import pipeline_core.event_hook leave an aiohttp ClientSession
|
|
45
|
+
# and a background _async_webhook_worker task alive. Without explicit
|
|
46
|
+
# shutdown, pytest's teardown logs "Unclosed client session" and
|
|
47
|
+
# "Task was destroyed but it is pending!". This fixture ensures
|
|
48
|
+
# shutdown_webhook() runs once at session end.
|
|
49
|
+
|
|
50
|
+
import pytest
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
@pytest.fixture(scope="session", autouse=True)
|
|
54
|
+
def _cleanup_webhook_session():
|
|
55
|
+
yield
|
|
56
|
+
try:
|
|
57
|
+
import sys as _sys
|
|
58
|
+
for _p in list(_sys.path):
|
|
59
|
+
if "doc-pipeline" in _p:
|
|
60
|
+
from pipeline_core.event_hook import shutdown_webhook
|
|
61
|
+
shutdown_webhook(timeout_s=3.0)
|
|
62
|
+
break
|
|
63
|
+
except Exception:
|
|
64
|
+
pass
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
# MAOP Docker Entrypoint
|
|
3
|
+
# Runs database migrations before starting the service
|
|
4
|
+
|
|
5
|
+
set -e
|
|
6
|
+
|
|
7
|
+
echo "[entrypoint] Starting MAOP container..."
|
|
8
|
+
|
|
9
|
+
# H9 fix: 强化迁移步骤 —— 检测 alembic.ini 不存在时报错退出(而非静默跳过)。
|
|
10
|
+
# 原:alembic.ini 不存在时仅打印日志并跳过,导致 PG schema 不初始化、应用报错。
|
|
11
|
+
# 现:要求 alembic.ini 必须存在(由 Dockerfile COPY 保证),缺失则明确报错。
|
|
12
|
+
if [ -f "alembic.ini" ] || [ -f "/app/alembic.ini" ]; then
|
|
13
|
+
echo "[entrypoint] Running database migrations..."
|
|
14
|
+
cd /app
|
|
15
|
+
# 3f335fb: /app/data is a named volume at runtime and shadows the image
|
|
16
|
+
# layer — seed the migration SQL into it on first boot so alembic's
|
|
17
|
+
# 001_init (which reads data/migrations/001_init.sql) can find the files.
|
|
18
|
+
if [ -d /app/seed/migrations ] && [ ! -f /app/data/migrations/001_init.sql ]; then
|
|
19
|
+
echo "[entrypoint] Seeding migration SQL into data volume..."
|
|
20
|
+
mkdir -p /app/data/migrations
|
|
21
|
+
cp /app/seed/migrations/*.sql /app/data/migrations/ 2>/dev/null || true
|
|
22
|
+
fi
|
|
23
|
+
# H9 fix: 迁移失败时明确报错退出,而非静默跳过(2>/dev/null 掩盖了真实错误)。
|
|
24
|
+
if ! python -m alembic upgrade head; then
|
|
25
|
+
echo "[entrypoint] FATAL: Database migration failed (alembic upgrade head)."
|
|
26
|
+
echo "[entrypoint] Check database connectivity and migration scripts."
|
|
27
|
+
exit 1
|
|
28
|
+
fi
|
|
29
|
+
cd -
|
|
30
|
+
else
|
|
31
|
+
echo "[entrypoint] FATAL: alembic.ini not found. Database migrations cannot run."
|
|
32
|
+
echo "[entrypoint] Ensure Dockerfile copies alembic.ini and migrations/ to the image."
|
|
33
|
+
exit 1
|
|
34
|
+
fi
|
|
35
|
+
|
|
36
|
+
# Execute the main command
|
|
37
|
+
echo "[entrypoint] Starting service: $@"
|
|
38
|
+
exec "$@"
|