Re: PATCH: RM# 1679 - Background process for "restore" not reporting status back to pgAdmin

From: Dave Page <dpage(at)pgadmin(dot)org>
To: Ashesh Vashi <ashesh(dot)vashi(at)enterprisedb(dot)com>
Cc: pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>, Syed Fahar Abbas <fahar(dot)abbas(at)enterprisedb(dot)com>
Subject: Re: PATCH: RM# 1679 - Background process for "restore" not reporting status back to pgAdmin
Date: 2017-01-11 13:19:43
Message-ID: CA+OCxoy=SeU3zCsV3yar0eqYAMMJPC_K9BpcYZ7uVgBRAhp9cQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

Hi

On Wed, Jan 11, 2017 at 12:28 PM, Ashesh Vashi <
ashesh(dot)vashi(at)enterprisedb(dot)com> wrote:

> Hi Dave,
>
> On Wed, Jan 11, 2017 at 12:03 PM, Dave Page <dpage(at)pgadmin(dot)org> wrote:
>
>>
>> KeyError: u'end_time'
>>
>> The status file contains:
>>
>> {"start_time": "2017-01-11 06:27:20.939703 +0000", "pid": 49363,
>> "exit_code": 0, "end_time": "2017-01-11 06:27:28.613456 +0000"}
>>
>
> Thanks for reviewing the patch.
> Please find the updated patch.
>
> Changes:
> - Using now ValueError instead of json.JSONDecodeError, which is subclass
> of ValueError, to allow to it to work with 2.6+ python.
> - Checking the existence of value in dict before accessing it.
>
>
>
That seems to work for me in a brief test on my Mac. :-)

Fahar; are you able to apply and test this patch on Windows and Linux, in
server and desktop modes? Basically all the external processes should be
tested - backup, restore & maintenance (vacuum) etc). I don't have any VMs
available at the moment due to travel.

--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Attachment Content-Type Size
RM1679_v7.patch application/octet-stream 35.6 KB

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message George Gelashvili 2017-01-11 16:54:15 Re: Driver Module
Previous Message Ashesh Vashi 2017-01-11 06:58:36 Re: PATCH: RM# 1679 - Background process for "restore" not reporting status back to pgAdmin