message
printed the exception
added the changes for trauin and junction ids
added the return for train junction id