[iphone-python] redirecting output (was: UIWebView in iphone-python?)
zhangchnxp at gmail.com
zhangchnxp at gmail.com
Thu Sep 25 02:14:06 UTC 2008
Sometimes piping does crash my app. Perhaps it's better to redirect
stderr directly with '2>logfile'.
Sent from my iPod
On 2008-9-25, at 5:55, Kheo <Kheo at Gmx.fr> wrote:
> renaud blanch a écrit :
>> On Fri, Sep 19, 2008 at 6:08 AM, Zhang chnxp <zhangchnxp at gmail.com>
>> wrote:
>> [...]
>>
>>
>>> BTW, I tried to get some output with 'exec "$(dirname "$0")"/Python
>>> "$(dirname "$0")"/App.py 2>&1|tee /var/tmp/app.log'.
>>>
>>> Is this the only way to test a python app?
>>>
>>
>> nop, syslogd is your friend
>> manually : <http://www.google.com/search?q=syslog+iphone>
>> and now thanks to saurik : search for syslogd in cydia
>>
>>
> Piping the error and standard outputs to 'tee' seems to be efficient
> to
> write error messages during loading time. If there is no issue during
> load, when the application must start, it closes. On my iTouch I get
> this error message in my log :
>
> 2008-09-24 23:50:31.717 python[1453:10b] MS:Notice: Installing:
> com.saurik.OfflineMaps
> Couldn't register com.saurik.OfflineMaps with the bootstrap server.
> Error: unknown error code.
> This generally means that another instance of this process was already
> running or is hung in the debugger.
>
> If I remove the pipe at the end, the application start normally.
> Is it normal ? I was so happy to have a solution to write output
> messages to a file (without using syslogd).
>
> _______________________________________________
> iPhone-Python mailing list
> iPhone-Python at telesphoreo.org
> http://www.telesphoreo.org/cgi-bin/mailman/listinfo/iphone-python
More information about the iPhone-Python
mailing list