how to deal with deprecating API functionality in python module?

C

Chris Friesen

Hi,

I'm pretty new to python, I'm trying to figure out how a python module
is supposed to make non-backwards-compatible changes without blowing up
the applications that use it.

In the C world this is straightforward, an application is linked against
version X of the library, and if the library developers make a
non-compatible change (remove a deprecated function, or change a
function signature) they bump the version to X+1. Then versions X and
X+1 can both be installed on the system at the same time and
applications will link against whichever one they were compiled against.

How would something like this work in a python application? I don't see
any way to do the equivalent of

import foo version X


Is the only way to incorporate the version in the name? Like:

import fooX


Any guidance would be appreciated...


Thanks,
Chris
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,575
Members
45,053
Latest member
billing-software

Latest Threads

Top