bumble 0.0.212__py3-none-any.whl → 0.0.213__py3-none-any.whl
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.
- bumble/_version.py +2 -2
- bumble/a2dp.py +6 -0
- bumble/apps/README.md +0 -3
- bumble/apps/auracast.py +11 -9
- bumble/apps/bench.py +480 -31
- bumble/apps/console.py +3 -3
- bumble/apps/controller_info.py +47 -10
- bumble/apps/controller_loopback.py +7 -3
- bumble/apps/controllers.py +2 -2
- bumble/apps/device_info.py +2 -2
- bumble/apps/gatt_dump.py +2 -2
- bumble/apps/gg_bridge.py +2 -2
- bumble/apps/hci_bridge.py +2 -2
- bumble/apps/l2cap_bridge.py +2 -2
- bumble/apps/lea_unicast/app.py +6 -1
- bumble/apps/pair.py +19 -11
- bumble/apps/pandora_server.py +2 -2
- bumble/apps/rfcomm_bridge.py +1 -1
- bumble/apps/scan.py +2 -2
- bumble/apps/show.py +4 -2
- bumble/apps/speaker/speaker.html +1 -0
- bumble/apps/speaker/speaker.js +113 -62
- bumble/apps/speaker/speaker.py +126 -18
- bumble/at.py +4 -4
- bumble/att.py +2 -6
- bumble/avc.py +7 -7
- bumble/avctp.py +3 -3
- bumble/avdtp.py +16 -20
- bumble/avrcp.py +41 -53
- bumble/colors.py +2 -2
- bumble/controller.py +84 -23
- bumble/device.py +348 -182
- bumble/drivers/__init__.py +2 -2
- bumble/drivers/common.py +0 -2
- bumble/drivers/intel.py +37 -40
- bumble/drivers/rtk.py +28 -35
- bumble/gatt.py +4 -4
- bumble/gatt_adapters.py +4 -5
- bumble/gatt_client.py +26 -31
- bumble/gatt_server.py +7 -11
- bumble/hci.py +2601 -2909
- bumble/helpers.py +4 -5
- bumble/hfp.py +32 -37
- bumble/host.py +94 -35
- bumble/keys.py +5 -5
- bumble/l2cap.py +310 -394
- bumble/link.py +6 -270
- bumble/pairing.py +23 -20
- bumble/pandora/__init__.py +1 -1
- bumble/pandora/config.py +2 -2
- bumble/pandora/device.py +6 -6
- bumble/pandora/host.py +27 -28
- bumble/pandora/l2cap.py +2 -2
- bumble/pandora/security.py +6 -6
- bumble/pandora/utils.py +3 -3
- bumble/profiles/ascs.py +132 -131
- bumble/profiles/asha.py +2 -2
- bumble/profiles/bap.py +3 -4
- bumble/profiles/csip.py +2 -2
- bumble/profiles/device_information_service.py +2 -2
- bumble/profiles/gap.py +2 -2
- bumble/profiles/hap.py +34 -33
- bumble/profiles/le_audio.py +4 -4
- bumble/profiles/mcp.py +4 -4
- bumble/profiles/vcs.py +3 -5
- bumble/rfcomm.py +10 -10
- bumble/rtp.py +1 -2
- bumble/sdp.py +2 -2
- bumble/smp.py +57 -61
- bumble/tools/rtk_util.py +2 -2
- bumble/transport/__init__.py +2 -16
- bumble/transport/android_netsim.py +5 -5
- bumble/transport/common.py +4 -4
- bumble/transport/pyusb.py +2 -2
- bumble/utils.py +2 -5
- bumble/vendor/android/hci.py +118 -200
- bumble/vendor/zephyr/hci.py +32 -27
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/METADATA +2 -2
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/RECORD +83 -86
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/WHEEL +1 -1
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/entry_points.txt +0 -1
- bumble/apps/link_relay/__init__.py +0 -0
- bumble/apps/link_relay/link_relay.py +0 -289
- bumble/apps/link_relay/logging.yml +0 -21
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/licenses/LICENSE +0 -0
- {bumble-0.0.212.dist-info → bumble-0.0.213.dist-info}/top_level.txt +0 -0
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: bumble
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.213
|
|
4
4
|
Summary: Bluetooth Stack for Apps, Emulation, Test and Experimentation
|
|
5
5
|
Author-email: Google <bumble-dev@google.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/google/bumble
|
|
7
|
-
Requires-Python: >=3.
|
|
7
|
+
Requires-Python: >=3.9
|
|
8
8
|
Description-Content-Type: text/markdown
|
|
9
9
|
License-File: LICENSE
|
|
10
10
|
Requires-Dist: aiohttp~=3.8; platform_system != "Emscripten"
|
|
@@ -1,130 +1,127 @@
|
|
|
1
1
|
bumble/__init__.py,sha256=Q8jkz6rgl95IMAeInQVt_2GLoJl3DcEP2cxtrQ-ho5c,110
|
|
2
|
-
bumble/_version.py,sha256=
|
|
3
|
-
bumble/a2dp.py,sha256=
|
|
4
|
-
bumble/at.py,sha256=
|
|
5
|
-
bumble/att.py,sha256=
|
|
6
|
-
bumble/avc.py,sha256=
|
|
7
|
-
bumble/avctp.py,sha256=
|
|
8
|
-
bumble/avdtp.py,sha256=
|
|
9
|
-
bumble/avrcp.py,sha256=
|
|
2
|
+
bumble/_version.py,sha256=hKS7blrtSK435_z2_dVerGuulxmUE5dVGJKOVcxFhLQ,515
|
|
3
|
+
bumble/a2dp.py,sha256=VVpswLglphWzPmXFvrICcJhPPpL7CvDoNs8845uGhEA,32032
|
|
4
|
+
bumble/at.py,sha256=u93DzB5Ghrxks_ufuUqoYV2RUSowLNLMDhq_j9GrCBc,3108
|
|
5
|
+
bumble/att.py,sha256=7YSEetl1rb9AmZPCVWZN9_wBYQ1er0I99RhV-tAqcPk,33393
|
|
6
|
+
bumble/avc.py,sha256=JCkud6q6MK19w4txXE6s6iSOdrIj0p-HFfVCiSQg80o,16400
|
|
7
|
+
bumble/avctp.py,sha256=zr3WEdYueM5YG-yZHJjrdc6gMgIUJamB8RFbhxbCZ_U,9965
|
|
8
|
+
bumble/avdtp.py,sha256=c3nIzyUkELegAKKNEp2nJbSU9GTXX2oWw3aekWuOass,79607
|
|
9
|
+
bumble/avrcp.py,sha256=cOrUuo6kQlWF3U4JFTeT8Q5qtabY7PCU9XNZDr9awiE,70020
|
|
10
10
|
bumble/bridge.py,sha256=yXwZNUe7pRpuTt41PEmgtfjBLpQKdDwvcxfbYxObqIU,3015
|
|
11
11
|
bumble/codecs.py,sha256=75TGfq-XWWtr-mCRRG7QzJYNRebG50Ypt_QGQkoWlxU,20915
|
|
12
|
-
bumble/colors.py,sha256=
|
|
12
|
+
bumble/colors.py,sha256=gm_PqgGfUF8Nkntn652apR4HrqN3vLv249YCIfw8mtk,3112
|
|
13
13
|
bumble/company_ids.py,sha256=B68e2QPsDeRYP9jjbGs4GGDwEkGxcXGTsON_CHA0uuI,118528
|
|
14
|
-
bumble/controller.py,sha256=
|
|
14
|
+
bumble/controller.py,sha256=2Q9Hq7h6S8WVOM8NsME-N0vWUCcbZqckYA7asmIXhGA,64137
|
|
15
15
|
bumble/core.py,sha256=iv7WBoWdJsWhVma9hvKnHx5nsKRthwOacywkYoHk_Lo,79067
|
|
16
16
|
bumble/decoder.py,sha256=0-VNWZT-u7lvK3qBpAuYT0M6Rz_bMgMi4CjfUXX_6RM,9728
|
|
17
|
-
bumble/device.py,sha256=
|
|
17
|
+
bumble/device.py,sha256=ofvkFVSYRDDXjF3Abann00RyShq84CByayRl7APz3zY,248608
|
|
18
18
|
bumble/gap.py,sha256=BYJN74KgOHTrgTF5NcdUCBsWrab6lXu7enCYnAMQQl0,2144
|
|
19
|
-
bumble/gatt.py,sha256=
|
|
20
|
-
bumble/gatt_adapters.py,sha256=
|
|
21
|
-
bumble/gatt_client.py,sha256=
|
|
22
|
-
bumble/gatt_server.py,sha256=
|
|
23
|
-
bumble/hci.py,sha256=
|
|
24
|
-
bumble/helpers.py,sha256=
|
|
25
|
-
bumble/hfp.py,sha256=
|
|
19
|
+
bumble/gatt.py,sha256=bTF1al-w8xFOLxKcK-yg1oAPK_ZExrcCpaY6UDe7c6M,34551
|
|
20
|
+
bumble/gatt_adapters.py,sha256=E4IaXUU9KPwOAs_84DZ1Il1PaV8JEFlTvQ7Lgepw7pQ,13223
|
|
21
|
+
bumble/gatt_client.py,sha256=7abratBIRXmN3GWNyg6eGmYVjlJ1sFBdlyOlrBtcelQ,44342
|
|
22
|
+
bumble/gatt_server.py,sha256=Eh3rS-8cR71zro7oj-_Eh_LSf-QVOvdBHaKJTOSvYo4,37529
|
|
23
|
+
bumble/hci.py,sha256=oV6dR5TqBH9i5XuL5qi2rA374CmZ2qNh6_m7hZcCSaw,324490
|
|
24
|
+
bumble/helpers.py,sha256=Qa5DrscGQ28NRX5-xeAdhPQnhjApY6YYsbWvV2FHOtg,12720
|
|
25
|
+
bumble/hfp.py,sha256=vMegYtDy3y4r_Jdrakok-1A27Isr7-gQfY65NpZF4W4,76781
|
|
26
26
|
bumble/hid.py,sha256=ctN_8Ickh63r5P0pTWrKuSUrc6ycSj2X1RlAPZ-SM3c,20790
|
|
27
|
-
bumble/host.py,sha256=
|
|
28
|
-
bumble/keys.py,sha256=
|
|
29
|
-
bumble/l2cap.py,sha256=
|
|
30
|
-
bumble/link.py,sha256=
|
|
31
|
-
bumble/pairing.py,sha256=
|
|
27
|
+
bumble/host.py,sha256=2iktyCW9m9t54RjfZ6iFSINb5u0QAplkq7WfbCbxZRs,64579
|
|
28
|
+
bumble/keys.py,sha256=z1EH-PlmpnCP4mKWVhuTh5NbWJREL0_9NQaSaMMxvdc,13414
|
|
29
|
+
bumble/l2cap.py,sha256=vwQ8K9oOOtGPT4Gx4VQJQi3L_AqaiDmC95JOdhOf_dU,78728
|
|
30
|
+
bumble/link.py,sha256=9dMHhhALSrZold937dfjt0KHGgqiR-c_uheY7r_wr_k,14511
|
|
31
|
+
bumble/pairing.py,sha256=sXb5J5zTKO4DCHYoyIcbqFDmuQC8ZJCwtnr-kXOwuzA,10141
|
|
32
32
|
bumble/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
33
|
-
bumble/rfcomm.py,sha256=
|
|
34
|
-
bumble/rtp.py,sha256=
|
|
35
|
-
bumble/sdp.py,sha256=
|
|
36
|
-
bumble/smp.py,sha256=
|
|
33
|
+
bumble/rfcomm.py,sha256=G-TrwVwC4qXQXjdzfWnV9PQihxWGmb7wqgv7VoaG-vQ,40988
|
|
34
|
+
bumble/rtp.py,sha256=s2cAnf0q6cFgN6yUhn4DwPI5JRgokLXLefaGzBg9te0,3463
|
|
35
|
+
bumble/sdp.py,sha256=lrAV-lOIEd6KptgsjUuQuXTXiQPOLdqfIvJruyYNXjY,49583
|
|
36
|
+
bumble/smp.py,sha256=LATcw9sAWt2Vv9_2RpkB_-Ysy-kfI5RenrA2LgBju0Y,78409
|
|
37
37
|
bumble/snoop.py,sha256=1mzwmp9LToUXbPnFsLrt8S4UHs0kqzbu7LDydwbmkZI,5715
|
|
38
|
-
bumble/utils.py,sha256
|
|
39
|
-
bumble/apps/README.md,sha256=
|
|
38
|
+
bumble/utils.py,sha256=-nQv_hPsleqTunKFE1aRyYy-gtFSh0upZ4xZddE4B-U,16199
|
|
39
|
+
bumble/apps/README.md,sha256=gY24s9zrX6yjVcaSfC1w-DQ4y-HCGXskS66nda0479k,1653
|
|
40
40
|
bumble/apps/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
41
|
-
bumble/apps/auracast.py,sha256=
|
|
42
|
-
bumble/apps/bench.py,sha256=
|
|
41
|
+
bumble/apps/auracast.py,sha256=6y-D8kRII36ykKglNjl82bQi3upyvTV5Dkegf9k6LUw,44624
|
|
42
|
+
bumble/apps/bench.py,sha256=T-OFV00Cklh1eSU64XGr5_zyaIEH5YkH5szGEMIzxMs,76877
|
|
43
43
|
bumble/apps/ble_rpa_tool.py,sha256=ZQtsbfnLPd5qUAkEBPpNgJLRynBBc7q_9cDHKUW2SQ0,1701
|
|
44
|
-
bumble/apps/console.py,sha256=
|
|
45
|
-
bumble/apps/controller_info.py,sha256=
|
|
46
|
-
bumble/apps/controller_loopback.py,sha256=
|
|
47
|
-
bumble/apps/controllers.py,sha256=
|
|
48
|
-
bumble/apps/device_info.py,sha256=
|
|
49
|
-
bumble/apps/gatt_dump.py,sha256=
|
|
50
|
-
bumble/apps/gg_bridge.py,sha256=
|
|
51
|
-
bumble/apps/hci_bridge.py,sha256=
|
|
52
|
-
bumble/apps/l2cap_bridge.py,sha256=
|
|
53
|
-
bumble/apps/pair.py,sha256=
|
|
54
|
-
bumble/apps/pandora_server.py,sha256=
|
|
55
|
-
bumble/apps/rfcomm_bridge.py,sha256=
|
|
56
|
-
bumble/apps/scan.py,sha256=
|
|
57
|
-
bumble/apps/show.py,sha256=
|
|
44
|
+
bumble/apps/console.py,sha256=UmrkwihPJuhws7NgCvWMXWVwVXFTTCAOy18nbA0H_hA,45450
|
|
45
|
+
bumble/apps/controller_info.py,sha256=7pWA6Nnh9kgjUShs9X1HhXfLL5Rc7626kN_VVsMkZYg,13728
|
|
46
|
+
bumble/apps/controller_loopback.py,sha256=aNl3XWk8x8VcBQDffzFdg3nZZFOkJDwi8FEDtJieoG0,7317
|
|
47
|
+
bumble/apps/controllers.py,sha256=VB1lgjG42z3_BrDl3E7dAsYU0ZoobNe9VT-BObiAFMk,2310
|
|
48
|
+
bumble/apps/device_info.py,sha256=XBXltkBm2ZqyhF1DJiz9XHr7QNMbb2yia3fUc1S_PPo,9926
|
|
49
|
+
bumble/apps/gatt_dump.py,sha256=CkRa_xr0xecRSGfsotE0S57TXHQGZ69wnrAXL94PQMY,4471
|
|
50
|
+
bumble/apps/gg_bridge.py,sha256=OzXuH9Fc8ZEE-MYimXPNJZyyfQwI05CTV_U_tpmw-u0,14700
|
|
51
|
+
bumble/apps/hci_bridge.py,sha256=I0WOYbnaPKjd2E8Q1IiB49QOfEUYNae1PzdSLturhqs,4013
|
|
52
|
+
bumble/apps/l2cap_bridge.py,sha256=_o0YwUTZc6Rm7AZ5NAwIR-O168dwBbBZii043-yuk9Q,13046
|
|
53
|
+
bumble/apps/pair.py,sha256=pegIwX5A4iIcSDcjga401-8oJBCh4K7FPEDcy-ECY_k,25077
|
|
54
|
+
bumble/apps/pandora_server.py,sha256=b0SfuZnondQrYTMfguVTaceSZ1IuztRH99Cae7jAYZY,1391
|
|
55
|
+
bumble/apps/rfcomm_bridge.py,sha256=sCkPKDF6xzndCEOrHvWfWVkiDaZa_ab6GfO_MOKqt1Q,17630
|
|
56
|
+
bumble/apps/scan.py,sha256=b-Yt-V5UjkBRkN__OFLhthzSMUCjpp3_6PgdSbkm1y0,8350
|
|
57
|
+
bumble/apps/show.py,sha256=N2ydt2uz2k3ASXS10o3xn_gHxnBs0uVn5U3wbHdAbgg,6336
|
|
58
58
|
bumble/apps/unbond.py,sha256=LDPWpmgKLMGYDdIFGTdGciFDcUliZ0OmseEbGfJ-MAM,3176
|
|
59
59
|
bumble/apps/usb_probe.py,sha256=zJqrqKSGVYcOntXzgONdluZDE6jfj3IwPNuLqmDPDsU,10351
|
|
60
|
-
bumble/apps/lea_unicast/app.py,sha256=
|
|
60
|
+
bumble/apps/lea_unicast/app.py,sha256=7nzOFilP9K03g2N2BYwnQKuZBWIqu0xDTfD8nCEJzJY,17724
|
|
61
61
|
bumble/apps/lea_unicast/index.html,sha256=d1IHsYd8TGOnxNZKaHolf4Y-7VwT1kO9Z72vpGMdy3k,2354
|
|
62
|
-
bumble/apps/link_relay/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
63
|
-
bumble/apps/link_relay/link_relay.py,sha256=GOESYPzkMJFrz5VOI_BSmnmgz4Y8EdSLHMWgdA63aDg,10066
|
|
64
|
-
bumble/apps/link_relay/logging.yml,sha256=t-P72RAHsTZOESw0M4I3CQPonymcjkd9SLE0eY_ZNiM,311
|
|
65
62
|
bumble/apps/player/player.py,sha256=sgAeoH3-tArE-hUZj2W9JPTzduXoPeidNLnHV3BBWX0,22378
|
|
66
63
|
bumble/apps/speaker/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
67
64
|
bumble/apps/speaker/logo.svg,sha256=SQ9XXIqhh07BnGaBZ653nJ7vOslm2Dogdqadhg2MdE4,4205
|
|
68
65
|
bumble/apps/speaker/speaker.css,sha256=nyM5TjzDYkkLwFzsaIOuTSngzSvgDnkLe0Z-fAn1_t4,1234
|
|
69
|
-
bumble/apps/speaker/speaker.html,sha256=
|
|
70
|
-
bumble/apps/speaker/speaker.js,sha256=
|
|
71
|
-
bumble/apps/speaker/speaker.py,sha256
|
|
66
|
+
bumble/apps/speaker/speaker.html,sha256=e1VD96pwiDwcaxVERvc4BPLwH1948BIcqPGmnWNHQNM,1259
|
|
67
|
+
bumble/apps/speaker/speaker.js,sha256=nom2zHJJ7lVFU_7TD1LS7Gl1PXAPztdUF9zMCgZvfVI,11245
|
|
68
|
+
bumble/apps/speaker/speaker.py,sha256=rWaxRNTq_zaZeskFxLrSu15dx3h60CN0T3QlQKQPX5E,27800
|
|
72
69
|
bumble/audio/__init__.py,sha256=tc75ofvV52qED31kB_LYRVLNrxtbZqnOWO8lHsZK3Ww,747
|
|
73
70
|
bumble/audio/io.py,sha256=xxEv-yUwlNRX-4ccy7VdrHBmLL4OrOekgI81hIpMWRU,17789
|
|
74
71
|
bumble/crypto/__init__.py,sha256=MHtq-7dK2Xh24BB4R5HMVdrdujPpyzXW0qN82KpJaeM,6565
|
|
75
72
|
bumble/crypto/builtin.py,sha256=VlSquDDt034KMOQwZp18wJBLLYsAH_VarkC4YhDb4Ts,60901
|
|
76
73
|
bumble/crypto/cryptography.py,sha256=tka7JIOoJUEXg457aov0QxXdQ0ImukQUa5SBdBRXrqQ,2788
|
|
77
|
-
bumble/drivers/__init__.py,sha256=
|
|
78
|
-
bumble/drivers/common.py,sha256=
|
|
79
|
-
bumble/drivers/intel.py,sha256=
|
|
80
|
-
bumble/drivers/rtk.py,sha256=
|
|
81
|
-
bumble/pandora/__init__.py,sha256=
|
|
82
|
-
bumble/pandora/config.py,sha256=
|
|
83
|
-
bumble/pandora/device.py,sha256=
|
|
84
|
-
bumble/pandora/host.py,sha256=
|
|
85
|
-
bumble/pandora/l2cap.py,sha256=
|
|
74
|
+
bumble/drivers/__init__.py,sha256=SR0rgwU3onejbBNZqbhxkcDOneVkTcFUzY6_rrhtmbY,3211
|
|
75
|
+
bumble/drivers/common.py,sha256=pS783hudolLZAzF8IUWp7g6TXyQsUCEzqCsd1VGeYfQ,1507
|
|
76
|
+
bumble/drivers/intel.py,sha256=vXLvO2_VdeXvMPbMxG6rQI4cl-BZVWg8N8H9JaczgTs,23228
|
|
77
|
+
bumble/drivers/rtk.py,sha256=HMDzxQyd5ME4cTmLJ2iOaR1s3CDhfsWjS98XgwdHy-0,22038
|
|
78
|
+
bumble/pandora/__init__.py,sha256=zal0mBOdd_aq9oLvGaxKS95S_9xGkSpDbt54WHPDP1A,3533
|
|
79
|
+
bumble/pandora/config.py,sha256=lWBLS3EjxTB4zzrubA4igtGJum8joD-_6nB2qpNvAnw,2382
|
|
80
|
+
bumble/pandora/device.py,sha256=Sy1_7V3MkW3lduKRrvZ4gsBnfA5h06HQGciUBr5rOXA,5332
|
|
81
|
+
bumble/pandora/host.py,sha256=iw2a7R3NQgbI6pckUV_h4WQe6td6QdO1pt8cBVRnntU,39341
|
|
82
|
+
bumble/pandora/l2cap.py,sha256=PM87N3Rh2BGIzRMqb4u63_UVoJAu1PcBdkvuzLmzJ8Q,11781
|
|
86
83
|
bumble/pandora/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
87
|
-
bumble/pandora/security.py,sha256=
|
|
88
|
-
bumble/pandora/utils.py,sha256=
|
|
84
|
+
bumble/pandora/security.py,sha256=zrPBlDMjVyr5lQu8vxeeiURbUofzXtgqy6LLkVsbWdw,22834
|
|
85
|
+
bumble/pandora/utils.py,sha256=XkkePlL8Qj5x7vhh4bbYXjmdW3eySgStQS2rePexPZM,3957
|
|
89
86
|
bumble/profiles/__init__.py,sha256=yBGC8Ti5LvZuoh1F42XtfrBilb39T77_yuxESZeX2yI,581
|
|
90
87
|
bumble/profiles/aics.py,sha256=cO_0JhguuMdSX5dsCvoZh4Wo7gfHFRBaoGD6INHwDeM,17729
|
|
91
88
|
bumble/profiles/ancs.py,sha256=sU_mn9H1l4WLiwNBfIPAgjewXRRrTu6jX7YtyvF2k1A,17808
|
|
92
|
-
bumble/profiles/ascs.py,sha256=
|
|
93
|
-
bumble/profiles/asha.py,sha256=
|
|
94
|
-
bumble/profiles/bap.py,sha256=
|
|
89
|
+
bumble/profiles/ascs.py,sha256=Mhw0HW1S_cJiAfj8e5PhVYHI74H5U_Y8NZzFJlz5pDc,25601
|
|
90
|
+
bumble/profiles/asha.py,sha256=HTTXM-4_r4PBtJmrGoRI1PxC15AAEyKs-aOWEso-3wc,10567
|
|
91
|
+
bumble/profiles/bap.py,sha256=X784NmuX_4etuNc8_FLuB0VS525m7Q6ya_r5zAq1GCQ,21955
|
|
95
92
|
bumble/profiles/bass.py,sha256=bVFTFqpJDzc_TBUjJcuT2NXzcAW_W2N9UKHXx7OsEJQ,14648
|
|
96
93
|
bumble/profiles/battery_service.py,sha256=-PM8gwXV2Aym5Z2Z4PAbl31Wefa7E260qy5P5jYVC4A,2572
|
|
97
94
|
bumble/profiles/cap.py,sha256=6gH7oOnUKjOggMPuB7rtbwj0AneoNmnWzQ_iR3io8e0,1945
|
|
98
|
-
bumble/profiles/csip.py,sha256=
|
|
99
|
-
bumble/profiles/device_information_service.py,sha256=
|
|
100
|
-
bumble/profiles/gap.py,sha256=
|
|
95
|
+
bumble/profiles/csip.py,sha256=0bxA7M_ypJHpyTS-HzWL9l14jiIoeABJhnkTQy_kRMU,10174
|
|
96
|
+
bumble/profiles/device_information_service.py,sha256=YvRgbFBPFqsSbw0rU8K--y0LsC-kg5DgF_YANAdQhhA,6344
|
|
97
|
+
bumble/profiles/gap.py,sha256=4Z6VRbj_jzwGHmV6cmWoduEjnaOlVSyjw2ErrdNrN8A,4026
|
|
101
98
|
bumble/profiles/gatt_service.py,sha256=jE28eY9H6jJwYwqvsxb3xGlhB2ne7W9J6UrUMPki5b0,6751
|
|
102
99
|
bumble/profiles/gmap.py,sha256=t59LucWKYSW8vAZIf3DHU3sbt3tdbw5M8BDE2bxTN-k,7327
|
|
103
|
-
bumble/profiles/hap.py,sha256=
|
|
100
|
+
bumble/profiles/hap.py,sha256=6hSd4eRJVtPFonsP5xeqsCSbPWtyFHJfj_C0yWVTciY,25519
|
|
104
101
|
bumble/profiles/heart_rate_service.py,sha256=Hw46AHc1NEVl0HAvjt4kc_HNSFK3byvETcXraZtW0ow,9251
|
|
105
|
-
bumble/profiles/le_audio.py,sha256=
|
|
106
|
-
bumble/profiles/mcp.py,sha256=
|
|
102
|
+
bumble/profiles/le_audio.py,sha256=VXvr73q9PHWpS-JmnxrKlgl_X6QYS-NmowMndwqTlcA,5827
|
|
103
|
+
bumble/profiles/mcp.py,sha256=PanZbl9_CXwR4gcDPXwsucTV408WGHgpwkyrNHP5gH0,17835
|
|
107
104
|
bumble/profiles/pacs.py,sha256=lO3HEsVCTaONtTkl1bwZzfZXlPviMoIGqu4McVEI5Hg,10469
|
|
108
105
|
bumble/profiles/pbp.py,sha256=TCAD4uH8dP8rbUpn-8H_DFR7T77rnCAfMmFYCruoRHs,1630
|
|
109
106
|
bumble/profiles/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
110
107
|
bumble/profiles/tmap.py,sha256=8VocfKspJpK8UiYS8sSNYXYaE6qUI-OPQnRPeMoFh6A,2935
|
|
111
|
-
bumble/profiles/vcs.py,sha256=
|
|
108
|
+
bumble/profiles/vcs.py,sha256=oQoycX32s12TP860MnImTDdaEJI6LdWcTFVzSH3In6U,8266
|
|
112
109
|
bumble/profiles/vocs.py,sha256=OqwTq170AzrKAFGjk9JtP9j1nCo1yh320SJIpl86WXQ,10989
|
|
113
110
|
bumble/tools/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
114
111
|
bumble/tools/generate_company_id_list.py,sha256=ysbPb3zmxKFBiSQ_MBG2r15-sqR5P_GWT6i0YUTTXOM,1736
|
|
115
112
|
bumble/tools/intel_fw_download.py,sha256=8YJ3y3yww7bEvL9cINq9cFucoCWf-Gf3pyu-gl4-UJE,4453
|
|
116
113
|
bumble/tools/intel_util.py,sha256=2hWoKS1NM8XJSmjZWBdn5mF33BWq2nWiYSNcfpUcY24,4699
|
|
117
114
|
bumble/tools/rtk_fw_download.py,sha256=KEPG-rDrdPGKBzZ78P4s3udLRYT3p7vesGhXvJTWTic,5453
|
|
118
|
-
bumble/tools/rtk_util.py,sha256=
|
|
119
|
-
bumble/transport/__init__.py,sha256=
|
|
115
|
+
bumble/tools/rtk_util.py,sha256=2l4KbSL1Sw3FHSdkB_FFG-W2zfgGg4opPdDMwEzcHno,5071
|
|
116
|
+
bumble/transport/__init__.py,sha256=WLKS002dAbWk0CaUh9Lil1PPiOooZ2m5n2S_01GFqK8,6834
|
|
120
117
|
bumble/transport/android_emulator.py,sha256=JLSgnmkBcMMYKLr28l0ItvF-thxHARLE8be7wKGuJE8,4464
|
|
121
|
-
bumble/transport/android_netsim.py,sha256=
|
|
122
|
-
bumble/transport/common.py,sha256=
|
|
118
|
+
bumble/transport/android_netsim.py,sha256=972v-zqwKhAI56BBpmFo0nhsTqp1qzAzKU8suRO-k7k,17283
|
|
119
|
+
bumble/transport/common.py,sha256=biGfoiEHX7VvpmKvDu6YrhUg7n9DkNeMBqHSqmr8cZU,16910
|
|
123
120
|
bumble/transport/file.py,sha256=EOZaubgnCGZzYmBZOlVdpGsVEFfpxp8zB5mgqRGHuX0,2026
|
|
124
121
|
bumble/transport/hci_socket.py,sha256=hevDs3GsmFWEsnGjQrd8LZqYVGWRjSs0VbKPWINjiAs,6347
|
|
125
122
|
bumble/transport/pty.py,sha256=eoNiTRfXjHivReeHRDgMtmUDnsgXnRXrvxkLV_9lAVY,2748
|
|
126
123
|
bumble/transport/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
127
|
-
bumble/transport/pyusb.py,sha256=
|
|
124
|
+
bumble/transport/pyusb.py,sha256=vjxr705k5Qw9HrxTxJgIOeYhhfxnkGFbZ6MOrpuYwFE,16201
|
|
128
125
|
bumble/transport/serial.py,sha256=-AqhYOxphl6_U-_N6_Zq-ksTiFxjy7FzPSAIkBVgc00,2462
|
|
129
126
|
bumble/transport/tcp_client.py,sha256=m_pwmi3hYPxkcUGA3eM4fuEGCLchzN8gK1jHxn90Xro,1870
|
|
130
127
|
bumble/transport/tcp_server.py,sha256=A19Ton--SqLO-ql2KU4rR6GjDs7gt1DG2XaRD2nVPYo,3795
|
|
@@ -172,12 +169,12 @@ bumble/transport/grpc_protobuf/rootcanal/configuration_pb2.pyi,sha256=W8j1bXHBrk
|
|
|
172
169
|
bumble/transport/grpc_protobuf/rootcanal/configuration_pb2_grpc.py,sha256=1oboBPFxaTEXt9Aw7EAj8gXHDCNMhZD2VXqocC9l_gk,159
|
|
173
170
|
bumble/vendor/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
174
171
|
bumble/vendor/android/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
175
|
-
bumble/vendor/android/hci.py,sha256
|
|
172
|
+
bumble/vendor/android/hci.py,sha256=N_htC7h7k0StYEl4hQNSxd0lpYdR9g4haQVj3Hjqueg,10486
|
|
176
173
|
bumble/vendor/zephyr/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
177
|
-
bumble/vendor/zephyr/hci.py,sha256=
|
|
178
|
-
bumble-0.0.
|
|
179
|
-
bumble-0.0.
|
|
180
|
-
bumble-0.0.
|
|
181
|
-
bumble-0.0.
|
|
182
|
-
bumble-0.0.
|
|
183
|
-
bumble-0.0.
|
|
174
|
+
bumble/vendor/zephyr/hci.py,sha256=vYb7Wa3UBnhf1xKbCxK0MUDsu8mnR2082UYyh54SqX4,3436
|
|
175
|
+
bumble-0.0.213.dist-info/licenses/LICENSE,sha256=FvaYh4NRWIGgS_OwoBs5gFgkCmAghZ-DYnIGBZPuw-s,12142
|
|
176
|
+
bumble-0.0.213.dist-info/METADATA,sha256=cTLtp_Il_FwE2Ja8I-K_1bDLG8cvrX1sxXTLNW3Mdqo,6071
|
|
177
|
+
bumble-0.0.213.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
178
|
+
bumble-0.0.213.dist-info/entry_points.txt,sha256=mX5dzixNMRo4CTAEQqiYTr-JIaWF62TYrRvJOstjjL8,1081
|
|
179
|
+
bumble-0.0.213.dist-info/top_level.txt,sha256=tV6JJKaHPYMFiJYiBYFW24PCcfLxTJZdlu6BmH3Cb00,7
|
|
180
|
+
bumble-0.0.213.dist-info/RECORD,,
|
|
@@ -10,7 +10,6 @@ bumble-hci-bridge = bumble.apps.hci_bridge:main
|
|
|
10
10
|
bumble-intel-fw-download = bumble.tools.intel_fw_download:main
|
|
11
11
|
bumble-intel-util = bumble.tools.intel_util:main
|
|
12
12
|
bumble-l2cap-bridge = bumble.apps.l2cap_bridge:main
|
|
13
|
-
bumble-link-relay = bumble.apps.link_relay.link_relay:main
|
|
14
13
|
bumble-pair = bumble.apps.pair:main
|
|
15
14
|
bumble-pandora-server = bumble.apps.pandora_server:main
|
|
16
15
|
bumble-player = bumble.apps.player.player:main
|
|
File without changes
|
|
@@ -1,289 +0,0 @@
|
|
|
1
|
-
# Copyright 2021-2022 Google LLC
|
|
2
|
-
#
|
|
3
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
-
# you may not use this file except in compliance with the License.
|
|
5
|
-
# You may obtain a copy of the License at
|
|
6
|
-
#
|
|
7
|
-
# https://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
-
#
|
|
9
|
-
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
-
# See the License for the specific language governing permissions and
|
|
13
|
-
# limitations under the License.
|
|
14
|
-
|
|
15
|
-
# ----------------------------------------------------------------------------
|
|
16
|
-
# Imports
|
|
17
|
-
# ----------------------------------------------------------------------------
|
|
18
|
-
import sys
|
|
19
|
-
import logging
|
|
20
|
-
import json
|
|
21
|
-
import asyncio
|
|
22
|
-
import argparse
|
|
23
|
-
import uuid
|
|
24
|
-
import os
|
|
25
|
-
from urllib.parse import urlparse
|
|
26
|
-
import websockets
|
|
27
|
-
|
|
28
|
-
from bumble.colors import color
|
|
29
|
-
|
|
30
|
-
# -----------------------------------------------------------------------------
|
|
31
|
-
# Logging
|
|
32
|
-
# -----------------------------------------------------------------------------
|
|
33
|
-
logger = logging.getLogger(__name__)
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
# ----------------------------------------------------------------------------
|
|
37
|
-
# Constants
|
|
38
|
-
# ----------------------------------------------------------------------------
|
|
39
|
-
DEFAULT_RELAY_PORT = 10723
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
# ----------------------------------------------------------------------------
|
|
43
|
-
# Utils
|
|
44
|
-
# ----------------------------------------------------------------------------
|
|
45
|
-
def error_to_json(error):
|
|
46
|
-
return json.dumps({'error': error})
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
def error_to_result(error):
|
|
50
|
-
return f'result:{error_to_json(error)}'
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
async def broadcast_message(message, connections):
|
|
54
|
-
# Send to all the connections
|
|
55
|
-
tasks = [connection.send_message(message) for connection in connections]
|
|
56
|
-
if tasks:
|
|
57
|
-
await asyncio.gather(*tasks)
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
# ----------------------------------------------------------------------------
|
|
61
|
-
# Connection class
|
|
62
|
-
# ----------------------------------------------------------------------------
|
|
63
|
-
class Connection:
|
|
64
|
-
"""
|
|
65
|
-
A Connection represents a client connected to the relay over a websocket
|
|
66
|
-
"""
|
|
67
|
-
|
|
68
|
-
def __init__(self, room, websocket):
|
|
69
|
-
self.room = room
|
|
70
|
-
self.websocket = websocket
|
|
71
|
-
self.address = str(uuid.uuid4())
|
|
72
|
-
|
|
73
|
-
async def send_message(self, message):
|
|
74
|
-
try:
|
|
75
|
-
logger.debug(color(f'->{self.address}: {message}', 'yellow'))
|
|
76
|
-
return await self.websocket.send(message)
|
|
77
|
-
except websockets.exceptions.WebSocketException as error:
|
|
78
|
-
logger.info(f'! client "{self}" disconnected: {error}')
|
|
79
|
-
await self.cleanup()
|
|
80
|
-
|
|
81
|
-
async def send_error(self, error):
|
|
82
|
-
return await self.send_message(f'result:{error_to_json(error)}')
|
|
83
|
-
|
|
84
|
-
async def receive_message(self):
|
|
85
|
-
try:
|
|
86
|
-
message = await self.websocket.recv()
|
|
87
|
-
logger.debug(color(f'<-{self.address}: {message}', 'blue'))
|
|
88
|
-
return message
|
|
89
|
-
except websockets.exceptions.WebSocketException as error:
|
|
90
|
-
logger.info(color(f'! client "{self}" disconnected: {error}', 'red'))
|
|
91
|
-
await self.cleanup()
|
|
92
|
-
|
|
93
|
-
async def cleanup(self):
|
|
94
|
-
if self.room:
|
|
95
|
-
await self.room.remove_connection(self)
|
|
96
|
-
|
|
97
|
-
def set_address(self, address):
|
|
98
|
-
logger.info(f'Connection address changed: {self.address} -> {address}')
|
|
99
|
-
self.address = address
|
|
100
|
-
|
|
101
|
-
def __str__(self):
|
|
102
|
-
return (
|
|
103
|
-
f'Connection(address="{self.address}", '
|
|
104
|
-
f'client={self.websocket.remote_address[0]}:'
|
|
105
|
-
f'{self.websocket.remote_address[1]})'
|
|
106
|
-
)
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
# ----------------------------------------------------------------------------
|
|
110
|
-
# Room class
|
|
111
|
-
# ----------------------------------------------------------------------------
|
|
112
|
-
class Room:
|
|
113
|
-
"""
|
|
114
|
-
A Room is a collection of bridged connections
|
|
115
|
-
"""
|
|
116
|
-
|
|
117
|
-
def __init__(self, relay, name):
|
|
118
|
-
self.relay = relay
|
|
119
|
-
self.name = name
|
|
120
|
-
self.observers = []
|
|
121
|
-
self.connections = []
|
|
122
|
-
|
|
123
|
-
async def add_connection(self, connection):
|
|
124
|
-
logger.info(f'New participant in {self.name}: {connection}')
|
|
125
|
-
self.connections.append(connection)
|
|
126
|
-
await self.broadcast_message(connection, f'joined:{connection.address}')
|
|
127
|
-
|
|
128
|
-
async def remove_connection(self, connection):
|
|
129
|
-
if connection in self.connections:
|
|
130
|
-
self.connections.remove(connection)
|
|
131
|
-
await self.broadcast_message(connection, f'left:{connection.address}')
|
|
132
|
-
|
|
133
|
-
def find_connections_by_address(self, address):
|
|
134
|
-
return [c for c in self.connections if c.address == address]
|
|
135
|
-
|
|
136
|
-
async def bridge_connection(self, connection):
|
|
137
|
-
while True:
|
|
138
|
-
# Wait for a message
|
|
139
|
-
message = await connection.receive_message()
|
|
140
|
-
|
|
141
|
-
# Skip empty messages
|
|
142
|
-
if message is None:
|
|
143
|
-
return
|
|
144
|
-
|
|
145
|
-
# Parse the message to decide how to handle it
|
|
146
|
-
if message.startswith('@'):
|
|
147
|
-
# This is a targeted message
|
|
148
|
-
await self.on_targeted_message(connection, message)
|
|
149
|
-
elif message.startswith('/'):
|
|
150
|
-
# This is an RPC request
|
|
151
|
-
await self.on_rpc_request(connection, message)
|
|
152
|
-
else:
|
|
153
|
-
await connection.send_message(
|
|
154
|
-
f'result:{error_to_json("error: invalid message")}'
|
|
155
|
-
)
|
|
156
|
-
|
|
157
|
-
async def broadcast_message(self, sender, message):
|
|
158
|
-
'''
|
|
159
|
-
Send to all connections in the room except back to the sender
|
|
160
|
-
'''
|
|
161
|
-
await broadcast_message(message, [c for c in self.connections if c != sender])
|
|
162
|
-
|
|
163
|
-
async def on_rpc_request(self, connection, message):
|
|
164
|
-
command, *params = message.split(' ', 1)
|
|
165
|
-
if handler := getattr(
|
|
166
|
-
self, f'on_{command[1:].lower().replace("-","_")}_command', None
|
|
167
|
-
):
|
|
168
|
-
try:
|
|
169
|
-
result = await handler(connection, params)
|
|
170
|
-
except Exception as error:
|
|
171
|
-
result = error_to_result(error)
|
|
172
|
-
else:
|
|
173
|
-
result = error_to_result('unknown command')
|
|
174
|
-
|
|
175
|
-
await connection.send_message(result or 'result:{}')
|
|
176
|
-
|
|
177
|
-
async def on_targeted_message(self, connection, message):
|
|
178
|
-
target, *payload = message.split(' ', 1)
|
|
179
|
-
if not payload:
|
|
180
|
-
return error_to_json('missing arguments')
|
|
181
|
-
payload = payload[0]
|
|
182
|
-
target = target[1:]
|
|
183
|
-
|
|
184
|
-
# Determine what targets to send to
|
|
185
|
-
if target == '*':
|
|
186
|
-
# Send to all connections in the room except the connection from which the
|
|
187
|
-
# message was received
|
|
188
|
-
connections = [c for c in self.connections if c != connection]
|
|
189
|
-
else:
|
|
190
|
-
connections = self.find_connections_by_address(target)
|
|
191
|
-
if not connections:
|
|
192
|
-
# Unicast with no recipient, let the sender know
|
|
193
|
-
await connection.send_message(f'unreachable:{target}')
|
|
194
|
-
|
|
195
|
-
# Send to targets
|
|
196
|
-
await broadcast_message(f'message:{connection.address}/{payload}', connections)
|
|
197
|
-
|
|
198
|
-
async def on_set_address_command(self, connection, params):
|
|
199
|
-
if not params:
|
|
200
|
-
return error_to_result('missing address')
|
|
201
|
-
|
|
202
|
-
current_address = connection.address
|
|
203
|
-
new_address = params[0]
|
|
204
|
-
connection.set_address(new_address)
|
|
205
|
-
await self.broadcast_message(
|
|
206
|
-
connection, f'address-changed:from={current_address},to={new_address}'
|
|
207
|
-
)
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
# ----------------------------------------------------------------------------
|
|
211
|
-
class Relay:
|
|
212
|
-
"""
|
|
213
|
-
A relay accepts connections with the following url: ws://<hostname>/<room>.
|
|
214
|
-
Participants in a room can communicate with each other
|
|
215
|
-
"""
|
|
216
|
-
|
|
217
|
-
def __init__(self, port):
|
|
218
|
-
self.port = port
|
|
219
|
-
self.rooms = {}
|
|
220
|
-
self.observers = []
|
|
221
|
-
|
|
222
|
-
def start(self):
|
|
223
|
-
logger.info(f'Starting Relay on port {self.port}')
|
|
224
|
-
|
|
225
|
-
# pylint: disable-next=no-member
|
|
226
|
-
return websockets.serve(self.serve, '0.0.0.0', self.port, ping_interval=None)
|
|
227
|
-
|
|
228
|
-
async def serve_as_controller(self, connection):
|
|
229
|
-
pass
|
|
230
|
-
|
|
231
|
-
async def serve(self, websocket, path):
|
|
232
|
-
logger.debug(f'New connection with path {path}')
|
|
233
|
-
|
|
234
|
-
# Parse the path
|
|
235
|
-
parsed = urlparse(path)
|
|
236
|
-
|
|
237
|
-
# Check if this is a controller client
|
|
238
|
-
if parsed.path == '/':
|
|
239
|
-
return await self.serve_as_controller(Connection('', websocket))
|
|
240
|
-
|
|
241
|
-
# Find or create a room for this connection
|
|
242
|
-
room_name = parsed.path[1:].split('/')[0]
|
|
243
|
-
if room_name not in self.rooms:
|
|
244
|
-
self.rooms[room_name] = Room(self, room_name)
|
|
245
|
-
room = self.rooms[room_name]
|
|
246
|
-
|
|
247
|
-
# Add the connection to the room
|
|
248
|
-
connection = Connection(room, websocket)
|
|
249
|
-
await room.add_connection(connection)
|
|
250
|
-
|
|
251
|
-
# Bridge until the connection is closed
|
|
252
|
-
await room.bridge_connection(connection)
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
# ----------------------------------------------------------------------------
|
|
256
|
-
def main():
|
|
257
|
-
# Check the Python version
|
|
258
|
-
if sys.version_info < (3, 6, 1):
|
|
259
|
-
print('ERROR: Python 3.6.1 or higher is required')
|
|
260
|
-
sys.exit(1)
|
|
261
|
-
|
|
262
|
-
logging.basicConfig(level=os.environ.get('BUMBLE_LOGLEVEL', 'INFO').upper())
|
|
263
|
-
|
|
264
|
-
# Parse arguments
|
|
265
|
-
arg_parser = argparse.ArgumentParser(description='Bumble Link Relay')
|
|
266
|
-
arg_parser.add_argument('--log-level', default='INFO', help='logger level')
|
|
267
|
-
arg_parser.add_argument('--log-config', help='logger config file (YAML)')
|
|
268
|
-
arg_parser.add_argument(
|
|
269
|
-
'--port', type=int, default=DEFAULT_RELAY_PORT, help='Port to listen on'
|
|
270
|
-
)
|
|
271
|
-
args = arg_parser.parse_args()
|
|
272
|
-
|
|
273
|
-
# Setup logger
|
|
274
|
-
if args.log_config:
|
|
275
|
-
from logging import config # pylint: disable=import-outside-toplevel
|
|
276
|
-
|
|
277
|
-
config.fileConfig(args.log_config)
|
|
278
|
-
else:
|
|
279
|
-
logging.basicConfig(level=getattr(logging, args.log_level.upper()))
|
|
280
|
-
|
|
281
|
-
# Start a relay
|
|
282
|
-
relay = Relay(args.port)
|
|
283
|
-
asyncio.get_event_loop().run_until_complete(relay.start())
|
|
284
|
-
asyncio.get_event_loop().run_forever()
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
# ----------------------------------------------------------------------------
|
|
288
|
-
if __name__ == '__main__':
|
|
289
|
-
main()
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
[loggers]
|
|
2
|
-
keys=root
|
|
3
|
-
|
|
4
|
-
[handlers]
|
|
5
|
-
keys=stream_handler
|
|
6
|
-
|
|
7
|
-
[formatters]
|
|
8
|
-
keys=formatter
|
|
9
|
-
|
|
10
|
-
[logger_root]
|
|
11
|
-
level=DEBUG
|
|
12
|
-
handlers=stream_handler
|
|
13
|
-
|
|
14
|
-
[handler_stream_handler]
|
|
15
|
-
class=StreamHandler
|
|
16
|
-
level=DEBUG
|
|
17
|
-
formatter=formatter
|
|
18
|
-
args=(sys.stderr,)
|
|
19
|
-
|
|
20
|
-
[formatter_formatter]
|
|
21
|
-
format=%(asctime)s %(name)-12s %(levelname)-8s %(message)s
|
|
File without changes
|
|
File without changes
|