I think I found how to fix it in my case, but not the ultimate cause.
When I saved a new screenshot from sikuliide, the resulting file was saved as a 0-byte file. Attempting to save or open the .sikuli from then on caused the 'read returned null' error mentioned before.
I haven't tracked down why the screenshot was saved as a 0-byte file, but if this error comes up for anyone else, that's probably the cause.
I think I found how to fix it in my case, but not the ultimate cause.
When I saved a new screenshot from sikuliide, the resulting file was saved as a 0-byte file. Attempting to save or open the .sikuli from then on caused the 'read returned null' error mentioned before.
I haven't tracked down why the screenshot was saved as a 0-byte file, but if this error comes up for anyone else, that's probably the cause.