Skip to content

examples and library ported to python 3 #5

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

BMJHayward
Copy link

No description provided.

@andrewryno
Copy link

Can you update this so it will try to import xmlrpc.client detect if it failed, and then import the 2.* package?

try:
    from xmlrpc.client import ServerProxy, Error
except ImportError:
    from xmlrpclib import ServerProxy, Error

@BMJHayward
Copy link
Author

Sure, will be able to get to this tomorrow night.

On 22/02/15 07:30, Andrew Ryno wrote:

Can you update this so it will try to import xmlrpc.client detect if
it failed, and then import the 2.* package?

|try:
from xmlrpc.client import ServerProxy, Error
except ImportError:
from xmlrpclib import ServerProxy, Error
|


Reply to this email directly or view it on GitHub
#5 (comment).

@BMJHayward
Copy link
Author

This version uses the try: except as advised. The other pull request uses if: else instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants