Skip to content

Commit ac70522

Browse files
committed
test/cql-pytest: revert incorrect fix to avoid a warning
In commit 0a71151 I wanted to avoid a incorrect deprecation warning from the Python driver but fixed it in an incorrect way. I never noticed the fix was incorrect because the test was already xfailing, and the incorrect fix just made it fail differently... In this patch I revert that commit. With this revert, I am *not* bringing back the spurious warning - the Python driver bug was already fixed in datastax/python-driver#1103 - so developers with a fairly recent version will no longer see the spurious warning. Both old and new drivers will at least do the correct thing, as it was before that unfortunate commit. Fixes scylladb#8752. Signed-off-by: Nadav Har'El <[email protected]>
1 parent 3b424e3 commit ac70522

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/cql-pytest/test_secondary_index.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ def test_order_of_indexes(scylla_only, cql, test_keyspace):
8181
# server restart), but some of them fail. Once a proper ordering
8282
# is implemented, all cases below should succeed.
8383
def index_used(query, index_name):
84-
assert any([index_name in event.description for event in cql.execute(query, trace=True).one().get_query_trace().events])
84+
assert any([index_name in event.description for event in cql.execute(query, trace=True).get_query_trace().events])
8585
index_used(f"SELECT * FROM {table} WHERE v3 = 1", "my_v3_idx")
8686
index_used(f"SELECT * FROM {table} WHERE v3 = 1 and v1 = 2 allow filtering", "my_v3_idx")
8787
index_used(f"SELECT * FROM {table} WHERE p = 1 and v1 = 1 and v3 = 2 allow filtering", "my_v1_idx")

0 commit comments

Comments
 (0)