format code
authorJacob Lifshay <programmerjake@gmail.com>
Mon, 20 Jun 2022 04:23:47 +0000 (21:23 -0700)
committerJacob Lifshay <programmerjake@gmail.com>
Mon, 20 Jun 2022 04:23:47 +0000 (21:23 -0700)
src/budget_sync/main.py
src/budget_sync/update.py

index b4c35c93e44f17e8be88a5ab49b31ec24fb84a61..e2e39d7280ec8e44f19072333ef9d43c1186d37e 100644 (file)
@@ -53,14 +53,14 @@ def print_budget_then_children(indent, nodes, bug_id):
     """
 
     bug = nodes[bug_id]
-    print("bug #%5d %s budget %7s excltasks %7s" % \
-            (bug.bug.id, ' ' * (indent*4),
-             str(bug.budget_including_subtasks),
-             str(bug.budget_excluding_subtasks)))
+    print("bug #%5d %s budget %7s excltasks %7s" %
+          (bug.bug.id, ' ' * (indent*4),
+           str(bug.budget_including_subtasks),
+           str(bug.budget_excluding_subtasks)))
     #print (repr(bug))
     for child in bug.immediate_children:
         if (str(child.budget_including_subtasks) == "0" and
-             str(child.budget_excluding_subtasks) == "0"):
+                str(child.budget_excluding_subtasks) == "0"):
             continue
         print_budget_then_children(indent+1, nodes, child.bug.id)
 
@@ -73,7 +73,7 @@ def summarize_milestones(budget_graph: BudgetGraph):
               f"{summary.total_submitted} paid: {summary.total_paid}")
         not_submitted = summary.get_not_submitted()
         if not_submitted:
-            print ("not submitted", not_submitted)
+            print("not submitted", not_submitted)
 
         # and one to display people
         for person in budget_graph.milestone_people[milestone]:
@@ -87,5 +87,6 @@ def summarize_milestones(budget_graph: BudgetGraph):
                                    milestone.canonical_bug_id)
         print()
 
+
 if __name__ == "__main__":
     main()
index c6bcbdd1d6ed39822897160211fcf91b6aff6e94..51e765762a6f31a51670b65c323af7fb0c8e0c79 100644 (file)
@@ -12,6 +12,7 @@ from datetime import datetime, date
 
 logging.basicConfig(level=logging.INFO)
 
+
 def main():
     parser = argparse.ArgumentParser(
         description="Check for errors in "
@@ -48,8 +49,8 @@ def main():
     buglist = bz.getbugs(bugs)
     logging.info("got bugs %s" % args.bug)
     for bug in buglist:
-        print ("payees", bug.id)
-        print ("    "+"\n    ".join(bug.cf_payees_list.split('\n')))
+        print("payees", bug.id)
+        print("    "+"\n    ".join(bug.cf_payees_list.split('\n')))
 
         parsed_toml = toml.loads(bug.cf_payees_list)
 
@@ -82,5 +83,6 @@ def main():
         #update = bz.build_update(cf_payees_list=ttxt)
         bz.update_bugs([bug.id], {'cf_payees_list': ttxt})
 
+
 if __name__ == "__main__":
     main()