home / github / issue_comments

Menu
  • GraphQL API

issue_comments: 1074180312

This data as json

html_url issue_url id node_id user created_at updated_at author_association body reactions issue performed_via_github_app
https://github.com/simonw/datasette/issues/1676#issuecomment-1074180312 https://api.github.com/repos/simonw/datasette/issues/1676 1074180312 IC_kwDOBm6k_c5ABrDY 9599 2022-03-21T17:16:45Z 2022-03-21T17:16:45Z OWNER When looking at this code earlier I assumed that the following would check each permission in turn and fail if any of them failed: ```python await self.ds.ensure_permissions( request.actor, [ ("view-table", (database, table)), ("view-database", database), "view-instance", ] ) ``` But it's not quite that simple: if any of them fail, it fails... but if an earlier one returns `True` the whole stack passes even if there would have been a failure later on! If that is indeed the right abstraction, I need to work to make the documentation as clear as possible. {"total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0} 1175690070  
Powered by Datasette · Queries took 1.065ms