Skip to content

Commit 0f03329

Browse files
authored
Merge pull request #160042 from fqazi/blathers/backport-release-26.1-160018
release-26.1: sql: deflake grant_in_txn logictest
2 parents cb0cd72 + bea5711 commit 0f03329

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

pkg/sql/logictest/testdata/logic_test/grant_in_txn

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,14 @@ GRANT role_bar TO role_foo WITH ADMIN OPTION;
191191
statement ok
192192
GRANT role_foo TO testuser WITH ADMIN OPTION;
193193

194+
# GRANTS only wait for the new version to be visible, but future schema changes
195+
# can retry errors if the old version is in use, due to the two version invariant.
196+
retry
197+
query I
198+
SELECT count(*) FROM system.lease WHERE desc_id = 'system.role_members'::REGCLASS::OID GROUP BY desc_id, version;
199+
----
200+
1
201+
194202
# switch to testuser
195203

196204
user testuser

0 commit comments

Comments
 (0)