The problem was that the Thrift interface I was consuming defined a type called "File". As soon as I pulled in the generated Ruby code for this file it rewrote the built-in File class. It would be nice if ruby's thrift generator namespaced things better!
Thrift causing undefined method 'write_struct_begin' on all IO objects
Pregunta
I'm running into a strange error... After I call a thrift method, all file IO I try to do fails with errors like:
log writing failed. undefined method `write_struct_begin'
This occurs if I try to do logger.info etc., or even if I just open a file directly, and try to write to it.
Totally stumped!
Solución
Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow