Commit Graph

  • 5c537e0a3e Fix type annotation bugs and remove unused imports Simon Willison 2025-10-26 15:52:36 -07:00
  • 2c8e92acf2 Require permissions-debug permission for /-/check endpoint Simon Willison 2025-10-26 11:12:11 -07:00
  • e7ed948238 Use ruff to upgrade Optional[x] to x | None Simon Willison 2025-10-26 10:39:15 -07:00
  • 06b442c894 Applied Black, refs #2544 Simon Willison 2025-10-26 10:05:12 -07:00
  • 6de83bf3a9 Make deploy-latest.yml workflow dispatch-only Simon Willison 2025-10-26 09:51:00 -07:00
  • 4fe1765dc3 Add test for RST heading underline lengths, closes #2544 Simon Willison 2025-10-26 09:44:58 -07:00
  • 653c94209c Remove broken reference to datasette_ensure_permissions in changelog Simon Willison 2025-10-26 09:41:14 -07:00
  • 95286fbb60 Refactor check_visibility() to use Resource objects, refs #2537 Simon Willison 2025-10-26 09:39:51 -07:00
  • 653475edde Fix permissions_debug.html to use takes_parent/takes_child, refs #2530 Simon Willison 2025-10-25 21:34:30 -07:00
  • c652e92049 Bump the python-packages group across 1 directory with 3 updates dependabot[bot] 2025-10-23 13:03:38 +00:00
  • d769e97ab8 Show multiple permission reasons as JSON arrays, refs #2531 Simon Willison 2025-10-25 21:24:05 -07:00
  • ee4fcff5c0 On /-/allowed show reason column if vsible to user Simon Willison 2025-10-25 21:08:59 -07:00
  • ee62bf9bdc Fix minor irritation with /-/allowed UI Simon Willison 2025-10-25 18:02:26 -07:00
  • 7d9d7acb0b Rename test_tables_endpoint.py and remove outdated tests Simon Willison 2025-10-25 17:27:07 -07:00
  • 5530a19d9f Remove Plugin Source column from /-/allowed Simon Willison 2025-10-25 17:16:40 -07:00
  • 6854270da3 Fix for actor restrictions + config bug Simon Willison 2025-10-25 16:47:07 -07:00
  • fb9cd5c72c Transform actor restrictions into SQL permission rules Simon Willison 2025-10-25 15:43:14 -07:00
  • bda69ff1c9 /-/tables.json with no ?q= returns tables Simon Willison 2025-10-25 16:10:00 -07:00
  • 59994e18e4 Fix for intermittent failing test Simon Willison 2025-10-25 15:33:47 -07:00
  • 62b99b1f55 Ran black Simon Willison 2025-10-25 15:25:21 -07:00
  • f18d1ecac6 Better failure message to help debug test Simon Willison 2025-10-25 15:20:57 -07:00
  • e7c7e21277 Ran blacken-docs Simon Willison 2025-10-25 15:01:19 -07:00
  • d7d7ead0ef Ran cog Simon Willison 2025-10-25 14:56:00 -07:00
  • 20ed5a00e7 Ran Black Simon Willison 2025-10-25 14:53:07 -07:00
  • e4f549301b Remove stale self.permissions dictionary and get_permission() method Simon Willison 2025-10-25 14:50:10 -07:00
  • deb0b87e1b Fix cli.py to use ds.actions instead of ds.permissions Simon Willison 2025-10-25 14:47:54 -07:00
  • 86ea2d2c99 Fix test_actor_restricted_permissions to match current API behavior Simon Willison 2025-10-25 14:39:33 -07:00
  • c3eeecfb22 Restore xfail markers for test_actor_restricted_permissions and test_cli_create_token Simon Willison 2025-10-25 14:33:44 -07:00
  • ca435d16f6 Fix test_auth_create_token - template variables and action abbreviation Simon Willison 2025-10-25 14:23:40 -07:00
  • 11fb528958 Fix test_actor_restrictions to match non-cascading permission design Simon Willison 2025-10-25 14:20:05 -07:00
  • 08014c9732 Rename permission_name to action_name Simon Willison 2025-10-25 13:58:58 -07:00
  • de21a4209c Apply database-level allow blocks to view-query action, refs #2510 Simon Willison 2025-10-25 13:53:45 -07:00
  • d300200ba5 Add datasette.resource_for_action() helper method, refs #2510 Simon Willison 2025-10-25 13:33:23 -07:00
  • eff4f931af Fix check_visibility to use action's resource_class, refs #2510 Simon Willison 2025-10-25 13:26:29 -07:00
  • 82cc3d5c86 Migrate view-query permission to SQL-based system, refs #2510 Simon Willison 2025-10-25 10:21:50 -07:00
  • 60ed646d45 Ran Black Simon Willison 2025-10-25 10:08:24 -07:00
  • 66f2dbb64a Fix assert_permissions_checked to handle PermissionCheck dataclass Simon Willison 2025-10-25 10:03:41 -07:00
  • 10ea23a59c Add PermissionCheck dataclass with parent/child fields, refs #2528 Simon Willison 2025-10-25 09:59:21 -07:00
  • 4760cb9e06 Refactor CreateTokenView to use allowed_resources() and rename variables, refs #2528 Simon Willison 2025-10-25 09:56:08 -07:00
  • 13318feb8e Use action.takes_parent/takes_child for resource object creation, refs #2528 Simon Willison 2025-10-25 09:52:07 -07:00
  • a5910f200e Code cleanup: rename variables, remove WHERE 0 check, cleanup files, refs #2528 Simon Willison 2025-10-25 09:50:21 -07:00
  • fabcfd68ad Add datasette.ensure_permission() method, refs #2525, refs #2528 Simon Willison 2025-10-25 09:28:33 -07:00
  • 6df364cb2c Ran cog Simon Willison 2025-10-25 09:04:36 -07:00
  • d0237187c4 Ran prettier Simon Willison 2025-10-25 08:58:46 -07:00
  • ee1d7983ba Mark canned query tests as xfail, refs #2510, refs #2528 Simon Willison 2025-10-25 08:53:33 -07:00
  • bc81975d85 Remove used_default feature from permission system, refs #2528 Simon Willison 2025-10-25 08:53:17 -07:00
  • 5c6b76f2f0 Migrate views from ds.permissions to ds.actions, refs #2528 Simon Willison 2025-10-25 08:53:03 -07:00
  • 5feb5fcf5d Remove permission_allowed hook entirely, refs #2528 Simon Willison 2025-10-25 08:52:48 -07:00
  • 60a38cee85 Run black formatter Simon Willison 2025-10-25 08:45:10 -07:00
  • b5f41772ca Fix view-database-download permission handling Simon Willison 2025-10-24 16:54:06 -07:00
  • ad00bb11f6 Mark test_auth_create_token as xfail, refs #2534 Simon Willison 2025-10-24 16:50:43 -07:00
  • 559a13a8c6 Mark additional canned query tests in test_html.py as xfail, refs #2510 Simon Willison 2025-10-24 16:21:12 -07:00
  • 09194c72f8 Replace permission_allowed_2() with allowed() in test_config_permission_rules.py Simon Willison 2025-10-24 16:18:44 -07:00
  • d07f8944fa Mark canned query and magic parameter tests as xfail, refs #2510 Simon Willison 2025-10-24 15:48:16 -07:00
  • 562a84e3f9 Mark test_cli_create_token as xfail, refs #2534 Simon Willison 2025-10-24 15:46:44 -07:00
  • 0fb148b1f4 Mark test_canned_queries.py module as xfail, refs #2534 Simon Willison 2025-10-24 15:42:03 -07:00
  • e5762b1f22 Mark actor restriction tests as xfail, refs #2534 Simon Willison 2025-10-24 15:40:42 -07:00
  • 182bfaed8e Fix expand_foreign_keys and filters to use new check_visibility() and allowed() signatures Simon Willison 2025-10-24 15:34:20 -07:00
  • 6584c9e03f Remove ensure_permissions() and simplify check_visibility() Simon Willison 2025-10-24 15:24:10 -07:00
  • 30e2f9064b Remove implies_can_view logic from actor restrictions Simon Willison 2025-10-24 14:48:30 -07:00
  • e1582c1424 Fix actor restrictions to work with new actions system Simon Willison 2025-10-24 14:35:23 -07:00
  • dc241e8691 Remove deprecated register_permissions hook Simon Willison 2025-10-24 14:31:42 -07:00
  • fe2084df66 Update test infrastructure to use register_actions hook Simon Willison 2025-10-24 14:31:33 -07:00
  • 59ccf797c4 Rename register_permissions tests to register_actions Simon Willison 2025-10-24 14:31:24 -07:00
  • 7aaff5e3d2 Update tests to use new allowed() method instead of permission_allowed() Simon Willison 2025-10-24 14:06:05 -07:00
  • 387afb0f69 Update tests to use simplified allowed() calls Simon Willison 2025-10-24 13:54:07 -07:00
  • cde1624d0a Update permission hooks to include source_plugin column and simplify menu_links Simon Willison 2025-10-24 13:53:58 -07:00
  • a0659075a3 Migrate all view files to use new allowed() method with Resource objects Simon Willison 2025-10-24 13:53:50 -07:00
  • 224084facc Make allowed() and check_permission_for_resource keyword-only, add default resource Simon Willison 2025-10-24 13:53:43 -07:00
  • 235962cd35 just blacken-docs Simon Willison 2025-10-25 15:02:49 -07:00
  • 785f2ad0bd Apply database-level allow blocks to view-query action, refs #2510 resource-based-permissions Simon Willison 2025-10-25 13:44:24 -07:00
  • 4be7eece8c just prettier, just format shortcuts Simon Willison 2025-10-25 09:04:04 -07:00
  • 4d03e8c12e Refactor AllowedResourcesView to use datasette.allowed_resources() Simon Willison 2025-10-24 12:21:48 -07:00
  • e8b79970fb Implement also_requires to enforce view-database for execute-sql Simon Willison 2025-10-24 11:54:37 -07:00
  • a2994cc5bb Remove automatic parameter namespacing from permission plugins Simon Willison 2025-10-24 11:44:43 -07:00
  • 7c6bc0b902 Fix #2509: Settings-based deny rules now override root user privileges Simon Willison 2025-10-24 10:56:51 -07:00
  • 16b2729847 Fix #2509: Settings-based deny rules now override root user privileges Simon Willison 2025-10-24 10:56:51 -07:00
  • 5138e95d69 Migrate homepage to use bulk allowed_resources() and fix NULL handling in SQL JOINs Simon Willison 2025-10-24 09:58:58 -07:00
  • 8674aaa392 Add parent filter and include_is_private to allowed_resources() Simon Willison 2025-10-24 09:30:37 -07:00
  • 2620938661 Migrate /database view to use bulk allowed_resources() Simon Willison 2025-10-24 00:28:16 -07:00
  • 23715d6c00 Error on startup if invalid setting types Simon Willison 2025-10-24 00:14:28 -07:00
  • 58ac5ccd6e Simplify types in datasette/permissions.py Simon Willison 2025-10-23 21:59:46 -07:00
  • b311f735f9 Fix schema mismatch in empty result query Simon Willison 2025-10-23 21:41:13 -07:00
  • 79879b834a Address PR #2515 review comments Simon Willison 2025-10-23 16:08:56 -07:00
  • a21a1b6c14 Ran blacken-docs Simon Willison 2025-10-23 15:53:49 -07:00
  • c0b5ce04c3 Ran cog Simon Willison 2025-10-23 15:50:26 -07:00
  • 9172020535 Removed unneccessary isinstance(candidate, PermissionSQL) Simon Willison 2025-10-23 15:48:48 -07:00
  • 4d6730e3c4 Remove unused methods from Resource base class Simon Willison 2025-10-23 15:48:31 -07:00
  • c7278c73f3 Ran latest prettier Simon Willison 2025-10-23 15:36:16 -07:00
  • 96d2e16e83 Use allowed_resources_sql() with CTE for table filtering Simon Willison 2025-10-23 15:33:35 -07:00
  • eb5a95ee6e Rewrite tables endpoint to use SQL LIKE instead of Python regex Simon Willison 2025-10-23 15:29:51 -07:00
  • 8e47f99874 Fix /-/tables endpoint: add .json support and correct response format Simon Willison 2025-10-23 15:28:37 -07:00
  • 7d04211559 Fix test_tables_endpoint_config_database_allow by using unique database names Simon Willison 2025-10-23 15:26:14 -07:00
  • d73b6f169f Add register_actions hook to test plugin and improve test Simon Willison 2025-10-23 15:21:55 -07:00
  • 130dad268d Fix test_navigation_menu_links by enabling root_enabled for root actor Simon Willison 2025-10-23 15:19:35 -07:00
  • e333827687 permission_allowed_default_allow_sql Simon Willison 2025-10-23 15:17:29 -07:00
  • 8b098e4b3e Applied Black Simon Willison 2025-10-23 15:08:34 -07:00
  • 06af34240f Fix permission endpoint tests by resolving method signature conflicts Simon Willison 2025-10-23 14:53:07 -07:00
  • 7423c1a999 Fixed some more tests Simon Willison 2025-10-23 14:43:51 -07:00
  • 98493b7587 Fix permission_allowed_sql_bridge to not apply defaults, closes #2526 Simon Willison 2025-10-23 14:34:48 -07:00