how to access bpy.data.objects thru bpy.context.scene.objects
That line of code is overly complex. ob is already a datablock, so you don't have to go through the hoop of getting its name and then looking it up somewhere else. Furthermore, this approach will break when you have linked datablocks from other blend files (then names aren't necessarily unique).

To create a set, you have to either use a set literal like {'abc', 'def'}, or pass an iterable to set(). This is why you get the error message that Object is not iterable. Use either data_blocks = {ob} or data_blocks = set([ob]). I would say the first method is easier to read. It's probably also faster, because you don't have to create an intermediary list first.