aspose file tools*
The moose likes Jython/Python and the fly likes backward compatability Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » Jython/Python
Bookmark "backward compatability" Watch "backward compatability" New topic
Author

backward compatability

Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 30749
    
156

Python 3 isn't backward compatible with Python 2. Is this a problem in practice? It sounds like it would be one, but I'm not seeing people crying about it.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Palak Mathur
Ranch Hand

Joined: Jan 29, 2007
Posts: 313

Backward compatibility is certainly an issue when you are trying to migrate from 2.x to 3.0. However, the Python community is not fast paced in adapting to changes like other communities such as Ruby, etc. are. Though people may not be crying out loud but certainly there are people who are crying. Advantage of Python is numerous additional Libraries that help to scale Python like NumPy, SciPy, etc. So the issue that someone may feel is about the port of these numerous libraries for 3.x. With the release of 3.0 ver, certainly these libraries have become legacy system and if you want to migrate to this version, then certainly it can be painful as with migrating from any legacy system to newer technology.

If you are using 2.6, 2.7 version of Python, then certainly the effort will be less.

Now, choice of version whether 2.7 or 3.0 will certainly depend on kind of work you do. If you just wish to play around with Python, then certainly go for 3.0 if it works for you. Otherwise stick to 2.7. I use 3.0 for my personal work and 2.7 for scripting purpose.


Palak Mathur | My Blog | TechJaunt | What is JavaRanch? | List of All FAQs
Allen Downey
Author
Greenhorn

Joined: Sep 07, 2012
Posts: 25

I think Palak summed it up pretty well. The transition from Python 2.x to 3 has been going on for a while, and no end in sight.

One consolation is that most of the changes are small, so while you are learning Python, it doesn't matter which one you learn. Except for the print statement/function. That's by far the most visible change.

Programs like 2to3 can convert many Python programs from 2.x to 3 automatically. There are limitations, but for the programs I have converted, everything worked out of the box.

Still, I think Python 2.x will be with us for a long time.

Allen

All of my books are available from http://greenteapress.com
Palak Mathur
Ranch Hand

Joined: Jan 29, 2007
Posts: 313

I also tried 2to3 and works fine for most of the cases
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: backward compatability