pub mod host;
pub mod transport;
#[cfg(feature = "webrtc")]
pub mod webrtc;
pub mod wire_input;
pub use host::{
DEFAULT_LIVE_TOOL_TIMEOUT, DeltaIdentity, LiveAdapterHost, LiveAdapterHostError,
LiveChannelCloseCommitAuthority, LiveChannelCloseObservation, LiveChannelId,
LiveChannelOpenAuthority, LiveChannelStatusCommitAuthority, LiveChannelStatusObservation,
LiveCommandAcceptanceKind, LiveCommandQueueAcceptance, LiveProjectionError, LiveProjectionSink,
LiveRefreshQueueAcceptance, LiveToolDispatchError, LiveToolDispatchTimeout, LiveToolDispatcher,
LiveTranscriptIdentity, LiveTranscriptIdentityError, NoOpProjectionSink, ObservationOutcome,
ObservationRouting, ToolDispatchSkipReason,
};
pub use transport::{
LIVE_WS_PATH, LiveChannelCloseFeedback, LiveChannelStatusFeedback, LiveTokenString,
LiveWsState, LiveWsTokenAdmission, LiveWsTokenAdmissionPublicErrorClass,
LiveWsTokenAdmissionRejection, LiveWsTokenAuthority, LiveWsTokenIssue, live_ws_router,
serve_live_ws_listener,
};
#[cfg(feature = "webrtc")]
pub use webrtc::{
LIVE_WEBRTC_ANSWER_METHOD, LIVE_WEBRTC_ANSWER_PATH, LiveWebrtcAnswerAccepted, LiveWebrtcError,
LiveWebrtcState, WebrtcAudioBridge, live_webrtc_router, serve_live_ws_and_webrtc_listener,
};
pub use wire_input::{
LiveInputChunkDecodeError, live_input_chunk_decode_rejection, live_input_chunk_from_wire,
};
#[cfg(test)]
mod e26_dependency_direction {
#[test]
fn cargo_toml_does_not_depend_on_meerkat_runtime() {
let cargo_toml = include_str!("../Cargo.toml");
for line in cargo_toml.lines() {
let trimmed = line.trim_start();
assert!(
!trimmed.starts_with("meerkat-runtime"),
"E26 regression: meerkat-live must not depend on meerkat-runtime; \
found Cargo.toml line: {line}"
);
}
}
#[test]
fn webrtc_media_dependencies_are_feature_gated() {
let cargo_toml = include_str!("../Cargo.toml");
assert!(
cargo_toml.lines().any(|line| line.trim() == "default = []"),
"meerkat-live default feature set must not enable WebRTC/media"
);
for dep in ["webrtc", "webrtc-media", "opus", "rubato"] {
let needle = format!("{dep} = ");
let dep_line = cargo_toml
.lines()
.find(|line| line.trim_start().starts_with(&needle))
.unwrap_or_else(|| panic!("missing optional {dep} dependency"));
assert!(
dep_line.contains("optional = true"),
"{dep} dependency must stay optional: {dep_line}"
);
}
}
}