yams/tests/integration/daemon
Trevon 211db15606
fix(daemon): bound semantic neighbor scores and report startup phase (#334)
Semantic-neighbor maintenance aborted the daemon during startup:
std::clamp<float> asserted '!(__hi < __lo)' because the adaptive cosine
threshold could exceed 1.0 for a legal pair of identical vectors. The same
work was also admitted while the daemon was still initializing, so the
300-second starvation guard forced a pass before readiness.

+ semanticInverseNorm/semanticCosineSimilarity/semanticExplicitThreshold in the
  existing embed policy header, shared by the streamed and corpus branches;
  non-finite vectors or scores produce no neighbor and legal scores are bounded
  before ranking and threshold selection
+ startupMaintenanceEligible() requires ServiceManagerState::Ready, not
  stopping and idle, and is evaluated before
  ResourceGovernor::admitDeferrable(), so an elapsed deferral deadline can no
  longer manufacture missing readiness
+ StartupPhaseTracker (two atomics, no mutex) plus a warn-level init-waiter
  line reporting state, phase and phase_elapsed_ms instead of a debug-level
  state number; a 53-minute startup previously logged nothing actionable
+ regression through the public backfill and corpus-rebuild APIs using a 64-D
  vector whose old float inverse norm rounds its self-cosine above 1
- removed the duplicated inverse-norm and cosine lambdas from EmbeddingService
- renamed __test_setModelProvider/__test_setKgStore to testing_* because they
  used reserved identifiers, across 11 files
- re-anchored 13 pre-existing raw-environment allowlist entries to their new
  line numbers; no new exception was added

Startup is still blocked by corpus-sized memory-sync scans; this change stops
the abort and names the blocking phase, it does not make startup fast.

Signed-off-by: trvon <git@trevon.dev>
2026-10-22 16:48:49 -06:00
..
cli_responsiveness_under_load_test.cpp refactor(test): consolidate daemon harness 2026-08-05 20:53:18 -04:00
client_timeout_recovery_test.cpp perf(search): bound topology routing and harden runtime paths (#59) 2026-07-19 14:53:10 -04:00
codex_sandbox_embedding_regression_test.cpp fix(daemon): bound semantic neighbor scores and report startup phase (#334) 2026-10-22 16:48:49 -06:00
daemon_db_corruption_recovery_test.cpp fix(daemon): delete corrupt DB copies only after confirmed salvage 2026-09-27 13:57:29 -06:00
daemon_harness_catch2_test.cpp test(harness): relocate runtime dir and scrub model overrides under isolation 2026-10-01 05:54:16 -06:00
daemon_shutdown_test.cpp fix(daemon): destroy the SocketServer only after its handlers are gone 2026-09-27 20:11:43 -06:00
daemon_sigterm_test.cpp testing improvements 2026-01-14 16:27:42 -05:00
daemon_socket_client_test.cpp fix(daemon): bound semantic neighbor scores and report startup phase (#334) 2026-10-22 16:48:49 -06:00
ghidra_kg_entity_ingestion_test.cpp chore(warnings): clean up compiler warnings on GCC, Clang and Apple Clang (#279) 2026-10-08 14:30:28 -06:00
lifecycle_single_instance_test.cpp test(daemon): keep repair work pending while awaiting degrade 2026-09-18 16:23:20 -06:00
memory_sync_service_integration_test.cpp fix(daemon): admit cold reads and preserve sync deferral accounting (#331) 2026-10-22 07:12:25 -06:00
meson.build fix(daemon): admit cold reads and preserve sync deferral accounting (#331) 2026-10-22 07:12:25 -06:00
onnx_tuning_integration_test.cpp build: standardize the Debug build dir on build/debug (#248) 2026-10-01 08:45:20 -06:00
post_ingest_queue_benchmark_test.cpp fix: updating conanfile for onnxruntime to respect system version, updated tests for windows compat, update vectors to enforce wal check point so files does not explode in size 2026-02-21 12:20:50 -05:00
post_ingest_queue_validation_test.cpp test: isolate process environment 2026-08-04 21:31:39 -04:00
post_ingest_trace.cpp test: isolate process environment 2026-08-04 21:31:39 -04:00
proxy_slot_starvation_test.cpp style(tests): align validation formatting 2026-08-12 12:29:12 -06:00
resource_governor_integration_test.cpp Stabilize sanitizer lanes and daemon concurrency (#40) 2026-06-01 12:14:43 -04:00
socket_memory_pressure_test.cpp feat: additional test improvements, improved logic for ingestion queue to increase throughput and client stability 2026-02-16 18:13:54 -05:00
stats_command_crash_test.cpp fix(tests): replace frozen expectations and harden release gates (#323) 2026-10-19 19:16:57 -06:00
test_async_helpers.h test improvements 2026-01-23 23:00:56 -05:00
test_daemon_harness.h chore(warnings): clean up compiler warnings on GCC, Clang and Apple Clang (#279) 2026-10-08 14:30:28 -06:00