Skip to content
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

LIBCLOUD-858: Fix Listing Libvirt Nodes with Python 3 #894

Closed
wants to merge 1 commit into from
Closed

LIBCLOUD-858: Fix Listing Libvirt Nodes with Python 3 #894

wants to merge 1 commit into from

Conversation

femnad
Copy link
Contributor

@femnad femnad commented Oct 9, 2016

Fix Listing Libvirt Nodes with Python 3

Description

Listing nodes with the Libvirt provider fails on Python 3 because of a split operation on a bytes object where the delimiter is not a bytes object.

Use the ensure_string function from the py3 module to ensure that the output of a subprocess.Popen call is always a string for Python 2 and 3. Also add a test to convert the mock command output results to bytes objects if the active Python version is 3.

Status

  • done, ready for review

Checklist (tick everything that applies)

  • Code linting (required, can be done after the PR checks)
  • Documentation
  • Tests
  • ICLA (required for bigger changes)

@tonybaloney
Copy link
Contributor

great, thanks for also contributing the test to assert the issue exists and the change resolves it. 👍

@asfgit asfgit closed this in f5ff0cf Oct 9, 2016
asfgit pushed a commit that referenced this pull request Oct 9, 2016
@femnad femnad deleted the LIBCLOUD-858_fix-libvirt-node-listing-with-python-3 branch October 15, 2016 09:21
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.

None yet

2 participants