electric-sql / electric-sql/pglite-build
initdb: REVOKE not supported
- Dominant language
- C
- Stars
- 9
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
in single stage of initdb there are two revoke operation that raise because a tuple is assumed in use in an already open transaction.
`REVOKE ALL ON pg_largeobject FROM PUBLIC;`
`REVOKE CREATE,TEMPORARY ON DATABASE template1 FROM public;`
https://github.com/electric-sql/pglite-build/blob/e4ac5e829c04ce1adb33166cd3b15b6280cac523/pglite-REL_17_4_WASM/pgl_mains.c#L101
nb: in 16.4 the workaround was to not use exit on error when running initdb, but now all errors will block initdb : [panic](https://github.com/electric-sql/pglite/issues/527) or report error properly.
Contributor guide
Research direction
Start at pglite-REL_17_4_WASM/pgl_mains.c around line 101 and trace the initdb stage containing the two REVOKE statements. Compare the 16.4 workaround described in the issue with the current exit-on-error behavior and inspect how the transaction handles these operations. Done means initdb completes without the tuple-related error while preserving proper error reporting.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100