[PATCH olpc-os-builder 02/14] Don't choke on 404 errors for activity pages

Daniel Drake dsd at laptop.org
Thu Mar 17 15:31:32 EDT 2011


Thanks for the patch

> @@ -154,7 +154,10 @@ def parse_url(url, **urlopen_args):
>     `bitfrost.util.urlrange.urlopen`."""
>     import bitfrost.util.urlrange as urlrange
>     with urlrange.urlopen(url, **urlopen_args) as f:
> -        return parse_html(f.read(), f.url)
> +       try:
> +            return parse_html(f.read(), f.url)
> +       except urllib2.HTTPError:
> +            return None, None, []

Whats the rationale here?
If an invalid activity group URL is passed, olpc-os-builder should
exit with error.
I don't see the value in silently continuing and producing a build
with missing activities.

Daniel



More information about the Devel mailing list