October 25th, 2004, 01:15 PM
Interfacing Python with Perl
I have some modules implemented in perl but my project is in python. What can I do so I can use those modules. Plus perl has some nice text manipulation featues I like.
October 25th, 2004, 04:30 PM
Your not in an easy position. Ideally I would just rewrite the perl modules in Python, so naturally that's what I would suggest. There was also a project designed to convert Python to perl a while ago, though I can't find it now.
There is another way of course, use Pythons & perls SOAP modules to create a web-service from the parts of the too languages – .NET works like this apparently.
You might want to do a proper search on google on these subjects,
October 25th, 2004, 04:38 PM
You might find this interesting: http://www.crazy-compilers.com/bridgekeeper/
October 26th, 2004, 06:34 AM
Thanks for your help, I think that it is best that I stick with Python. It seems to me that the best features of perl are not would be nice but it is not worth the hasle. But I am surprised that Python and Perl are not bed buddies just like VB.Net and C# are.
Originally Posted by Tkinter_Bell
October 26th, 2004, 07:59 AM
VB.Net and C# are only buddies because they share a common core (the .NET framework with it's intermediate run time language) - it also helps that they were developed by just one company. They can only make use of code written in other languages within the context of that framework.
In contrast Perl and Python are totally seperate developments and there is no over arching group that dictates their interoperation.
October 26th, 2004, 08:05 AM
As well as the standard string operations, python has regular expressions support (import re), also strings being lists of characters, list comprehensions, itertools, generators and other modules support many more options for string manipulation and verification.
Perhaps if you gave some examples we could come up with some Python ideas to do the same things?
October 26th, 2004, 12:41 PM
You can try pyPerl-
I made an attempt, but had a hard time. You may have better luck
PyPerl at python.org
October 27th, 2004, 02:52 PM
Thanks but no thanks, It would have been nice to use Perl because it is less verbose then Python or any other language while handling regular expressions. Regex is a part of Perls syntax.
I will stick to python to save any hasle