MCPcopy Create free account
hub / github.com/IfcOpenShell/IfcOpenShell / assert_number

Function assert_number

src/ifcbimtester/bimtester/util.py:54–58  ·  view source on GitHub ↗
(number)

Source from the content-addressed store, hash-verified

52
53
54def assert_number(number):
55 try:
56 return float(number)
57 except ValueError:
58 assert False, _("A number should be specified, not {}").format(number)
59
60
61def assert_type(element, ifc_class, is_exact=False):

Callers

nothing calls this directly

Calls 2

_Function · 0.90
formatMethod · 0.80

Tested by

no test coverage detected