aplying exception tratament in hash_format_graph