Run black, and add black to a "qa" target to make it a standardised process.

This commit is contained in:
Dion Moult
2021-09-09 21:27:23 +10:00
parent 95903c965d
commit 865c0f4895
305 changed files with 1968 additions and 1143 deletions
@@ -9,8 +9,11 @@ class Usecase:
self.settings[key] = value
def execute(self):
self.file.create_entity("IfcRelFillsElement", **{
"GlobalId": ifcopenshell.guid.new(),
"RelatingOpeningElement": self.settings["opening"],
"RelatedBuildingElement": self.settings["element"]
})
self.file.create_entity(
"IfcRelFillsElement",
**{
"GlobalId": ifcopenshell.guid.new(),
"RelatingOpeningElement": self.settings["opening"],
"RelatedBuildingElement": self.settings["element"],
}
)
@@ -10,9 +10,12 @@ class Usecase:
self.settings[key] = value
def execute(self):
self.file.create_entity("IfcRelVoidsElement", **{
"GlobalId": ifcopenshell.guid.new(),
"OwnerHistory": ifcopenshell.api.run("owner.create_owner_history", self.file),
"RelatingBuildingElement": self.settings["element"],
"RelatedOpeningElement": self.settings["opening"]
})
self.file.create_entity(
"IfcRelVoidsElement",
**{
"GlobalId": ifcopenshell.guid.new(),
"OwnerHistory": ifcopenshell.api.run("owner.create_owner_history", self.file),
"RelatingBuildingElement": self.settings["element"],
"RelatedOpeningElement": self.settings["opening"],
}
)
@@ -40,9 +40,9 @@ class Data:
cls.fillings[filling_id] = {"Name": filling.Name, "FillsVoid": opening_id}
cls.openings[opening_id]["HasFillings"].add(filling_id)
return # See bug #1224
#if not hasattr(product, "HasOpenings") or not product.HasOpenings:
# if not hasattr(product, "HasOpenings") or not product.HasOpenings:
# return
#for rel_voids_element in product.HasOpenings:
# for rel_voids_element in product.HasOpenings:
# opening = rel_voids_element.RelatedOpeningElement
# opening_id = int(opening.id())
# fillings = []