- changes_files = init()
-
- examine_package.use_html=1
-
- for changes_file in changes_files:
- changes_file = daklib.utils.validate_changes_file_arg(changes_file, 0)
- if not changes_file:
- continue
- print "\n" + changes_file
- do_pkg (changes_file)
- files = set(os.listdir(Cnf["Show-New::HTMLPath"]))
- to_delete = filter(lambda x: x.endswith(".html"), files.difference(sources))
- for file in to_delete:
- os.remove(os.path.join(Cnf["Show-New::HTMLPath"],file))
+ examine_package.use_html = True
+ pool = DakProcessPool(processes=5)
+
+ session = DBConn().session()
+ upload_ids = [ u.id for u in init(session) ]
+ session.close()
+
+ for upload_id in upload_ids:
+ pool.apply_async(do_pkg, [upload_id])
+ pool.close()
+
+ #p.wait(timeout=600)
+ pool.join()
+ for htmlfile in htmlfiles_to_process:
+ with open(htmlfile, "w") as fd:
+ fd.write(timeout_str)
+
+ files = set(os.listdir(cnf["Show-New::HTMLPath"]))
+ to_delete = filter(lambda x: x.endswith(".html"), files.difference(set(sources)))
+ for f in to_delete:
+ os.remove(os.path.join(cnf["Show-New::HTMLPath"],f))