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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix couchup for python3 #1905

Merged
merged 2 commits into from Feb 7, 2019

Conversation

Projects
None yet
2 participants
@klaemo
Copy link
Contributor

klaemo commented Feb 5, 2019

A tale of strings, bytes and pyhon3, I guess. This is probably the first line of python I've written in my life. Hooray! 馃榾 I consulted this fun document to understand what's going on.

Overview

couchup crashed in python3, because base64.b64encode expects a bytes-like object instead of a string. With this PR the string passed to base64.b64encode is properly encoded and decoded.

Testing recommendations

Run couchup with credentials with python3:
couchup replicate -a --login admin --password <my-password>

I was able to run couchup successfully on my DB with the change applied.

Related Issues or Pull Requests

fixes #1899

Checklist

  • Code is written and works correctly;
  • Changes are covered by tests;
  • Documentation reflects the changes;
@wohali

wohali approved these changes Feb 5, 2019

@wohali

This comment has been minimized.

Copy link
Member

wohali commented Feb 5, 2019

@klaemo Unfortunately I can't merge this because our style checker is failing. If you run sudo pip3 install black then make python-black-update and update your PR, it should solve the problem.

Thanks again for your PR!

fix couchup for python3
A tale of strings, bytes and pyhon3, I guess

@klaemo klaemo force-pushed the klaemo:patch-1 branch from 0a62068 to 68c80e4 Feb 6, 2019

@klaemo

This comment has been minimized.

Copy link
Contributor Author

klaemo commented Feb 6, 2019

@wohali Done! Sorry I missed this step.

@wohali wohali merged commit e702598 into apache:master Feb 7, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

janl added a commit that referenced this pull request Feb 7, 2019

@klaemo klaemo deleted the klaemo:patch-1 branch Feb 7, 2019

@wohali wohali referenced this pull request Feb 7, 2019

Merged

2.3.1 Release Proposal #1908

janl added a commit that referenced this pull request Feb 17, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can鈥檛 perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.