The IronPython engine is bloody slow to initialize.
Maybe not the best scripting language for a CAD in terms of speed.
Initial start up is a bit slow but once the scripts are loaded and jitted, IronPython is as fast as C#. (I compile the scripts on load rather than use 'eval'). IronPython is reported to be 10x-100x faster than CPython which is tolerable for a lot of projects
I could not find a way to hot-reload python scripts without restarting the application. This is a major drawback since you normally use a script for prototyping and the write-test-change-reload pattern is extrememly convenient. It seems that is not so easy to clean symbols once you reload the script. This is perfectly reasonable but I did the same thing for LUA language and had no problems reloading scripts.
The IPY_RELOAD does indeed do a hot reload without restart, as you say, this is key!
I scrap the old scope and create a new one and it seems to work well so far. I will setup a GitHub repo soon with all source as soon as I get it sorted a bit more.
Anyway that is my (limited) experience. It is an interesting project!
Thanks for your interest Danipon!
I actually built a scripting engine in Clojure which works the same but is probably a bit quicker on start-up. I like Lisp but Python is a lot easier on the brain than Clojure for newbies who just want to knock out a quick script
The end goal is to have a plugins directory where tested/finalised scripts are kept and loaded once which should have good performance. I'm working on a simple editor for testing new scripts that will use the reload feature, you can create as many scripting engines and scopes as you like so any new code won't tread on any preloaded code.
I now have a lot better error reporting output with line numbers etc for errors that works well enough for debugging.
If you end up with a lot of scripts it's very easy to create an IronPython class lib project and compile them into a dll proper. the main goal though is to make it easy for newbies to use without having to install a full blown dev environment and I can just write scripts for clients without having to do a full rebuild and release of the main app.
It still has a ways to go but it's coming along well and I'm very happy with it and I doubt I'll write too much more C# until I need too