Commit
•
14347eb
1
Parent(s):
6f48f23
Changed an Exception type
Browse files- super_eurlex.py +4 -1
super_eurlex.py
CHANGED
@@ -349,6 +349,9 @@ class SuperEurlexConfig(datasets.BuilderConfig):
|
|
349 |
self.citation = citation
|
350 |
self.url = url
|
351 |
|
|
|
|
|
|
|
352 |
# TODO: Name of the dataset usually matches the script name with CamelCase instead of snake_case
|
353 |
class SuperEurlex(datasets.GeneratorBasedBuilder):
|
354 |
"""TODO: Short description of my dataset."""
|
@@ -410,7 +413,7 @@ class SuperEurlex(datasets.GeneratorBasedBuilder):
|
|
410 |
try:
|
411 |
data_dir = dl_manager.download_and_extract(urls)
|
412 |
except FileNotFoundError:
|
413 |
-
raise
|
414 |
It could be that the demanded sector isn't yet available in your language of choice""")
|
415 |
return [
|
416 |
datasets.SplitGenerator(
|
|
|
349 |
self.citation = citation
|
350 |
self.url = url
|
351 |
|
352 |
+
class FileNotFoundException(Exception):
|
353 |
+
pass
|
354 |
+
|
355 |
# TODO: Name of the dataset usually matches the script name with CamelCase instead of snake_case
|
356 |
class SuperEurlex(datasets.GeneratorBasedBuilder):
|
357 |
"""TODO: Short description of my dataset."""
|
|
|
413 |
try:
|
414 |
data_dir = dl_manager.download_and_extract(urls)
|
415 |
except FileNotFoundError:
|
416 |
+
raise FileNotFoundException("""The demanded Files weren't found.
|
417 |
It could be that the demanded sector isn't yet available in your language of choice""")
|
418 |
return [
|
419 |
datasets.SplitGenerator(
|