• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / supautils / 23022592194
89%

Build:
DEFAULT BRANCH: master
Ran 12 Mar 2026 08:34PM UTC
Jobs 1
Files 10
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

12 Mar 2026 08:33PM UTC coverage: 88.656% (+0.2%) from 88.441%
23022592194

push

github

web-flow
feat: add hint when GRANT privilege is missing (#178)

Whenever we hit an ERRCODE_INSUFFICIENT_PRIVILEGE, we give a hint for
the precise privilege missing for the current role.

Simple SELECT:

```sql
select from hint_target;
ERROR:  permission denied for table hint_target
HINT:  Grant the required privileges to the current role with: GRANT SELECT ON public.hint_target TO hint_role;
```

If multiple privileges are missing on an upsert:

```sql
insert into hint_target(id)
values (1)
on conflict (id) do update set id = excluded.id;
ERROR:  permission denied for table hint_target
HINT:  Grant the required privileges to the current role with: GRANT SELECT, INSERT, UPDATE ON public.hint_target TO hint_role;
```

NOTES:

- This is done by adding an ExecutorStart_hook which only purpose is to
  catch the ERRCODE_INSUFFICIENT_PRIVILEGE error and override the empty
  privilege.
- Also adds a loadtest for a simple select to ensure the perf loss is not great (the impact is around 1-2%, mostly due to the `is_hint_role` check)
- Hints for views under pg 18 are not working and left as TODO, hints for views on all the previous versions work normally

92 of 101 new or added lines in 2 files covered. (91.09%)

1 existing line in 1 file now uncovered.

1102 of 1243 relevant lines covered (88.66%)

31.94 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
4
91.58
0.18% src/supautils.c
5
88.1
src/permission_hints.c

Uncovered Existing Lines

Lines Coverage ∆ File
1
91.58
0.18% src/supautils.c
Jobs
ID Job ID Ran Files Coverage
1 23022592194.1 12 Mar 2026 08:34PM UTC 10
88.66
GitHub Action Run
Source Files on build 23022592194
  • Tree
  • List 10
  • Changed 2
  • Source Changed 2
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #23022592194
  • 6d20b577 on github
  • Prev Build on master (#22863736634)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc