tf.data.Dataset.save deadlocks on error 
Hi @nmatare ,

Thanks for your time in reporting this. I have replicated the issue with tf-nightly as well. I observed dead lock and proposed work around with `dataset = dataset.ignore_errors()` works here. Attached [gist](https://colab.sandbox.google.com/gist/SuryanarayanaY/e5101988b8f68a39f907faaf7643c012/61736.ipynb) here for reference.

Since other methods like `dataset.as_numpy_iterator()` works fine by raising the intended exception even without `dataset = dataset.ignore_errors()` , I believe this might be a bug that can be resolvable. Escalating to Dev team for their review.

Thanks!

### Issue type

Bug

### Have you reproduced the bug with TensorFlow Nightly?

Yes

### Source

source

### TensorFlow version

v2.13.0-rc2-7-g1cb1a030a62 2.13.0

### Custom code

Yes

### OS platform and distribution

Linux

### Mobile device

_No response_

### Python version

3.8.17

### Bazel version

_No response_

### GCC/compiler version

_No response_

### CUDA/cuDNN version

_No response_

### GPU model and memory

_No response_

### Current behavior?

When saving a dataset to disk, TF will silently brick if there's an error in the data input pipeline. Methinks it should rather raise on the save instead of deadlocking.

Here's a reproducible example:

```python
import tensorflow as tf
# '2.13.0'

dataset = tf.data.Dataset.from_tensor_slices([1., 2., 0., 4.])
dataset = dataset.map(lambda x: tf.debugging.check_numerics(1. / x, "error"))
dataset.save('/tmp/hello')
# => deadlock
```

You can add an `ignore_errors` to the pipeline and it'll rightfully ignore, but it's nonintuitive to track down why the input bricks. 

```python
dataset = dataset.ignore_errors()
# => OK save
```

### Standalone code to reproduce the issue

```shell
See above.
```


### Relevant log output

_No response_