Skip to content

IfcImporter leaves out list, bounded, enumerated and table properties, so property sets point at items with no data #323

Closed

Description

@helenkwok

Summary

ifcClasses.properties in IfcImporter holds IFCPROPERTYSET, IFCPROPERTYSINGLEVALUE and the quantities, so IfcPropertyListValue, IfcPropertyBoundedValue, IfcPropertyEnumeratedValue (and its IfcPropertyEnumeration) and IfcPropertyTableValue are not imported. The property set still lists their ids in HasProperties, so getItemsData returns them as items with _category: null and no attributes. Their names and values are lost, and code that expects a Name on every property crashes (engine_components#827: the IDS property facet throws on 19 of buildingSMART's IDS test cases).

Reproduce

resources/ifc/property-values.ifc (added in the PR: one property set with a list, a bounded, an enumerated and a table property) converted with the default importer: none of the four properties has a category or data. Adding the five classes with importer.classes.abstract.add(...) gives, for example, ListValues: { value: ["A", "B"], type: "IFCLABEL" } and LowerBoundValue / UpperBoundValue / SetPointValue as separate attributes, so the existing attribute serialization already handles them.

Fix

Add the five classes to ifcClasses.properties. PR to follow. Reference and complex properties are left out: IDS treats them as unsupported, and a complex property's nested properties need more thought.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions