diff options
author | Ian Kelling <iank@fsf.org> | 2018-06-05 00:44:23 -0400 |
---|---|---|
committer | Ian Kelling <iank@fsf.org> | 2018-06-05 00:44:23 -0400 |
commit | 16ce915aac7add2650aa539a3f1428da358ee337 (patch) | |
tree | 2dbed69c59625f823a1dcd0d9e6a404d81128dac /export.py | |
parent | bf52ba26d47054ed0619eb4f67f5f167f39ad5f8 (diff) |
fix export.py error, add example output
Diffstat (limited to 'export.py')
-rw-r--r-- | export.py | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -294,7 +294,11 @@ def export_srcpkgs(data, name, srcpkg_names): res.extend(list(extract_resources(pkg_cps))) pkg_cl = data.cl[data.cl['_srcpkg'] == srcpkg] - cl_date = pkg_cl['date'][0] + cl_date = pkg_cl['date'] + # avoid rare bad index error: + if cl_date.empty: + continue + cl_date = cl_date[0] cl_uploader = pkg_cl['author'][0] for template in srcpkg_extract_licenses( pkg_cps, pkg_cpf, pkg_licenses, cl_date, cl_uploader): @@ -413,4 +417,3 @@ def main(): if __name__ == '__main__': main() - |