Rendered object color different from viewport color, set in Python
You are changing the viewport setting instead of node value.

NodeSocketColor

Use ob.material_slots[0].material.node_tree.nodes[1].inputs['Base Color'].default_value = (0,0,0,0)