chbrown / overdrive

Bash script to download mp3s from the OverDrive audiobook service

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Check that files in MEDIA array exist

chbrown opened this issue · comments

Current behavior is just to assume all supplied paths are good; if a path is missing, xmllint will fail with a cryptic error message:

$ overdrive download DoesNotExist.odm
Generating random ClientID=B49967C8-61F8-4365-88E0-F5C822B13235
warning: failed to load external entity "DoesNotExist.odm"

This is an unusual error case, but when it does arise, the fatal "warning" can be confusing / misleading, and the proper solution of explicitly checking for existence as a preliminary step is trivial.

See, e.g., #40, comments 3–4.