# Ocra-fied exe doesn't trace with set\_trace\_func

**URL:** <https://www.ruby-forum.com/t/ocra-fied-exe-doesnt-trace-with-set-trace-func/188010>\
**Category:** Ruby\
**Created:** [May 4, 2010, 5:49am UTC](https://www.ruby-forum.com/t/ocra-fied-exe-doesnt-trace-with-set-trace-func/188010 "2010-05-04T05:49:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![drlelon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ee59a6/32.png) [@drlelon](https://www.ruby-forum.com/u/drlelon)\
**Post date:** [May 4, 2010, 5:49am UTC](https://www.ruby-forum.com/t/ocra-fied-exe-doesnt-trace-with-set-trace-func/188010/1 "2010-05-04T05:49:54Z")

</div>

set\_trace\_func does not seem to work in an ocra executable – the proc  
specified for tracing seems simply not to execute. The tracing works  
fine when running under straight ruby and under NetBeans, but not with  
the ocra-fied exe.

I’m doing this, by the way, because the ocra-fied exe crashes someplace  
for a client that it does not crash in straight ruby or NetBeans, and I  
cannot reproduce it on my system. So I need to put the exe at the  
customer site with tracing on. If this doesn’t work, I guess I will put  
in a lot of explicit logfile.write’s, but that’s a p-i-t-a.

Thanks. --David.

---

<div class="post-metadata">

**Author:** ![drlelon](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ee59a6/32.png) [@drlelon](https://www.ruby-forum.com/u/drlelon)\
**Post date:** [May 4, 2010, 2:01pm UTC](https://www.ruby-forum.com/t/ocra-fied-exe-doesnt-trace-with-set-trace-func/188010/2 "2010-05-04T14:01:36Z")

</div>

David Lewis wrote:

> set\_trace\_func does not seem to work in an ocra executable

Ah, I see that set\_trace\_func is “unsupported”. I guess that means  
flaky. I’m now seeing it fail even in a straight ruby execution, so  
it’s not due to ocra. It works so far in NetBeans, fwiw.

[http://redmine.ruby-lang.org/issues/show/693](http://redmine.ruby-lang.org/issues/show/693)

–David.
