Skip to content

Postgres.app failed to verify "trust" authentication #809

Open

Description

@diek

PostgresApp is up to date. I have not altered anything in PostgresApp in a long time, I use PostgreSQL with Django. Today I tried to start the server and I am faced with:
"django.db.utils.OperationalError: connection to server at "localhost" (::1), port 5432 failed: FATAL: Postgres.app failed to verify "trust" authentication
DETAIL: The helper application terminated with signal 6. For more information see https://postgresapp.com/l/app-permissions/
HINT: You may be able to connect by editing app permission in Postgres.app settings. Please report this error to https://github.com/PostgresApp/PostgresApp/issues"

With Django all the connection variables are set including user and password.

I cannot connect to the database via the PostgresApp either, with a similar error.
"connection to server at "localhost" (::1), port 5432 failed: FATAL: Postgres.app failed to verify "trust" authentication
DETAIL: The helper application terminated with signal 6. For more information see https://postgresapp.com/l/app-permissions/
HINT: You may be able to connect by editing app permission in Postgres.app settings. Please report this error to https://github.com/PostgresApp/PostgresApp/issues"

Activity

  1. diek commented on Mar 29, 2025

    @diek
    Author
  2. tbussmann commented on Mar 30, 2025

    @tbussmann
    Member

    Thanks for reporting this. We were trying to chase this bug for quite some time (see #749).

    I followed the directions on [...] and it did not work.

    Could you clarify this to me - did you find the entry for your django application in state Ask but changing it to Allow did not help? Or was it not listed there? Both could be possible in case the helper is crashing with SIGABRT.

    I cannot connect to the database via the PostgresApp either, with a similar error.

    By this, do you mean you get the error when double clicking on a database in the GUI of Postgres.app?

    As a quick remedy, you can either activate password authentication or disable permission dialogs.

    But I'd rather like to collect as much information on this rare crash as possible: Could you please open Console.app and have look under "Crash Reports" for anything from PostgresPermissionDialog and attach this here?

    Other users have reported that stopping and starting the server in question or quitting Postgres.app (via the Menu icon) and starting it again did change the situation. Could you try this and report back?

    TIA!

  3. denver768 commented on May 1, 2025

    @denver768

    I suddenly got this error this morning. Like others, I had not changed anything and am getting the identical error above. In trying to connect via the postgres.app, via my go backend, or pgAdmin any other method. i tried restarting via the Menu icon as suggested above. I pulled my console.app and have a bunch of PostgresPermissionDialog crash reports. Please advise as I can send this over.

  4. denver768 commented on May 1, 2025

    @denver768

    Part of one of the crash reports.
    Process: PostgresPermissionDialog [21632]
    Path: /Applications/Postgres.app/Contents/MacOS/PostgresPermissionDialog
    Identifier: PostgresPermissionDialog
    Version: ???
    Code Type: ARM-64 (Native)
    Parent Process: Exited process [21631]
    User ID: 501

    Date/Time: 2025-05-01 11:14:37.4650 -0600
    OS Version: macOS 15.3.2 (24D81)
    Report Version: 12
    Anonymous UUID: 0050D83A-A1F0-E832-C9F7-51A6E6429B73

    Sleep/Wake UUID: C26C3D3A-A6B8-4996-8A55-4ACB57128F0B

    Time Awake Since Boot: 15000 seconds
    Time Since Wake: 611 seconds

    System Integrity Protection: enabled

    Crashed Thread: 0 Dispatch queue: com.apple.main-thread

    Exception Type: EXC_CRASH (SIGABRT)
    Exception Codes: 0x0000000000000000, 0x0000000000000000

    Termination Reason: Namespace SIGNAL, Code 6 Abort trap: 6
    Terminating Process: PostgresPermissionDialog [21632]

    Application Specific Information:
    abort() called

  5. jakob commented on May 7, 2025

    @jakob
    Member

    @denver768 Can you paste the full crash report? The most important part would be the part with the stack traces. You can also send it to jakob@eggerapps.at if you don't want to paste them online. (If you have multiple crash reports, please send all of them!)

  6. jakob commented on Nov 11, 2025

    @jakob
    Member

    @tbussmann and I have been investigating this issue.

    We think this bug happens when you start a PostgreSQL server, and then log out from your user account. The PostgreSQL server keeps running (see #834), but it no longer has a GUI session associated with it. When the helper app tries to show a permission dialog, it can't find the GUI session and crashes.

    So the workaround for this bug should be simple: just stop and start the PostgreSQL server.

    In the most recent update of Postgres.app, we've already added fallback code that allows it to read user defaults even when there is no GUI session available. This should fix the common case when you have connected to the PostgreSQL server before.

    However, it still fails when an app connects for the first time. Then Postgres.app needs to show a dialog, which is not possible. In the upcoming update, we try to catch this specific crash and show an error message recommending to restart the server. It's not ideal, but should at least give people actionable advice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions