File tree Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Expand file tree Collapse file tree 2 files changed +3
-4
lines changed Original file line number Diff line number Diff line change 26
26
from typing import Any
27
27
28
28
from etils import epath
29
- from tensorflow_datasets.core.utils import py_utils
30
29
from tensorflow_datasets.core.utils import version as version_lib
31
30
32
31
_NAME_CLASS = r'[a-zA-Z][\w]*'
@@ -185,8 +184,9 @@ def _dataset_name_and_kwargs_from_name_str(
185
184
raise ValueError('Dataset %s: cannot pass %s twice.' % (name, attr))
186
185
kwargs[attr] = val
187
186
return name, kwargs
188
- except Exception as e: # pylint: disable=broad-except
189
- py_utils.reraise(e, prefix=err_msg) # pytype: disable=bad-return-type
187
+ except Exception as e:
188
+ e.add_note(err_msg)
189
+ raise e
190
190
191
191
192
192
@dataclasses.dataclass(order=True)
Original file line number Diff line number Diff line change 24
24
from tensorflow_datasets.core import constants
25
25
from tensorflow_datasets.core import naming
26
26
from tensorflow_datasets.core.utils import file_utils
27
- from tensorflow_datasets.core.utils import read_config
28
27
29
28
_DATA_DIR = epath.Path('/a')
30
29
_DATASET_NAME = 'my_ds'
You can’t perform that action at this time.
0 commit comments