add more try catch to trac the source of the error.