Wednesday, June 03, 2009

A Good Mix 8: Python 101, Regular Expressions, Silverlight, IronRuby and More

The Coding Geekette is a Python and .NET developer who has spoken on IronPython at many developer conferences including PyCon. Her next adventure is teaching .NET developers Python in Cleveland:
What: "Python 101 for the .NET Developer" with Sarah Dutkiewicz, Cleveland C#/VB.NET SIG

When: Tuesday, June 23, 6:30-8:30pm

Where: Beacon Place Conference Center, Beacon Place Office Building, 6055 Rockside Woods Blvd, Lower Level, Independence, OH 44131
This blog entry (non-English) shows two interactive sessions using the System.Text.RegularExpressions.Regex class; performing the same task from both IronPython (2.6 beta) and IronRuby (0.4). The interactive interpreter is a great environment for experimenting, and the sessions ably demonstrate this.

Of course you could also achieve the same thing with the Python re module.

This is true of many things in IronPython, file and path handling or threading being two more examples; you have the choice of whether to do things the Python way or the .NET way. Whether you use the Python standard library or .NET framework libraries depends on which you are more familiar with, whether you need the code to be portable across implementations or whether one of the alternatives more closely matches what you need to achieve.
IronPython has been designed to make it easy to embed in .NET applications. With code evaluated and executed at runtime it opens up all sorts of possibilities for user scripting of applications, storing rules as text that can be created and modified at runtime and so on. Hosting IronPython in Silverlight is slightly different from desktop .NET applications. Although the hosting API is the same there is some initial configuration that needs to be done.

I've updated my article on the topic to include the configuration needed for IronPython code to import from other Python files contained in the xap file, plus adding references to the standard .NET / Silverlight assemblies.
An O'Reilly Radar article. James Turner interviews Eric Schuman about how Microsoft tests user experiences on its websites. Notable for this quote:
JT: Microsoft has done a lot of work providing dynamic language support through projects through IronRuby and IronPython. Do those technologies find any traction internally?

ES: Oh, yeah, actually. I think it depends a lot on what group you're in. Like in the research teams, they tend to be used more than the product teams that I've been on. But there's definitely -- we're all geeks, you know? You get geeks and you get neat technologies and the geeks will try and use them. So I know that Iron Python, I know quite a few people who've experimented with it for everything from build tools to little data analysis tools.
IronRuby in Action is a book being written for Manning Publications by Ivan Porto Carrero. About half the book is complete and available through the Manning Early Access Program. Jan Van Ryswyck has posted a review of the book so far...
Moonlight 2, the Mono port of the Silverlight 2 browser plugin for Linux, is making great progress. Preview 3 is out now and can run my IronPython web-IDE example. You can now script the browser with Python on Windows, Mac OS X and Linux.

No comments:

Post a Comment

Note: only a member of this blog may post a comment.