When you call get_collider() it returns the object itself, when you call print(obj) it prints a string representation of the object which, in this case is a KinematicBody2D with obj_id=606.
Anyways, I recommend you to just add player to the block's rays' exception list.
So if you have a Block class where every instance will have 2 RayCast2D children, and assuming that player is a brother of block_spawner, and foo the method that spawns the blocks; in your code, where you spawn the new blocks, it should go something like this:
# Do stuff...
var player = $"../player" # short for get_parent().get_node("player")
var new_block = Block.new()
get_parent().add_child(new_block) # don't forget to add it to the tree
Of course I'm missing certain details about your code but that's the gist of it, adjust it to your needs.