(cqlsh) fix formatting bytearray values patch by Stefania Alborghetti; reviewed by Jim Witschey for CASSANDRA-10839
Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/26dc07b7 Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/26dc07b7 Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/26dc07b7 Branch: refs/heads/cassandra-3.0 Commit: 26dc07b7db6334fd7d7f54ba0f4e8359117e60e9 Parents: c0747d2 Author: Stefania Alborghetti <stefania.alborghe...@datastax.com> Authored: Tue Dec 22 14:18:26 2015 +0100 Committer: Aleksey Yeschenko <alek...@apache.org> Committed: Thu Jan 14 15:48:10 2016 +0000 ---------------------------------------------------------------------- CHANGES.txt | 1 + pylib/cqlshlib/formatting.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cassandra/blob/26dc07b7/CHANGES.txt ---------------------------------------------------------------------- diff --git a/CHANGES.txt b/CHANGES.txt index 552aca2..9c73adf 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -1,4 +1,5 @@ 2.1.13 + * (cqlsh) fix formatting bytearray values (CASSANDRA-10839) * (cqlsh) Add request timeout option to cqlsh (CASSANDRA-10686) * Avoid AssertionError while submitting hint with LWT (CASSANDRA-10477) * If CompactionMetadata is not in stats file, use index summary instead (CASSANDRA-10676) http://git-wip-us.apache.org/repos/asf/cassandra/blob/26dc07b7/pylib/cqlshlib/formatting.py ---------------------------------------------------------------------- diff --git a/pylib/cqlshlib/formatting.py b/pylib/cqlshlib/formatting.py index c88ffaf..abb4896 100644 --- a/pylib/cqlshlib/formatting.py +++ b/pylib/cqlshlib/formatting.py @@ -126,7 +126,7 @@ def formatter_for(typname): @formatter_for('bytearray') def format_value_blob(val, colormap, **_): - bval = '0x' + binascii.hexlify(val) + bval = '0x' + binascii.hexlify(str(val)) return colorme(bval, colormap, 'blob') formatter_for('buffer')(format_value_blob)