Added error support for junction matching