Apologies, I accidentally sent the message before I finished. The remaining part of my reply is as below.
I think having the asserts in ProcessLibraryConstructorList() creates more problem. It is very hard to debug issues if the serial port initialisation fails.
Regards,
Sami Mujawar