Import and Update a 3D asset, path is not iterable

I often find myself needing to update a 3D asset in Threekit. If that asset doesn’t have many attributes or rules tagged to it, the update process is seamless. I drag in the USDZ, and Threekit updates the geometry. However, this process fails on assets with a typical amount of Threekit metadata (rules, attributes, tags, etc.). The import and update process fails in this case, and the Threekit log reports a “Path is not iterable” error. When this happens, there is little I can do except wipe out all of my Threekit work, import a fresh USDZ, and rebuild all the Threekit metadata on that asset.

I wish that the error message was a little more descriptive. I want to know what is confusing the importer. If I knew exactly what was tripping it up, I might be able to avoid doing that in the future.

Has anyone else seen this behavior? If so, did you find a workaround?

For the record, here is a snippet from the log of a typical import failure:

[2023-06-09T20:36:01.833Z] error: ##### ERROR
: TypeError: path is not iterable
[2023-06-09T20:36:01.835Z] error: path is not iterable {“stack”:“TypeError: path is not iterable\n at actionMap (/threekit/jobs/importers/build/common/rules.js:47:64)\n at ()\n at /threekit/jobs/importers/build/common/rules.js:71:38\n at ()\n at fixRules (/threekit/jobs/importers/build/common/rules.js:70:28)\n at createOrUpdateAsset (/threekit/jobs/importers/build/common/assets.js:22:36)\n at processGLTF (/threekit/jobs/importers/build/importGLTF/index.js:47:44)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async importFiles (/threekit/jobs/importers/build/importers.js:189:9)\n at async Command. (/threekit/jobs/importers/build/index.js:130:9)”}
[2023-06-09T20:36:01.854Z] error: TypeError: path is not iterable


Hey @jem - a fix for this issue was deployed recently and this should be resolved. Can you attempt your update again? If it fails in the same way please let me know what environment you are working on and we’ll log a case.

You are right. It worked! I uploaded the same GLTF file that had caused the previous error, but it worked without issue this time. I am embarrassed that I didn’t check before I posted. I felt gunshy about using the update asset feature because of all the grief it had caused me in the past.

I know that I have a lot of updates to make. I feel a lot more confident now making those changes. If this glitch pops up again, I will email you the specifics.

Thank you very much.

1 Like

Don’t worry at all, it’s not terribly obvious a bug you’ve encountered has been fixed so I’m always happy to check.

Please do come back if anything related (or otherwise) comes up!