Repository navigation
fix(db): grant service_role on core.construction_projects (#732 follow-up) - #749
Merged
Merged
Conversation
…w-up)
GET /v1/work-logs/public-feed answered 500 in production:
permission denied for table construction_projects
The handler reads with the service client and joins the work log's project. It
had returned 401 to anonymous callers until #732 opened it to the public page it
was built for, and that 401 was hiding the grant gap — the request never reached
the query. Local carries the grant, production does not, so local testing could
not have found it.
Same defect as #481 and migration 352, which granted eight tables but not this
one. A sweep of production found 29 core tables service_role cannot read. 352
covers eight; this covers the one actively breaking a public page. The remaining
twenty are filed separately rather than swept into an incident fix.
Co-Authored-By: Claude Opus 5 <[email protected]>
This was referenced Sep 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
GET /v1/work-logs/public-feedanswered 500 in production:The handler reads with the service client and joins the work log's project. It returned 401 to anonymous callers until #732 opened it to the public page it was built for — and that 401 was hiding the grant gap, because the request never reached the query. Local carries the grant, production does not, so no amount of local testing would have found it.
Same defect as #481 and migration 352, which granted eight tables but not this one.
The wider finding
A sweep of production found 29 core tables
service_rolecannot read. 352 covers eight. This covers the one actively breaking a public page; the remaining twenty are filed separately rather than swept into an incident fix, so each is a decision rather than a side effect.🤖 Generated with Claude Code