aminghadersohi commented on code in PR #43800:
URL: https://github.com/apache/superset/pull/43800#discussion_r3917629887


##########
superset/security/manager.py:
##########
@@ -2626,7 +2627,7 @@ def get_schemas_accessible_by_user(
         self,
         database: "Database",
         catalog: Optional[str],
-        schemas: set[str],
+        schemas: Collection[str],

Review Comment:
   NIT: `Collection[str]` is also satisfied by `str`, so `set("public")` would 
silently shred a bare string into `{'p','u','b','l','i','c'}` instead of 
failing type check as `set[str]` did. No caller does this and the intersection 
still prevents any over-grant, but `AbstractSet[str] | list[str]` would keep 
the widening to just the shape you actually need.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to