Re: [pgAdmin4][Patch] Add formatted error message support in psycopg2

From: Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>
To: Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com>
Cc: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: Re: [pgAdmin4][Patch] Add formatted error message support in psycopg2
Date: 2016-04-01 10:23:33
Message-ID: CAG7mmoxUbLPaEsEygo3UebdR=NpgqLmed-0spRS+3EWPpMhhYQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi Akshay,

I've update the patch a little bit as discussed offline.
Also, renamed the variable 'is_cancel_transaction' to 'execution_aborted',
and enum value to 'ASYNC_EXECUTION_ABORTED'.

--

Thanks & Regards,

Ashesh Vashi
EnterpriseDB INDIA: Enterprise PostgreSQL Company
<http://www.enterprisedb.com>

*http://www.linkedin.com/in/asheshvashi*
<http://www.linkedin.com/in/asheshvashi>

On Thu, Mar 31, 2016 at 4:55 PM, Akshay Joshi <akshay(dot)joshi(at)enterprisedb(dot)com
> wrote:

> Hi
>
> Please ignore the last two patches, While implementing Query Tool I have
> found one more issue in poll function when run queries like "create table"
> , "insert table". I have added exception handling before fetching the row
> from the cursor directly.
>
> Attached is the modified patch. Please review it and if it looks good
> please commit it.
>
> On Thu, Mar 31, 2016 at 12:37 PM, Akshay Joshi <
> akshay(dot)joshi(at)enterprisedb(dot)com> wrote:
>
>> Hi
>>
>> On Tue, Mar 29, 2016 at 8:09 PM, Akshay Joshi <akshay(dot)joshi(at)enterprisedb
>> .com> wrote:
>>
>>> Hi All
>>>
>>> While implementing Query Tool, I came to know we need error message's
>>> with some extra information and also I have faced one issue regarding
>>> asynchronous connection polling. I have added support for formatted error
>>> message and also fixed the issue.
>>>
>>> Attached is the patch file. Please review it and let me know the review
>>> comments if any.
>>>
>>
>> Apart from above, today I fixed one more issue. In case of user cancel
>> the running transaction, poll function of psycopg2 returns
>> psycopg2.extensions.POLL_OK, which is mislead by the caller of the
>> function, so I have added one flag which will be true if user purposely
>> cancel the transaction and from our poll function we return new status i.e.
>> ASYNC_CANCEL_TRANSACTION.
>>
>> Attached is the modified patch. Please review it and if it looks good
>> please commit it.
>>
>>>
>>>
>>> --
>>> *Akshay Joshi*
>>> *Principal Software Engineer *
>>>
>>>
>>>
>>> *Phone: +91 20-3058-9517Mobile: +91 976-788-8246*
>>>
>>
>>
>>
>> --
>> *Akshay Joshi*
>> *Principal Software Engineer *
>>
>>
>>
>> *Phone: +91 20-3058-9517Mobile: +91 976-788-8246*
>>
>
>
>
> --
> *Akshay Joshi*
> *Principal Software Engineer *
>
>
>
> *Phone: +91 20-3058-9517Mobile: +91 976-788-8246*
>
>
> --
> Sent via pgadmin-hackers mailing list (pgadmin-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgadmin-hackers
>
>

Attachment Content-Type Size
psycopg2.patch application/octet-stream 9.1 KB

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Khushboo Vashi 2016-04-01 10:26:57 Re: [pgAdmin4][Patch]: Backgrid StringDepsCell
Previous Message Ashesh Vashi 2016-04-01 10:06:14 Re: Tree reload & panel close issue after saving new node on server [pgadmin4]