/** * Stable internal log event names and component tags. * * Boundaries must emit only these constants so downstream log analysis can * key on stable strings. All names pass the identifier allowlist enforced by * `internalLog.ts`. Internal only — never exported from the root barrel. */ /** Dotted event names emitted at instrumented boundaries. */ export declare const HIKOUTEI_LOG_EVENTS: { /** Local or mapped runtime opened successfully. */ readonly RUNTIME_OPENED: "hikoutei.runtime.opened"; /** Runtime open failed (storage init, descriptor resolution, provider). */ readonly RUNTIME_OPEN_FAILED: "hikoutei.runtime.open_failed"; /** Runtime closed after stopping internal service work. */ readonly RUNTIME_CLOSED: "hikoutei.runtime.closed"; /** Runtime close failed (provider close or shutdown hook). */ readonly RUNTIME_CLOSE_FAILED: "hikoutei.runtime.close_failed"; /** EntityManager flush failed inside its provider transaction. */ readonly EM_FLUSH_FAILED: "hikoutei.em.flush_failed"; /** A transactional() callback or its commit failed and rolled back. */ readonly EM_TRANSACTIONAL_FAILED: "hikoutei.em.transactional_failed"; /** A find/findOne/count/findAndCount read failed. */ readonly EM_QUERY_FAILED: "hikoutei.em.query_failed"; /** A lifecycle call (create/persist/remove) failed validation. */ readonly EM_LIFECYCLE_INVALID: "hikoutei.em.lifecycle_invalid"; /** Sync auto-start succeeded and the service is running. */ readonly SYNC_AUTOSTART_STARTED: "hikoutei.sync.autostart_started"; /** Sync auto-start failed (config, credentials, transport, provisioning). */ readonly SYNC_AUTOSTART_FAILED: "hikoutei.sync.autostart_failed"; /** The internal sync service bootstrap failed and is cleaning up. */ readonly SYNC_SERVICE_START_FAILED: "hikoutei.sync.service_start_failed"; /** One Google Sheets transport request failed (HTTP, timeout, network). */ readonly TRANSPORT_REQUEST_FAILED: "hikoutei.transport.request_failed"; /** One Google Sheets response failed shape validation. */ readonly TRANSPORT_RESPONSE_INVALID: "hikoutei.transport.response_invalid"; /** One effect-worker pass threw (claim/dispatch/postcondition error). */ readonly OUTBOX_PASS_FAILED: "hikoutei.outbox.pass_failed"; /** Non-idle effect-worker pass summary (counts only). */ readonly OUTBOX_PASS_SUMMARY: "hikoutei.outbox.pass_summary"; /** A reconciliation or User_Input cleanup scan failed (fail-open repair net). */ readonly RECONCILIATION_SCAN_FAILED: "hikoutei.reconciliation.scan_failed"; /** A User_Input polling pass threw; the supervisor backs off and retries. */ readonly POLLING_PASS_FAILED: "hikoutei.polling.pass_failed"; /** Non-idle polling pass summary (counts only, quarantines included). */ readonly POLLING_PASS_SUMMARY: "hikoutei.polling.pass_summary"; /** An effect-worker pass could not claim the writer lease (another writer holds it). */ readonly WRITER_LEASE_UNAVAILABLE: "hikoutei.writer_lease.unavailable"; /** Background writer-lease heartbeat CHANGED held state (renewed ↔ not held). */ readonly WRITER_LEASE_HEARTBEAT: "hikoutei.writer_lease.heartbeat"; /** One Google Sheets API transport request completed (DEBUG, redacted counts). */ readonly SHEETS_REQUEST: "hikoutei.sheets.request"; /** Non-empty Google Sheets request window summary flushed per non-idle pass. */ readonly SHEETS_REQUEST_SUMMARY: "hikoutei.sheets.request_summary"; }; /** Stable component tags naming the owning subsystem. */ export declare const HIKOUTEI_LOG_COMPONENTS: { readonly RUNTIME: "runtime"; readonly ENTITY_MANAGER: "entity-manager"; readonly SYNC_AUTOSTART: "sync-autostart"; readonly SYNC_SERVICE: "sync-service"; readonly TRANSPORT: "transport"; readonly OUTBOX: "outbox"; readonly RECONCILIATION: "reconciliation"; readonly POLLING: "polling"; readonly SHEETS: "sheets"; }; /** * Explicit registry of every stable machine-readable error code the * internal log may carry in its `code` field. * * The literal strings mirror the `*_ERROR_CODES` constants across layers * (public API, sync sheets contract, Google Sheets transport, sync service, * storage, evaluation, mapped ORM, domain event identity, stable encoding) * plus the SQLite driver family that can surface through the persistence * engine. Intentionally out of scope: the CLI setup taxonomy * (`SETUP_ERROR_CODES` in `src/cli/errors.ts`) and the internal MCP * sync-status reader (`HIKOUTEI_SYNC_STATUS_ERROR_CODES` in * `src/internal/syncStatus.ts`) are separate tooling surfaces that never * route through the runtime log, and the canonical-codec family of * `@hikoutei/kohkai` is broader than the stable-encoding subset Hikoutei * actually raises. This is a deliberate allowlist: an unknown or arbitrary * `error.code` (which could be an ID-like secret) must never pass through * to the log. A test asserts the registry stays in sync with every * `*_ERROR_CODES` constant in the repository. */ export declare const HIKOUTEI_LOG_STABLE_CODES: readonly ["invalid_entity_descriptor", "duplicate_entity", "unregistered_entity", "entity_primary_key_unavailable", "entity_primary_key_mutation", "unmanaged_entity", "invalid_scalar_value", "invalid_query", "entity_not_found", "entity_identity_conflict", "sync_startup_failed", "sync_spreadsheet_url_invalid", "sync_credentials_file_missing", "sync_credentials_invalid_json", "sync_credentials_field_missing", "sync_auth_failed", "sync_spreadsheet_access_denied", "sync_spreadsheet_not_found", "sync_provisioning_failed", "invalid_sync_effect_payload", "invalid_sync_provisioning", "invalid_sync_client_options", "invalid_sync_provider_response", "invalid_fake_sync_provider_input", "google_sheets_api_timeout", "google_sheets_api_network_error", "google_sheets_api_http_error", "google_sheets_api_invalid_response", "google_sheets_api_request_start_refused", "invalid_sync_service_options", "invalid_sync_projection_config", "sync_provider_unavailable", "sync_service_startup_failed", "existing_sheet_adoption_dry_run_report", "existing_sheet_adoption_cell_kind_mismatch", "sync_polling_positive_integer_required", "sync_polling_backoff_order_invalid", "unsupported_sync_effect_kind", "unsupported_sync_projection", "unsupported_sync_effect_target_kind", "invalid_writer_lease_options", "invalid_sync_registration", "sync_registration_write_failed", "sync_registration_conflict", "sync_registry_target_unavailable", "invalid_observation_input", "observation_storage_inconsistent", "observation_audit_serialization_failed", "invalid_effect_options", "invalid_pending_effect", "effect_write_failed", "effect_replan_conflict", "invalid_effect_result", "invalid_projection_confirmation", "projection_confirmation_regression", "stale_writer_fence", "invalid_resolution_command", "resolution_command_identity_conflict", "resolution_storage_inconsistent", "resolution_effect_conflict", "resolution_target_unavailable", "invalid_stored_conflict", "schema_version_too_new", "schema_table_missing", "schema_index_missing", "schema_column_missing", "schema_version_invalid", "invalid_sql_script", "canonical_state_required", "canonical_field_required", "base_field_revision_required", "duplicate_changed_field", "invalid_entity_mapping", "duplicate_entity_mapping", "entity_mapping_not_found", "entity_primary_key_mismatch", "invalid_mapped_field_value", "writer_lease_unavailable", "row_binding_conflict", "canonical_commit_rejected", "projection_outbox_blocked", "observation_entity_mutation_failed", "unsupported_value_type", "non_finite_number", "invalid_date_format", "invalid_date_byte_length", "duplicate_object_key", "unpaired_high_surrogate", "unpaired_low_surrogate", "cyclic_value", "ERR_SQLITE_ERROR"]; /** * Explicit registry of error class names the internal log may carry in its * `errorClass` field. * * Covers the JavaScript built-ins, the project's structured error classes, * and the current persistence engine's error families. Unknown class names * are redacted; losing a diagnostic detail is always safer than risking a * secret-like value in the log. * * Intentionally out of scope: the CLI setup taxonomy (a `SetupFailure` * value, never a class) and the MCP sync-status reader * (`HikouteiSyncStatusError` in `src/internal/syncStatus.ts`) are separate * tooling surfaces that never route through the runtime log, and the * internal storage sentinels (`FenceLostError`, `ResolutionStaleFenceError`, * `CanonicalStaleError`, `AsyncFenceLostError`) are caught and converted into * result kinds before * any boundary, so they never surface as thrown classes. */ export declare const HIKOUTEI_LOG_STABLE_CLASSES: readonly ["Error", "TypeError", "RangeError", "ReferenceError", "SyntaxError", "EvalError", "URIError", "AggregateError", "HikouteiError", "TypedSheetsOrmError", "SyncSheetsContractError", "SyncServiceError", "PollingSupervisorOptionsError", "SyncEffectContractError", "StorageError", "EvaluationContractError", "StableEncodingError", "DuplicateChangedFieldError", "GoogleSheetsApiTransportError", "ValidationError", "CursorError", "OptimisticLockError", "MetadataError", "NotFoundError", "TransactionStateError", "DriverException", "ConnectionException", "ServerException", "ConstraintViolationException", "DatabaseObjectExistsException", "DatabaseObjectNotFoundException", "DeadlockException", "ForeignKeyConstraintViolationException", "CheckConstraintViolationException", "InvalidFieldNameException", "LockWaitTimeoutException", "NonUniqueFieldNameException", "NotNullConstraintViolationException", "ReadOnlyException", "SyntaxErrorException", "TableExistsException", "TableNotFoundException", "UniqueConstraintViolationException"]; /** * Explicit allowlist of provider-operation tags the internal log may carry in * its `providerOperation` field. * * Mirrors `SYNC_INVALID_PROVIDER_OPERATIONS` in * `packages/library/core/sync-engine/src/sync/sheetsContract/errors.ts`. Only proven invalid- * provider-state operations are allowed; anything else (including an ID-like * or secret value) is redacted by the internal log writer. */ export declare const HIKOUTEI_LOG_PROVIDER_OPERATIONS: readonly ["preflight", "batch_update_reply", "get_reply", "postcondition_read", "unclassified"]; /** * Explicit allowlist of Google Sheets API transport operation names the * internal log may carry in its `providerOperation` field. * * These are the exact operation values of the provider's redacted request * telemetry events (`GoogleSheetsApiRequestEvent.operation` in * `@hikoutei/contracts/sheets/googleSheetsApi.ts`), so the request-telemetry * boundary can log `providerOperation = event.operation` without redaction. * Kept SEPARATE from {@link HIKOUTEI_LOG_PROVIDER_OPERATIONS} (which mirrors * the invalid-provider-state classification constants and is pinned to them * by test) — the request telemetry is a different producer of the same * structured field, so the formatter accepts the union of both registries. */ export declare const HIKOUTEI_LOG_TRANSPORT_OPERATIONS: readonly ["getSpreadsheet", "batchUpdate"]; /** * Explicit allowlist of provider-reason codes the internal log may carry in * its `providerReason` field. * * Mirrors `SYNC_INVALID_PROVIDER_REASONS` in * `packages/library/core/sync-engine/src/sync/sheetsContract/errors.ts`. Every value is a stable * lowercase identifier with no ID/URL/payload content. */ export declare const HIKOUTEI_LOG_PROVIDER_REASONS: readonly ["malformed_reply", "identity_already_exists", "missing_tab", "unclassified"]; //# sourceMappingURL=logEvents.d.ts.map