[web-nfc] Notify NFCReaders of failures when trying to get a message from a tag? (#279)

leonhsl has just created a new issue for https://github.com/w3c/web-nfc:

== Notify NFCReaders of failures when trying to get a message from a tag? ==
See
https://developer.android.com/reference/android/nfc/tech/Ndef.html#getNdefMessage().
Once a tag is discovered, we call `android.nfc.tech.Ndef.getNdefMessage()` to try to get a message from it, which may
  - return null if the tag is in the `INITIALIZED` state, i.e. formatted but empty
  - throw exceptions: `TagLostException,` `IOException,` or `FormatException`

In such cases do we need to let all active `NFCReaders` be aware of these failures so that they can choose how to proceed next? i.e. dispatching some error events properly to `NFCReaders.`

Currently http://w3c.github.io/web-nfc/#the-nfc-reading-algorithm only describes the case that a ndef message has already been gotten from the tag, so does the implementation in Chromium.

Please view or discuss this issue at https://github.com/w3c/web-nfc/issues/279 using your GitHub account

Received on Tuesday, 6 August 2019 03:33:58 UTC