Py_Main: fix double delete. add test. fix #9
Merge pull request #11 from sbinet/feature/fix-9

Py_Main: fix double delete. add test.