On Monday, December 8, 2025, tushar <[email protected]> wrote: > > > So this query is a failed query and now if i give 'postgres' instead of > 'abc123', Am I not supposed to get the same error , instead of > pg_dump overwriting the postgres executable. >
The code chooses to initialize the archive first, then open the connection. In hindsight, maybe that wasn’t the most user-friendly choice; along with not having a “—clobber” option to overwrite an existing archive. So, no, the error you get depends on whether you managed to clobber the postgres service that is handling the connection attempt. Personally I’d be fine with fixing both behaviors and accept any pushback on making “—no-clobber” the new default; if someone were inclined to write the patch. It’s a failure mode that seems sufficiently rare to not deal with accommodating at this point though. David J.
