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

pybind/ceph_argparse: handle non ascii unicode args #8943

Merged
merged 1 commit into from Jul 22, 2016

Conversation

tchaikov
Copy link
Contributor

@tchaikov tchaikov commented May 5, 2016

we raise UnicodeDecodeError at seeing non-ascii args if we fail to match
it with any command signatures. instead, we should use a unicode string
for representing the error in that case. please note, the exception is not
printed at all in real-world. =)

Fixes: http://tracker.ceph.com/issues/12287
Signed-off-by: Kefu Chai tchaikov@gmail.com

@tchaikov
Copy link
Contributor Author

tchaikov commented May 6, 2016

pkg_resources.DistributionNotFound: ceph-disk==1.0.0
/home/jenkins-build/build/workspace/ceph-pull-requests/qa/workunits/ceph-helpers.sh:474: run_osd:  return 1

the failure is not relevant.

we raise UnicodeDecodeError at seeing non-ascii args if we fail to match
it with any command signatures. instead, we should use a unicode string
for representing the error in that case. please note, the exception is
not printed at all in real-world. =)

Fixes: http://tracker.ceph.com/issues/12287
Signed-off-by: Kefu Chai <kchai@redhat.com>
@tchaikov
Copy link
Contributor Author

@dachary could you help review this PR?

@ghost
Copy link

ghost commented Jul 22, 2016

Yikes, tricky :-( Good job :-)

Reviewed-by: Loic Dachary <ldachary@redhat.com>

as soon as make check verifies it does pass the test.

@tchaikov tchaikov merged commit 65bd58b into ceph:master Jul 22, 2016
@tchaikov tchaikov deleted the wip-12287 branch September 5, 2016 05:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant