[IronPython] Improvements to the hosting APIs

Dino Viehland dinov at microsoft.com
Fri Feb 12 21:47:55 CET 2010


Jeff wrote:
> Hi all,
> Dave F. mentioned on Twitter that he was looking at the hosting APIs,
> and the made the mistake of accepting my unsolicited advice. So, here
> are a couple of my wishes (both form NWSGI):
> 
> * A version of PythonOps.MakeException that doesn't take a code
> context - It's not hard to create one, but every time I do I feel like
> I'm doing something wrong.
> * An easy way to wrap a Stream as a PythonFile.

I'm guessing you also want the Stream->PythonFile to not take a CodeContext? 

Do you think an extension method on Stream would be nice - such as
stream.ToPythonFile(string filename, string mode)?
 
> 
> I don't know where these make the most sense, but engine.MakeException
> and engine.MakeFile both seem right to me.
> 
> Other than that, the hosting APIs are very nice to use. I'm really
> reaching to come up with those issues.
> 
> - Jeff
> _______________________________________________
> Users mailing list
> Users at lists.ironpython.com
> http://lists.ironpython.com/listinfo.cgi/users-ironpython.com




More information about the Ironpython-users mailing list