- edited description
Error while importing HD mesh
Hello!
I started to receive that message for some characters while doing HD import (non HD works fine).
Python: Traceback (most recent call last):
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\error.py", line 223, in execute
self.run(context)
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\main.py", line 758, in run
self.easyImport(context)
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\main.py", line 767, in easyImport
bpy.ops.daz.import_daz_manually(
File "D:\Steam\steamapps\common\Blender\4.0\scripts\modules\bpy\ops.py", line 109, in call
ret = _op_call(self.idname_py(), kw)
RuntimeError: Error: Python: Traceback (most recent call last):
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\error.py", line 223, in execute
self.run(context)
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\main.py", line 287, in run
self.loadDazFile(filepath, context)
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\main.py", line 182, in loadDazFile
inst.finalize(context)
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\figure.py", line 100, in finalize
geonode.hideVertexGroups(self.hiddenBones.keys())
File "C:\Users\whatever\AppData\Roaming\Blender Foundation\Blender\4.0\scripts\addons\import_daz\geometry.py", line 508, in hideVertexGroups
self.data.hidePolyGroup(self.hdobject.rna, fnums)
AttributeError: 'Object' object has no attribute 'rna'
Location: D:\Steam\steamapps\common\Blender\4.0\scripts\modules\bpy\ops.py:109
I use last version of plugin for daz_importer and mhx runtime system from master branch.
Daz version - 4.22
Blender - 4.0
Replacing this condition:
if self.hdobject and self.hdobject != self.rna:
self.data.hidePolyGroup(self.hdobject.rna, fnums)
to this:
if self.hdobject and hasattr(self.hdobject, "rna") and self.hdobject != self.rna:
self.data.hidePolyGroup(self.hdobject.rna, fnums)
fix the issue. But im not sure it will not cause other bugs in another scenarios and why we expect to "nra" property be exist in object without that field. May be some initialization steps was missed for some cases?
Can you clarify please?
Comments (5)
-
reporter -
repo owner - changed status to open
-
repo owner The crash should be fixed in the latest commit. It happened if there are hidden polygon groups in DS. In that case the plugin replaces the material of the hidden polygons with a transparent material. I’m not sure if it is such a good idea.
-
Thomas, that’s
#516. -
- changed status to resolved
- Log in to comment