python-aidot-cameras 0.17.3b2__tar.gz → 1.0.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.
Files changed (407) hide show
  1. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/LICENSE +2 -1
  2. python_aidot_cameras-1.0.0/MANIFEST.in +3 -0
  3. python_aidot_cameras-1.0.0/PKG-INFO +475 -0
  4. python_aidot_cameras-1.0.0/README.md +425 -0
  5. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/__init__.py +55 -1
  6. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/__main__.py +119 -150
  7. python_aidot_cameras-1.0.0/aidot_cameras/_log_redaction.py +126 -0
  8. python_aidot_cameras-1.0.0/aidot_cameras/_upstream.py +421 -0
  9. python_aidot_cameras-1.0.0/aidot_cameras/_vendor/__init__.py +3 -0
  10. python_aidot_cameras-1.0.0/aidot_cameras/_vendor/aiortc/LICENSE +25 -0
  11. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcdtlstransport.py +12 -1
  12. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcicetransport.py +21 -2
  13. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcpeerconnection.py +22 -2
  14. python_aidot_cameras-1.0.0/aidot_cameras/camera/aac_track.py +449 -0
  15. python_aidot_cameras-1.0.0/aidot_cameras/camera/agc.py +170 -0
  16. python_aidot_cameras-1.0.0/aidot_cameras/camera/client.py +7707 -0
  17. python_aidot_cameras-1.0.0/aidot_cameras/camera/constants.py +197 -0
  18. python_aidot_cameras-1.0.0/aidot_cameras/camera/controls.py +620 -0
  19. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/go2rtc.py +103 -21
  20. python_aidot_cameras-1.0.0/aidot_cameras/camera/h264_sps.py +341 -0
  21. python_aidot_cameras-1.0.0/aidot_cameras/camera/health.py +232 -0
  22. python_aidot_cameras-1.0.0/aidot_cameras/camera/hls_ts.py +195 -0
  23. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/hwaccel.py +90 -46
  24. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/lan_control.py +94 -57
  25. python_aidot_cameras-1.0.0/aidot_cameras/camera/models.py +366 -0
  26. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/protocol.py +1705 -328
  27. python_aidot_cameras-1.0.0/aidot_cameras/camera/recording.py +141 -0
  28. python_aidot_cameras-1.0.0/aidot_cameras/camera/rtp_h264.py +123 -0
  29. python_aidot_cameras-1.0.0/aidot_cameras/camera/rtsp_publish.py +1923 -0
  30. python_aidot_cameras-1.0.0/aidot_cameras/camera/sd_events.py +326 -0
  31. python_aidot_cameras-1.0.0/aidot_cameras/camera/sd_listing.py +422 -0
  32. python_aidot_cameras-1.0.0/aidot_cameras/camera/sd_playback.py +862 -0
  33. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/sdes.py +222 -42
  34. python_aidot_cameras-1.0.0/aidot_cameras/camera/sdes_open.py +10041 -0
  35. python_aidot_cameras-1.0.0/aidot_cameras/camera/ts_fanout.py +398 -0
  36. python_aidot_cameras-1.0.0/aidot_cameras/camera/ts_tee.py +335 -0
  37. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/webrtc.py +81 -34
  38. python_aidot_cameras-1.0.0/aidot_cameras/camera/webrtc_open.py +4977 -0
  39. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/client.py +135 -136
  40. python_aidot_cameras-1.0.0/aidot_cameras/cloud_auth.py +195 -0
  41. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/const.py +18 -6
  42. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/credentials.py +31 -13
  43. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/crypto.py +9 -5
  44. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/device_client.py +53 -99
  45. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/discover.py +36 -56
  46. python_aidot_cameras-1.0.0/aidot_cameras/exceptions.py +234 -0
  47. python_aidot_cameras-1.0.0/aidot_cameras/lan_retry.py +647 -0
  48. python_aidot_cameras-1.0.0/aidot_cameras/settings.py +504 -0
  49. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/pyproject.toml +65 -22
  50. python_aidot_cameras-1.0.0/python_aidot_cameras.egg-info/PKG-INFO +475 -0
  51. python_aidot_cameras-1.0.0/python_aidot_cameras.egg-info/SOURCES.txt +369 -0
  52. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/python_aidot_cameras.egg-info/requires.txt +14 -2
  53. python_aidot_cameras-1.0.0/tests/test_aac_track.py +854 -0
  54. python_aidot_cameras-1.0.0/tests/test_abandoned_attempt_skips_the_doomed_serve.py +288 -0
  55. python_aidot_cameras-1.0.0/tests/test_abandoned_wait_still_maps_audio.py +94 -0
  56. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_aioice_compat.py +17 -2
  57. python_aidot_cameras-1.0.0/tests/test_alarm_event.py +108 -0
  58. python_aidot_cameras-1.0.0/tests/test_answer_pt_kinds.py +138 -0
  59. python_aidot_cameras-1.0.0/tests/test_answer_section_selection.py +184 -0
  60. python_aidot_cameras-1.0.0/tests/test_arrival_timestamps.py +53 -0
  61. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_audio_mux_offline.py +40 -3
  62. python_aidot_cameras-1.0.0/tests/test_auth_error_routing.py +246 -0
  63. python_aidot_cameras-1.0.0/tests/test_auto_alarm.py +69 -0
  64. python_aidot_cameras-1.0.0/tests/test_auto_light_settings.py +150 -0
  65. python_aidot_cameras-1.0.0/tests/test_avio_ctrl_uses_the_session_dseq.py +134 -0
  66. python_aidot_cameras-1.0.0/tests/test_avio_header_single_layout.py +46 -0
  67. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_avio_request.py +84 -4
  68. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_avio_response_parse.py +1 -0
  69. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_avio_response_router.py +6 -2
  70. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_backoff.py +18 -12
  71. python_aidot_cameras-1.0.0/tests/test_battery_cap_spans_sessions.py +105 -0
  72. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_battery_detection.py +32 -40
  73. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_battery_evidence_corroboration.py +22 -11
  74. python_aidot_cameras-1.0.0/tests/test_battery_stale_offer_is_abandoned_early.py +154 -0
  75. python_aidot_cameras-1.0.0/tests/test_battery_wake_settles_before_the_command.py +66 -0
  76. python_aidot_cameras-1.0.0/tests/test_ble_gateway_is_gone.py +59 -0
  77. python_aidot_cameras-1.0.0/tests/test_bridge_state_sentinels.py +84 -0
  78. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_busy_backoff.py +1 -0
  79. python_aidot_cameras-1.0.0/tests/test_camera_closed_session.py +269 -0
  80. python_aidot_cameras-1.0.0/tests/test_camera_properties.py +242 -0
  81. python_aidot_cameras-1.0.0/tests/test_canary_log_names_the_camera.py +40 -0
  82. python_aidot_cameras-1.0.0/tests/test_close_mid_ice_leaves_nothing_pending.py +131 -0
  83. python_aidot_cameras-1.0.0/tests/test_cloud_count.py +158 -0
  84. python_aidot_cameras-1.0.0/tests/test_cloud_error_log_names_the_exception.py +91 -0
  85. python_aidot_cameras-1.0.0/tests/test_cloud_error_severity.py +164 -0
  86. python_aidot_cameras-1.0.0/tests/test_cloud_plan.py +168 -0
  87. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_constants_imports_resolve.py +3 -2
  88. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_control_verdicts.py +75 -15
  89. python_aidot_cameras-1.0.0/tests/test_declared_properties.py +103 -0
  90. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_deferred_hardening.py +15 -26
  91. python_aidot_cameras-1.0.0/tests/test_detection_types.py +98 -0
  92. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_device_cmd_seq_match.py +10 -6
  93. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_device_login_guard.py +41 -3
  94. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_device_user_info_cache.py +4 -2
  95. python_aidot_cameras-1.0.0/tests/test_direct_publish_attaches_negotiated_audio.py +113 -0
  96. python_aidot_cameras-1.0.0/tests/test_direct_ts_keyframe_signal.py +178 -0
  97. python_aidot_cameras-1.0.0/tests/test_direct_ts_serve.py +359 -0
  98. python_aidot_cameras-1.0.0/tests/test_direct_ts_serve_only_for_http.py +55 -0
  99. python_aidot_cameras-1.0.0/tests/test_dormant_camera_cleanup.py +162 -0
  100. python_aidot_cameras-1.0.0/tests/test_drain_is_cancellable.py +86 -0
  101. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_not_ready_burst.py +1 -0
  102. python_aidot_cameras-1.0.0/tests/test_dtls_open_abort_covers_every_exit.py +163 -0
  103. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_pinning.py +3 -1
  104. python_aidot_cameras-1.0.0/tests/test_dtls_recorder_wiring.py +158 -0
  105. python_aidot_cameras-1.0.0/tests/test_dtls_refusal_after_the_echo.py +134 -0
  106. python_aidot_cameras-1.0.0/tests/test_dtls_resolution_ack.py +239 -0
  107. python_aidot_cameras-1.0.0/tests/test_dtls_serve_backoff.py +1081 -0
  108. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_serve_decode_skip.py +28 -5
  109. python_aidot_cameras-1.0.0/tests/test_dtls_serve_ice_wait.py +121 -0
  110. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_serve_open_timeout.py +13 -7
  111. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_skip_signaling_wait.py +9 -4
  112. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_slow_probe.py +27 -16
  113. python_aidot_cameras-1.0.0/tests/test_dtls_stdout_producer.py +168 -0
  114. python_aidot_cameras-1.0.0/tests/test_dtls_tap_states_no_reorder.py +64 -0
  115. python_aidot_cameras-1.0.0/tests/test_dtls_ts_copy_recording.py +347 -0
  116. python_aidot_cameras-1.0.0/tests/test_dtls_video_presence.py +98 -0
  117. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_egress_guard.py +3 -2
  118. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_env_seams.py +12 -3
  119. python_aidot_cameras-1.0.0/tests/test_every_exception_is_exported.py +35 -0
  120. python_aidot_cameras-1.0.0/tests/test_feature_probe_needs_a_live_session.py +139 -0
  121. python_aidot_cameras-1.0.0/tests/test_ffmpeg_rx_sdp_single_template.py +181 -0
  122. python_aidot_cameras-1.0.0/tests/test_ffmpeg_signal_exit_is_not_a_crash.py +64 -0
  123. python_aidot_cameras-1.0.0/tests/test_first_media_abandon_rules.py +133 -0
  124. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_futile_keepalive.py +1 -0
  125. python_aidot_cameras-1.0.0/tests/test_gate_requires_a_decoded_frame.py +105 -0
  126. python_aidot_cameras-1.0.0/tests/test_go2rtc.py +282 -0
  127. python_aidot_cameras-1.0.0/tests/test_go2rtc_cli.py +144 -0
  128. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_h264_decode_rate_limit.py +10 -3
  129. python_aidot_cameras-1.0.0/tests/test_h264_sps.py +168 -0
  130. python_aidot_cameras-1.0.0/tests/test_health_line.py +306 -0
  131. python_aidot_cameras-1.0.0/tests/test_health_line_counts_pictures.py +108 -0
  132. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_highport_nomination.py +16 -9
  133. python_aidot_cameras-1.0.0/tests/test_hls_ts_end_to_end.py +120 -0
  134. python_aidot_cameras-1.0.0/tests/test_hls_ts_wiring.py +319 -0
  135. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_hwaccel_probe.py +67 -45
  136. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_ice_config_cache.py +1 -0
  137. python_aidot_cameras-1.0.0/tests/test_ice_credentials_match_the_app.py +149 -0
  138. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_ice_peer_reflexive.py +21 -17
  139. python_aidot_cameras-1.0.0/tests/test_idle_release_both_loops.py +218 -0
  140. python_aidot_cameras-1.0.0/tests/test_ipc_envelope_single_builder.py +83 -0
  141. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_keepalive_renew.py +10 -7
  142. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_key_restart_sdp.py +5 -0
  143. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_keyframe_prompter.py +19 -9
  144. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_lan_control.py +19 -4
  145. python_aidot_cameras-1.0.0/tests/test_lan_login_accessors.py +85 -0
  146. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_lan_retry_reaches_the_storming_devices.py +52 -29
  147. python_aidot_cameras-1.0.0/tests/test_lan_retry_short_sessions.py +342 -0
  148. python_aidot_cameras-1.0.0/tests/test_lan_retry_silences_upstream_over_ceiling.py +186 -0
  149. python_aidot_cameras-1.0.0/tests/test_lan_retry_stops_on_close.py +460 -0
  150. python_aidot_cameras-1.0.0/tests/test_lan_sweep_only_with_lights.py +71 -0
  151. python_aidot_cameras-1.0.0/tests/test_late_repeats_are_dropped.py +122 -0
  152. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_light_active_color_mode.py +53 -6
  153. python_aidot_cameras-1.0.0/tests/test_live_session_carries_talk.py +109 -0
  154. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_live_stream_param.py +18 -17
  155. python_aidot_cameras-1.0.0/tests/test_live_validate_policy.py +778 -0
  156. python_aidot_cameras-1.0.0/tests/test_live_validate_token_refresh.py +206 -0
  157. python_aidot_cameras-1.0.0/tests/test_live_video_canary.py +91 -0
  158. python_aidot_cameras-1.0.0/tests/test_liveplay_echo_timeout.py +86 -0
  159. python_aidot_cameras-1.0.0/tests/test_local_only_controls.py +74 -0
  160. python_aidot_cameras-1.0.0/tests/test_log_hygiene.py +251 -0
  161. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_logging_caps.py +7 -2
  162. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_login_connect_deadline.py +9 -3
  163. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_login_reconnect_backoff.py +1 -0
  164. python_aidot_cameras-1.0.0/tests/test_loop_break_ends_the_loop.py +69 -0
  165. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_media_counted_only_when_plaintext.py +75 -61
  166. python_aidot_cameras-1.0.0/tests/test_media_path_is_reported.py +111 -0
  167. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_media_socket_rcvbuf.py +22 -12
  168. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_media_wait_floor.py +1 -0
  169. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_motion_poll.py +30 -18
  170. python_aidot_cameras-1.0.0/tests/test_mqtt_client_id_is_exact.py +108 -0
  171. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_mqtt_credential_refetch.py +41 -27
  172. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_mqtt_credential_self_heal.py +7 -3
  173. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_mqtt_password_not_persisted.py +3 -2
  174. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_mqtt_session_reconnect.py +74 -34
  175. python_aidot_cameras-1.0.0/tests/test_mqtt_thread_not_orphaned.py +70 -0
  176. python_aidot_cameras-1.0.0/tests/test_mypy_new_findings.py +77 -0
  177. python_aidot_cameras-1.0.0/tests/test_nack.py +280 -0
  178. python_aidot_cameras-1.0.0/tests/test_nack_cannot_add_load_in_a_burst.py +94 -0
  179. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_narrow_pc_ice.py +2 -0
  180. python_aidot_cameras-1.0.0/tests/test_no_key_material_in_logs.py +244 -0
  181. python_aidot_cameras-1.0.0/tests/test_no_private_notes_on_the_public_surface.py +104 -0
  182. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_no_self_referential_go2rtc.py +13 -6
  183. python_aidot_cameras-1.0.0/tests/test_no_unbounded_hex_dumps.py +74 -0
  184. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_no_undefined_names.py +27 -12
  185. python_aidot_cameras-1.0.0/tests/test_nominates_as_soon_as_the_answer_lands.py +445 -0
  186. python_aidot_cameras-1.0.0/tests/test_off_subnet_candidate.py +81 -0
  187. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_offer_keeps_rtcp_feedback.py +52 -42
  188. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_offline_keepalive_pause.py +2 -6
  189. python_aidot_cameras-1.0.0/tests/test_on_frame_is_an_av_frame.py +73 -0
  190. python_aidot_cameras-1.0.0/tests/test_open_errors_are_aidot_errors.py +121 -0
  191. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_open_fail_logger.py +1 -0
  192. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_open_gate_delay.py +1 -0
  193. python_aidot_cameras-1.0.0/tests/test_peer_id_client_type.py +153 -0
  194. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_peerid_reuse.py +45 -23
  195. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_persistent_mqtt.py +8 -2
  196. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_persistent_mqtt_robustness.py +21 -13
  197. python_aidot_cameras-1.0.0/tests/test_phase_returns_reach_the_caller.py +134 -0
  198. python_aidot_cameras-1.0.0/tests/test_phase_state_is_complete.py +388 -0
  199. python_aidot_cameras-1.0.0/tests/test_plaintext_mqtt_refused.py +204 -0
  200. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_post_merge_hardening.py +13 -55
  201. python_aidot_cameras-1.0.0/tests/test_ptz_probe_reads_what_it_is_told.py +94 -0
  202. python_aidot_cameras-1.0.0/tests/test_public_signature_matches_impl.py +60 -0
  203. python_aidot_cameras-1.0.0/tests/test_publish_target_readiness.py +91 -0
  204. python_aidot_cameras-1.0.0/tests/test_quality_campaign_in_session.py +403 -0
  205. python_aidot_cameras-1.0.0/tests/test_reboot_action.py +68 -0
  206. python_aidot_cameras-1.0.0/tests/test_recent_recordings.py +161 -0
  207. python_aidot_cameras-1.0.0/tests/test_region_allowlist.py +115 -0
  208. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_remb.py +7 -4
  209. python_aidot_cameras-1.0.0/tests/test_remb_goes_out_the_relay_aware_sender.py +94 -0
  210. python_aidot_cameras-1.0.0/tests/test_removed_keepalive_arguments_are_tolerated.py +30 -0
  211. python_aidot_cameras-1.0.0/tests/test_resent_frames_are_dropped.py +115 -0
  212. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_resolution_persists.py +4 -3
  213. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_restart_cycle.py +2 -3
  214. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_retry_policy.py +1 -0
  215. python_aidot_cameras-1.0.0/tests/test_review_lan_retry_and_graces.py +154 -0
  216. python_aidot_cameras-1.0.0/tests/test_rtp_h264.py +125 -0
  217. python_aidot_cameras-1.0.0/tests/test_rtsp_publish.py +2821 -0
  218. python_aidot_cameras-1.0.0/tests/test_rtsp_publish_go2rtc.py +625 -0
  219. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_scripts_importable.py +21 -9
  220. python_aidot_cameras-1.0.0/tests/test_sctp_in_order.py +215 -0
  221. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sctp_init_ack_tsn.py +14 -10
  222. python_aidot_cameras-1.0.0/tests/test_sctp_reassembly.py +108 -0
  223. python_aidot_cameras-1.0.0/tests/test_sctp_sack.py +102 -0
  224. python_aidot_cameras-1.0.0/tests/test_sd_card_presence.py +96 -0
  225. python_aidot_cameras-1.0.0/tests/test_sd_event_decode.py +197 -0
  226. python_aidot_cameras-1.0.0/tests/test_sd_event_probe_payloads.py +141 -0
  227. python_aidot_cameras-1.0.0/tests/test_sd_listing.py +621 -0
  228. python_aidot_cameras-1.0.0/tests/test_sd_playback.py +98 -0
  229. python_aidot_cameras-1.0.0/tests/test_sd_playback_clock.py +225 -0
  230. python_aidot_cameras-1.0.0/tests/test_sd_playback_controls.py +165 -0
  231. python_aidot_cameras-1.0.0/tests/test_sd_playback_dtls.py +577 -0
  232. python_aidot_cameras-1.0.0/tests/test_sd_playback_end.py +118 -0
  233. python_aidot_cameras-1.0.0/tests/test_sd_playback_entry.py +156 -0
  234. python_aidot_cameras-1.0.0/tests/test_sd_playback_media_hold.py +205 -0
  235. python_aidot_cameras-1.0.0/tests/test_sd_playback_open.py +308 -0
  236. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_avio_dispatch.py +3 -7
  237. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_bridge_break_gate.py +14 -6
  238. python_aidot_cameras-1.0.0/tests/test_sdes_connection_mode.py +282 -0
  239. python_aidot_cameras-1.0.0/tests/test_sdes_echo_wait_is_not_dead_time.py +168 -0
  240. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_fast_liveplay.py +12 -4
  241. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_ffmpeg_stderr_log.py +8 -7
  242. python_aidot_cameras-1.0.0/tests/test_sdes_first_media_stall_report.py +512 -0
  243. python_aidot_cameras-1.0.0/tests/test_sdes_ice_teardown.py +110 -0
  244. python_aidot_cameras-1.0.0/tests/test_sdes_idle_release.py +351 -0
  245. python_aidot_cameras-1.0.0/tests/test_sdes_nack_bridge.py +133 -0
  246. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_offer_video_pin.py +18 -6
  247. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_open_cleanup.py +1 -0
  248. python_aidot_cameras-1.0.0/tests/test_sdes_open_yields_the_loop.py +256 -0
  249. python_aidot_cameras-1.0.0/tests/test_sdes_pinned_codec_retry.py +110 -0
  250. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_sctp_abort.py +17 -5
  251. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_serve_audio.py +62 -5
  252. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_serve_cmd.py +88 -6
  253. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_serve_stderr_drain.py +46 -29
  254. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_sprop.py +47 -15
  255. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_talk.py +36 -13
  256. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_teardown_exit_log.py +65 -37
  257. python_aidot_cameras-1.0.0/tests/test_sdes_terminal_ack.py +62 -0
  258. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_terminal_ack_latency.py +1 -0
  259. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdes_watchdog.py +29 -11
  260. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdp_narrowing_properties.py +4 -1
  261. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sdp_payload_type_narrowing.py +10 -5
  262. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_security_hardening.py +10 -5
  263. python_aidot_cameras-1.0.0/tests/test_self_peer_is_an_address_not_an_ip.py +102 -0
  264. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_serializable_login_info.py +17 -9
  265. python_aidot_cameras-1.0.0/tests/test_serve_bound_survives_arrival_stamping.py +86 -0
  266. python_aidot_cameras-1.0.0/tests/test_serve_input_timeout.py +67 -0
  267. python_aidot_cameras-1.0.0/tests/test_serve_loop_releases_on_error.py +370 -0
  268. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_serve_loss_tolerance.py +1 -0
  269. python_aidot_cameras-1.0.0/tests/test_serve_pt_respects_the_pin.py +63 -0
  270. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_serve_relay.py +15 -5
  271. python_aidot_cameras-1.0.0/tests/test_serve_stderr_keeps_the_reason.py +84 -0
  272. python_aidot_cameras-1.0.0/tests/test_session_mode_seq.py +82 -0
  273. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_session_stats.py +18 -8
  274. python_aidot_cameras-1.0.0/tests/test_session_stop_twice.py +112 -0
  275. python_aidot_cameras-1.0.0/tests/test_set_dev_attr_payload.py +69 -0
  276. python_aidot_cameras-1.0.0/tests/test_settings_registry.py +510 -0
  277. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_shared_house_seam.py +27 -9
  278. python_aidot_cameras-1.0.0/tests/test_signalling_is_attributable_to_a_camera.py +173 -0
  279. python_aidot_cameras-1.0.0/tests/test_skip_guard.py +69 -0
  280. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_snapshot_cancellation.py +1 -0
  281. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_speak.py +7 -5
  282. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sprop_capture_gate.py +7 -2
  283. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_sprop_staleness.py +2 -2
  284. python_aidot_cameras-1.0.0/tests/test_sprop_unstable_public.py +32 -0
  285. python_aidot_cameras-1.0.0/tests/test_sprop_write_is_reported_truthfully.py +106 -0
  286. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_srtp_rx_rekey.py +8 -8
  287. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_srtp_tx_key_note.py +6 -3
  288. python_aidot_cameras-1.0.0/tests/test_stable_terminal_id.py +65 -0
  289. python_aidot_cameras-1.0.0/tests/test_stall_nudge_policy.py +51 -0
  290. python_aidot_cameras-1.0.0/tests/test_stall_report_says_what_the_answer_carried.py +295 -0
  291. python_aidot_cameras-1.0.0/tests/test_stall_report_says_whether_the_trigger_was_answered.py +85 -0
  292. python_aidot_cameras-1.0.0/tests/test_stall_report_separates_silence_from_undecryptable.py +100 -0
  293. python_aidot_cameras-1.0.0/tests/test_stall_report_survives_a_caller_giving_up.py +124 -0
  294. python_aidot_cameras-1.0.0/tests/test_stall_reports_reach_the_artifact.py +114 -0
  295. python_aidot_cameras-1.0.0/tests/test_status_and_trace_channels.py +76 -0
  296. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_stream_cap.py +5 -2
  297. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_stream_drain_ownership.py +7 -6
  298. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_stream_idle.py +11 -4
  299. python_aidot_cameras-1.0.0/tests/test_stream_settings.py +193 -0
  300. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_stream_slot_cap.py +8 -0
  301. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_stream_teardown.py +18 -9
  302. python_aidot_cameras-1.0.0/tests/test_stun_attr_single_builder.py +53 -0
  303. python_aidot_cameras-1.0.0/tests/test_swallowed_exception_names.py +60 -0
  304. python_aidot_cameras-1.0.0/tests/test_talk.py +190 -0
  305. python_aidot_cameras-1.0.0/tests/test_talk_reports_a_speaker_that_never_opened.py +179 -0
  306. python_aidot_cameras-1.0.0/tests/test_tap_to_mux_end_to_end.py +96 -0
  307. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_terminal_ack.py +22 -7
  308. python_aidot_cameras-1.0.0/tests/test_tmmbr.py +118 -0
  309. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_token_file_robustness.py +42 -0
  310. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_token_refresh.py +8 -15
  311. python_aidot_cameras-1.0.0/tests/test_transport_failure_reporting.py +227 -0
  312. python_aidot_cameras-1.0.0/tests/test_ts_fanout.py +409 -0
  313. python_aidot_cameras-1.0.0/tests/test_ts_tee.py +537 -0
  314. python_aidot_cameras-1.0.0/tests/test_turn_create_permission.py +413 -0
  315. python_aidot_cameras-1.0.0/tests/test_turn_target_shared.py +97 -0
  316. python_aidot_cameras-1.0.0/tests/test_unbuildable_summary_repeats_at_debug.py +139 -0
  317. python_aidot_cameras-1.0.0/tests/test_unreachable_nominee_is_abandoned_early.py +110 -0
  318. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_upstream_compat.py +223 -141
  319. python_aidot_cameras-1.0.0/tests/test_upstream_seam_adapter.py +114 -0
  320. python_aidot_cameras-1.0.0/tests/test_upstream_secrets_redacted.py +216 -0
  321. python_aidot_cameras-1.0.0/tests/test_validator_shares_one_token.py +229 -0
  322. python_aidot_cameras-1.0.0/tests/test_vendored_aiortc_integrity.py +73 -0
  323. python_aidot_cameras-1.0.0/tests/test_video_presence_needs_a_keyframe.py +48 -0
  324. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_video_profile_log.py +1 -0
  325. python_aidot_cameras-1.0.0/tests/test_video_pts_dts.py +104 -0
  326. python_aidot_cameras-1.0.0/tests/test_video_ts_unwrap.py +89 -0
  327. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_viewer_check_throttle.py +5 -1
  328. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_viewer_presence.py +20 -4
  329. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_viewer_present_push_mode.py +21 -8
  330. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_wait_or_event.py +7 -2
  331. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_wake_gate_camera_evidence.py +14 -10
  332. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_wake_readiness_retry.py +60 -30
  333. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_webrtc_answer_race.py +1 -0
  334. python_aidot_cameras-0.17.3b2/MANIFEST.in +0 -1
  335. python_aidot_cameras-0.17.3b2/PKG-INFO +0 -233
  336. python_aidot_cameras-0.17.3b2/README.md +0 -202
  337. python_aidot_cameras-0.17.3b2/aidot_cameras/_upstream.py +0 -396
  338. python_aidot_cameras-0.17.3b2/aidot_cameras/_vendor/__init__.py +0 -2
  339. python_aidot_cameras-0.17.3b2/aidot_cameras/ble_gateway.py +0 -564
  340. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/client.py +0 -5197
  341. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/constants.py +0 -159
  342. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/controls.py +0 -227
  343. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/models.py +0 -209
  344. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/playback.py +0 -542
  345. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/sdes_open.py +0 -5548
  346. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/tutk.py +0 -266
  347. python_aidot_cameras-0.17.3b2/aidot_cameras/camera/webrtc_open.py +0 -3797
  348. python_aidot_cameras-0.17.3b2/aidot_cameras/exceptions.py +0 -47
  349. python_aidot_cameras-0.17.3b2/aidot_cameras/lan_retry.py +0 -198
  350. python_aidot_cameras-0.17.3b2/python_aidot_cameras.egg-info/PKG-INFO +0 -233
  351. python_aidot_cameras-0.17.3b2/python_aidot_cameras.egg-info/SOURCES.txt +0 -202
  352. python_aidot_cameras-0.17.3b2/tests/test_alarm_event.py +0 -69
  353. python_aidot_cameras-0.17.3b2/tests/test_battery_skip_turn.py +0 -59
  354. python_aidot_cameras-0.17.3b2/tests/test_ble_gateway.py +0 -393
  355. python_aidot_cameras-0.17.3b2/tests/test_bridge_state_sentinels.py +0 -68
  356. python_aidot_cameras-0.17.3b2/tests/test_dormant_camera_cleanup.py +0 -117
  357. python_aidot_cameras-0.17.3b2/tests/test_dtls_stdout_producer.py +0 -77
  358. python_aidot_cameras-0.17.3b2/tests/test_go2rtc.py +0 -123
  359. python_aidot_cameras-0.17.3b2/tests/test_go2rtc_cli.py +0 -55
  360. python_aidot_cameras-0.17.3b2/tests/test_idle_release_both_loops.py +0 -48
  361. python_aidot_cameras-0.17.3b2/tests/test_live_validate_policy.py +0 -336
  362. python_aidot_cameras-0.17.3b2/tests/test_no_key_material_in_logs.py +0 -140
  363. python_aidot_cameras-0.17.3b2/tests/test_playback_tls.py +0 -23
  364. python_aidot_cameras-0.17.3b2/tests/test_sdes_adaptive.py +0 -126
  365. python_aidot_cameras-0.17.3b2/tests/test_sdes_echo_wait_timeout.py +0 -20
  366. python_aidot_cameras-0.17.3b2/tests/test_sdes_idle_release.py +0 -143
  367. python_aidot_cameras-0.17.3b2/tests/test_sdes_terminal_ack.py +0 -79
  368. python_aidot_cameras-0.17.3b2/tests/test_talk.py +0 -105
  369. python_aidot_cameras-0.17.3b2/tests/test_turn_create_permission.py +0 -291
  370. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/__init__.py +0 -0
  371. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/clock.py +0 -0
  372. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/__init__.py +0 -0
  373. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/base.py +0 -0
  374. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/g711.py +0 -0
  375. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/g722.py +0 -0
  376. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/h264.py +0 -0
  377. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/opus.py +0 -0
  378. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/codecs/vpx.py +0 -0
  379. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/contrib/__init__.py +0 -0
  380. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/contrib/media.py +0 -0
  381. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/contrib/signaling.py +0 -0
  382. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/events.py +0 -0
  383. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/exceptions.py +0 -0
  384. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/jitterbuffer.py +0 -0
  385. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/mediastreams.py +0 -0
  386. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rate.py +0 -0
  387. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcconfiguration.py +0 -0
  388. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcdatachannel.py +0 -0
  389. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcrtpparameters.py +0 -0
  390. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcrtpreceiver.py +0 -0
  391. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcrtpsender.py +0 -0
  392. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcrtptransceiver.py +0 -0
  393. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcsctptransport.py +0 -0
  394. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtcsessiondescription.py +0 -0
  395. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/rtp.py +0 -0
  396. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/sdp.py +0 -0
  397. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/stats.py +0 -0
  398. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/_vendor/aiortc/utils.py +0 -0
  399. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/camera/__init__.py +0 -0
  400. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/g711.py +0 -0
  401. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/aidot_cameras/py.typed +0 -0
  402. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/python_aidot_cameras.egg-info/dependency_links.txt +0 -0
  403. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/python_aidot_cameras.egg-info/entry_points.txt +0 -0
  404. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/python_aidot_cameras.egg-info/top_level.txt +0 -0
  405. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/setup.cfg +0 -0
  406. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_answer_sdp_video_pt.py +0 -0
  407. {python_aidot_cameras-0.17.3b2 → python_aidot_cameras-1.0.0}/tests/test_dtls_mux_terminal_write.py +0 -0
@@ -1,6 +1,7 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2024 Aidot Development Team
3
+ Copyright (c) 2024-2026 Aidot Development Team
4
+ Copyright (c) 2026 Chris Brightly
4
5
 
5
6
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
7
  of this software and associated documentation files (the "Software"), to deal
@@ -0,0 +1,3 @@
1
+ # py.typed ships via pyproject.toml's package-data; nothing extra is needed
2
+ # here. The previous line pointed at an `aidot/` directory that does not
3
+ # exist in this distribution.
@@ -0,0 +1,475 @@
1
+ Metadata-Version: 2.4
2
+ Name: python-aidot-cameras
3
+ Version: 1.0.0
4
+ Summary: Control AiDot/Leedarson WiFi lights and cameras (WebRTC streaming, two-way audio, PTZ, controls)
5
+ Author-email: cbrightly <chris.brightly@gmail.com>
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/cbrightly/python-aidot-cameras
8
+ Project-URL: Issue Tracker, https://github.com/cbrightly/python-aidot-cameras/issues
9
+ Classifier: Development Status :: 4 - Beta
10
+ Classifier: Framework :: AsyncIO
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Operating System :: OS Independent
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Topic :: Home Automation
18
+ Classifier: Typing :: Typed
19
+ Requires-Python: >=3.11
20
+ Description-Content-Type: text/markdown
21
+ License-File: LICENSE
22
+ License-File: aidot_cameras/_vendor/aiortc/LICENSE
23
+ Requires-Dist: python-aidot<0.4,>=0.3.56
24
+ Requires-Dist: aiohttp>=3.9
25
+ Requires-Dist: paho-mqtt>=1.6.1
26
+ Requires-Dist: cryptography>=42.0
27
+ Requires-Dist: pycryptodome>=3.20
28
+ Requires-Dist: dacite>=1.8
29
+ Provides-Extra: webrtc
30
+ Requires-Dist: av<20.0.0,>=14.0.0; extra == "webrtc"
31
+ Requires-Dist: aioice<0.12,>=0.10.1; extra == "webrtc"
32
+ Requires-Dist: pylibsrtp>=0.10.0; extra == "webrtc"
33
+ Requires-Dist: pyopenssl>=25.0.0; extra == "webrtc"
34
+ Requires-Dist: cryptography>=44.0.0; extra == "webrtc"
35
+ Requires-Dist: pyee>=13.0.0; extra == "webrtc"
36
+ Requires-Dist: google-crc32c>=1.1; extra == "webrtc"
37
+ Requires-Dist: numpy; extra == "webrtc"
38
+ Requires-Dist: Pillow; extra == "webrtc"
39
+ Provides-Extra: test
40
+ Requires-Dist: python-aidot-cameras[webrtc]; extra == "test"
41
+ Requires-Dist: pytest; extra == "test"
42
+ Requires-Dist: pytest-asyncio; extra == "test"
43
+ Requires-Dist: pytest-timeout; extra == "test"
44
+ Requires-Dist: pytest-xdist; extra == "test"
45
+ Requires-Dist: amqtt; extra == "test"
46
+ Requires-Dist: pyflakes; extra == "test"
47
+ Provides-Extra: codemod
48
+ Requires-Dist: libcst>=1.1; extra == "codemod"
49
+ Dynamic: license-file
50
+
51
+ # python-aidot-cameras
52
+
53
+ [![PyPI version](https://img.shields.io/pypi/v/python-aidot-cameras)](https://pypi.org/project/python-aidot-cameras/)
54
+ [![Python versions](https://img.shields.io/pypi/pyversions/python-aidot-cameras)](https://pypi.org/project/python-aidot-cameras/)
55
+ [![License: MIT](https://img.shields.io/pypi/l/python-aidot-cameras)](https://github.com/cbrightly/python-aidot-cameras/blob/main/LICENSE)
56
+
57
+ Control AiDot / Leedarson WiFi lights **and cameras** from Python: live WebRTC
58
+ video (DTLS-SRTP and SDES-SRTP cameras), snapshots, PTZ, camera controls, cloud
59
+ recordings, the recordings on a camera's own SD card, motion events and two-way
60
+ (push-to-talk) audio. It also ships `aidot-go2rtc`, a command that turns a
61
+ camera into an ordinary RTSP or MPEG-TS stream for go2rtc, Frigate or an NVR.
62
+
63
+ - **Home Assistant users:** install the companion integration,
64
+ [`cbrightly/hass-aidot-cameras`](https://github.com/cbrightly/hass-aidot-cameras),
65
+ instead. It installs this library and manages go2rtc for you; you need nothing
66
+ on this page.
67
+ - **Upstream:** this extends the lights-only
68
+ [`python-aidot`](https://github.com/AiDot-Development-Team/python-AiDot), which
69
+ it installs as a dependency rather than forking. Upstream owns the `aidot`
70
+ import name and handles lights, plugs and switches; everything here lives
71
+ under `aidot_cameras`. GitHub still shows this repository as a fork "N commits
72
+ behind" upstream; that count means nothing, as no upstream file is edited.
73
+ How a new upstream release is taken in: [`docs/UPSTREAM.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/UPSTREAM.md).
74
+
75
+ Requires Python 3.11 or later. The supported cameras are listed in
76
+ [`docs/CAMERAS.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md#supported-cameras):
77
+ the M3 Pro (A000088, DTLS), the L2 battery camera (A001513, SDES) and the PTZ
78
+ (A001064, SDES) are tested live; other `LK.IPC.*` models fall through to the
79
+ generic SDES path.
80
+
81
+ ## Install
82
+
83
+ ```bash
84
+ # lights + camera cloud/control only:
85
+ pip install python-aidot-cameras
86
+ # add live streaming, snapshots and two-way audio (aiortc, av, ...):
87
+ pip install "python-aidot-cameras[webrtc]"
88
+ # the CLI as an isolated tool:
89
+ pipx install "python-aidot-cameras[webrtc]"
90
+ uv tool install "python-aidot-cameras[webrtc]"
91
+ ```
92
+
93
+ Releases carry plain versions (1.0.0 and up); a release before 1.0.0 was a
94
+ release candidate and needed `--pre`. Versions 0.x predate the camera line's
95
+ current form and have known faults fixed since.
96
+
97
+ The latest unreleased code:
98
+ `pip install "python-aidot-cameras[webrtc] @ git+https://github.com/cbrightly/python-aidot-cameras"`.
99
+
100
+ **ffmpeg must be on PATH** (`apt install ffmpeg`, `brew install ffmpeg`); pip
101
+ cannot install it. Recordings, snapshots, the CLI's `-` and `http://` forms and
102
+ any session that negotiates H.265 run through an ffmpeg subprocess. A live
103
+ `rtsp://` push does not (see "Direct publish" below).
104
+
105
+ To see which upstream `python-aidot` an install resolved (it is a range, not a
106
+ pin, and Home Assistant pins its own):
107
+ `python -c "from importlib.metadata import version; print(version('python-aidot'))"`.
108
+ Home Assistant users get both versions in the integration's **Download
109
+ diagnostics** file.
110
+
111
+ ## How it works
112
+
113
+ ```
114
+ AiDot cloud python-aidot-cameras consumers
115
+ ----------- -------------------- ---------
116
+ MQTT signaling <---------------> open a session: offer, answer,
117
+ ICE / TURN ICE, keys (DTLS or SDES)
118
+ |
119
+ camera ====SRTP over the LAN====> decrypt, reorder, count ---(RTSP push)---> go2rtc ---> WebRTC view, rtsp:// URL
120
+ (relay only when there is | (Home Assistant, Frigate,
121
+ no route back to us) +---(MPEG-TS, loopback)--------------------------> HA HLS view, camera.record
122
+ +---(JPEG)----------------------------------------> snapshots
123
+ +---(.ts / .mp4 copy)-----------------------------> recordings
124
+ +<--(PCM, 20 ms)----------------------------------- two-way audio
125
+ ```
126
+
127
+ The cameras have no RTSP, ONVIF or local HTTP endpoint. The cloud brokers the
128
+ WebRTC handshake and never carries the media: on the same network the camera
129
+ sends straight to this library, and only a camera with no route back rides the
130
+ vendor's relay. The library decrypts once and fans the camera's own packets
131
+ out without re-encoding.
132
+
133
+ ## Quick start (Python)
134
+
135
+ Import from `aidot_cameras`, never from `aidot`: upstream's `AidotClient` is
136
+ lights-only, and importing it gives a client with no camera surface and no
137
+ error to say why.
138
+
139
+ ```python
140
+ import aiohttp
141
+ from aidot_cameras.client import AidotClient
142
+ from aidot_cameras.const import CONF_DEVICE_LIST, CONF_NAME
143
+
144
+ async with aiohttp.ClientSession() as http:
145
+ client = AidotClient(http, country_code="US", username=..., password=...)
146
+ await client.async_post_login()
147
+ devices = (await client.async_get_all_device())[CONF_DEVICE_LIST]
148
+ cam = next(d for d in devices if d.get(CONF_NAME) == "Front Door")
149
+ device_client = client.get_device_client(cam) # a CameraDeviceClient
150
+ ```
151
+
152
+ `get_device_client` returns a `CameraDeviceClient` for a camera; the lights
153
+ clients (`DeviceClient`, `LightDeviceClient`) carry none of the camera surface,
154
+ so a `hasattr` probe against the wrong one fails silently.
155
+
156
+ Open a live stream:
157
+
158
+ ```python
159
+ # DTLS cameras (A000088): decoded frames in-process
160
+ session = await device_client.async_open_webrtc_stream(on_frame=cb, timeout=30.0)
161
+
162
+ # any camera: record to a file, or push to an RTSP server such as go2rtc
163
+ session = await device_client.async_open_webrtc_stream(
164
+ output_path="/tmp/live.ts", # or rtsp_push_url="rtsp://127.0.0.1:8554/cam"
165
+ )
166
+ await session.stop()
167
+ ```
168
+
169
+ `on_frame` receives a PyAV `av.VideoFrame` and is **DTLS-only**: SDES cameras
170
+ (A001513, A001064) are decoded out of process, so it never fires for them and
171
+ no error is raised.
172
+
173
+ Two-way (push-to-talk) audio, on both transports:
174
+
175
+ ```python
176
+ session = await device_client.async_open_webrtc_stream(..., talk=True)
177
+ await session.async_start_talk(pcm_provider) # provider() -> 320 B s16le PCM (20 ms @ 8 kHz), or None
178
+ await session.async_stop_talk()
179
+ # or, open + play + tear down in one call:
180
+ await device_client.async_speak(pcm_provider, max_seconds=30)
181
+ ```
182
+
183
+ If you persist the login, serialize `client.serializable_login_info()`, not
184
+ `client.login_info` (which holds a live lock once the persistent MQTT
185
+ connection exists).
186
+
187
+ The full camera API (streaming, recordings, motion polling, talk, SD playback)
188
+ is in [`docs/CAMERAS.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md);
189
+ what is public and stable is in
190
+ [`docs/API-STABILITY.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/API-STABILITY.md).
191
+
192
+ ## Standalone use: `aidot-go2rtc` and an RTSP URL
193
+
194
+ `aidot-go2rtc` does the cloud handshake for one camera per process and hands
195
+ the result out as an RTSP push (into go2rtc or any RTSP server), MPEG-TS on
196
+ stdout, or an HTTP endpoint. Use it for Frigate, a standalone go2rtc, an NVR or
197
+ debugging. **If you run Home Assistant, use the integration instead**: running
198
+ both means two clients competing for a camera that serves a limited number of
199
+ viewers (and holds a slot for about 120 s after one leaves), so the loser gets
200
+ a clean handshake and no media. A second AiDot account with the house shared to
201
+ it does not avoid that; the limit is the device's.
202
+
203
+ **1. Sign in and list your cameras.**
204
+
205
+ ```console
206
+ $ export AIDOT_USERNAME='you@example.com' AIDOT_PASSWORD='...' AIDOT_COUNTRY=US
207
+ $ aidot-go2rtc --list
208
+ 1a2b3c4d... LK.IPC.A000088 DTLS (stdout)
209
+ 5e6f7a8b... LK.IPC.A001064 SDES (rtsp-push)
210
+ ```
211
+
212
+ `--list` also prints a paste-ready go2rtc `streams:` block. A dedicated login
213
+ is recommended for long-running use, so it does not fight Home Assistant or the
214
+ phone app over a rotating refresh token; set `AIDOT_TOKEN_FILE` to cache the
215
+ login across restarts. `aidot-go2rtc --help` lists every option.
216
+
217
+ **2. Add one line per camera to `go2rtc.yaml`.** go2rtc starts the process on
218
+ the first viewer and stops it when the last one leaves, so nothing talks to a
219
+ camera nobody is watching:
220
+
221
+ ```yaml
222
+ streams:
223
+ driveway: exec:aidot-go2rtc 1a2b3c4d... - # DTLS camera
224
+ frontdoor: exec:aidot-go2rtc 5e6f7a8b... {output} # SDES camera (works for DTLS too)
225
+ ```
226
+
227
+ | Output argument | Works on | What you get |
228
+ | --- | --- | --- |
229
+ | `{output}` | any camera | go2rtc fills in its own publish URL. The library publishes into it directly (no ffmpeg): the camera's G.711 A-law plus an in-process AAC track. Quote it in a shell; run by hand, the literal text fails, so give a real `rtsp://` URL there instead. |
230
+ | `-` | DTLS only | MPEG-TS with 48 kHz AAC on stdout. An SDES camera given `-` exits with a message telling you to use `{output}`. |
231
+ | `http://127.0.0.1:8555/cam.ts` | any camera | the process serves MPEG-TS and waits for a consumer to pull. It must keep running to hold the port, so it holds a camera session whether or not anyone watches; prefer the `exec:` forms. |
232
+
233
+ go2rtc must have the same `AIDOT_*` variables in its environment (its shell,
234
+ service unit or container definition). A stream that fails at once with an
235
+ authentication error usually means they are missing.
236
+
237
+ **3. Use the URL** go2rtc serves, and check it first:
238
+
239
+ ```console
240
+ $ ffprobe rtsp://127.0.0.1:8554/driveway
241
+ Stream #0:0: Video: h264 (High), yuv420p, 1280x720, 15 fps
242
+ Stream #0:1: Audio: aac (LC), 48000 Hz, mono
243
+ ```
244
+
245
+ Worth knowing:
246
+
247
+ - **Direct publish** (on by default; `AIDOT_DIRECT_PUBLISH=0` restores ffmpeg)
248
+ publishes an `rtsp://` / `{output}` push from the library itself, for both
249
+ transports and H.264 sessions; a session that negotiates H.265 keeps the
250
+ ffmpeg serve. Design and measurements:
251
+ [`docs/DESIGN-direct-publish.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/DESIGN-direct-publish.md).
252
+ - **Audio.** A push carries the camera's own PCMA (G.711 A-law, 8 kHz) first,
253
+ which WebRTC viewers play untranscoded, and (unless `AIDOT_PUBLISH_AAC=0`)
254
+ an AAC-LC 48 kHz mono track for AAC-only consumers such as Home Assistant's
255
+ HLS player, selected with go2rtc's `?audio=aac`. A camera whose audio is
256
+ mu-law (PCMU) gets no AAC track. Do not add an `ffmpeg:<stream>#audio=aac`
257
+ source in go2rtc: it makes every player crawl
258
+ ([why](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md#an-aac-transcoding-source-makes-every-player-crawl)).
259
+ Only with `AIDOT_DIRECT_PUBLISH=0` does a DTLS push transcode its audio to
260
+ G.711 through ffmpeg.
261
+ - **A stream that starts with no video** and picks it up a few seconds later is
262
+ normal: the mux waits for a keyframe. One that stays audio-only is a camera
263
+ that never sent one; retry the view.
264
+ - **From Python:** `rtsp_push_url=` pushes, `output_path=` records.
265
+ `Go2rtcClient.rtsp_url(name)` builds the URL above, and
266
+ `ensure_stream(name, source)` registers a stream with a running go2rtc
267
+ without editing YAML.
268
+
269
+ ## Camera features
270
+
271
+ Controls are on the camera device client. Writes are confirmed by reading the
272
+ value back where the model offers it, because this firmware acknowledges writes
273
+ it then ignores.
274
+
275
+ ```python
276
+ await device_client.async_set_motion_detection(True)
277
+ await device_client.async_set_night_vision("auto") # auto | on | off
278
+ await device_client.async_set_speaker_volume(50)
279
+ ```
280
+
281
+ ### Reboot
282
+
283
+ `sent = await device_client.async_reboot()` sends the reboot request the AiDot
284
+ app's camera settings page sends. It reports that the request was **sent**, not
285
+ that the camera rebooted (a reboot succeeds by dropping off the network), and
286
+ it refuses when the cloud reports the camera offline. For a few seconds after,
287
+ a viewer gets a session that connects and delivers nothing.
288
+
289
+ ### Sound detection
290
+
291
+ ```python
292
+ flags = await device_client.async_get_sound_detection()
293
+ # {'sound_enable': False, 'all_sound': True, 'glass_Break': False,
294
+ # 'smoke_T3': False, 'smoke_T4': False, 'baby_cry': False}
295
+ await device_client.async_set_sound_detection("glass_Break", True)
296
+ ```
297
+
298
+ The keys come from the camera, so a detector not listed here still works. A
299
+ write is read-modify-write and refuses when there is no current list to echo.
300
+ **`None` means unknown, never "all off"**: a sleeping battery camera or a model
301
+ without the feature returns `None`.
302
+
303
+ ### Motion events
304
+
305
+ Cameras do not push motion to a passive subscriber, so motion is polled from the
306
+ cloud event list:
307
+
308
+ ```python
309
+ await device_client.async_start_motion_polling(callback, interval=30.0)
310
+ await device_client.async_stop_motion_polling()
311
+ ```
312
+
313
+ ### Recordings
314
+
315
+ Whether a camera records to the cloud or to its own SD card is per camera, not
316
+ per model (the device reports it as `IsSupportPlayback`).
317
+
318
+ - **Cloud:** `async_get_cloud_recordings` lists clips, and
319
+ `async_get_event_video_media` resolves a playable HLS URL for one.
320
+ - **SD card:** `async_get_sd_recordings` lists what the card holds and
321
+ `async_open_sd_playback` plays one, on all three tested models. An SDES camera
322
+ serves it like a live stream; a DTLS camera (A000088) records it to a `.ts`
323
+ file.
324
+
325
+ ```python
326
+ listing = await device_client.async_get_sd_recordings(session=live_session, days=7)
327
+ await device_client.async_stop_streaming() # the camera has one media slot
328
+ session = await device_client.async_open_sd_playback(
329
+ listing.records[-1], output_path="/tmp/clip.ts"
330
+ )
331
+ await session.async_sd_seek(20) # also async_sd_pause() / async_sd_resume()
332
+ await session.stop()
333
+ ```
334
+
335
+ A listing never opens a session of its own: it rides the one you pass (or the
336
+ client's current one) and returns `None` when there is none. `answered=False`
337
+ means the camera did not reply, which says nothing about the card; only
338
+ `answered=True` with no records means an empty card. Details, the three
339
+ outcomes and the playback caveats: [`docs/CAMERAS.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md#on-device-sd-card-recordings).
340
+
341
+ ### WiFi, SD card and other reads
342
+
343
+ ```python
344
+ await device_client.async_get_wifi_info() # {'ssid': ..., 'rssi': 63}
345
+ await device_client.async_get_sd_card_info() # {'present': True, 'total': 29838, 'used': 28848, 'raw': [...]}
346
+ out = await device_client.async_query_device_action("getWorkMode")
347
+ ```
348
+
349
+ Only confirmed fields are named: the units of `total` and `used` are
350
+ unconfirmed, so they pass through as the camera reports them, and a fourth
351
+ value that looks like a percentage stays unnamed in `raw`.
352
+ `async_query_device_action` sends a read-only action and returns the camera's
353
+ `out` payload (`getWorkMode`, `getAutoAlarm`, `getRoiHuman`, `getRoiPrivacy`
354
+ and others); `None` means no reply, not "unsupported". **Do not use it for
355
+ actions that change something** unless you know the payload shape:
356
+ `SDcardFormatFunc` is one the cameras accept.
357
+
358
+ ## Local (LAN) control and account ownership
359
+
360
+ Local control over the devices' TCP port 10000 (lights, plugs and this
361
+ package's `CameraLanClient`) is accepted **only for the account that owns the
362
+ devices**. A member of a shared home gets a full device list from the cloud,
363
+ credentials included, and is then refused at the device. If local control never
364
+ engages, check which account you signed in as first: everything still works
365
+ through the cloud. Camera live video does not use this path.
366
+
367
+ The refusal is easy to misread, because the code varies by firmware family:
368
+
369
+ | Model | Ack |
370
+ | --- | --- |
371
+ | `LK.light.A001493` | 400 `not equal abort user id or password` (it is the user id that does not match) |
372
+ | `LK.light.A001497`, `LK.plug.A001535` | 4354 `fail` |
373
+ | `LK.IPC.A000088` | 4352 `fail` |
374
+
375
+ ## Troubleshooting
376
+
377
+ ### Reading the health line
378
+
379
+ Every live session logs one INFO line a minute (`AIDOT_HEALTH_LINE_S`, `0`
380
+ turns it off). A DTLS camera's looks like this:
381
+
382
+ ```
383
+ health 20s: packets=1686 (84.1/s) lost=0 (0.0%) stall=0.0s path=direct viewers=present frames=300 (15.0/s) resent=207 keyframes=7 max_keyframe_gap=44
384
+ ```
385
+
386
+ Each figure covers that period alone:
387
+
388
+ | Field | Meaning |
389
+ | --- | --- |
390
+ | `packets` | RTP packets that arrived, with the rate. SDES cameras also report `bytes`; DTLS cameras report `lost`. |
391
+ | `stall` | Seconds since the last media packet. Rising with `lost=0` means the camera stopped sending, not that the link dropped packets. A DTLS session with no video for `AIDOT_DTLS_VIDEO_GRACE_S` (30 s) is re-opened on its own. |
392
+ | `path` | `direct` (over the LAN) or `relay` (the vendor's TURN relay: a camera with no route back, or on another subnet). |
393
+ | `viewers` | `present`, `absent`, or `unknown` when the consumer cannot be counted. A battery camera nobody watches is released after its idle window. |
394
+ | `frames`, `keyframes`, `max_keyframe_gap`, `resent` | DTLS only: pictures served, keyframes among them, the longest run between keyframes since the session started, and frames the camera sent again (about 40%; every consumer drops the repeats). |
395
+
396
+ So a pasted log says whether the link was lossy, the picture froze, or nobody
397
+ was watching. A report that fails is dropped and never ends the session.
398
+
399
+ ### Other behaviour that is not a fault
400
+
401
+ These are covered in
402
+ [`docs/CAMERAS.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md):
403
+ the A001064 using about a quarter more bandwidth than the AiDot app, a failed
404
+ go2rtc registration that silently downgrades to HLS, a battery camera's first
405
+ open after a long sleep, and the SD playback limits.
406
+
407
+ ## Environment variables
408
+
409
+ The variables below are the ones a user may set, and they are part of the
410
+ public surface. The rest (tuning knobs, each with a measured default) are in
411
+ [`docs/ENVIRONMENT.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/ENVIRONMENT.md);
412
+ they are not part of that surface and may be removed once the behaviour they
413
+ tune has settled.
414
+
415
+ ### Credentials
416
+
417
+ Read by the credential helper ([`aidot_cameras/credentials.py`](https://github.com/cbrightly/python-aidot-cameras/blob/main/aidot_cameras/credentials.py))
418
+ and the CLI; they take priority over a stored credentials file.
419
+
420
+ | Variable | Purpose | Default |
421
+ | --- | --- | --- |
422
+ | `AIDOT_USERNAME` | AiDot account username/email. Used with `AIDOT_PASSWORD`. | (none) |
423
+ | `AIDOT_PASSWORD` | AiDot account password. Used with `AIDOT_USERNAME`. | (none) |
424
+ | `AIDOT_COUNTRY` | Account region/country code. | `US` |
425
+ | `AIDOT_TOKEN_FILE` | JSON file that caches the login across restarts; token rotations are written back to it. Share one file between every process on the account, since a second login invalidates the first's token. | (none) |
426
+ | `AIDOT_INCLUDE_SHARED_HOUSES` | Also list houses this account does not own (the cameras a shared-home member sees). Unset, those houses are skipped. | `0` |
427
+
428
+ ### Streaming
429
+
430
+ | Variable | Purpose | Default |
431
+ | --- | --- | --- |
432
+ | `AIDOT_VIDEO_DECODER` | Force a video decoder instead of measuring one: a decoder name (`h264_v4l2m2m`), or an acceleration method prefixed with `hwaccel:` (`hwaccel:videotoolbox`). The prefix is required: VideoToolbox and VAAPI have no decoder to name. How the decoder is otherwise measured: [`docs/CAMERAS.md`](https://github.com/cbrightly/python-aidot-cameras/blob/main/docs/CAMERAS.md#choosing-a-video-decoder). | (measured) |
433
+ | `AIDOT_DISABLE_HWACCEL` | Keep to software decoding and skip the measurement. | (unset) |
434
+ | `AIDOT_MAX_CONCURRENT_STREAMS` | How many cameras may stream at once. | `3` |
435
+ | `AIDOT_MAX_CONCURRENT_OPENS` | How many stream opens may run at once across all cameras. | `2` |
436
+ | `AIDOT_SDES_CONNECTION_MODE` | Which media path an SDES offer proposes. `auto`: every reachable candidate, LAN preferred, relay as last resort (on the reference fleet six of seven cameras stream direct). `lan`: no relay, except that battery cameras always keep it, as a cloud-woken camera has no other path back. `relay`: EXPERIMENTAL and does not steer in practice (the cameras still dial the host address directly). A per-open `sdes_connection_mode` beats this. The path a session took is `media_stats().media_path` (`direct`/`relay`). | unset (`auto`) |
437
+ | `AIDOT_SDES_VIDEO_PT` | Pin the SDES offer to one video codec. The camera otherwise chooses: an A001064 sends H.264 1280x720 most sessions and H.265 2560x1440 occasionally. `96` pins H.264; `none` leaves the camera its choice. **Do not set `97`**: an H.265-only offer returned no video at all. | `96` (H.264) |
438
+ | `AIDOT_PERSISTENT_MQTT` | Reuse one account-level MQTT connection for commands, attribute fetches and stream-open signaling instead of connecting per operation (cut SDES no-media opens from about 57% to 11-19% in soaks). `0`/`false`/`no`/`off` disables. | on |
439
+ | `AIDOT_DIRECT_PUBLISH` | Publish a live `rtsp://` push into go2rtc from the library itself instead of through ffmpeg, for both transports: no ffmpeg process per stream, packets put back in order, audio PCMA plus an in-process AAC track, attached from the camera's answer. H.264 sessions only (H.265 keeps ffmpeg); recordings, snapshots and `-`/`http://` serves are unchanged. Live-validated on A000088, A001064 and A001513. `0` turns it off. | `1` (on) |
440
+ | `AIDOT_PUBLISH_AAC` | Add an AAC-LC 48 kHz mono track, encoded in-process, after the A-law one on a direct publish, so AAC-only consumers (Home Assistant's HLS player, `camera.record`) have sound; select it with go2rtc's `?audio=aac`. Costs one AAC encode per streaming camera. PCMU cameras get none. `0` turns it off. | `1` (on) |
441
+ | `AIDOT_HLS_DIRECT_TS` | Give each eligible camera a library-muxed MPEG-TS on a loopback listener (`CameraMixin.hls_ts_url()`) with video and AAC on one clock, for Home Assistant's HLS view and recordings to read instead of go2rtc's RTSP (through go2rtc a reader joining a running stream had its sound 0.1-0.75 s late). Needs `AIDOT_DIRECT_PUBLISH` and `AIDOT_PUBLISH_AAC`. Eligible: DTLS cameras, and a mains SDES camera whose media the bridge decrypts (A001064) with its offer pinned to H.264; never a battery camera (its packet loss can keep the TS empty past Home Assistant's open timeout), and never a pulled session. When a camera's SPS changes, readers are disconnected to rebuild their decoder. Each URL carries a per-listener secret as `?auth=<secret>` (a request without it gets 404); for your own tools the listener URL (`http://127.0.0.1:<port>/{name}.ts?auth=<secret>`, `{name}` being `aidot_` plus the first 12 characters of the device id) is written, owner-readable, to `hls-ts-url` in `AIDOT_SPROP_DIR` while it runs. A reader counts as a viewer. `0` turns it off. | `1` (on) |
442
+ | `AIDOT_LOGIN_RETRY_LIMIT` | Consecutive failed LAN logins after which a device is left alone: discovery and the retry loop stop kicking it, and a login something else still asks for (Home Assistant's five-minute light poll) is made quietly, until the device's address changes or a login succeeds. One warning marks the moment. A login the device accepts and closes within `AIDOT_LAN_STABLE_SESSION_S` counts as a failure. Applies to every device; in practice, lights on another subnet. | `6` |
443
+
444
+ `AIDOT_DIRECT_PUBLISH`, `AIDOT_PUBLISH_AAC`, `AIDOT_HLS_DIRECT_TS` and
445
+ `AIDOT_SDES_VIDEO_PT` can also be given to one account client, as
446
+ `CameraClient(..., stream_settings=StreamSettings(...))`. A value set there wins
447
+ for that client's cameras; one left unset is read from the variable, then the
448
+ default. Two clients in one process keep their own.
449
+
450
+ ### Security hardening
451
+
452
+ Defaults keep current behaviour (the firmware's signaling carries no verifiable
453
+ material, so strict modes are off until you pin a value), and the library warns
454
+ when one is left permissive. `AIDOT_ALLOW_PLAINTEXT_MQTT` and
455
+ `AIDOT_EXTRA_REGIONS` are the exceptions: strict by default, loosened when set.
456
+
457
+ | Variable | Purpose | Default |
458
+ | --- | --- | --- |
459
+ | `AIDOT_ALLOW_PLAINTEXT_MQTT` | Accept a non-TLS MQTT broker URL from the cloud (`ws://`, `tcp://`, `mqtt://`, `http://`). The connection carries the account's MQTT password, so by default such a URL is refused: control calls fail with an error in the log and a stream open raises `AidotPlaintextMqttRefused`. A URL with no scheme is treated as `wss://`. Does not affect `AIDOT_MQTT_URL`. | unset (refuse) |
460
+ | `AIDOT_EXTRA_REGIONS` | Comma-separated account regions to accept beyond `us`, `eu` and `jp`; an unknown region is refused with `AidotUnknownRegion`. Each entry must be a hostname label. | unset |
461
+ | `AIDOT_ALLOW_LAN_SERVE` | Silence the warning when decrypted media is served on a non-loopback bind (e.g. `0.0.0.0`), where any LAN host can read it. | unset (warn) |
462
+ | `AIDOT_CRED_KEY_FILE` | Fernet key file for stored credentials; point it outside the config dir. Default credentials path only (ignored with an explicit `creds_path`). | `$XDG_CONFIG_HOME/aidot/.key` (else `~/.config/aidot/.key`) |
463
+ | `AIDOT_DTLS_PINNED_FP` | Pin DTLS cameras' certificate to this `sha-256` fingerprint (case and `:` ignored). Set, any other certificate, or none, fails the handshake. | unset (not independently verified; warns) |
464
+ | `AIDOT_SDES_HOLEPUNCH_HOST` | NAT hole-punch target when the cloud supplies no TURN entry. Unset uses a hardcoded vendor TURN host; empty disables that fallback. | unset (vendor host + warn) |
465
+
466
+ **Without `AIDOT_DTLS_PINNED_FP`, a DTLS camera's (A000088's) certificate is
467
+ not independently verified.** The camera echoes our own fingerprint back, or
468
+ sends an empty one, in which case whatever it presents is accepted with a
469
+ warning; a fingerprint it does send arrives over the same cloud signaling. The
470
+ media is encrypted but not authenticated against something standing in for the
471
+ camera. With a pin, every DTLS open checks the presented certificate and fails
472
+ closed, logging the fingerprint on a mismatch. The pin applies to every DTLS
473
+ camera the process opens, so it suits a one-camera process (the CLI) or
474
+ cameras that share a certificate. SDES cameras key their media through
475
+ signaling and have no certificate to check.