@bharper/atv-js 0.2.6 → 0.3.4
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.
- package/dist/index.d.ts +15 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +89 -9
- package/dist/index.js.map +1 -1
- package/dist/mdns.d.ts.map +1 -1
- package/dist/mdns.js +96 -11
- package/dist/mdns.js.map +1 -1
- package/examples/print-device-json.js +22 -0
- package/package.json +2 -3
- package/pyatv/.codecov.yml +38 -0
- package/pyatv/.github/FUNDING.yml +3 -0
- package/pyatv/.github/ISSUE_TEMPLATE/bug_report.yml +80 -0
- package/pyatv/.github/ISSUE_TEMPLATE/config.yml +1 -0
- package/pyatv/.github/ISSUE_TEMPLATE/feature_request.yml +22 -0
- package/pyatv/.github/ISSUE_TEMPLATE/implementation-proposal.yml +29 -0
- package/pyatv/.github/ISSUE_TEMPLATE/investigation.yml +16 -0
- package/pyatv/.github/ISSUE_TEMPLATE/minor-change.yml +10 -0
- package/pyatv/.github/ISSUE_TEMPLATE/question-or-idea.yml +11 -0
- package/pyatv/.github/dependabot.yml +26 -0
- package/pyatv/.github/workflows/codeql-analysis.yml +71 -0
- package/pyatv/.github/workflows/release.yml +160 -0
- package/pyatv/.github/workflows/tests.yml +104 -0
- package/pyatv/.gitpod.yml +23 -0
- package/pyatv/CHANGES.md +3708 -0
- package/pyatv/CODE_OF_CONDUCT.md +76 -0
- package/pyatv/CONTRIBUTING.md +72 -0
- package/pyatv/CONTRIBUTORS.md +3 -0
- package/pyatv/Dockerfile +15 -0
- package/pyatv/LICENSE.md +9 -0
- package/pyatv/MANIFEST.in +14 -0
- package/pyatv/README.md +111 -0
- package/pyatv/base_versions.txt +13 -0
- package/pyatv/chickn.yaml +75 -0
- package/pyatv/docs/404.html +24 -0
- package/pyatv/docs/CNAME +1 -0
- package/pyatv/docs/Gemfile +31 -0
- package/pyatv/docs/_config.yml +121 -0
- package/pyatv/docs/_includes/api +10 -0
- package/pyatv/docs/_includes/atvremote_scan +32 -0
- package/pyatv/docs/_includes/code +6 -0
- package/pyatv/docs/_includes/issue +14 -0
- package/pyatv/docs/_includes/pypi +5 -0
- package/pyatv/docs/_layouts/template.html +109 -0
- package/pyatv/docs/api/pyatv.conf.html +312 -0
- package/pyatv/docs/api/pyatv.const.html +974 -0
- package/pyatv/docs/api/pyatv.convert.html +106 -0
- package/pyatv/docs/api/pyatv.exceptions.html +489 -0
- package/pyatv/docs/api/pyatv.helpers.html +102 -0
- package/pyatv/docs/api/pyatv.html +120 -0
- package/pyatv/docs/api/pyatv.interface.html +2369 -0
- package/pyatv/docs/api/pyatv.settings.html +484 -0
- package/pyatv/docs/api/pyatv.storage.file_storage.html +102 -0
- package/pyatv/docs/api/pyatv.storage.html +186 -0
- package/pyatv/docs/api/pyatv.storage.memory_storage.html +83 -0
- package/pyatv/docs/assets/css/custom.css +19 -0
- package/pyatv/docs/assets/css/hljs.css +1 -0
- package/pyatv/docs/assets/css/normalize.css +349 -0
- package/pyatv/docs/assets/css/pdoc.css +287 -0
- package/pyatv/docs/assets/css/sanitize.css +566 -0
- package/pyatv/docs/assets/css/style.scss +9 -0
- package/pyatv/docs/assets/img/logo.svg +63 -0
- package/pyatv/docs/assets/js/highlight.9.12.0.min.js +3 -0
- package/pyatv/docs/assets/js/mermaid.8.9.2.min.js +32 -0
- package/pyatv/docs/assets/js/mermaid.min.js.map +1 -0
- package/pyatv/docs/development/apps.md +81 -0
- package/pyatv/docs/development/audio.md +42 -0
- package/pyatv/docs/development/control.md +56 -0
- package/pyatv/docs/development/development.md +15 -0
- package/pyatv/docs/development/device_info.md +36 -0
- package/pyatv/docs/development/examples.md +44 -0
- package/pyatv/docs/development/features.md +70 -0
- package/pyatv/docs/development/keyboard.md +51 -0
- package/pyatv/docs/development/listeners.md +144 -0
- package/pyatv/docs/development/logging.md +55 -0
- package/pyatv/docs/development/metadata.md +115 -0
- package/pyatv/docs/development/power_management.md +53 -0
- package/pyatv/docs/development/scan_pair_and_connect.md +331 -0
- package/pyatv/docs/development/services.md +9 -0
- package/pyatv/docs/development/storage.md +259 -0
- package/pyatv/docs/development/stream.md +241 -0
- package/pyatv/docs/development/testing.md +9 -0
- package/pyatv/docs/documentation/atvlog.md +64 -0
- package/pyatv/docs/documentation/atvproxy.md +244 -0
- package/pyatv/docs/documentation/atvremote.md +639 -0
- package/pyatv/docs/documentation/atvscript.md +275 -0
- package/pyatv/docs/documentation/concepts.md +168 -0
- package/pyatv/docs/documentation/documentation.md +130 -0
- package/pyatv/docs/documentation/getting_started.md +248 -0
- package/pyatv/docs/documentation/protocols.md +1959 -0
- package/pyatv/docs/documentation/supported_features.md +246 -0
- package/pyatv/docs/documentation/tutorial.md +1062 -0
- package/pyatv/docs/documentation/workspace.code-workspace +7 -0
- package/pyatv/docs/favicon.ico +0 -0
- package/pyatv/docs/index.md +109 -0
- package/pyatv/docs/internals/design.md +354 -0
- package/pyatv/docs/internals/documentation.md +84 -0
- package/pyatv/docs/internals/interfaces.md +95 -0
- package/pyatv/docs/internals/internals.md +157 -0
- package/pyatv/docs/internals/submit_pr.md +56 -0
- package/pyatv/docs/internals/testing.md +176 -0
- package/pyatv/docs/internals/tools.md +574 -0
- package/pyatv/docs/pdoc_templates/config.mako +46 -0
- package/pyatv/docs/pdoc_templates/html.mako +454 -0
- package/pyatv/docs/support/acknowledgements.md +87 -0
- package/pyatv/docs/support/faq.md +214 -0
- package/pyatv/docs/support/migration.md +138 -0
- package/pyatv/docs/support/scanning_issues.md +110 -0
- package/pyatv/docs/support/support.md +18 -0
- package/pyatv/docs/support/troubleshooting.md +83 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFadeMessage.proto +13 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFadeMessage_pb2.pyi +37 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFadeResponseMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFadeResponseMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFormatSettingsMessage.proto +5 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/AudioFormatSettingsMessage_pb2.pyi +27 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ClientUpdatesConfigMessage.proto +16 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ClientUpdatesConfigMessage_pb2.pyi +44 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CommandInfo.proto +117 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CommandInfo_pb2.pyi +325 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CommandOptions.proto +36 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CommandOptions_pb2.pyi +115 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/Common.proto +79 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/Common_pb2.pyi +228 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ConfigureConnectionMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ConfigureConnectionMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ContentItem.proto +27 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ContentItemMetadata.proto +213 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ContentItemMetadata_pb2.pyi +630 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ContentItem_pb2.pyi +94 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CryptoPairingMessage.proto +15 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/CryptoPairingMessage_pb2.pyi +46 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/DeviceInfoMessage.proto +69 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/DeviceInfoMessage_pb2.pyi +226 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GenericMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GenericMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetKeyboardSessionMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetKeyboardSessionMessage_pb2.pyi +26 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetRemoteTextInputSessionMessage.proto +10 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetRemoteTextInputSessionMessage_pb2.pyi +26 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetVolumeMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetVolumeMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetVolumeResultMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/GetVolumeResultMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/KeyboardMessage.proto +88 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/KeyboardMessage_pb2.pyi +261 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/LanguageOption.proto +9 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/LanguageOption_pb2.pyi +42 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ModifyOutputContextRequestMessage.proto +23 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ModifyOutputContextRequestMessage_pb2.pyi +86 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NotificationMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NotificationMessage_pb2.pyi +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingClient.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingClient_pb2.pyi +49 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingInfo.proto +24 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingInfo_pb2.pyi +79 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingPlayer.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/NowPlayingPlayer_pb2.pyi +45 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/Origin.proto +17 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/OriginClientPropertiesMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/OriginClientPropertiesMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/Origin_pb2.pyi +63 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueue.proto +15 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueCapabilities.proto +7 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueCapabilities_pb2.pyi +33 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueContext.proto +5 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueContext_pb2.pyi +27 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueRequestMessage.proto +29 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueueRequestMessage_pb2.pyi +87 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlaybackQueue_pb2.pyi +53 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlayerClientPropertiesMessage.proto +13 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlayerClientPropertiesMessage_pb2.pyi +37 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlayerPath.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/PlayerPath_pb2.pyi +39 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ProtocolMessage.proto +171 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/ProtocolMessage_pb2.pyi +377 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterForGameControllerEventsMessage.proto +18 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterForGameControllerEventsMessage_pb2.pyi +54 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterHIDDeviceMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterHIDDeviceMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterHIDDeviceResultMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterHIDDeviceResultMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterVoiceInputDeviceMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterVoiceInputDeviceMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterVoiceInputDeviceResponseMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RegisterVoiceInputDeviceResponseMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoteTextInputMessage.proto +13 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoteTextInputMessage_pb2.pyi +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveClientMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveClientMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveEndpointsMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveEndpointsMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveOutputDevicesMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemoveOutputDevicesMessage_pb2.pyi +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemovePlayerMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/RemovePlayerMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendButtonEventMessage.proto +13 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendButtonEventMessage_pb2.pyi +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendCommandMessage.proto +16 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendCommandMessage_pb2.pyi +43 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendCommandResultMessage.proto +100 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendCommandResultMessage_pb2.pyi +286 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendHIDEventMessage.proto +41 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendHIDEventMessage_pb2.pyi +63 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendPackedVirtualTouchEventMessage.proto +24 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendPackedVirtualTouchEventMessage_pb2.pyi +64 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendVoiceInputMessage.proto +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SendVoiceInputMessage_pb2.pyi +134 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetArtworkMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetArtworkMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetConnectionStateMessage.proto +18 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetConnectionStateMessage_pb2.pyi +54 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetDefaultSupportedCommandsMessage.proto +28 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetDefaultSupportedCommandsMessage_pb2.pyi +74 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetDiscoveryModeMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetDiscoveryModeMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetHiliteModeMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetHiliteModeMessage_pb2.pyi +32 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetNowPlayingClientMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetNowPlayingClientMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetNowPlayingPlayerMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetNowPlayingPlayerMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetRecordingStateMessage.proto +17 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetRecordingStateMessage_pb2.pyi +54 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetStateMessage.proto +27 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetStateMessage_pb2.pyi +72 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetVolumeMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SetVolumeMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SupportedCommands.proto +7 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/SupportedCommands_pb2.pyi +30 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TextInputMessage.proto +23 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TextInputMessage_pb2.pyi +76 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionKey.proto +6 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionKey_pb2.pyi +30 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionMessage.proto +15 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionMessage_pb2.pyi +42 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionPacket.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionPacket_pb2.pyi +41 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionPackets.proto +7 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/TransactionPackets_pb2.pyi +30 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateClientMessage.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateClientMessage_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateContentItemArtworkMessage.proto +14 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateContentItemArtworkMessage_pb2.pyi +41 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateContentItemMessage.proto +14 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateContentItemMessage_pb2.pyi +41 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateEndPointsMessage.proto +25 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateEndPointsMessage_pb2.pyi +74 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateOutputDeviceMessage.proto +88 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdateOutputDeviceMessage_pb2.pyi +277 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdatePlayerPath.proto +12 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/UpdatePlayerPath_pb2.pyi +34 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VirtualTouchDeviceDescriptorMessage.proto +8 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VirtualTouchDeviceDescriptorMessage_pb2.pyi +36 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VoiceInputDeviceDescriptorMessage.proto +8 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VoiceInputDeviceDescriptorMessage_pb2.pyi +35 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeControlAvailabilityMessage.proto +23 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeControlAvailabilityMessage_pb2.pyi +71 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeControlCapabilitiesDidChangeMessage.proto +14 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeControlCapabilitiesDidChangeMessage_pb2.pyi +40 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeDidChangeMessage.proto +13 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/VolumeDidChangeMessage_pb2.pyi +38 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/WakeDeviceMessage.proto +11 -0
- package/pyatv/pyatv/protocols/mrp/protobuf/WakeDeviceMessage_pb2.pyi +26 -0
- package/pyatv/pyatv/py.typed +0 -0
- package/pyatv/pylintrc +49 -0
- package/pyatv/pyproject.toml +74 -0
- package/pyatv/requirements/requirements.txt +14 -0
- package/pyatv/requirements/requirements_docs.txt +2 -0
- package/pyatv/requirements/requirements_test.txt +20 -0
- package/pyatv/scripts/build_docs.sh +17 -0
- package/pyatv/scripts/setup_dev_env.sh +83 -0
- package/pyatv/setup.cfg +14 -0
- package/pyatv/tests/data/README +23 -0
- package/pyatv/tests/data/audio_10_frames.wav +0 -0
- package/pyatv/tests/data/audio_1_packet_metadata.wav +0 -0
- package/pyatv/tests/data/audio_3_packets.wav +0 -0
- package/pyatv/tests/data/only_metadata.wav +0 -0
- package/pyatv/tests/data/only_title.wav +0 -0
- package/pyatv/tests/data/static_3sec.ogg +0 -0
- package/pyatv/tests/data/testfile.txt +1 -0
- package/pyatv/tests/support/pyatv.code-workspace +14 -0
- package/src/index.ts +122 -8
- package/src/mdns.ts +64 -11
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: template
|
|
3
|
+
title: FAQ
|
|
4
|
+
permalink: /support/faq/
|
|
5
|
+
link_group: support
|
|
6
|
+
---
|
|
7
|
+
# Table of Contents
|
|
8
|
+
{:.no_toc}
|
|
9
|
+
* TOC
|
|
10
|
+
{:toc}
|
|
11
|
+
|
|
12
|
+
# General Questions
|
|
13
|
+
|
|
14
|
+
## My device is not found when scanning?
|
|
15
|
+
|
|
16
|
+
See [Troubleshooting](../troubleshooting/) for some hints on locating the issue.
|
|
17
|
+
|
|
18
|
+
## My Apple TV turns on every time I send a command with atvremote (it turns on my TV, receiver, etc). How do I disable that?
|
|
19
|
+
|
|
20
|
+
You can't. The device will turn itself on whenever a request is made to it
|
|
21
|
+
(and of course `atvremote` does that). It is how Apple has designed it. The only
|
|
22
|
+
thing you can do is to disable CEC so that your other devices doesn't wake up too.
|
|
23
|
+
That's about it.
|
|
24
|
+
|
|
25
|
+
## Is it possible to "see" if a device is turned on before sending a command?
|
|
26
|
+
|
|
27
|
+
"Yes". Since version 0.7.0 it is possible to see (when scanning) if a device
|
|
28
|
+
is in deep sleep mode. A device can however be asleep (appear off) without being
|
|
29
|
+
in deep sleep, so it's not fully reliable. This is still also considered an
|
|
30
|
+
experimental feature.
|
|
31
|
+
|
|
32
|
+
## Why is all or some metadata missing when I am playing some media on my device?
|
|
33
|
+
|
|
34
|
+
Sometimes the Apple TV does not provide any metadata and in those cases there
|
|
35
|
+
is no metadata available. Unfortunately, there is nothing that can be done about
|
|
36
|
+
this. If you, however, can see for example a title or artwork in the
|
|
37
|
+
*Remote app* on your iPhone or iPad, then something is likely wrong. In this
|
|
38
|
+
case, you should write a bug report.
|
|
39
|
+
|
|
40
|
+
## Streaming with AirPlay does not work. It says "This AirPlay connection requires iOS 7.1 or later, OS X 10.10 or later, or iTunes 11.2 or later." on the screen. What's wrong?
|
|
41
|
+
|
|
42
|
+
The device authentication process has now been reversed engineered and implemented
|
|
43
|
+
in pyatv. In order to get rid of this message, you must perform AirPlay pairing with
|
|
44
|
+
the device and use the obtained credentials with playing media. See
|
|
45
|
+
[pairing with atvremote](../..//documentation/atvremote).
|
|
46
|
+
|
|
47
|
+
## When I scan, other devices like AirPlay speakers and iTunes libraries show up. Why is that?
|
|
48
|
+
|
|
49
|
+
~~Apple has reused several protocols across different products. AirPlay is AirPlay and
|
|
50
|
+
there's no practical difference if it's on a speaker or an Apple TV: it's the same
|
|
51
|
+
thing. Because of this, they might show up in the scan results. In the future some
|
|
52
|
+
devices might be filtered (like pure AirPlay devices, since you can't connect to them
|
|
53
|
+
anyway), but for now they are there.~~
|
|
54
|
+
|
|
55
|
+
This is no longer the case. From pyatv 0.5.0, pure AirPlay devices are no longer included in the scan result.
|
|
56
|
+
|
|
57
|
+
## Is there a synchronous version of the library?
|
|
58
|
+
|
|
59
|
+
No, the library is implemented with asyncio, introduced in python 3.4. A plain
|
|
60
|
+
synchronous library is currently out of scope and not a priority.
|
|
61
|
+
|
|
62
|
+
## Unicast scanning does not work if my device is on a different subnet (NonLocalSubnetError), why?
|
|
63
|
+
|
|
64
|
+
To obtain the information pyatv needs to connect to a device, Zeroconf is used
|
|
65
|
+
for "scanning". Zeroconf is designed to only work within the local network. If a
|
|
66
|
+
request is received from a host on a different subnet it will be silently dropped. This
|
|
67
|
+
is the reason why it is not possible to use unicast scanning between subnets and
|
|
68
|
+
it's not possible to work around this.
|
|
69
|
+
|
|
70
|
+
If you need to keep the network separation, you can still rely on regular scanning
|
|
71
|
+
and configure an mDNS repeater (try "mdns repeater" on your favorite search engine).
|
|
72
|
+
|
|
73
|
+
## It is really slow to send commands to the device with atvremote. It takes several seconds, is pyatv really this slow?
|
|
74
|
+
|
|
75
|
+
From version 0.8.x, scanning for a particular device has been optimized. Normally a scan
|
|
76
|
+
is performed for a specific time and filtering done after that. This has been changed
|
|
77
|
+
so that scanning is aborted once the requested device has been found, making the discovery
|
|
78
|
+
phase a lot shorter.
|
|
79
|
+
|
|
80
|
+
The information below reflects all versions prior to 0.8.x (although everything except
|
|
81
|
+
for bullet two applies to 0.8.x as well):
|
|
82
|
+
|
|
83
|
+
It is a common misconception that pyatv is slow because atvremote takes its time.
|
|
84
|
+
The fact is this: *every* time you run atvremote, this happens:
|
|
85
|
+
|
|
86
|
+
1. pyatv and its dependencies are loaded into memory
|
|
87
|
+
2. A scan is performed with a default timeout of three seconds
|
|
88
|
+
3. A (TCP) connection is established to the device
|
|
89
|
+
4. Authentication is performed and encryption enabled
|
|
90
|
+
5. Command is executed
|
|
91
|
+
6. Connection is torn down
|
|
92
|
+
|
|
93
|
+
Once a connection has been established and authentication performed, issuing commands
|
|
94
|
+
are more or less instant. But since atvremote exits after executing a command, everything
|
|
95
|
+
must be done from the beginning again for the next command. This behavior is by definition
|
|
96
|
+
slow.
|
|
97
|
+
|
|
98
|
+
To get instantaneous feedback, the connection must remain active and commands sent by
|
|
99
|
+
reusing the connection. This can be done in many ways, e.g. by implementing a daemon
|
|
100
|
+
that maintains the connection in the background and receives commands via some interface
|
|
101
|
+
(maybe REST). Currently, pyatv does not ship with such a tool since it's first and foremost
|
|
102
|
+
a library. You will have to implement a solution that fits your needs.
|
|
103
|
+
|
|
104
|
+
A small tip is to use unicast scanning to speed up the process (to at least make the situation
|
|
105
|
+
better):
|
|
106
|
+
|
|
107
|
+
```shell
|
|
108
|
+
$ atvremote -s 10.0.0.3 stop
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
## I get an error about "ed25519 is not supported", how can I fix that?
|
|
112
|
+
|
|
113
|
+
For cryptography, pyatv relies on the `cryptography` package. This package
|
|
114
|
+
wraps crypto routines in OpenSSL, so if a given routine is missing then that
|
|
115
|
+
crypto routine simply won't work.
|
|
116
|
+
|
|
117
|
+
For MRP this means that you need to have decently new version of OpenSSL with
|
|
118
|
+
support for ed25519 compiled in. Otherwise you get this error:
|
|
119
|
+
|
|
120
|
+
```raw
|
|
121
|
+
pyatv.exceptions.PairingError: ed25519 is not supported by this version of OpenSSL.
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
It is still a bit unclear which version of OpenSsl that added support for ed25519,
|
|
125
|
+
so grab the latest one. Please refer to your operating system community on
|
|
126
|
+
how to upgrade.
|
|
127
|
+
|
|
128
|
+
## My Apple TV crashed/lost network connection/... and the connection in pyatv just hangs, why?
|
|
129
|
+
|
|
130
|
+
To discover dangling connections, i.e. when the other device disappears without
|
|
131
|
+
properly closing the connection, TCP keepalives are used. The support for this
|
|
132
|
+
in python varies on different platforms. It might be the case that your operating
|
|
133
|
+
system or version of python does not support TCP keep-alive properly, in which
|
|
134
|
+
case this is a problem pyatv currently does not solve.
|
|
135
|
+
|
|
136
|
+
A log point will indicate if configuration of keep-alive succeeded:
|
|
137
|
+
|
|
138
|
+
```raw
|
|
139
|
+
2020-06-10 22:31:28 INFO: Configured keep-alive on <asyncio.TransportSocket fd=8, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('10.0.10.254', 60849), raddr=('10.0.10.81', 49153)> (Linux)
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
Or a warning if not supported:
|
|
143
|
+
|
|
144
|
+
```raw
|
|
145
|
+
2020-06-10 22:32:28 WARNING: Keep-alive not supported: System does not support keep-alive
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
Most versions of macOS and Linux should work with no problems. For Windows, you need at
|
|
149
|
+
least Windows 10 build 1709.
|
|
150
|
+
|
|
151
|
+
pyatv.
|
|
152
|
+
|
|
153
|
+
# When using pyatv on a Raspberry pi, e.g running atvremote, I get "Illegal instruction". How do I fix that?
|
|
154
|
+
|
|
155
|
+
It seems like the wheels (prebuilt binaries) for miniaudio does not work properly. You can fix this
|
|
156
|
+
by manually uninstalling miniaudio and building it from source:
|
|
157
|
+
|
|
158
|
+
```shell
|
|
159
|
+
pip uninstall miniaudio
|
|
160
|
+
pip install --no-binary :all: miniaudio
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
You might have to install some additional system packages (like a C-compiler) for this.
|
|
164
|
+
|
|
165
|
+
Reported in this issue: {% include issue no="1249" %}
|
|
166
|
+
|
|
167
|
+
# Known Issues
|
|
168
|
+
|
|
169
|
+
Some apps behave in unexpected ways that are out of control of this library (including general things in tvOS), i.e. nothing can be done in pyatv to circumvent these behaviors. This sections lists the known ones. If you are experiencing issues with an app, feel free to add it here (write an issue, make a PR or just press *Edit this page* at the bottom of this page).
|
|
170
|
+
|
|
171
|
+
## Idle state during previews
|
|
172
|
+
|
|
173
|
+
The deveice generally moves to {% include api i="const.DeviceState.Idle" %} when playing trailers or "what's next"
|
|
174
|
+
sequences. For now, there's no known solution to circumvent this. This might change in the
|
|
175
|
+
future, so a solution should be re-evaluate every now and then.
|
|
176
|
+
|
|
177
|
+
Reported in these issues: {% include issue no="994" %}
|
|
178
|
+
|
|
179
|
+
## Power state is not updated when using external speaker (e.g. HomePod)
|
|
180
|
+
|
|
181
|
+
The power state is derived from the number of connected output devices (as there seems to be no
|
|
182
|
+
"real" power state). This however fails when using an external spekar for audio, e.g. a HomePod,
|
|
183
|
+
as the connection seems to remain active even when putting the Apple TV to sleep. So it is not
|
|
184
|
+
possible to detect if a device is sleeping or nog in these cases. No solution or workaround is
|
|
185
|
+
known so far.
|
|
186
|
+
|
|
187
|
+
Reported in these issues: {% include issue no="958" %}
|
|
188
|
+
|
|
189
|
+
## Netflix (com.netflix.Netflix)
|
|
190
|
+
|
|
191
|
+
* Previews in the main menu yields play status updates (usually with what was played most recently,
|
|
192
|
+
not content of the preview). A workaround is to disable these previews, see
|
|
193
|
+
[this](https://help.netflix.com/sv/node/2102) page.
|
|
194
|
+
* During episode intros and "next episode" screens the device goes to idle state.
|
|
195
|
+
|
|
196
|
+
## com.cellcom.cellcomtvappleos
|
|
197
|
+
|
|
198
|
+
Does not seem to report any state. This app likely implements its own media player, bypassing
|
|
199
|
+
the metadata management used by MRP meaning that no information is available when this app is used.
|
|
200
|
+
|
|
201
|
+
Link to app in App Store: https://apps.apple.com/il/app/%D7%A1%D7%9C%D7%A7%D7%95%D7%9D-tv/id1159313682
|
|
202
|
+
|
|
203
|
+
Reported in these issues: {% include issue no="1160" %}
|
|
204
|
+
|
|
205
|
+
## playbackRate issue
|
|
206
|
+
|
|
207
|
+
Some apps incorrectly set the metadata item "playbackRate" as 0.0 instead of 1.0 which causes
|
|
208
|
+
pyatv to report the media as paused at all times. A workaround for this issue has been pushed at
|
|
209
|
+
{% include issue no="673" %}, seeking, fast-forwarding or rewinding will still return a "paused" state.
|
|
210
|
+
|
|
211
|
+
Apps known to cause this issue are listed below
|
|
212
|
+
|
|
213
|
+
* Amazon Prime Video (com.amazon.aiv.AIVApp)
|
|
214
|
+
* BBC iPlayer (uk.co.bbc.iplayer)
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: template
|
|
3
|
+
title: Migration
|
|
4
|
+
permalink: /support/migration/
|
|
5
|
+
link_group: support
|
|
6
|
+
---
|
|
7
|
+
# Table of Contents
|
|
8
|
+
{:.no_toc}
|
|
9
|
+
* TOC
|
|
10
|
+
{:toc}
|
|
11
|
+
|
|
12
|
+
# Migration
|
|
13
|
+
|
|
14
|
+
This page contains details on how to migrate between different versions
|
|
15
|
+
of pyatv. Beware that these guides are written according to "best effort"
|
|
16
|
+
and might be incomplete or missing some details. If you find something
|
|
17
|
+
to be unclear, please help out by writing an issue or creating a pull
|
|
18
|
+
request
|
|
19
|
+
|
|
20
|
+
# From 0.9.0-0.9.7
|
|
21
|
+
|
|
22
|
+
## General Changes
|
|
23
|
+
|
|
24
|
+
* Each service now has {% include api i="interface.BaseService.enabled" %}, indicating if pyatv
|
|
25
|
+
should connect to the service or not. Generally this is of little importance, but it must be
|
|
26
|
+
verified before initiaing pairing. Pairing should never be initiated for disabled services.
|
|
27
|
+
|
|
28
|
+
## Deprecations
|
|
29
|
+
|
|
30
|
+
None
|
|
31
|
+
|
|
32
|
+
# From 0.8.2-0.9.0
|
|
33
|
+
|
|
34
|
+
## General Changes
|
|
35
|
+
|
|
36
|
+
* To restore support with tvOS 15, make sure to provide AirPlay credentials. Credentials obtained with earlier versions of pyatv are incompatible (pair again).
|
|
37
|
+
* The `password` property previously present in `conf.RaopService` is now part of `interface.BaseService` instead.
|
|
38
|
+
* Make sure to verify {% include api i="interface.BaseService.pairing" %} before calling {% include api i="pyatv.pair" %} (in case new credentials are needed).
|
|
39
|
+
* Check {% include api i="interface.BaseService.requires_password" %} if a password needs to be provided
|
|
40
|
+
* At least version 3.17.3 of {% include pypi package="protobuf" %} is now required.
|
|
41
|
+
* {% include pypi package="mediafile" %} replaced {% include pypi package="audio-metadata" %} as a dependency
|
|
42
|
+
|
|
43
|
+
## Deprecations
|
|
44
|
+
|
|
45
|
+
* Service specific configurations, e.g. {% include api i="conf.MrpService" %}, have been replaced by {% include api i="conf.ManualService" %}. Scheduled for removal in 1.0.0.
|
|
46
|
+
* {% include api i="interface.RemoteControl.volume_up" %} and {% include api i="interface.RemoteControl.volume_down" %} are now replaced by {% include api i="interface.Audio.volume_up" %} and {% include api i="interface.Audio.volume_up" %}. Scheduled for removal in 1.0.0.
|
|
47
|
+
|
|
48
|
+
# From 0.7.1-... to 0.8.0
|
|
49
|
+
|
|
50
|
+
## General Changes
|
|
51
|
+
|
|
52
|
+
* The push updater interface is now considered a feature and availability
|
|
53
|
+
(via {% include api i="interface.Features.get_feature" %} and
|
|
54
|
+
{% include api i="const.FeatureName.PushUpdates" %}) should now be performed
|
|
55
|
+
before using it.
|
|
56
|
+
* {% include pypi package="audio-metadata" %}, {% include pypi package="bitarray" %}
|
|
57
|
+
and {% include pypi package="miniaudio" %} are new dependencies in this
|
|
58
|
+
release (used by RAOP).
|
|
59
|
+
* At least version 3.14 of {% include pypi package="protobuf" %} is now required.
|
|
60
|
+
|
|
61
|
+
## Deprecations
|
|
62
|
+
|
|
63
|
+
* Passing `protocol` to {% include api i="pyatv.connect" %} is no longer
|
|
64
|
+
needed and its value will be ignored. Scheduled for removal in version 1.0.0.
|
|
65
|
+
|
|
66
|
+
# From 0.7.0 to 0.7.1
|
|
67
|
+
|
|
68
|
+
## General Changes
|
|
69
|
+
|
|
70
|
+
* Unicast scanning (i.e. passing `hosts` to {% include api i="pyatv.scan" %}) will
|
|
71
|
+
not verify if hosts are on the same network anymore (`NonLocalSubnetError` will
|
|
72
|
+
not be thrown). Requests will just time out. See {% include issue no="775" %}
|
|
73
|
+
for more details.
|
|
74
|
+
|
|
75
|
+
## Deprecations
|
|
76
|
+
|
|
77
|
+
* `NonLocalSubnetError` is never thrown and shall not be checked for. It
|
|
78
|
+
will be removed in 0.9.0.
|
|
79
|
+
|
|
80
|
+
# From 0.6.0 to 0.7.0
|
|
81
|
+
|
|
82
|
+
## General Changes
|
|
83
|
+
|
|
84
|
+
* No library changes
|
|
85
|
+
* MRP arguments to atvproxy has been simplified (only credentials and IP to
|
|
86
|
+
Apple TV must now be provided)
|
|
87
|
+
|
|
88
|
+
## Deprecations
|
|
89
|
+
|
|
90
|
+
* None
|
|
91
|
+
|
|
92
|
+
# From 0.5.0 to 0.6.0
|
|
93
|
+
|
|
94
|
+
## General Changes
|
|
95
|
+
|
|
96
|
+
* {% include api i="interface.AppleTV.close" %} has been changed to a
|
|
97
|
+
regular function instead of a coroutine.
|
|
98
|
+
* All listeners are now stored as weak references
|
|
99
|
+
|
|
100
|
+
# From 0.4.0 to 0.5.0
|
|
101
|
+
|
|
102
|
+
## General Changes
|
|
103
|
+
|
|
104
|
+
* None
|
|
105
|
+
|
|
106
|
+
## Deprecations
|
|
107
|
+
|
|
108
|
+
* Python 3.6 or later is now required
|
|
109
|
+
* `suspend` and `wakeup` in {% include api i="interface.RemoteControl" %}
|
|
110
|
+
have been deprecated. Use {% include api i="interface.Power.turn_on" %}
|
|
111
|
+
and {% include api i="interface.Power.turn_off" %} instead.
|
|
112
|
+
* {% include api i="helpers.auto_connect" %} is now a coroutine. The
|
|
113
|
+
[example](https://github.com/postlund/pyatv/blob/master/examples/auto_connect.py)
|
|
114
|
+
has been updated.
|
|
115
|
+
|
|
116
|
+
# From 0.3.x to 0.4.0
|
|
117
|
+
|
|
118
|
+
## General Changes
|
|
119
|
+
|
|
120
|
+
* Device configuration has moved from `AppleTVDevice` to {% include api i="conf.AppleTV" %}
|
|
121
|
+
* `pyatv.connect_to_apple_tv` has been renamed to {% include api i="pyatv.connect" %}
|
|
122
|
+
* `pyatv.scan_for_apple_tvs` has been renamed to {% include api i="pyatv.scan" %}
|
|
123
|
+
* Pairing has been made generic and is done via {% include api i="pyatv.pair" %}
|
|
124
|
+
* Constants, e.g. media type, has been changed into enums
|
|
125
|
+
* `play_state` has been renamed to `device_state`
|
|
126
|
+
* AirPlay interface has been renamed from `AppleTV.airplay` to
|
|
127
|
+
{% include api i="interface.AppleTV.stream" %}
|
|
128
|
+
|
|
129
|
+
## Deprecations
|
|
130
|
+
|
|
131
|
+
* Arguments `abort_on_found` and `only_home_sharing` have been removed from
|
|
132
|
+
{% include api i="pyatv.scan" %}
|
|
133
|
+
* The `Metadata.artwork_url` method has been deprecated and has no
|
|
134
|
+
replacement
|
|
135
|
+
* All methods in the AirPlay interface has been deprecated in favor
|
|
136
|
+
of the generic pairing interface (except for `play_url`)
|
|
137
|
+
* `pyatv.pair_with_apple_tv` has been replaced by {% include api i="pyatv.pair" %}
|
|
138
|
+
which can pair all protocols
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: template
|
|
3
|
+
title: Scanning Issues
|
|
4
|
+
permalink: /support/scanning_issues/
|
|
5
|
+
link_group: support
|
|
6
|
+
---
|
|
7
|
+
# Table of Contents
|
|
8
|
+
{:.no_toc}
|
|
9
|
+
* TOC
|
|
10
|
+
{:toc}
|
|
11
|
+
|
|
12
|
+
# Scanning Issues
|
|
13
|
+
|
|
14
|
+
Scanning for devices relies on the [Zeroconf](https://en.m.wikipedia.org/wiki/Zero-configuration_networking)
|
|
15
|
+
technology stack. Simplified (and technically) it means that zeroconf devices acts
|
|
16
|
+
as DNS servers and listens to requests on a specific multicast address (also using
|
|
17
|
+
port 5353 instead of regular 53). When someone wants to find devices supporting a
|
|
18
|
+
particular service, it sends a DNS request to the multicast address (on port 5353)
|
|
19
|
+
and await response from other devices. This is an *extremely* simplified view of
|
|
20
|
+
what is going on.
|
|
21
|
+
|
|
22
|
+
There are a number of sources of errors to consider:
|
|
23
|
+
|
|
24
|
+
* Firewalls or routers block multicast traffic
|
|
25
|
+
* Timing issues: responses not received in time
|
|
26
|
+
* Responses filtered by kernel (or somewhere else), not received in application
|
|
27
|
+
|
|
28
|
+
The latter two seems to be most common. Lets break them down.
|
|
29
|
+
|
|
30
|
+
# Timing issues
|
|
31
|
+
|
|
32
|
+
Timing issues can happen because pyatv only scans for a small period of time. By
|
|
33
|
+
saying "scan", we actually mean sending out requests and waiting for responses. The
|
|
34
|
+
wait time should be long enough to receive all responses but short enough to not be
|
|
35
|
+
annoying to the user. Waiting five minutes for a scan to finish *is* annoying. By
|
|
36
|
+
default, pyatv scans for 3 seconds (with `atvremote`).
|
|
37
|
+
|
|
38
|
+
Not receiving responses within the time frame obviously is problematic. To make the
|
|
39
|
+
matter even more complex: pyatv relies upon several services. One for `MRP`,
|
|
40
|
+
one for AirPlay and so on. They are requested *independently* of each other. This
|
|
41
|
+
means that it is possible to get a response for AirPlay but miss `MRP` because of
|
|
42
|
+
timing issues (or other issues as well). You might see this happen sometimes when
|
|
43
|
+
scanning, that one or more service is missing. This is the reason why that happens.
|
|
44
|
+
|
|
45
|
+
# Response filtering
|
|
46
|
+
|
|
47
|
+
A behavior that has been observed is that the response is indeed received by the host
|
|
48
|
+
(as seen with Wireshark), but it is never forwarded to the python process so `zeroconf`
|
|
49
|
+
never receives it. Some filtering happens at some point for some reason. It is still
|
|
50
|
+
unclear if this is a bug in python or not and should be investigated further.
|
|
51
|
+
|
|
52
|
+
# Working around issues
|
|
53
|
+
|
|
54
|
+
Issues with scanning has always plauged pyatv and it still does. To mitigate the
|
|
55
|
+
problems, support for "unicast scanning" has been added. It is meant as a compliment
|
|
56
|
+
to regular scanning, as it cannot replace that.
|
|
57
|
+
|
|
58
|
+
Unicast scanning (which is an expression used here, it is not a commonly accepted term)
|
|
59
|
+
works in the same way as regular multicast but the request is sent to specific hosts instead.
|
|
60
|
+
You basically say: "scan *these* IP-addresses". This seems to work more relibly and it also
|
|
61
|
+
comes with some other advantages:
|
|
62
|
+
|
|
63
|
+
* It is fast because we know exactly which answers to wait for
|
|
64
|
+
* All services can be obtained with *one* request, so no timing issues
|
|
65
|
+
* All data pyatv requires, like unique identifiers, are present so it is more reliable than manual configuration
|
|
66
|
+
|
|
67
|
+
Support for unicast scanning has been added via the `--scan-hosts` flag in `atvremote`.
|
|
68
|
+
|
|
69
|
+
# Troubleshooting further
|
|
70
|
+
|
|
71
|
+
If pyatv doesn't find your devices, you can try other Zeroconf tools to see if it is
|
|
72
|
+
a general issue or not.
|
|
73
|
+
|
|
74
|
+
For Linux:
|
|
75
|
+
|
|
76
|
+
$ avahi-browse --all
|
|
77
|
+
|
|
78
|
+
For macOS:
|
|
79
|
+
|
|
80
|
+
$ dns-sd -B _appletv-v2._tcp.
|
|
81
|
+
OR
|
|
82
|
+
$ dns-sd -G -B _touch-able._tcp.
|
|
83
|
+
OR
|
|
84
|
+
$ dns-sd -G -B _mediaremotetv._tcp.
|
|
85
|
+
|
|
86
|
+
If you get an error such as "command not found", you do do not have avahi
|
|
87
|
+
installed. You will have to consult your distributions support channels
|
|
88
|
+
(e.g. forum) for help on this.
|
|
89
|
+
|
|
90
|
+
Here are some other possible sources of problems:
|
|
91
|
+
|
|
92
|
+
- Bonjour/Zeroconf requires you to be on the same network as the devices
|
|
93
|
+
you are looking for. This means that you cannot scan for devices from
|
|
94
|
+
inside of a container or virtual machine, unless they are using a bridged
|
|
95
|
+
network interface.
|
|
96
|
+
- If you are running a Mac or using an iPhone, try enabling AirPlay mirroring
|
|
97
|
+
or use the Remote app. Unless you can get that to work, it is highly
|
|
98
|
+
unlikely that pyatv will work either.
|
|
99
|
+
- If you can see your Apple TV on your iPhone, you can try to install an app
|
|
100
|
+
suitable for Bonjour discovery. Just search for *bonjour* in the App store
|
|
101
|
+
(there might be alternatives for Android as well) and lool for your device.
|
|
102
|
+
If it's not found then pyatv will likely not fins it either.
|
|
103
|
+
- Firewalls might block the necessary traffic for Bonjour. Make sure the
|
|
104
|
+
traffic is allowed or disable it when scanning.
|
|
105
|
+
- We have seen that switching the Apple TV from WiFi to cable solves the problem
|
|
106
|
+
in some cases. It is recommended that you try it out.
|
|
107
|
+
|
|
108
|
+
If you continue having problems scanning for devices, consider writing a
|
|
109
|
+
[support issue](https://github.com/postlund/pyatv/issues/new?assignees=&labels=question&template=question-or-idea.md&title=).
|
|
110
|
+
Remember to include debug logs (`--debug` if you are using `atvremote`).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: template
|
|
3
|
+
title: Support
|
|
4
|
+
permalink: /support/
|
|
5
|
+
link_group: support
|
|
6
|
+
---
|
|
7
|
+
# :fire: Support
|
|
8
|
+
|
|
9
|
+
If you are having problems or questions, this section aims to help you.
|
|
10
|
+
Check out the subpages above.
|
|
11
|
+
|
|
12
|
+
In case you have found a potential bug or need help, please write issues on GitHub:
|
|
13
|
+
|
|
14
|
+
**:bug: [I have found a bug](https://github.com/postlund/pyatv/issues/new?assignees=&labels=bug&template=bug_report.md&title=)**
|
|
15
|
+
|
|
16
|
+
**:raised_hands: [I need help](https://github.com/postlund/pyatv/issues/new?assignees=&labels=question&template=question-or-idea.md&title=)**
|
|
17
|
+
|
|
18
|
+
**:question: [Something is missing...](https://github.com/postlund/pyatv/issues/new?assignees=&labels=feature&template=feature_request.md&title=)**
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
---
|
|
2
|
+
layout: template
|
|
3
|
+
title: Troubleshooting
|
|
4
|
+
permalink: /support/troubleshooting/
|
|
5
|
+
link_group: support
|
|
6
|
+
---
|
|
7
|
+
# Table of Contents
|
|
8
|
+
{:.no_toc}
|
|
9
|
+
* TOC
|
|
10
|
+
{:toc}
|
|
11
|
+
|
|
12
|
+
# Scanning does not find any devices
|
|
13
|
+
|
|
14
|
+
Please see [this](../scanning_issues/) page on scanning issues.
|
|
15
|
+
|
|
16
|
+
# No PIN code is displayed when I try to pair with AirPlay
|
|
17
|
+
|
|
18
|
+
First check that you've got Apple TV assigned to a "room" in the correct HomeKit
|
|
19
|
+
home. Go to Settings, Airplay and Homekit, and make sure that "Room" has a valid
|
|
20
|
+
value assigned. Then retry pairing.
|
|
21
|
+
|
|
22
|
+
If no screen is displayed with the PIN code, try navigating to the AirPlay
|
|
23
|
+
settings menu on your Apple TV. The code should be visible there.
|
|
24
|
+
|
|
25
|
+
# The exception "pyatv.exceptions.DeviceAuthenticationError: pair start failed" is thrown when I try to pair with AirPlay
|
|
26
|
+
|
|
27
|
+
Make sure you have *Allow Access* set to *Anyone on the Same Network* for
|
|
28
|
+
AirPlay on your Apple TV. For details, see issue {% include issue no="377" %}.
|
|
29
|
+
|
|
30
|
+
# How do I get additional logs that I can attach when creating an issue?
|
|
31
|
+
|
|
32
|
+
You can pass `--debug` to `atvremote` to get extensive debug logs. For more details, see
|
|
33
|
+
the [atvremote](../../documentation/atvremote) page.
|
|
34
|
+
|
|
35
|
+
# I do not receive updates in my listeners, e.g. when media state changes
|
|
36
|
+
|
|
37
|
+
From version 0.6.0 of pyatv, *weak references* are kept to all listeners. This means that if a listener
|
|
38
|
+
is not "reachable" from outside of pyatv, it will be garbage collected the next time the garbage
|
|
39
|
+
collector runs. A typical situation when this would happen looks like this:
|
|
40
|
+
|
|
41
|
+
```python
|
|
42
|
+
class DummyPushListener:
|
|
43
|
+
@staticmethod
|
|
44
|
+
def playstatus_update(updater, playstatus):
|
|
45
|
+
pass
|
|
46
|
+
|
|
47
|
+
@staticmethod
|
|
48
|
+
def playstatus_error(updater, exception):
|
|
49
|
+
pass
|
|
50
|
+
|
|
51
|
+
self.atv.push_updater.listener = DummyPushListener()
|
|
52
|
+
self.atv.push_updater.start()
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
In this case, no one else has a reference to the instance of `DummyPushListener` (other than pyatv), so
|
|
56
|
+
it will be freed when the garbage collector runs (which can be at any given time). Changing the code into
|
|
57
|
+
this would work better:
|
|
58
|
+
|
|
59
|
+
|
|
60
|
+
```python
|
|
61
|
+
listener = DummyPushListener()
|
|
62
|
+
self.atv.push_updater.listener = listener
|
|
63
|
+
self.atv.push_updater.start()
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Here a local reference is kept to the listener. Beware that the same issue will arise when `listener`
|
|
67
|
+
goes out of scope, so make sure all your listeners live at least as long as they are used in pyatv.
|
|
68
|
+
|
|
69
|
+
# Pairing requirement is listed as "disabled", what does that mean?
|
|
70
|
+
<a name="pairing-disabled"></a>
|
|
71
|
+
|
|
72
|
+
This either means that the service is turned off or an access restriction is in place
|
|
73
|
+
that does not allow pyatv to pair (pyatv probably does not support this method of pairing). To solve this,
|
|
74
|
+
you need to go to your device and change access settings to "Allow everyone on the same network".
|
|
75
|
+
How this is done depends on device, here a few links to check out depending on device:
|
|
76
|
+
|
|
77
|
+
* [Apple TV](https://support.apple.com/guide/tv/stream-audio-and-video-with-airplay-atvbf2be9ef7/tvos) -
|
|
78
|
+
Expand *Set who can use AirPlay to stream content to Apple TV* and pick *Anyone on the Same Network*
|
|
79
|
+
* [HomePod](https://support.apple.com/guide/ipad/share-controls-with-others-ipad76474c82/ipados) -
|
|
80
|
+
Follow instructions under *Allow others to access your AirPlay 2-enabled speakers and TVs*, pick
|
|
81
|
+
*Anyone on the same network*
|
|
82
|
+
* [macOS](https://support.apple.com/guide/mac-help/set-up-your-mac-to-be-an-airplay-receiver-mchleee00ec8/mac) -
|
|
83
|
+
Follow instructions and pick *Anyone on the Same Network*
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
syntax = "proto2";
|
|
2
|
+
|
|
3
|
+
import "pyatv/protocols/mrp/protobuf/ProtocolMessage.proto";
|
|
4
|
+
import "pyatv/protocols/mrp/protobuf/PlayerPath.proto";
|
|
5
|
+
|
|
6
|
+
extend ProtocolMessage {
|
|
7
|
+
optional AudioFadeMessage audioFadeMessage = 88;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
message AudioFadeMessage {
|
|
11
|
+
optional PlayerPath playerPath = 1;
|
|
12
|
+
optional int32 fadeType = 2;
|
|
13
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import builtins
|
|
7
|
+
import google.protobuf.descriptor
|
|
8
|
+
import google.protobuf.internal.extension_dict
|
|
9
|
+
import google.protobuf.message
|
|
10
|
+
import pyatv.protocols.mrp.protobuf.PlayerPath_pb2
|
|
11
|
+
import pyatv.protocols.mrp.protobuf.ProtocolMessage_pb2
|
|
12
|
+
import typing
|
|
13
|
+
|
|
14
|
+
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
|
15
|
+
|
|
16
|
+
@typing.final
|
|
17
|
+
class AudioFadeMessage(google.protobuf.message.Message):
|
|
18
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
19
|
+
|
|
20
|
+
PLAYERPATH_FIELD_NUMBER: builtins.int
|
|
21
|
+
FADETYPE_FIELD_NUMBER: builtins.int
|
|
22
|
+
fadeType: builtins.int
|
|
23
|
+
@property
|
|
24
|
+
def playerPath(self) -> pyatv.protocols.mrp.protobuf.PlayerPath_pb2.PlayerPath: ...
|
|
25
|
+
def __init__(
|
|
26
|
+
self,
|
|
27
|
+
*,
|
|
28
|
+
playerPath: pyatv.protocols.mrp.protobuf.PlayerPath_pb2.PlayerPath | None = ...,
|
|
29
|
+
fadeType: builtins.int | None = ...,
|
|
30
|
+
) -> None: ...
|
|
31
|
+
def HasField(self, field_name: typing.Literal["fadeType", b"fadeType", "playerPath", b"playerPath"]) -> builtins.bool: ...
|
|
32
|
+
def ClearField(self, field_name: typing.Literal["fadeType", b"fadeType", "playerPath", b"playerPath"]) -> None: ...
|
|
33
|
+
|
|
34
|
+
global___AudioFadeMessage = AudioFadeMessage
|
|
35
|
+
|
|
36
|
+
AUDIOFADEMESSAGE_FIELD_NUMBER: builtins.int
|
|
37
|
+
audioFadeMessage: google.protobuf.internal.extension_dict._ExtensionFieldDescriptor[pyatv.protocols.mrp.protobuf.ProtocolMessage_pb2.ProtocolMessage, global___AudioFadeMessage]
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
syntax = "proto2";
|
|
2
|
+
|
|
3
|
+
import "pyatv/protocols/mrp/protobuf/ProtocolMessage.proto";
|
|
4
|
+
|
|
5
|
+
extend ProtocolMessage {
|
|
6
|
+
optional AudioFadeResponseMessage audioFadeResponseMessage = 89;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
message AudioFadeResponseMessage {
|
|
10
|
+
optional int64 fadeDuration = 1;
|
|
11
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"""
|
|
2
|
+
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
+
isort:skip_file
|
|
4
|
+
"""
|
|
5
|
+
|
|
6
|
+
import builtins
|
|
7
|
+
import google.protobuf.descriptor
|
|
8
|
+
import google.protobuf.internal.extension_dict
|
|
9
|
+
import google.protobuf.message
|
|
10
|
+
import pyatv.protocols.mrp.protobuf.ProtocolMessage_pb2
|
|
11
|
+
import typing
|
|
12
|
+
|
|
13
|
+
DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
|
|
14
|
+
|
|
15
|
+
@typing.final
|
|
16
|
+
class AudioFadeResponseMessage(google.protobuf.message.Message):
|
|
17
|
+
DESCRIPTOR: google.protobuf.descriptor.Descriptor
|
|
18
|
+
|
|
19
|
+
FADEDURATION_FIELD_NUMBER: builtins.int
|
|
20
|
+
fadeDuration: builtins.int
|
|
21
|
+
def __init__(
|
|
22
|
+
self,
|
|
23
|
+
*,
|
|
24
|
+
fadeDuration: builtins.int | None = ...,
|
|
25
|
+
) -> None: ...
|
|
26
|
+
def HasField(self, field_name: typing.Literal["fadeDuration", b"fadeDuration"]) -> builtins.bool: ...
|
|
27
|
+
def ClearField(self, field_name: typing.Literal["fadeDuration", b"fadeDuration"]) -> None: ...
|
|
28
|
+
|
|
29
|
+
global___AudioFadeResponseMessage = AudioFadeResponseMessage
|
|
30
|
+
|
|
31
|
+
AUDIOFADERESPONSEMESSAGE_FIELD_NUMBER: builtins.int
|
|
32
|
+
audioFadeResponseMessage: google.protobuf.internal.extension_dict._ExtensionFieldDescriptor[pyatv.protocols.mrp.protobuf.ProtocolMessage_pb2.ProtocolMessage, global___AudioFadeResponseMessage]
|