ucupumar / ucupaint

Ucupaint is Blender addon to manage texture layers for Eevee and Cycles renderer.
GNU General Public License v3.0
874 stars 31 forks source link

Display error popup when AOBake to layer #111

Closed emptybraces closed 1 month ago

emptybraces commented 1 month ago

I got this stacktrace but I'm newbie didn't know what happen.

Python: Traceback (most recent call last): File "C:\Users\motos\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\ucupaint\BakeToLayer.py", line 1671, in execute layer = Layer.add_new_layer(node.node_tree, layer_name, 'IMAGE', int(self.channel_idx), self.blend_type, ^^^^^^^^^^^^^^^^^^^^^ ValueError: invalid literal for int() with base 10: ''

I was doing a tutorial using my clothes mesh. When I AO bake, after a little while, I get error message, showing the hidden hair and body, and the clothes are hidden. I do reappear clothes mesh and try again, bake will be successful. I hope this helps for something.

ucupumar commented 1 month ago

I can't seem to reproduce the issue here. Can you upload an example file?

emptybraces commented 1 month ago

Thank you for quick fix, But I downloaded latest code mannually then applied and still does error occurs, seems to be another one.

Python: Traceback (most recent call last): File "C:\Users\motos\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\ucupaint\BakeToLayer.py", line 1569, in execute image = denoise_image(image) ^^^^^^^^^^^^^^^^^^^^ File "C:\Users\motos\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\ucupaint\bake_common.py", line 890, in denoise_image recover_composite_settings(book) File "C:\Users\motos\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\ucupaint\bake_common.py", line 819, in recover_composite_settings set_active_object(ori_object) File "C:\Users\motos\AppData\Roaming\Blender Foundation\Blender\4.1\scripts\addons\ucupaint\common.py", line 618, in set_active_object bpy.context.view_layer.objects.active = obj ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ RuntimeError: Error: ViewLayer 'ViewLayer' does not contain object 'Woman_Basics_Swimsuit_2'

ucupumar commented 1 month ago

can you provide a sample blend file?

emptybraces commented 1 month ago

I tried make minimum sample, but why, I couldn't do it this time, sorry.

ucupumar commented 1 month ago

I couldn't reproduce the issue here, so I can't fix the bug if there's no sample blend file.

ucupumar commented 1 month ago

Okay, I can reproduce the issue here, please create a proper bug report next time.