$ oslc test.osl && testshade test
Compiled test.osl -> test.oso
ERROR: Shader error [test]: Invalid image file "none.exr": Could not open file "none.exr"
ERROR: Shader error [test]: No data present
So nonexistant file gets an error all the way from the texture system, reported through the renderer (as expected), as well as the error called by your shader.
When I try with a file that exists, but just doesn't contain the requested metadata, I get:
$ oslc test.osl && testshade test
Compiled test.osl -> test.oso
ERROR: Shader error [test]: No data present
that's just the error directly called by your shader. Nothing else from the texture system or OSL internals (such as RendererServices::get_texture_info).
So some things to ponder:
1. Which renderer/version? Can you reproduce via our 'testshade' as I tried to do?
2. Which version of OSL?
3. Do you know which version of OIIO is being used for the texture system?
I'm also intrigued by the error message you quoted. The string "unspecified OIIO error" does not appear anywhere in the current OSL or OIIO source code! So I'm wondering if this is coming from code in your renderer?