<div dir="ltr">Hi,<div>very good point, I've been on beta3. But the upgrade didn't help. I've figured out how to debug the internals in VS, but there's nothing I could be able to fix (or even understand) myself at this point.<div><br></div><div>ad 1) after running wdb.server, Tornado at first says </div><div><div>\tornado\netutil.py", line 88, in bind_sockets</div><div>AttributeError: 'module' object has no attribute 'IPV6_V6ONLY'</div></div><div>When I comment the whole if section out, it starts the loop and waits for connections.</div><div><br></div><div>Running the client, the server reports this and continues listening:</div><div><div>Connection received from ('127.0.0.1', 1518)</div><div>[E 141125 11:51:35 stack_context:1] Exception in I/O handler for fd 1616</div><div>    Traceback (most recent call last):</div><div>      File "-\tornado\stack_context.py", line 304, in wrapped</div><div>        ret = fn(*args, **kwargs)</div><div>      File "-\tornado\netutil.py", line 154, in accept_handler</div><div>        callback(connection, address)</div><div>      File "-\wdb_server\streams.py", line 95, in handle_connection</div><div>        stream.read_bytes(4, partial(read_uuid_size, stream))</div><div>      File "-\tornado\iostream.py", line 168, in read_bytes</div><div>        self._try_inline_read()</div><div>      File "-\tornado\iostream.py", line 424, in _try_inline_read</div><div>        if self._read_to_buffer() == 0:</div><div>      File "-\tornado\iostream.py", line 447, in _read_to_buffer</div><div>        chunk = self.read_from_fd()</div><div>      File "-\tornado\iostream.py", line 686, in read_from_fd</div><div>        chunk = self.socket.recv(self.read_chunk_size)</div><div>    error: [Errno 10022] A request to send or receive data was disallowed because the socket is not connected and (when sending on a datagram socket using a sendto call) no address was supplied</div></div><div><br></div><div>And the client crashes with </div><div>wdb\client\wdb\_compat.py", line 165, in send_bytes</div><div>socket.error: [Errno 10053] An established connection was aborted by the software in your host machine</div><div><br></div><div><div>When trying to debug this in VS, I came to the conclusion that the Tornado server's socket handling (or my commenting out a piece, or something else inside Tornado running under IronPython-) is at fault, since it's not true what I've written previously (that a message gets communicated and then coms fail) - in fact nothing gets communicated, it crashes in the client on trying to send the first message using socket.cs sendallWorker(byte[] buffer, int flags).</div><div><br></div><br>ad 2) running the server in Python and client in IronPython, I get a bit further, but the error is the same - the client in IronPython reports</div><div><div>Launching browser and wait for connection</div><div>Exception Traceback (most recent call last):</div><div>  File "-\wdb\client\wdb\__init__.py", line 291, in trace_debug_dispatch</div><div>  File "-\wdb\client\wdb\__init__.py", line 250, in trace_dispatch</div><div>  File "-\wdb\client\wdb\__init__.py", line 686, in handle_call</div><div>  File "-\wdb\client\wdb\__init__.py", line 660, in interaction</div><div>  File "-\wdb\client\wdb\ui.py", line 80, in __init__</div><div>  File "-\wdb\client\wdb\__init__.py", line 575, in get_trace</div><div>TypeError: Unable to cast object of type 'System.Linq.Expressions.FieldExpression' to type 'System.Linq.Expressions.BlockExpression'.</div></div><div><br></div><div>It's the same place and line of code I mentioned in my previous mail:</div><div>> startlnos = dis.findlinestarts(code)</div><div><br></div><div>Debugging in VS yields an impressive stack trace, but I don't have any idea where to start with this, so again - I'll be very grateful for any pointers.<br></div><div><br></div><div>Thanks - for even reading this far.</div><div><br></div><div><br></div><div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitAssign(BinaryExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 831</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBinary(BinaryExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 876</div><div>   at System.Linq.Expressions.BinaryExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitTry(TryExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 297</div><div>   at System.Linq.Expressions.TryExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitAssign(BinaryExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 789</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBinary(BinaryExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 876</div><div>   at System.Linq.Expressions.BinaryExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(ReadOnlyCollection`1 nodes)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.VisitBlock(BlockExpression node) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 595</div><div>   at System.Linq.Expressions.BlockExpression.Accept(ExpressionVisitor visitor)</div><div>   at System.Linq.Expressions.ExpressionVisitor.Visit(Expression node)</div><div>   at Microsoft.Scripting.Ast.GeneratorRewriter.Reduce() in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorRewriter.cs:line 100</div><div>   at Microsoft.Scripting.Ast.GeneratorExpression.Reduce() in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Ast\GeneratorExpression.cs:line 94</div><div>   at System.Linq.Expressions.Expression.ReduceAndCheck()</div><div>   at System.Linq.Expressions.Expression.ReduceExtensions()</div><div>   at System.Linq.Expressions.Compiler.StackSpiller.RewriteExtensionExpression(Expression expr, Stack stack)</div><div>   at System.Linq.Expressions.Compiler.StackSpiller.RewriteExpression(Expression node, Stack stack)</div><div>   at System.Linq.Expressions.Compiler.StackSpiller.RewriteExpressionFreeTemps(Expression expression, Stack stack)</div><div>   at System.Linq.Expressions.Compiler.StackSpiller.Rewrite[T](Expression`1 lambda)</div><div>   at System.Linq.Expressions.Expression`1.Accept(StackSpiller spiller)</div><div>   at System.Linq.Expressions.Compiler.LambdaCompiler.Compile(LambdaExpression lambda, DebugInfoGenerator debugInfoGenerator)</div><div>   at System.Linq.Expressions.LambdaExpression.Compile()</div><div>   at Microsoft.Scripting.Debugging.DebuggableLambdaBuilder.CreateFunctionInfo(LambdaExpression generatorFactoryLambda) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Debugging\DebuggableLambdaBuilder.cs:line 386</div><div>   at Microsoft.Scripting.Debugging.DebuggableLambdaBuilder.TransformLambda(LambdaExpression lambda) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Debugging\DebuggableLambdaBuilder.cs:line 171</div><div>   at Microsoft.Scripting.Debugging.DebuggableLambdaBuilder.Transform(LambdaExpression lambda) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Debugging\DebuggableLambdaBuilder.cs:line 111</div><div>   at Microsoft.Scripting.Debugging.CompilerServices.DebugContext.TransformLambda(LambdaExpression lambda, DebugLambdaInfo lambdaInfo) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Debugging\DebugContext.cs:line 68</div><div>   at IronPython.Runtime.FunctionCode.<>c__DisplayClass1a.<GetGeneratorOrNormalLambdaTracing>b__19(Expression`1 x) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\FunctionCode.cs:line 787</div><div>   at IronPython.Compiler.GeneratorRewriter.Reduce(Boolean shouldInterpret, Boolean emitDebugSymbols, Int32 compilationThreshold, IList`1 parameters, Func`2 bodyConverter) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\GeneratorRewriter.cs:line 147</div><div>   at IronPython.Runtime.FunctionCode.GetGeneratorOrNormalLambdaTracing(PythonContext context) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\FunctionCode.cs:line 777</div><div>   at IronPython.Runtime.FunctionCode.UpdateDelegate(PythonContext context, Boolean forceCreation) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\FunctionCode.cs:line 717</div><div>   at IronPython.Runtime.FunctionCode.LazyCompileFirstTarget(PythonFunction function) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\FunctionCode.cs:line 697</div><div>   at IronPython.Compiler.PythonCallTargets.OriginalCallTarget1(PythonFunction function, Object arg0) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\PythonCallTargets.cs:line 42</div><div>   at IronPython.Runtime.FunctionCaller`1.Call1(CallSite site, CodeContext context, Object func, T0 arg0) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\PythonFunction.Generated.cs:line 420</div><div>   at System.Dynamic.UpdateDelegates.UpdateAndExecute3[T0,T1,T2,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2)</div><div>   at get_trace$495(Closure , PythonFunction , Object , Object , Object )</div><div>   at IronPython.Compiler.PythonFunctionRecursionCheck3.CallTarget(PythonFunction function, Object arg0, Object arg1, Object arg2) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\PythonCallTargets.cs:line 273</div><div>   at IronPython.Compiler.PythonCallTargets.OriginalCallTarget3(PythonFunction function, Object arg0, Object arg1, Object arg2) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\PythonCallTargets.cs:line 53</div><div>   at IronPython.Runtime.FunctionCaller`3.Call3(CallSite site, CodeContext context, Object func, T0 arg0, T1 arg1, T2 arg2) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\PythonFunction.Generated.cs:line 676</div><div>   at System.Dynamic.UpdateDelegates.UpdateAndExecute5[T0,T1,T2,T3,T4,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3, T4 arg4)</div><div>   at CallSite.Target(Closure , CallSite , CodeContext , Object , Object , Object , Object )</div><div>   at IronPython.Runtime.Method.MethodBinding`2.SelfTarget(CallSite site, CodeContext context, Object target, T0 arg0, T1 arg1) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Runtime\Method.Generated.cs:line 195</div><div>   at System.Dynamic.UpdateDelegates.UpdateAndExecute4[T0,T1,T2,T3,TRet](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)</div><div>   at Microsoft.Scripting.Interpreter.DynamicInstruction`5.Run(InterpretedFrame frame) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Interpreter\Instructions\DynamicInstructions.Generated.cs:line 218</div><div>   at Microsoft.Scripting.Interpreter.Interpreter.Run(InterpretedFrame frame) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Interpreter\Interpreter.cs:line 132</div><div>   at Microsoft.Scripting.Interpreter.LightLambda.Run10[T0,T1,T2,T3,T4,T5,T6,T7,T8,T9,TRet](T0 arg0, T1 arg1, T2 arg2, T3 arg3, T4 arg4, T5 arg5, T6 arg6, T7 arg7, T8 arg8, T9 arg9) in c:\Users\jmatysek\Documents\main\Runtime\Microsoft.Dynamic\Interpreter\LightLambda.Generated.cs:line 417</div><div>   at IronPython.Compiler.PythonFunctionRecursionCheck9.CallTarget(PythonFunction function, Object arg0, Object arg1, Object arg2, Object arg3, Object arg4, Object arg5, Object arg6, Object arg7, Object arg8) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\PythonCallTargets.cs:line 375</div><div>   at IronPython.Compiler.PythonCallTargets.OriginalCallTarget9(PythonFunction function, Object arg0, Object arg1, Object arg2, Object arg3, Object arg4, Object arg5, Object arg6, Object arg7, Object arg8) in c:\Users\jmatysek\Documents\main\Languages\IronPython\IronPython\Compiler\PythonCallTargets.cs:line 83</div></div><div> </div><div><br></div><div><br></div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 24, 2014 at 3:07 PM, Pawel Jasinski <span dir="ltr"><<a href="mailto:pawel.jasinski@gmail.com" target="_blank">pawel.jasinski@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">hi,<br>
<br>
just to be sure,are you using 2.7.5RC1?<br>
If not, please try it. There were quite a few cpython compatibility<br>
improvements including socket module.<br>
<div><div class="h5"><br>
On Mon, Nov 24, 2014 at 1:53 PM, Kerray <<a href="mailto:kerray.cz@gmail.com">kerray.cz@gmail.com</a>> wrote:<br>
> Hi everyone,<br>
> We're using IronPython to script the insides of SharePoint (<a href="http://ASP.NET" target="_blank">ASP.NET</a> on IIS).<br>
> For quite some time, I've been looking for a comfortable way to debug these<br>
> scripts without having to install Visual Studio.<br>
><br>
> I've considered using standard PDB, with console redirected over the net by<br>
> some sort of messaging. This was the least preferable option, as the user<br>
> comfort is quite low and we'd have to take care of the messaging layer.<br>
><br>
> I also considered using IPython to do this, but despite using<br>
> <a href="https://github.com/paweljasinski/" target="_blank">https://github.com/paweljasinski/</a> repositories, I haven't been anywhere<br>
> close to success.<br>
><br>
> However, recently I've re-visited <a href="https://github.com/Kozea/wdb" target="_blank">https://github.com/Kozea/wdb</a> and was<br>
> surprised how far it has come since I've seen it for the first time. It<br>
> looked exactly like the debugger I was looking for. I tried playing with it,<br>
> added small IPy compatibility changes here and there, and the results are<br>
> promising.<br>
><br>
> I've been attacking this on two fronts:<br>
><br>
> 1) I've tried running the server side in IronPython, but it uses Tornado,<br>
> and while I can get it to run (using<br>
> <a href="https://github.com/paweljasinski/tornado" target="_blank">https://github.com/paweljasinski/tornado</a>), on client connect the server<br>
> fails with<br>
> Exception in I/O handler for fd 1492<br>
>     Traceback (most recent call last):<br>
>       File "c:\Program Files (x86)\IronPython<br>
> 2.7\lib\site-packages\tornado-3.1.1-py2.7.egg\tornado\iostream.py", line<br>
> 694, in read_from_fd<br>
>         chunk = self.socket.recv(self.read_chunk_size)<br>
>     error: [Errno 10022] A request to send or receive data was disallowed<br>
> because the socket is not connected and (when sending on a datagram socket<br>
> using a sendto call) no address was supplied<br>
><br>
> While the client reports:<br>
> site-packages\wdb\_compat.py", line 135, in recv_bytes<br>
>     size, = struct.unpack("!i", self._handle.recv(4))<br>
> struct.error: unpack requires a string argument of length 4<br>
><br>
> But seeing my added debug output, the server and the client have<br>
> successfully communicated over the socket at least once, succesfully sending<br>
> and receiving a guid, and then crash on the message "ServerBreaks" which<br>
> should get server breakpoints.<br>
><br>
> Could this be an error with how sockets are handled in IPy/Windows? I've no<br>
> idea.<br>
><br>
> 2) I've also tried running the server side in Python, and the client in<br>
> IronPython (as I wouldn't mind doing it like this), but this also fails with<br>
> File "c:\Program Files (x86)\IronPython<br>
> 2.7\lib\site-packages\wdb-2.0.7-py2.7.egg\wdb\__init__.py", line 575, in<br>
> get_trace<br>
> TypeError: Unable to cast object of type<br>
> 'System.Linq.Expressions.FieldExpression' to type<br>
> 'System.Linq.Expressions.BlockExpression'.<br>
><br>
> And I've been unable to get any further from here - the line 575 in question<br>
> contains<br>
> startlnos = dis.findlinestarts(code)<br>
> and even when I take the dis.findlinestarts function, put it into the file<br>
> in question, and enhance it with debug output, it seem the call doesn't come<br>
> through to the inside of the function as none of the debug output appears.<br>
><br>
> Both points seem to me more like IronPython issues than an issues with WDB<br>
> directly, which is why I'm trying to ask here.<br>
><br>
> This is far too deep in the insides for my shallow "expertise", but I'd be<br>
> grateful for any pointers or ideas as to what to try next.<br>
><br>
><br>
> Thanks - and have a nice day<br>
><br>
> Jaromír Matýšek<br>
><br>
</div></div>> _______________________________________________<br>
> Ironpython-users mailing list<br>
> <a href="mailto:Ironpython-users@python.org">Ironpython-users@python.org</a><br>
> <a href="https://mail.python.org/mailman/listinfo/ironpython-users" target="_blank">https://mail.python.org/mailman/listinfo/ironpython-users</a><br>
><br>
</blockquote></div><br></div></div></div>