I found the cause eventually!
This part of the error is possibly misleading:
Really you need a discriminator to help identifying the typeIt seems to suggest that you need to use a discriminator (which we already are) so that could lead the developer to check their metadata etc.,
The real problem was that metadata was missing due to two package.jdo files being provided for the same package but having different classes in them - result of a split up/refactor that ended up reusing the same package name for different classes - some in the main app and some that were migrated to a shared library, hence at runtime two package.jdo files were present "in" the same package (same logical package but two separate package.jdo files).
The root cause was that the lookup of the class name using the discriminator value failed - because the metadata was not present.
Perhaps I can look at making the error a more accurate description of the cause - or maybe it needs two separate error messages: