Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3xtY-00016n-Vl for pgadmin-hackers@arkaria.postgresql.org; Thu, 05 Apr 2018 05:57:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f3xtX-0001VD-Qv for pgadmin-hackers@arkaria.postgresql.org; Thu, 05 Apr 2018 05:57:11 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f3xtX-0001V2-L6 for pgadmin-hackers@lists.postgresql.org; Thu, 05 Apr 2018 05:57:11 +0000 Received: from mail-qk0-x232.google.com ([2607:f8b0:400d:c09::232]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1f3xtP-0004tD-Fj for pgadmin-hackers@postgresql.org; Thu, 05 Apr 2018 05:57:10 +0000 Received: by mail-qk0-x232.google.com with SMTP id s78so25122398qkl.8 for ; Wed, 04 Apr 2018 22:57:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=enterprisedb-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=wNahB6hosxWjWY/9aUrTINzYp2WehfWCa9RzzxXZ6Qo=; b=DTLEuAmILfngp4N/j3aKH8AU6ri/v6FAKapKOq4NcIeaS2WKwt0QDbLplmWnvGrKkQ UgMaXrFA4I8K3deRUoEA5n8wv7mqTyutf7xav//fh91fYMM9I5tRTK3Z26lW5ASyW/sQ Amsbht9e+yI1nV5HTmDDBzpj6JDkNA00oCpegblmXhJ3dhR4ruEeZvajNb/dWgLRiBik wJ+ObRu2Ba30r1lJ2itUh9BSAG09+nhkeXLadIRMXTqsWzd9cHcWKcvRB5GWrvv1sTI0 2UMmiL968A6fgjTxbmQF01K/jDvdMHsG0oTVOH6osrgVqE7tTiqmm0oXZMD5sL9kVYlh hubA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=wNahB6hosxWjWY/9aUrTINzYp2WehfWCa9RzzxXZ6Qo=; b=SLpQbdxa+4h+Yrlb0m2mZ0SFW+FxKgvKTou2RUfykmCAiFNN539zLbyuitQyrwkOyM xwlxlYuj8vWsJCzWzXJgiGp5Nmx6HmTE1Ow2U/S4i2XBbTCZ4LPielzmtAXf+4z/y9+f 9jWD12SBv9Qb4C4rex3vIgk0nGa4Exfxdx+BfwwK96gjVtx4IiuHBVWZvnR6DzfFmkdx nTPVYmZ+hH1c9/A5CWUvdllx2nZmD+YB0uDhp/G+5fugPc4p77vM+30C1rRLVxL+EPPY 5k+QeZ5bAV7gQqOcf5PlWDJVhqmTZqbEa5IZvBGO4awa2apPGSBlRda+tKCG327JFN1t Bmew== X-Gm-Message-State: ALQs6tBbbnS45hdD19u9Hc8R2jOGzJyHtRmmcJMZfG0V2X0vxX5vRREg gUhnqRCrdnknkyCoutpFh1H2BlBaB6sipADJ7wINXg== X-Google-Smtp-Source: AIpwx49NMWonq7VRn5qQl00u0UaWpvIxilg5AVuPmTKP3KPzNG7debQtuyE9h0OdvmqcQN96fhfAqsu66dAH2NhU4I0= X-Received: by 10.55.75.205 with SMTP id y196mr28969693qka.44.1522907821264; Wed, 04 Apr 2018 22:57:01 -0700 (PDT) MIME-Version: 1.0 Received: by 10.12.182.1 with HTTP; Wed, 4 Apr 2018 22:57:00 -0700 (PDT) In-Reply-To: References: From: Akshay Joshi Date: Thu, 5 Apr 2018 11:27:00 +0530 Message-ID: Subject: Re: pgAdmin 4 commit: Fix a number of broken connection detection scenarios To: Neel Patel Cc: Dave Page , pgadmin-hackers Content-Type: multipart/alternative; boundary="001a114db914b66f950569139b06" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --001a114db914b66f950569139b06 Content-Type: text/plain; charset="UTF-8" Hi Neel This issue is not due to the above fix, if you can see the error it is showing in dashboard.js line no 454 "err = JSON.parse(xhr.responseText);" that code is from long time. I have just added an extra check of the readyState in case of server is down in the above commit. Though it is a bug can you please create a new RM for this. On Thu, Apr 5, 2018 at 10:52 AM, Neel Patel wrote: > Hi Akshay, > > Due to above commit, when user "Drop" any database it gives exception in > browser console. > Check attached screenshot. > > Thanks, > Neel Patel > > > > On Wed, Mar 21, 2018 at 2:08 PM, Dave Page wrote: > >> Fix a number of broken connection detection scenarios. >> >> Branch >> ------ >> master >> >> Details >> ------- >> https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdif >> f;h=637f3b9d1a54df8b9a1bfad9e26f27fdea407683 >> Author: Akshay Joshi >> >> Modified Files >> -------------- >> web/pgadmin/dashboard/static/js/dashboard.js | 58 >> ++++++++++++-------- >> web/pgadmin/static/js/sqleditor/execute_query.js | 62 >> +++++++++++---------- >> .../js/sqleditor/is_new_transaction_required.js | 9 ++++ >> web/pgadmin/tools/sqleditor/__init__.py | 4 +- >> web/pgadmin/tools/sqleditor/static/js/sqleditor.js | 20 ++++--- >> .../tools/sqleditor/tests/test_start_query_tool.py | 2 +- >> .../tools/sqleditor/utils/start_running_query.py | 63 >> ++++++++++------------ >> .../utils/tests/test_start_running_query.py | 15 +++++- >> .../user_management/static/js/user_management.js | 13 ++++- >> .../utils/driver/psycopg2/server_manager.py | 1 + >> .../javascript/sqleditor/execute_query_spec.js | 48 ++++++++++++----- >> .../sqleditor/is_new_transaction_required_spec.js | 14 ++--- >> 12 files changed, 195 insertions(+), 114 deletions(-) >> >> > -- *Akshay Joshi* *Sr. Software Architect * *Phone: +91 20-3058-9517Mobile: +91 976-788-8246* --001a114db914b66f950569139b06 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Neel=C2=A0

This issue is not due to = the above fix, if you can see the error it is showing in dashboard.js line no 454 &qu= ot;err =3D JSON.parse(xhr.responseTex= t);" that code is from long time.=C2=A0
I have just a= dded an extra check of the readyState in case of server is down in the above commit.= =C2=A0
Though it is a bug can you please create a new RM for this= .=C2=A0 =C2=A0

On Thu, Apr 5, 2018 at 10:52 AM, Neel Patel <= neel.patel= @enterprisedb.com> wrote:
<= div dir=3D"ltr">Hi Akshay,

Due to above commit, when use= r "Drop" any database it gives exception in browser console.=C2= =A0
Check attached screenshot.

Thanks,
Neel Patel



On Wed, Mar 21, 2018 at 2:08 PM, Dave Page <<= a href=3D"mailto:dpage@pgadmin.org" target=3D"_blank">dpage@pgadmin.org= > wrote:
Fix a number of broken= connection detection scenarios.

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=3Dpgadmin4.git;a=3Dcom= mitdiff;h=3D637f3b9d1a54df8b9a1bfad9e26f27fdea407683
Author: Akshay Joshi <akshay.joshi@enterprisedb.com>

Modified Files
--------------
web/pgadmin/dashboard/static/js/dashboard.js=C2=A0 =C2=A0 =C2=A0 =C2= =A0| 58 ++++++++++++--------
web/pgadmin/static/js/sqleditor/execute_query.js=C2=A0 =C2=A0| 62 ++++= +++++++----------
.../js/sqleditor/is_new_transaction_required.js=C2=A0 =C2=A0 |=C2=A0 9= ++++
web/pgadmin/tools/sqleditor/__init__.py=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 |=C2=A0 4 +-
web/pgadmin/tools/sqleditor/static/js/sqleditor.js | 20 ++++---
.../tools/sqleditor/tests/test_start_query_tool.py |=C2=A0 2 +-
.../tools/sqleditor/utils/start_running_query.py=C2=A0 =C2=A0| 63 ++++= ++++++------------
.../utils/tests/test_start_running_query.py=C2=A0 =C2=A0 =C2=A0 =C2=A0= | 15 +++++-
.../user_management/static/js/user_management.js=C2=A0 =C2=A0| 13 ++++= -
.../utils/driver/psycopg2/server_manager.py=C2=A0 =C2=A0 =C2=A0 =C2=A0= |=C2=A0 1 +
.../javascript/sqleditor/execute_query_spec.js=C2=A0 =C2=A0 =C2=A0| 48= ++++++++++++-----
.../sqleditor/is_new_transaction_required_spec.js=C2=A0 | 14 ++---
12 files changed, 195 insertions(+), 114 deletions(-)





--
=
Akshay Joshi
Sr. Software Architect
<= /font>

=

Phone: +91 20-3058= -9517
Mobile: +91 976-788-8246
=
--001a114db914b66f950569139b06--