In my experience with these types of issues, I’ll always back off until things start working again. I’ll uninstall URL Rewrite, and remove all references to any extensions in IIS to my Python Apps, and then start again, verifying the functionality at every step.
I haven’t used isapi_wsgi in depth for a while. I’ve been using it to mount a simple Python web site at the root, but not for anything else. I don’t even remember how I did it (though it’s all in my code repository for the site).
One thing I notice is that you’re running the demo from your home directory. I often find that I run into permission issues if I run any isapi_wsgi pages from anywhere except /inetpub, so I generally run my sites from there.
I’m unsure how URL Rewrite might interact with isapi_wsgi. It does seem to be interfering, though I couldn’t be sure how. I know it’s frustrating that isapi_rewrite is difficult to troubleshoot, but it’s the nature of the beast. Try to keep it as simple as possible and use win32traceutil to create trace statements (in isapi_wsgi or your code) to determine where things are going wrong.
Based on the error message you reported, it may be the case that URL Rewrite is actually modifying the code being passed to ISAPI_wsgi. If that’s the case, we may need to make some enhancements to it.
In any case, I hope that helps.