Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Proper error codes #53

Closed
cookpete opened this issue Apr 13, 2016 · 6 comments
Closed

Proper error codes #53

cookpete opened this issue Apr 13, 2016 · 6 comments

Comments

@cookpete
Copy link
Owner

Further to #44, there is a need for more robust onError return values to align the different problems that can occur with the different players.

@rijk
Copy link
Contributor

rijk commented Sep 25, 2017

Also, the onError is not called when the URL returns a 404 (example: https://vimeo.com/235229611) or is not embeddable (403, example: https://vimeo.com/161597420).

Uncaught (in promise) Error: “https://vimeo.com/161597420” is not embeddable.
    at XMLHttpRequest.a.onload (player.js:2)

@rijk
Copy link
Contributor

rijk commented Sep 25, 2017

Above possibly related to vimeo/player.js#57

@rijk
Copy link
Contributor

rijk commented Oct 2, 2017

Here's a way to catch those errors: vimeo/player.js#165 (comment)

Should I make a PR?

@cookpete
Copy link
Owner Author

cookpete commented Oct 2, 2017

Also, the onError is not called when the URL returns a 404

This is now sorted by d34d228, but there is still a bug with the Vimeo API that renders the player useless after the initial error occurs: vimeo/player.js#166.

@rijk
Copy link
Contributor

rijk commented Oct 2, 2017

Yeah, the Vimeo player is pretty crap. I submitted like 4 issues in the last week 😛

@cookpete
Copy link
Owner Author

Closing this off for now as it is a very old issue that doesn't serve much of a purpose any more. Each player has an entirely different set of errors and things that can possibly go wrong. The current behaviour of just passing these errors through to onError is good enough for nearly 100% of use cases. The effort required to try and reconcile every possible error from every player into a common set just doesn't seem to justify the benefit.

If any problems come up regarding a specific error, then people can open a separate issue for it. PRs to improve error handling are always welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants