mozilla/mozdownload — pull request #99 by davehunt (2013-07-16 13:39:02+00:00)
Title: Filter potential build dirs by whether or not they contain a build

I've rebased and updated @mykmelez's pull #47 for inclusion in mozdownload. I've also tested it, and it's working well. Below is example output.

With patch applied:
```bash
$ mozdownload --type=daily --date=2013-07-02
Retrieving list of builds from https://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2013/07/
Downloading from: https://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2013/07/2013-07-02-11-03-00-mozilla-central/firefox-25.0a1.en-US.mac.dmg
```

Without patch applied:
```bash
$ mozdownload --type=daily --date=2013-07-02
Retrieving list of builds from https://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2013/07/
Traceback (most recent call last):
File "/Users/dhunt/.virtualenvs/mozdownload/bin/mozdownload", line 8, in
load_entry_point('mozdownload==1.7.2', 'console_scripts', 'mozdownload')()
File "/Users/dhunt/workspace/mozdownload/mozdownload/scraper.py", line 935, in cli
build.download()
File "/Users/dhunt/workspace/mozdownload/mozdownload/scraper.py", line 233, in download
if os.path.isfile(os.path.abspath(self.target)):
File "/Users/dhunt/workspace/mozdownload/mozdownload/scraper.py", line 193, in target
self.build_filename(self.binary))
File "/Users/dhunt/workspace/mozdownload/mozdownload/scraper.py", line 145, in binary
self.path)
mozdownload.scraper.NotFoundError: Binary not found in folder: https://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/2013/07/2013-07-02-15-30-59-mozilla-central
```