Problem/Motivation
When offline, the OEmbed provider throws an exception, which is not passed to the user.
The website encountered an unexpected error. Please try again later.
Drupal\media\OEmbed\ProviderException: Could not retrieve the oEmbed provider database from https://oembed.com/providers.json in Drupal\media\OEmbed\ProviderRepository->getAll() (line 85 of core/modules/media/src/OEmbed/ProviderRepository.php).
Steps to reproduce
Have a media type remote video enabled and try to quick-edit a remote video on the overview page,
or add a new media in the field widget.
Proposed resolution
Catch the exception and pass it to the user, so that the AJAX call does not return HTTP 500.
Comments
Comment #2
ytsurkComment #3
ytsurkCatching and passing the error on.
Comment #5
ytsurk