[web-bluetooth] Bluetooth device connection promise not resolving if device times out
メンテナーはふだん 13 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 38/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- javascript
調査の方向性
automatic-reconnect.html にある web-bluetooth/automatic-reconnect の例を開き、macOS 上の Chrome 79 で Wahoo センサーのタイムアウトシーケンスを再現します。まず、gattserverdisconnected の後の再接続フローと、bluetoothDevice.gatt.disconnect() の後の動作を比較します。タイムアウトした bluetoothDevice.gatt.connect() によって requestDevice() の chooser が停止したままにならず、接続 promise が定義された結果に到達すれば完了です。
索引モデルが issue の本文から書いたものです。
説明
There seems to be a bug in the web-bluetooth/automatic-reconnect example or in the way web bluetooth is implemented in Chrome.
I have already filed a bug-report for Chrome, but since this may relate to API changes the bug may be caused by the fact that the sample code is out of date.
The problem:
Bluetooth device connection promise not resolving if device times out.
Steps to reproduce the problem:
- Launch Chrome
- Go to: https://googlechrome.github.io/samples/web-bluetooth/automatic-reconnect.html
- Click Scan button
- Select BTLE device
(Tested with Wahoo Cadence Sensor and Wahoo Heart Rate Sensor) - Wait for the device to connect
- Let the sensor rest until it disconnects
- Wait for the 'gattserverdisconnected' event to be triggered and the first reconnect cycle to start
- The program will stall and the requestDevice() chooser will stop responding
What is the expected behavior?
The bluetoothDevice.gatt.connect() call should time out after some time if the client can not connect to the server. This does happen if the client disconnects but not the server (The BT device).
What went wrong?
The bluetoothDevice.gatt.connect() Promise seems to never get resolved. This does only happen if the device times out. If the device is removed via bluetoothDevice.gatt.disconnect() the API behaves as expected.
Chrome version: 79.0.3945.130 Channel: stable
OS Version: OS X 10.15.2
- 主要言語
- JavaScript
- スター
- 5.9k
- フォーク
- 2.4k
- 平均マージ
- 12日 12時間
- マージ済み PR(30日)
- 1
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
GoogleChrome/samples のほかの issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 15/100
GoogleChrome/samples#957 · コメント 2 件 ·
メンテナーはふだん 13 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 35/100
GoogleChrome/samples#876 · リアクション 1 件 ·
メンテナーはふだん 13 日以内に返信
-
難易度 3/5 1〜2日 初心者へのやさしさ 45/100
GoogleChrome/samples#869 · リアクション 1 件 ·
メンテナーはふだん 13 日以内に返信
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
GoogleChrome/samples#836 · リアクション 1 件 ·
メンテナーはふだん 13 日以内に返信
-
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
GoogleChrome/samples#827 ·
メンテナーはふだん 13 日以内に返信
GoogleChrome/samples の issue をすべて見る
似ている issue
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
thunderbird/services-ui#365 ·
メンテナーはふだん 1 日以内に返信
-
Add: Explorisオープンchannels:add check:passed
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
PolicyEngine/ai-inequality#64 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 73/100