home contents changes options help subscribe

GSOC Midterm Report

Working for Zope has been a great experience for me. My project was to port Zope3 to Python2.5.In the initial phase of the project I faced many challenges. Thanks to Baiju who helped me to over come them and easily jump to the ideas like eggification, buildout etc which formed an important part this project. The project mainly consisted of testing and debugging. Some of the failures or errors repeated in later modules which allowed me to dispose them sooner. The lack of documentation of certain Python changes also were a little trouble. Initially I went by the way of the changes which were given in Python documentation suspecting mostly these changes as the cause of failures. Then sooner I understood the mistake in this approach and started going through the corresponding Python module sources for understanding the changes.Pdb was very helpful in isolating errors and was extensively used through out this project.

Let me give a brief idea of the Python changes which interfered with my testing before going to the Zope part. The main change I encountered often was the change in Exception class inheritance hierarchy in Python2.5. This generated a lot of failures in Zope modules when tested in 2.5. A fair bit of this was dealt with using renormalization which also ensured its backward compatibility. Through out the project I was also ensuring that the code when made to work in Python2.5 continues to behave same in 2.4. Then there where a lot of errors caused by changes in specific Python modules also

Later the major problem in which I was hooked was ZEO module which was hanging in python2.5.For which I asked a question in the ZODB-dev list and Tim peters gave the reason of causing errors. Jim Fulton on seeing these mails got interested and he took over the ZEO problem solved it and made the ZODB release branch to support Python2.5 also.

This was the time I turned my attention to the Restricted Python module as advised by Jim. This is the module which suffers the worst under Python changes mainly due to the change in the design of the byte code compiler. But after going into the issue it was realized that Zope3 is less affected by this change as it uses the security proxies for supporting restricted execution. Also it passes all the tests in Python2.5. So after a discussion with Jim on this, I decided to leave the matter to be considered after finishing the other Zope3 modules.

I had the policy of porting the modules with minimum code changes so that the overall structure of the code is not lost and the chance of errors is minimum. In some cases this created problems like in zope.app.undo, Benji York suggested that it affected the understandability of the code, which we later corrected by replacing the code as per Python's style guidelines.

And about other modules (I wont bore you with all their details), most of them have been ported into python2.5 and are listed in http://wiki.zope.org/zope3/ModuleImplementationStatus (Please inform me if there is any correction).These modules mainly contained errors due to changes in single Python modules and some of them were repeating ones. Also there are some modules which are corrected and these will be soon merged to the repository and wiki will be updated. Now I am working in zope.server which I think remains the sole major problem left to finish in the zope modules. The other modules which I consider to look soon are zope.testbrowser, zope.formlib zope.publisher , zope.formlib etc whose errors appear to be trivial.

Telling about my next plans , I will be finishing the remaining modules in a week and half and then moving on to Restricted Python. Firstly there remains certain issues related to zope.security that needs to be solved before moving onto Zope2 and try to make the security restrictions of Zope2 work in Python2.5.I will also be requesting Python 2.5 support in buildbot for these modules and the support of individual coders so as to ensure its continued working in 2.5.

This is the brief summary of my work till date and my future steps. Hoping to do better in the coming days and once again thanking every one who helped me.

Nikhil N