Skip to content

IfcOpenShell 0.8.3-post2 3.9 using none supported python language feature. #7363

@xz-autodesk

Description

@xz-autodesk

Bug Description

  1. install python 3.9.16
  2. install ifcopenshell pip install ifcopenshell
  3. Run the ifcopenshell command below:
python -m ifcopenshell.simple_spf --json "D:\some.ifc"

we will get error:

Traceback (most recent call last):
  File "<somewhere_of_my_root_dir>\Tools\python-win-intel64-3.9.16\lib\runpy.py", line 188, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "<somewhere_of_my_root_dir>\Tools\python-win-intel64-3.9.16\lib\runpy.py", line 147, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "<somewhere_of_my_root_dir>\Tools\python-win-intel64-3.9.16\lib\runpy.py", line 111, in _get_module_details
    __import__(pkg_name)
  File "<somewhere_of_my_root_dir>\Tools\python-win-intel64-3.9.16\lib\site-packages\ifcopenshell\simple_spf\__init__.py", line 14, in <module>
    from .mvd_info import MvdInfo, LARK_AVAILABLE
  File "<somewhere_of_my_root_dir>\Tools\python-win-intel64-3.9.16\lib\site-packages\ifcopenshell\simple_spf\mvd_info.py", line 112, in <module>
    def parse_semicolon_separated_kv(text: str) -> dict[str, str | list[str]] | None:
TypeError: unsupported operand type(s) for |: 'type' and 'types.GenericAlias'

Attachments

No response

Debug and Error Output


Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions