Skip to content

Commit

Permalink
Drop list of default excludes (hoechenberger#65)
Browse files Browse the repository at this point in the history
  • Loading branch information
hoechenberger authored Oct 4, 2022
1 parent 02400ae commit 7c48465
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 39 deletions.
22 changes: 0 additions & 22 deletions openneuro/default_excludes.json

This file was deleted.

17 changes: 0 additions & 17 deletions openneuro/download.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,6 @@
from . import __version__
from .config import default_base_url

DEFAULT_EXCLUDES = json.loads(
(Path(__file__).parent / 'default_excludes.json')
.read_text(encoding='utf-8')
)


if hasattr(sys.stdout, 'encoding') and sys.stdout.encoding.lower() == 'utf-8':
stdout_unicode = True
Expand Down Expand Up @@ -584,18 +579,6 @@ def download(*,
exclude = [exclude] if isinstance(exclude, str) else exclude
exclude = [] if exclude is None else list(exclude)

for dataset_default_excludes in DEFAULT_EXCLUDES:
if dataset_default_excludes['datasetName'] == dataset:
msg = f'Adding default excludes for dataset {dataset}: \n '
msg += '\n '.join(dataset_default_excludes['excludeFiles'])
if stdout_unicode:
msg = f'🤕 {msg}'
tqdm.write(msg)
exclude = list(
set(exclude + dataset_default_excludes['excludeFiles'])
)
break

retry_backoff = 0.5 # seconds
metadata = _get_download_metadata(base_url=default_base_url,
dataset_id=dataset,
Expand Down

0 comments on commit 7c48465

Please sign in to comment.