cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alek...@apache.org
Subject git commit: cqlsh: ignore empty 'value alias' in DESCRIBE
Date Mon, 21 Oct 2013 15:15:03 GMT
Updated Branches:
  refs/heads/cassandra-2.0 b365edc46 -> 20f1b816b


cqlsh: ignore empty 'value alias' in DESCRIBE

patch by Aleksey Yeschenko; reviewed by Brandon Williams for
CASSANDRA-6139


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/20f1b816
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/20f1b816
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/20f1b816

Branch: refs/heads/cassandra-2.0
Commit: 20f1b816b36befb1c142d883cf9ef76c7be5bce0
Parents: b365edc
Author: Aleksey Yeschenko <aleksey@apache.org>
Authored: Mon Oct 21 23:12:21 2013 +0800
Committer: Aleksey Yeschenko <aleksey@apache.org>
Committed: Mon Oct 21 23:14:37 2013 +0800

----------------------------------------------------------------------
 CHANGES.txt                    | 1 +
 bin/cqlsh                      | 2 +-
 pylib/cqlshlib/cql3handling.py | 4 ++--
 3 files changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/20f1b816/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 02bbc1d..895ffcc 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -25,6 +25,7 @@
  * Fix NPE if StorageService.getOperationMode() is executed before full startup (CASSANDRA-6166)
  * CQL3: support pre-epoch longs for TimestampType (CASSANDRA-6212)
  * Add reloadtriggers command to nodetool (CASSANDRA-4949)
+ * cqlsh: ignore empty 'value alias' in DESCRIBE (CASSANDRA-6139)
 Merged from 1.2:
  * (Hadoop) Require CFRR batchSize to be at least 2 (CASSANDRA-6114)
  * Add a warning for small LCS sstable size (CASSANDRA-6191)

http://git-wip-us.apache.org/repos/asf/cassandra/blob/20f1b816/bin/cqlsh
----------------------------------------------------------------------
diff --git a/bin/cqlsh b/bin/cqlsh
index a062dcd..82c9906 100755
--- a/bin/cqlsh
+++ b/bin/cqlsh
@@ -32,7 +32,7 @@ exit 1
 from __future__ import with_statement
 
 description = "CQL Shell for Apache Cassandra"
-version = "4.0.1"
+version = "4.0.2"
 
 from StringIO import StringIO
 from itertools import groupby

http://git-wip-us.apache.org/repos/asf/cassandra/blob/20f1b816/pylib/cqlshlib/cql3handling.py
----------------------------------------------------------------------
diff --git a/pylib/cqlshlib/cql3handling.py b/pylib/cqlshlib/cql3handling.py
index 3b50cc9..8ec3573 100644
--- a/pylib/cqlshlib/cql3handling.py
+++ b/pylib/cqlshlib/cql3handling.py
@@ -1186,8 +1186,8 @@ class CqlTableDef:
         for attr in ('compaction_strategy_options', 'compression_parameters'):
             setattr(cf, attr, json.loads(getattr(cf, attr)))
 
-        # deal with columns
-        columns = map(CqlColumnDef.from_layout, coldefs)
+        # deal with columns, filter out empty column names (see CASSANDRA-6139)
+        columns = filter(lambda c: c.name, map(CqlColumnDef.from_layout, coldefs))
 
         partition_key_cols = filter(lambda c: c.component_type == u'partition_key', columns)
         partition_key_cols.sort(key=lambda c: c.component_index)


Mime
View raw message