Title: Error when calculating quantities with all items selected · Issue #4765 · IfcOpenShell/IfcOpenShell · GitHub
Open Graph Title: Error when calculating quantities with all items selected · Issue #4765 · IfcOpenShell/IfcOpenShell
X Title: Error when calculating quantities with all items selected · Issue #4765 · IfcOpenShell/IfcOpenShell
Description: With a blank project created, when calculating quantities for elements by pressing Shift+Q, after selecting all elements in workspace with A keyboard short cut, following error is shown. os: Linux os_version: #35~22.04.1-Ubuntu SMP PREEM...
Open Graph Description: With a blank project created, when calculating quantities for elements by pressing Shift+Q, after selecting all elements in workspace with A keyboard short cut, following error is shown. os: Linux ...
X Description: With a blank project created, when calculating quantities for elements by pressing Shift+Q, after selecting all elements in workspace with A keyboard short cut, following error is shown. os: Linux ...
Opengraph URL: https://github.com/IfcOpenShell/IfcOpenShell/issues/4765
X: @github
Domain: github.com
IPv4 address: 140.82.114.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Error when calculating quantities with all items selected","articleBody":"With a blank project created, when calculating quantities for elements by pressing `Shift+Q`, after selecting all elements in workspace with `A` keyboard short cut, following error is shown.\r\n\r\n```\r\nos: Linux\r\nos_version: #35~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue May 7 09:00:52 UTC 2\r\npython_version: 3.11.7\r\narchitecture: ('64bit', 'ELF')\r\nmachine: x86_64\r\nprocessor: x86_64\r\nblender_version: 4.1.1\r\nblenderbim_version: 0.0.240528\r\nlast_actions: \r\n# operator: BIM_OT_hotkey\r\n# operator: BIM_OT_calculate_all_quantities\r\n# operator: BIM_OT_hotkey\r\n# operator: BIM_OT_calculate_all_quantities\r\n# ifcopenshell.api: pset.edit_qto\r\n>>> {\"qto\": {\"cast_type\": \"entity_instance\", \"value\": 66, \"Name\": \"Qto_BuildingStoreyBaseQuantities\"}, \"properties\": \"{}\"}\r\n# ifcopenshell.api: pset.edit_qto\r\n>>> {\"qto\": {\"cast_type\": \"entity_instance\", \"value\": 68, \"Name\": \"Qto_BuildingBaseQuantities\"}, \"properties\": \"{}\"}\r\n# operator: BIM_OT_hotkey\r\n# operator: BIM_OT_calculate_all_quantities\r\n# ifcopenshell.api: pset.edit_qto\r\n>>> {\"qto\": {\"cast_type\": \"entity_instance\", \"value\": 66, \"Name\": \"Qto_BuildingStoreyBaseQuantities\"}, \"properties\": \"{}\"}\r\n# ifcopenshell.api: pset.edit_qto\r\n>>> {\"qto\": {\"cast_type\": \"entity_instance\", \"value\": 68, \"Name\": \"Qto_BuildingBaseQuantities\"}, \"properties\": \"{}\"}\r\nlast_error: Traceback (most recent call last):\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/ifc.py\", line 360, in execute_ifc_operator\r\n result = getattr(operator, \"_execute\")(context)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/model/workspace.py\", line 591, in _execute\r\n getattr(self, f\"hotkey_{self.hotkey}\")()\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/model/workspace.py\", line 617, in hotkey_S_Q\r\n bpy.ops.bim.calculate_all_quantities()\r\n File \"/snap/blender/4786/4.1/scripts/modules/bpy/ops.py\", line 109, in __call__\r\n ret = _op_call(self.idname_py(), kw)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\nRuntimeError: Error: Python: Traceback (most recent call last):\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/ifc.py\", line 360, in execute_ifc_operator\r\n result = getattr(operator, \"_execute\")(context)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/qto/operator.py\", line 200, in _execute\r\n core.calculate_all_quantities(\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/core/qto.py\", line 48, in calculate_all_quantities\r\n calculate_object_base_quantities(ifc, cost, qto, calculator, obj)\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/core/qto.py\", line 66, in calculate_object_base_quantities\r\n calculated_quantities = qto.get_calculated_object_quantities(calculator, base_quantity_name, obj)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/tool/qto.py\", line 112, in get_calculated_object_quantities\r\n return {\r\n ^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/tool/qto.py\", line 116, in \u003cdictcomp>\r\n and (value := calculator.calculate_quantity(qto_name, quantity_name, obj)) is not None\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/pset/qto_calculator.py\", line 65, in calculate_quantity\r\n value: float = eval(string)\r\n ^^^^^^^^^^^^\r\n File \"\u003cstring>\", line 1, in \u003cmodule>\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/pset/qto_calculator.py\", line 317, in get_gross_perimeter\r\n mesh = self.get_gross_element_mesh(element)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/pset/qto_calculator.py\", line 1221, in get_gross_element_mesh\r\n return self.create_mesh_from_shape(element, settings)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/bim/module/pset/qto_calculator.py\", line 1228, in create_mesh_from_shape\r\n shape = ifcopenshell.geom.create_shape(settings, element)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/libs/site/packages/ifcopenshell/geom/main.py\", line 242, in create_shape\r\n ifcopenshell_wrapper.create_shape(settings, inst.wrapped_data, repr.wrapped_data if repr is not None else None),\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\n File \"/home/eee/.config/blender/4.1/scripts/addons/blenderbim/libs/site/packages/ifcopenshell/ifcopenshell_wrapper.py\", line 2083, in create_shape\r\n return _ifcopenshell_wrapper.create_shape(settings, instance, representation)\r\n ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\r\nRuntimeError: Representation is NULL\r\nLocation: /snap/blender/4786/4.1/scripts/modules/bpy/ops.py:109\r\n\r\n\r\nifc: Unsaved\r\nschema: IFC4\r\npreprocessor_version: IfcOpenShell v0.7.0-f7c03db75\r\noriginating_system: IfcOpenShell v0.7.0-f7c03db75\r\n```\r\n\r\nOn further probing it is observed that error occurs when `IfcSite` element is selected when calculation of quantities are performed.","author":{"url":"https://github.com/manuvarkey","@type":"Person","name":"manuvarkey"},"datePublished":"2024-05-30T11:02:15Z","url":"https://github.com/IfcOpenShell/IfcOpenShell/issues/4765"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:78d22ac4-6bc1-5156-92da-9fa949085549 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A0C4:E046C:AE236B:F33F64:6B048A30 |
| html-safe-nonce | 61673d6f16a39aa0506bd9858dae041af1fbb87939d785fe2c394abd9c66254a |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMEM0OkUwNDZDOkFFMjM2QjpGMzNGNjQ6NkIwNDhBMzAiLCJ2aXNpdG9yX2lkIjoiODg3ODgwODg5NzIxMzk5MTQ3MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | a8282e67efba1b9f08c0d6e3805505d36f2eb232c738bce4101f8502b1118723 |
| hovercard-subject-tag | issue:2325371252 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/IfcOpenShell/IfcOpenShell/4765/issue_layout |
| twitter:image | https://opengraph.githubassets.com/c2de98172cf1a2d7bfe2a1332c8cbf539ff7530929b27b342e9927373f8d307d/IfcOpenShell/IfcOpenShell/issues/4765 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/c2de98172cf1a2d7bfe2a1332c8cbf539ff7530929b27b342e9927373f8d307d/IfcOpenShell/IfcOpenShell/issues/4765 |
| og:image:alt | With a blank project created, when calculating quantities for elements by pressing Shift+Q, after selecting all elements in workspace with A keyboard short cut, following error is shown. os: Linux ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | manuvarkey |
| hostname | github.com |
| expected-hostname | github.com |
| None | 1d5c152376e38b7d2e37f3d5179be29a73bee93b85110da28a4eebe1159cdc70 |
| turbo-cache-control | no-preview |
| go-import | github.com/IfcOpenShell/IfcOpenShell git https://github.com/IfcOpenShell/IfcOpenShell.git |
| octolytics-dimension-user_id | 13692563 |
| octolytics-dimension-user_login | IfcOpenShell |
| octolytics-dimension-repository_id | 40473201 |
| octolytics-dimension-repository_nwo | IfcOpenShell/IfcOpenShell |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 40473201 |
| octolytics-dimension-repository_network_root_nwo | IfcOpenShell/IfcOpenShell |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | f5017e8ff4ea25a8011fcf0f2a0e430c60dc86c8 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width