Hi,
I'm using the s8 and iris scanning seems to work in most lighting conditions for me but not so much if I'm in a dark room.
Usually I'd suggest to delete your current scan and try registration again but it sounds like its working but only in certain conditions which sounds like the sensor.
If this was my situation I'd still do that after soft rebooting by turning the phone Off and On.
If you have a Samsung Experience Store they'd be able to run a diagnostic on it.
Daily Driver > Samsung Galaxy s²³ Ultra 512Gb in Phantom Black.
The advice I offer is my own and does not represent Samsung’s position.
I'm here to help. " This is the way. "