MicrosoftEdge / MicrosoftEdge/MSEdgeExplainers

[Web Install] Error types

Open
#898 4 comments 0 reactions 1 assignee View on GitHub

@diekus is already working on this.

Since Oct 22, 2024.

Web Install API
Dominant language
HTML
Stars
1.4k
Forks
286
Avg merge
3d 1h
Merged PRs (30d)
8

Description

We once had had a detailed list of error types which was later pruned down to a single AbortError to represent all failure types whether they were related to the user aborting an action or not. Although this may be beneficial for privacy, it poses usability issues as the developer can't tell the difference between bad inputs, user action/cancellation, and misc other technical mishaps. Instead, here is a proposed list of minimal errors that balance usability and privacy:

DOMExceptions:

  • InvalidStateError:
    • When used outside of the main frame
  • NotAllowedError:
    • When used without user activation
    • Invalid inputs (e.g. install url isn't a valid url)
  • AbortError
    • User aborts installation when prompted
    • Browser aborts installation due to privacy settings

Custom rejection messages:

  • ManifestIdMismatch: when the provided id param doesn't match the app's id
  • NoIdInManifest: For same-origin only. When the app's manifest does not declare a valid id

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.