Including custom *.py scripts with Jython
I have an application where I use pickle to do data serialization. In a development environment, I didn't have a single issue with running my Jython scripts through Java (by including the jython.jar).
After packaging and deploying on a production environment, I've experienced an error with Jython that it couldn't find the pickle module for inclusion.
After some analysis, I found out that a special lib folder 'Lib' in the Jython source directory exists where these custom scripts live.
The easiest way to solve this, was creating a custom Jython jar file that include all these *.py scripts.
To do this, add the Lib folder in the Jython source directory to the jython.jar file. This can be done by some popular file managers (such as midnight commander, ...) or with the following command:
$ zip -r jython.jar Lib
