Skip to content

Commit

Permalink
Removed int requirement from Epoch string (#123)
Browse files Browse the repository at this point in the history
* Removed int requirement from Epoch string

* Fixed download epoch

* Fix find fields ada issue #120
  • Loading branch information
ajstewart authored Mar 2, 2020
1 parent 808e301 commit 942bdcf
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
4 changes: 2 additions & 2 deletions bin/get_vast_pilot_dbx.py
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ def filter_files_list(
epochs = []
for i in base_file_list.entries:
if isinstance(i, dropbox.files.FolderMetadata) and "EPOCH" in i.name:
epochs.append(int(i.name.split('EPOCH')[-1]))
epochs.append(i.name.split('EPOCH')[-1])
dropbox_name = RELEASED_EPOCHS[args.download_epoch]
if dropbox_name not in epochs:
logger.error(
Expand All @@ -489,7 +489,7 @@ def filter_files_list(
logger.info(
"Gathering {} files to download...".format(epoch_string))
files_list, folders_list = vast_dropbox.recursive_build_files(
epoch_file_list, dbx, preappend=epoch_string)
epoch_file_list, preappend=epoch_string)
logger.info("{} files to download".format(len(files_list)))

for folder in folders_list:
Expand Down
2 changes: 1 addition & 1 deletion vasttools/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
'''

__author__ = 'Dougal Dobie, Adam Stewart'
__version__ = "1.1.0"
__version__ = "1.1.1"
7 changes: 4 additions & 3 deletions vasttools/query.py
Original file line number Diff line number Diff line change
Expand Up @@ -573,9 +573,10 @@ def __init__(self, args, pilot_epoch, stokes_param):

if not BASE_FOLDER:
if HOST != HOST_ADA:
self.logger.critical(
"Base folder must be specified if not running on ada")
sys.exit()
if not FIND_FIELDS:
self.logger.critical(
"Base folder must be specified if not running on ada")
sys.exit()
BASE_FOLDER = "/import/ada1/askap/"

if not IMAGE_FOLDER:
Expand Down

0 comments on commit 942bdcf

Please sign in to comment.