<div dir="ltr">I had another (maybe related) pickling problem, which i have taken up with Wing (because it does not happen in e.g. Idle):<div><br></div><div>-----------------------------------------------<br><div><div>import pickle</div>
<div><br></div><div>class Test(object):</div><div>    def __init__(self):</div><div>        self.func = self.func2</div><div>    def func2(self):</div><div>        print "something"</div><div>        </div><div>
if __name__ == '__main__':</div><div>    </div><div>    t = Test()</div><div>    t.func()</div><div>    s = pickle.dumps(t)</div><div>    print s</div></div><div>-----------------------------------------------<br>
<div></div></div><div><br></div><div>with error:</div><div><div><br></div></div><div><div>pickle.PicklingError: Can't pickle <built-in function wingdb_import_hook>: it's not found as tdbgtracer27stackless.wingdb_import_hook</div>
</div><div><br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Oct 22, 2013 at 9:32 AM, lars van Gemerden <span dir="ltr"><<a href="mailto:lars@rational-it.com" target="_blank">lars@rational-it.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks,<div><br></div><div>I'll to get back to that, i am trying to get a demo up and running ...</div>
<div><br></div><div>Cheers, Lars</div></div><div class="gmail_extra"><div><div class="h5"><br><br><div class="gmail_quote">
On Mon, Oct 14, 2013 at 9:04 PM, Richard Tew <span dir="ltr"><<a href="mailto:richard.m.tew@gmail.com" target="_blank">richard.m.tew@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

If you use the stackless socket module, it can make blocking functions<br>
like network access stackless compatible.  That means they block the<br>
tasklet rather than the thread, and you don't necessarily need to call<br>
schedule.<br>
<br>
stacklesslib provides monkey patching for the socket module and a<br>
range of others.<br>
<br>
It might help you out.<br>
<br>
This is a very old example from when the stackless socket module was standalone:<br>
<br>
<a href="https://mail.python.org/pipermail/python-announce-list/2006-September/005252.html" target="_blank">https://mail.python.org/pipermail/python-announce-list/2006-September/005252.html</a><br>
<br>
Nowadays you'd want to obtain stacklesslib and import that rather than<br>
stacklesssocket.<br>
<div><div><br>
Richard.<br>
<br>
_______________________________________________<br>
Stackless mailing list<br>
<a href="mailto:Stackless@stackless.com" target="_blank">Stackless@stackless.com</a><br>
<a href="http://www.stackless.com/mailman/listinfo/stackless" target="_blank">http://www.stackless.com/mailman/listinfo/stackless</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div></div></div><div class="im">-- <br>====================================<br>Lars van Gemerden<br><a href="mailto:lars@rational-it.com" target="_blank">lars@rational-it.com</a><br>
<a href="tel:%2B31%206%2026%2088%2055%2039" value="+31626885539" target="_blank">+31 6 26 88 55 39</a><br>
====================================
</div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>====================================<br>Lars van Gemerden<br><a href="mailto:lars@rational-it.com">lars@rational-it.com</a><br>+31 6 26 88 55 39<br>====================================
</div>