Skip to content
This repository has been archived by the owner on Jun 10, 2020. It is now read-only.

Harvester: Throws errors for invalid files, even when no harvest.yml file is present #53

Open
atruskie opened this issue Feb 20, 2017 · 0 comments

Comments

@atruskie
Copy link
Member

In a multistage harvest, where some directories that are full of audio files but do net yet have harvest.yml files, there is an attempt to try and parse file's date time anyway.

The result is an exception of the form:

2017-02-20T06:03:09.453+0000 [ERROR-BawWorkers::Harvest::GatherFiles-022503] Problem getting details for .../data_prod/harvester_to_do/.../015408_20161103_210000.wav using utc offset '': Error: No UTC offset provided and file name did not contain a utc offset.
Backtrace: .../baw-workers_production/lib/baw-workers/file_info.rb:174:in `block in file_name_datetime'
.../baw-workers_production/lib/baw-workers/file_info.rb:166:in `scan'
.../baw-workers_production/lib/baw-workers/file_info.rb:166:in `file_name_datetime'
.../baw-workers_production/lib/baw-workers/file_info.rb:96:in `advanced'
.../baw-workers_production/lib/baw-workers/harvest/gather_files.rb:173:in `file_info'
.../baw-workers_production/lib/baw-workers/harvest/gather_files.rb:150:in `file'
.../baw-workers_production/lib/baw-workers/harvest/gather_files.rb:89:in `block in process'
.../baw-workers_production/lib/baw-workers/harvest/gather_files.rb:88:in `each'
2017-02-20T06:03:09.453+0000 [ WARN-BawWorkers::Harvest::GatherFiles-022503] Not enough information for .../data_prod/harvester_to_do/.../015408_20161103_210000.wav.

Expected behaviour

For directories where there is no harvest.yml file, the audio should be ignored and an exception should not be thrown

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant