cqlsh prompt includes name of keyspace after failed `use` statement

patch by Robert Stupp; reviewed by Aleksey Yeschenko for CASSANDRA-10369
This commit is contained in:
Robert Stupp 2015-09-29 13:22:21 +02:00
parent 4595ec03f0
commit 13b4bb41c7
2 changed files with 3 additions and 1 deletions

View File

@ -1,4 +1,5 @@
2.2.2
* cqlsh prompt includes name of keyspace after failed `use` statement (CASSANDRA-10369)
* Configurable page size in cqlsh (CASSANDRA-9855)
* Defer default role manager setup until all nodes are on 2.2+ (CASSANDRA-9761)
* Cancel transaction for sstables we wont redistribute index summary

View File

@ -1116,7 +1116,8 @@ class Shell(cmd.Cmd):
def do_use(self, parsed):
ksname = parsed.get_binding('ksname')
if self.perform_simple_statement(SimpleStatement(parsed.extract_orig())):
result, future = self.perform_simple_statement(SimpleStatement(parsed.extract_orig()))
if result:
if ksname[0] == '"' and ksname[-1] == '"':
self.current_keyspace = self.cql_unprotect_name(ksname)
else: