pgAdmin debugger failure when search_path set

From: Aditya Toshniwal <aditya(dot)toshniwal(at)enterprisedb(dot)com>
To: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: pgAdmin debugger failure when search_path set
Date: 2020-08-06 11:17:21
Message-ID: CAM9w-_=MfokguDFWvUyBFVQcs_n55Fk5DEodpDWfXiBGb_-Y9Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi Dave/Team,

I've been working on an issue to make debugger work no matter what the
search patch is set. I've managed to call the appropriate functions from
pgAdmin using a schema qualified name with no issues. However, the internal
calls in the function don't look schema qualified.
For instance,
I have two schemas "public" where the debugger is installed and "other"
where my user defined function is. I set the search_path to "other" on the
database. Calling plpgsql_oid_debug directly fails because of the search
path set, but I can call the debugger functions with
public.plpgsql_oid_debug, but it fails with:
ERROR: function pldbg_oid_debug(oid) does not exist LINE 1: SELECT
pldbg_oid_debug($1) ^ HINT: No function matches the given name and argument
types. You might need to add explicit type casts. QUERY: SELECT
pldbg_oid_debug($1) CONTEXT: SQL function "plpgsql_oid_debug" during
inlining

How to approach this ? It is inconvenient for users to remove their
search_path to make debugger work.

--
Thanks,
Aditya Toshniwal
pgAdmin hacker | Sr. Software Engineer | *edbpostgres.com*
<http://edbpostgres.com>
"Don't Complain about Heat, Plant a TREE"

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Akshay Joshi 2020-08-06 11:23:54 pgAdmin 4 commit: Fixed ssh tunnel hang issue when the user tries to di
Previous Message Murtuza Zabuawala 2020-08-06 10:45:32 Re: [pgAdmin][RM5716] AJAX to generate the charts continues to fire after we disconnect the server