Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fTm6s-0001MU-9H for pgadmin-hackers@arkaria.postgresql.org; Fri, 15 Jun 2018 10:37:38 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fTm6q-0008P6-PM for pgadmin-hackers@arkaria.postgresql.org; Fri, 15 Jun 2018 10:37:36 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fTm6p-0008Ot-H6 for pgadmin-hackers@lists.postgresql.org; Fri, 15 Jun 2018 10:37:36 +0000 Received: from mail-wr0-x243.google.com ([2a00:1450:400c:c0c::243]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1fTm6k-0005hA-4H for pgadmin-hackers@postgresql.org; Fri, 15 Jun 2018 10:37:33 +0000 Received: by mail-wr0-x243.google.com with SMTP id o12-v6so9417076wrm.12 for ; Fri, 15 Jun 2018 03:37:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pgadmin-org.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=1rC7DBPoqrm9xsA+HjdxgQDuwWtPOqQJLP/984WyARc=; b=1E4QDittm/HHFgq9G5eyVM0HRZmTd8HpPl216+BCwDQbjxqBGJItv0zK0mvGFNhPog aRYRVnjoq+/5+GJkrlLNOPp+o22iX4o1N+XyX2bxZuOG7RKsfQ2OvYP5i9lleRNpHY2z xnuqRgq+KNkPwvHRIEOP31UiTZP04RQietCfnYLoG9HvtP2oomvN2Tf76IAI04Sg/Due eJWuhWOMxGF1/7apkaJnwlGoth2aRk0Eqsz1QHd+Njv1y7viAxMMUTVI0M9Nv1NLArIm qkxyCS8D3/MlK8nH/EVtt1FspYgtH7XyLbS1D4DUtMecVLFaHniNuhZVwvGd1vQU+4wu wbqA== 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=1rC7DBPoqrm9xsA+HjdxgQDuwWtPOqQJLP/984WyARc=; b=icg469QRgsfNGOgP+1+rvT3vCI+XGxXUHJN0CMZ20LSEKwLnS3arvHoRxC7FUIFB0o AeSSuv8b6FgvDVkjyiawBhTodJDNFF6BOWKXolGy7VY+zl2E8FH1mfAyKhm0P74A2VNK bbyQat3B1vmcqgRQ5VS4i6klNIckapbpgzgQeBhHtQUY3JvW2rrkvglr/IgBgzFWC4ne u2YKoN/j3BBtryl/gOqhpJhvRnsy1ddFN5NIcbIGJMzCo9BzmX63rZWT5ptjtEbAR1bF tniVKdmgNE1P6S0SPBIkWiiQVPI7GkAD/O3l8DXbjuIGeTHGOWSY+ZskMSy95FIFMoZy T6vQ== X-Gm-Message-State: APt69E1EpbepIkKPTOb/rbMulAztCtlAOoW1DG7MZqXhes+PkdBsVS6l vzWcB90SegvFIg1hMK2Z6u+hWrv3Ft8YVZbUseXJqg== X-Google-Smtp-Source: ADUXVKJo/ol7OyLDn6A1TJvyOO/h+DknQ/SxhD8TWueSSMRs2yFlISgkeZ9S0FJziFmrfUh1AI27L2Kyl6GdhAxV/c8= X-Received: by 2002:adf:f40a:: with SMTP id g10-v6mr1147440wro.256.1529059047670; Fri, 15 Jun 2018 03:37:27 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a1c:2907:0:0:0:0:0 with HTTP; Fri, 15 Jun 2018 03:37:26 -0700 (PDT) In-Reply-To: References: From: Dave Page Date: Fri, 15 Jun 2018 11:37:26 +0100 Message-ID: Subject: Re: [pgadmin4][Patch]: Test cases for the backup module To: Khushboo Vashi Cc: Victoria Henry , Joao De Almeida Pereira , pgadmin-hackers Content-Type: multipart/alternative; boundary="0000000000006094ce056eabcd4e" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --0000000000006094ce056eabcd4e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Thanks, applied with a few tweaks to remove some unused imports and a couple of variables. On Fri, Jun 15, 2018 at 8:13 AM, Khushboo Vashi < khushboo.vashi@enterprisedb.com> wrote: > Hi, > > Please find the attached updated patch. > > On Wed, Jun 13, 2018 at 5:42 PM, Khushboo Vashi < > khushboo.vashi@enterprisedb.com> wrote: > >> Hi Victoria, >> >> >> On Tue, Jun 12, 2018 at 9:06 PM, Victoria Henry >> wrote: >> >>> Hi Khushboo >>> can you explain a little bit more this while loop? >>> >>> >>> cnt =3D 0 >>> while 1: >>> if cnt > 1: >>> break >>> # Check the process list >>> response1 =3D self.tester.get('/misc/bgprocess/?_=3D'.format( >>> random.randint(1, 9999999))) >>> self.assertEquals(response1.status_code, 200) >>> process_list =3D json.loads(response1.data.decode('utf-8')) >>> >>> if len(process_list) > 0 and 'execution_time' in process_list[0]: >>> break >>> time.sleep(0.5) >>> cnt +=3D 1 >>> >>> From what it looks like this will only run twice, maybe a for would be = a >>> better solution because we know it will only run twice. Also are we sur= e we >>> only want it to run twice? >>> >>> The code waits till the background process completes. So, while I >> originally developed, not intended to run only twice. >> But after that I put a kind of break point and that remains there. So, I >> will remove that if condition which is not required. >> > I have made maximum 5 attempts. > >> We are using PyCharm to do our developments and we notice there are a bi= g >>> group of unused variables throughout. We should remove them if they are= not >>> needed. Not sure if your editor also shows that information or not. >>> >> Do you know if there is a configuration in pycodestyle to enable the >>> check for unused variables? That would help a lot. >>> >>> Removed unused local variables. > >> Thanks for sharing the information. >> >>> The code >>> >>> assert 'execution_time' in process_list[0] >>> assert 'stime' in process_list[0] >>> assert 'exit_code' in process_list[0] >>> assert process_list[0]['exit_code'] in self.expected_exit_code >>> >>> in test_Create_restore_job should use self.assertEqual or similar from >>> unittest instead of plain assert. Because when something fails we do >>> not have a way to understand what was wrong. >>> >> Will do. >> > Done > >> The tests on the restore are still failing GreenPlum. >>> >> It is failing because, Restore is not working with GreenPlum. Can you >> please look into the Restore functionality for GPDB? >> >> >> Thanks, >> Khushboo >> >>> =E2=80=8B >>> >>> >>> Thanks, > Khushboo > >> >>> Thanks >>> Victoria & Joao >>> >>> On Tue, Jun 12, 2018 at 6:44 AM Khushboo Vashi < >>> khushboo.vashi@enterprisedb.com> wrote: >>> >>>> Please find the attached updated patch with some code cleanup. >>>> >>>> On Tue, Jun 12, 2018 at 3:54 PM, Khushboo Vashi < >>>> khushboo.vashi@enterprisedb.com> wrote: >>>> >>>>> Hi, >>>>> >>>>> Please find the attached patch excluding feature test cases. >>>>> Python test cases are working fine, so we can commit this patch. I am >>>>> working on fixing the feature tests which are failing on the differen= t >>>>> window sizes. >>>>> >>>>> Thanks, >>>>> Khushboo >>>>> >>>>> On Fri, Jun 8, 2018 at 2:38 PM, Dave Page wrote: >>>>> >>>>>> Hi >>>>>> >>>>>> On Fri, Jun 8, 2018 at 6:33 AM, Khushboo Vashi < >>>>>> khushboo.vashi@enterprisedb.com> wrote: >>>>>> >>>>>>> Hi Dave, >>>>>>> >>>>>>> As per our discussion I have changed the window size to 1280X800, >>>>>>> before it was 1280X900. >>>>>>> Please find the attached updated patch >>>>>>> >>>>>> >>>>>> I'm not sure that actually made any difference on my system. The >>>>>> window continued to look taller than it is wide, so I wonder if the = code to >>>>>> set the size is being ignored, or is at the wrong place? >>>>>> >>>>>> Anyway, I got 10 failures with this patch :-( >>>>>> >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> >>>>>> ERROR: runTest (pgadmin.feature_tests.pg_util >>>>>> ities_backup_restore_test.PGUtilitiesBackupFeatureTest) >>>>>> >>>>>> Test for PG utilities - Backup and Restore >>>>>> >>>>>> ------------------------------------------------------------ >>>>>> ---------- >>>>>> >>>>>> Traceback (most recent call last): >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/pg_utili= ties_backup_restore_test.py", >>>>>> line 97, in runTest >>>>>> >>>>>> self.page.find_by_xpath("//div[contains(@class,'wcFloatingFo >>>>>> cus')" >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 171, in find_by_xpath >>>>>> >>>>>> lambda driver: driver.find_element_by_xpath(xpath) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 263, in wait_for_element >>>>>> >>>>>> return self._wait_for("element to exist", element_if_it_exists) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 337, in _wait_for >>>>>> >>>>>> "Timed out waiting for " + waiting_for_message >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packa >>>>>> ges/selenium/webdriver/support/wait.py", line 80, in until >>>>>> >>>>>> raise TimeoutException(message, screen, stacktrace) >>>>>> >>>>>> TimeoutException: Message: Timed out waiting for element to exist >>>>>> >>>>>> >>>>>> >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> >>>>>> ERROR: runTest (pgadmin.feature_tests.xss_che >>>>>> cks_pgadmin_debugger_test.CheckDebuggerForXssFeatureTest) >>>>>> >>>>>> Tests to check if Debugger is vulnerable to XSS >>>>>> >>>>>> ------------------------------------------------------------ >>>>>> ---------- >>>>>> >>>>>> Traceback (most recent call last): >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/xss_chec= ks_pgadmin_debugger_test.py", >>>>>> line 42, in runTest >>>>>> >>>>>> self._function_node_expandable() >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/xss_chec= ks_pgadmin_debugger_test.py", >>>>>> line 57, in _function_node_expandable >>>>>> >>>>>> self.page.select_tree_item("a_test_function()") >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 135, in select_tree_item >>>>>> >>>>>> "' and @class=3D'aciTreeItem']").click() >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 171, in find_by_xpath >>>>>> >>>>>> lambda driver: driver.find_element_by_xpath(xpath) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 263, in wait_for_element >>>>>> >>>>>> return self._wait_for("element to exist", element_if_it_exists) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadm= in_page.py", >>>>>> line 337, in _wait_for >>>>>> >>>>>> "Timed out waiting for " + waiting_for_message >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packa >>>>>> ges/selenium/webdriver/support/wait.py", line 80, in until >>>>>> >>>>>> raise TimeoutException(message, screen, stacktrace) >>>>>> >>>>>> TimeoutException: Message: Timed out waiting for element to exist >>>>>> >>>>>> >>>>>> >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> >>>>>> ERROR: runTest (pgadmin.tools.backup.tests.te >>>>>> st_create_backup_job.BackupJobTest) >>>>>> >>>>>> When backup the object with the default options >>>>>> >>>>>> ------------------------------------------------------------ >>>>>> ---------- >>>>>> >>>>>> Traceback (most recent call last): >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/tes= t_create_backup_job.py", >>>>>> line 58, in runTest >>>>>> >>>>>> self.assertNotIn >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/tes= t_backup_utils.py", >>>>>> line 33, in run_backup_job >>>>>> >>>>>> random.randint(1, 9999999))) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 830, in get >>>>>> >>>>>> return self.open(*args, **kw) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/testing.py", >>>>>> line 127, in open >>>>>> >>>>>> follow_redirects=3Dfollow_redirects) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 803, in open >>>>>> >>>>>> response =3D self.run_wsgi_app(environ, buffered=3Dbuffered) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 716, in run_wsgi_app >>>>>> >>>>>> rv =3D run_wsgi_app(self.application, environ, buffered=3Dbuffer= ed) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 923, in run_wsgi_app >>>>>> >>>>>> app_rv =3D app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1997, in __call__ >>>>>> >>>>>> return self.wsgi_app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1985, in wsgi_app >>>>>> >>>>>> response =3D self.handle_exception(e) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1540, in handle_exception >>>>>> >>>>>> reraise(exc_type, exc_value, tb) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1982, in wsgi_app >>>>>> >>>>>> response =3D self.full_dispatch_request() >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1614, in full_dispatch_request >>>>>> >>>>>> rv =3D self.handle_user_exception(e) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1517, in handle_user_exception >>>>>> >>>>>> reraise(exc_type, exc_value, tb) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1612, in full_dispatch_request >>>>>> >>>>>> rv =3D self.dispatch_request() >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1598, in dispatch_request >>>>>> >>>>>> return self.view_functions[rule.endpoint](**req.view_args) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask_login.py", >>>>>> line 792, in decorated_view >>>>>> >>>>>> return func(*args, **kwargs) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/__init_= _.py", >>>>>> line 62, in index >>>>>> >>>>>> return make_response(response=3DBatchProcess.list()) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/process= es.py", >>>>>> line 584, in list >>>>>> >>>>>> details =3D desc.details(p.command, args) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.= py", >>>>>> line 159, in details >>>>>> >>>>>> name, host, port =3D self.get_server_details() >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.= py", >>>>>> line 122, in get_server_details >>>>>> >>>>>> host =3D manager.local_bind_host if manager.use_ssh_tunnel else >>>>>> s.host >>>>>> >>>>>> AttributeError: 'NoneType' object has no attribute 'use_ssh_tunnel' >>>>>> >>>>>> >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> >>>>>> ERROR: runTest (pgadmin.tools.maintenance.tes >>>>>> ts.test_create_maintenance_job.MaintenanceJobTest) >>>>>> >>>>>> When maintenance the object with the default options >>>>>> >>>>>> ------------------------------------------------------------ >>>>>> ---------- >>>>>> >>>>>> Traceback (most recent call last): >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/maintenance/tes >>>>>> ts/test_create_maintenance_job.py", line 71, in runTest >>>>>> >>>>>> random.randint(1, 9999999))) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 830, in get >>>>>> >>>>>> return self.open(*args, **kw) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/testing.py", >>>>>> line 127, in open >>>>>> >>>>>> follow_redirects=3Dfollow_redirects) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 803, in open >>>>>> >>>>>> response =3D self.run_wsgi_app(environ, buffered=3Dbuffered) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 716, in run_wsgi_app >>>>>> >>>>>> rv =3D run_wsgi_app(self.application, environ, buffered=3Dbuffer= ed) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 923, in run_wsgi_app >>>>>> >>>>>> app_rv =3D app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1997, in __call__ >>>>>> >>>>>> return self.wsgi_app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1985, in wsgi_app >>>>>> >>>>>> response =3D self.handle_exception(e) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1540, in handle_exception >>>>>> >>>>>> reraise(exc_type, exc_value, tb) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1982, in wsgi_app >>>>>> >>>>>> response =3D self.full_dispatch_request() >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1614, in full_dispatch_request >>>>>> >>>>>> rv =3D self.handle_user_exception(e) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1517, in handle_user_exception >>>>>> >>>>>> reraise(exc_type, exc_value, tb) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1612, in full_dispatch_request >>>>>> >>>>>> rv =3D self.dispatch_request() >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1598, in dispatch_request >>>>>> >>>>>> return self.view_functions[rule.endpoint](**req.view_args) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask_login.py", >>>>>> line 792, in decorated_view >>>>>> >>>>>> return func(*args, **kwargs) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/__init_= _.py", >>>>>> line 62, in index >>>>>> >>>>>> return make_response(response=3DBatchProcess.list()) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/process= es.py", >>>>>> line 584, in list >>>>>> >>>>>> details =3D desc.details(p.command, args) >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.= py", >>>>>> line 159, in details >>>>>> >>>>>> name, host, port =3D self.get_server_details() >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.= py", >>>>>> line 122, in get_server_details >>>>>> >>>>>> host =3D manager.local_bind_host if manager.use_ssh_tunnel else >>>>>> s.host >>>>>> >>>>>> AttributeError: 'NoneType' object has no attribute 'use_ssh_tunnel' >>>>>> >>>>>> >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >>>>>> >>>>>> ERROR: runTest (pgadmin.tools.restore.tests.t >>>>>> est_create_restore_job.RestoreJobTest) >>>>>> >>>>>> When restore the object with the default options >>>>>> >>>>>> ------------------------------------------------------------ >>>>>> ---------- >>>>>> >>>>>> Traceback (most recent call last): >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/restore/tests/te= st_create_restore_job.py", >>>>>> line 95, in runTest >>>>>> >>>>>> self.create_backup() >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/restore/tests/te= st_create_restore_job.py", >>>>>> line 86, in create_backup >>>>>> >>>>>> self.assertNotIn >>>>>> >>>>>> File "/Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/tes= t_backup_utils.py", >>>>>> line 33, in run_backup_job >>>>>> >>>>>> random.randint(1, 9999999))) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 830, in get >>>>>> >>>>>> return self.open(*args, **kw) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/testing.py", >>>>>> line 127, in open >>>>>> >>>>>> follow_redirects=3Dfollow_redirects) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 803, in open >>>>>> >>>>>> response =3D self.run_wsgi_app(environ, buffered=3Dbuffered) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 716, in run_wsgi_app >>>>>> >>>>>> rv =3D run_wsgi_app(self.application, environ, buffered=3Dbuffer= ed) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/werkzeug/test.py", >>>>>> line 923, in run_wsgi_app >>>>>> >>>>>> app_rv =3D app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1997, in __call__ >>>>>> >>>>>> return self.wsgi_app(environ, start_response) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1985, in wsgi_app >>>>>> >>>>>> response =3D self.handle_exception(e) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1540, in handle_exception >>>>>> >>>>>> reraise(exc_type, exc_value, tb) >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1982, in wsgi_app >>>>>> >>>>>> response =3D self.full_dispatch_request() >>>>>> >>>>>> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packag= es/flask/app.py", >>>>>> line 1614, in full_dispatch_request >>>>>> >>>>>> rv =3D self.handle_user_exception(e) >>>>>> >>>>>> >> > --=20 Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company --0000000000006094ce056eabcd4e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks, applied with a few tweaks to remove some unused im= ports and a couple of variables.

On Fri, Jun 15, 2018 at 8:13 AM, Khushboo Vashi <khushboo.vashi@enterprisedb.com> wrote:
Hi,

Please fin= d the attached updated patch.

On Wed, Jun 13, 2018 at 5:42 PM, Khushboo Vashi <khushboo.vashi@enterprisedb.com> wrote:
Hi Victoria,


On Tue, Jun 12, 2018 at= 9:06 PM, Victoria Henry <vhenry@pivotal.io> wrote:
Hi Khushboo
can you explain = a little bit more this while loop?

cnt =3D 0
<= /span>while 1:
if cnt > 1:
= break
# C= heck the process list
= response1 =3D self.test= er.get('/misc/bgprocess/?_= =3D'.format(
random.randint(1, 9999999)))
self.assertEquals(response1.status_code, 200) process_list =3D json.loads(response1.data.decode('utf-8'))

if len= (process_list) > 0 = and 'execution_time' in process_list[0]:
break
time.sleep(0.5)
cnt +=3D 1
From what it looks like this will only run twice, = maybe a for would be a better solution because we know it will only run twi= ce. Also are we sure we only want it to run twice?

The code waits till the background process completes. S= o, while I originally developed, not intended to run only twice.=C2=A0
But after that I put a kind of break point and that remains there. So= , I will remove that if condition which is not required.
<= /div>
I have made maximum 5 attempts.=C2=A0
We are using PyCharm to do our developments and we notice there are = a big group of unused variables throughout. We should remove them if they a= re not needed. Not sure if your editor also shows that information or not.= =C2=A0=C2=A0
Do you know if there is a configuration in pycodestyle to en= able the check for unused variables? That would help a lot.

<= /div>
Removed unused = local variables.=C2=A0
Thanks for s= haring the information.=C2=A0
The code
assert 'execution_time' in process_list[0]
assert 'stime' in process_list[0]
assert 'exit_code' in process_list[0]
asse= rt process_list[0]['exit_code'
] in = self.expected_exit_code

in test_Create_restore_job should = use self.assertEqual or similar from unittest instead of plain assert. Because= when something fails we do not have a way to understand what was wrong.

Will do.=C2=A0
Done=C2=A0

The tests on the restore are still failing Green= Plum.

It is failing because, Restore is no= t working with GreenPlum. Can you please look into the Restore functionalit= y for GPDB?


Thanks,
Khush= boo=C2=A0
=E2=80=8B


Thanks,
Khushb= oo=C2=A0

Thanks
Victoria &= ; Joao

On Tue, J= un 12, 2018 at 6:44 AM Khushboo Vashi <khushboo.vashi@enterprisedb.com> wrote:

On Tue, Jun 12, 2018 at 3:5= 4 PM, Khushboo Vashi <khushboo.vashi@enterprisedb.com> wrote:
Hi,=

Please find the attached patch excluding feature test c= ases.
Python test cases are working fine, so we can commit this p= atch. I am working on fixing the feature tests which are failing on the dif= ferent window sizes.

Thanks,
Khushboo

On Fri, J= un 8, 2018 at 2:38 PM, Dave Page <dpage@pgadmin.org> wrote:<= br>
Hi

On Fri, Jun 8, 2018 at 6:33 AM, Khu= shboo Vashi <khushboo.vashi@enterprisedb.com> wrote:
Hi Dave,
As per our discussion I have changed the window size to 128= 0X800, before it was 1280X900.
Please find th= e attached updated patch
=C2=A0
I'm not sure that actually made any difference on my system. The wind= ow continued to look taller than it is wide, so I wonder if the code to set= the size is being ignored, or is at the wrong place?

<= div>Anyway, I got 10 failures with this patch :-(

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D

ERROR: runTest (pgadmin.feature_tests.pg_utilities_backup_restor= e_test.PGUtilitiesBackupFeatureTest)

Test for PG utilities - Backup and Restore

----------------------------------------------------------------------

Traceback (most recent call last):

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/pg_utilities_= backup_restore_test.py", line 97, in runTest

=C2=A0 =C2=A0 self= .page.find_by_xpath("//div[contains(@class,'wcFloatingFo= cus')"

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 171, in find_by_xpath

=C2=A0 =C2=A0 lamb= da driver: driver.find_element_by_xpath(xpath)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 263, in wait_for_element

=C2=A0 =C2=A0 retu= rn self._wait_for("element to exist", element_if_it_exists)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 337, in _wait_for

=C2=A0 =C2=A0 &quo= t;Timed out waiting for " + waiting_for_message

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/se= lenium/webdriver/support/wait.py", line 80, in until

=C2=A0 =C2=A0 rais= e TimeoutException(message, screen, stacktrace)

TimeoutException: Message: Timed out waiting for element to exist



=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D

ERROR: runTest (pgadmin.feature_tests.xss_checks_pgadmin_debugge= r_test.CheckDebuggerForXssFeatureTest)

Tests to check if Debugger is vulnerable to XSS

----------------------------------------------------------------------

Traceback (most recent call last):

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/xss_checks_pg= admin_debugger_test.py", line 42, in runTest

=C2=A0 =C2=A0 self= ._function_node_expandable()

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/feature_tests/xss_checks_pg= admin_debugger_test.py", line 57, in _function_node_expandable<= /p>

=C2=A0 =C2=A0 self= .page.select_tree_item("a_test_function()")

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 135, in select_tree_item

=C2=A0 =C2=A0 &quo= t;' and @class=3D'aciTreeItem']").click()

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 171, in find_by_xpath

=C2=A0 =C2=A0 lamb= da driver: driver.find_element_by_xpath(xpath)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 263, in wait_for_element

=C2=A0 =C2=A0 retu= rn self._wait_for("element to exist", element_if_it_exists)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/regression/feature_utils/pgadmin_pa= ge.py", line 337, in _wait_for

=C2=A0 =C2=A0 &quo= t;Timed out waiting for " + waiting_for_message

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/se= lenium/webdriver/support/wait.py", line 80, in until

=C2=A0 =C2=A0 rais= e TimeoutException(message, screen, stacktrace)

TimeoutException: Message: Timed out waiting for element to exist



=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D

ERROR: runTest (pgadmin.tools.backup.tests.test_create_backup_jo= b.BackupJobTest)

When backup the object with the default options

----------------------------------------------------------------------

Traceback (most recent call last):

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/test_cre= ate_backup_job.py", line 58, in runTest

=C2=A0 =C2=A0 self= .assertNotIn

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/test_bac= kup_utils.py", line 33, in run_backup_job

=C2=A0 =C2=A0 rand= om.randint(1, 9999999)))

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 830, in get

=C2=A0 =C2=A0 retu= rn self.open(*args, **kw)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/testing.py", line 127, in open

=C2=A0 =C2=A0 foll= ow_redirects=3Dfollow_redirects)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 803, in open

=C2=A0 =C2=A0 resp= onse =3D self.run_wsgi_app(environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 716, in run_wsgi_app

=C2=A0 =C2=A0 rv = =3D run_wsgi_app(self.application, environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 923, in run_wsgi_app

=C2=A0 =C2=A0 app_= rv =3D app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1997, in __call__

=C2=A0 =C2=A0 retu= rn self.wsgi_app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1985, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.handle_exception(e)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1540, in handle_exception

=C2=A0 =C2=A0 rera= ise(exc_type, exc_value, tb)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1982, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.full_dispatch_request()

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1614, in full_dispatch_request

=C2=A0 =C2=A0 rv = =3D self.handle_user_exception(e)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1517, in handle_user_exception

=C2=A0 =C2=A0 rera= ise(exc_type, exc_value, tb)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1612, in full_dispatch_request

=C2=A0 =C2=A0 rv = =3D self.dispatch_request()

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1598, in dispatch_request

=C2=A0 =C2=A0 retu= rn self.view_functions[rule.endpoint](**req.view_args)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask_login.py", line 792, in decorated_view

=C2=A0 =C2=A0 retu= rn func(*args, **kwargs)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/__init__.py&= quot;, line 62, in index

=C2=A0 =C2=A0 retu= rn make_response(response=3DBatchProcess.list())

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/processes.py= ", line 584, in list

=C2=A0 =C2=A0 deta= ils =3D desc.details(p.command, args)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.py&qu= ot;, line 159, in details

=C2=A0 =C2=A0 name= , host, port =3D self.get_server_details()

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.py&qu= ot;, line 122, in get_server_details

=C2=A0 =C2=A0 host= =3D manager.local_bind_host if manager.use_ssh_tunnel else s.host

AttributeError: 'NoneType' object has no attribute 'use_s= sh_tunnel'


=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D

ERROR: runTest (pgadmin.tools.maintenance.tests.test_create_main= tenance_job.MaintenanceJobTest)

When maintenance the object with the default options

----------------------------------------------------------------------

Traceback (most recent call last):

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/maintenance/tests/tes= t_create_maintenance_job.py", line 71, in runTest

=C2=A0 =C2=A0 rand= om.randint(1, 9999999)))

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 830, in get

=C2=A0 =C2=A0 retu= rn self.open(*args, **kw)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/testing.py", line 127, in open

=C2=A0 =C2=A0 foll= ow_redirects=3Dfollow_redirects)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 803, in open

=C2=A0 =C2=A0 resp= onse =3D self.run_wsgi_app(environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 716, in run_wsgi_app

=C2=A0 =C2=A0 rv = =3D run_wsgi_app(self.application, environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 923, in run_wsgi_app

=C2=A0 =C2=A0 app_= rv =3D app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1997, in __call__

=C2=A0 =C2=A0 retu= rn self.wsgi_app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1985, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.handle_exception(e)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1540, in handle_exception

=C2=A0 =C2=A0 rera= ise(exc_type, exc_value, tb)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1982, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.full_dispatch_request()

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1614, in full_dispatch_request

=C2=A0 =C2=A0 rv = =3D self.handle_user_exception(e)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1517, in handle_user_exception

=C2=A0 =C2=A0 rera= ise(exc_type, exc_value, tb)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1612, in full_dispatch_request

=C2=A0 =C2=A0 rv = =3D self.dispatch_request()

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1598, in dispatch_request

=C2=A0 =C2=A0 retu= rn self.view_functions[rule.endpoint](**req.view_args)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask_login.py", line 792, in decorated_view

=C2=A0 =C2=A0 retu= rn func(*args, **kwargs)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/__init__.py&= quot;, line 62, in index

=C2=A0 =C2=A0 retu= rn make_response(response=3DBatchProcess.list())

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/misc/bgprocess/processes.py= ", line 584, in list

=C2=A0 =C2=A0 deta= ils =3D desc.details(p.command, args)

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.py&qu= ot;, line 159, in details

=C2=A0 =C2=A0 name= , host, port =3D self.get_server_details()

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/__init__.py&qu= ot;, line 122, in get_server_details

=C2=A0 =C2=A0 host= =3D manager.local_bind_host if manager.use_ssh_tunnel else s.host

AttributeError: 'NoneType' object has no attribute 'use_s= sh_tunnel'


=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D

ERROR: runTest (pgadmin.tools.restore.tests.test_create_restore_= job.RestoreJobTest)

When restore the object with the default options

----------------------------------------------------------------------

Traceback (most recent call last):

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/restore/tests/test_cr= eate_restore_job.py", line 95, in runTest

=C2=A0 =C2=A0 self= .create_backup()

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/restore/tests/test_cr= eate_restore_job.py", line 86, in create_backup

=C2=A0 =C2=A0 self= .assertNotIn

=C2=A0 File "= /Users/dpage/git/pgadmin4/web/pgadmin/tools/backup/tests/test_bac= kup_utils.py", line 33, in run_backup_job

=C2=A0 =C2=A0 rand= om.randint(1, 9999999)))

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 830, in get

=C2=A0 =C2=A0 retu= rn self.open(*args, **kw)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/testing.py", line 127, in open

=C2=A0 =C2=A0 foll= ow_redirects=3Dfollow_redirects)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 803, in open

=C2=A0 =C2=A0 resp= onse =3D self.run_wsgi_app(environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 716, in run_wsgi_app

=C2=A0 =C2=A0 rv = =3D run_wsgi_app(self.application, environ, buffered=3Dbuffered)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/we= rkzeug/test.py", line 923, in run_wsgi_app

=C2=A0 =C2=A0 app_= rv =3D app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1997, in __call__

=C2=A0 =C2=A0 retu= rn self.wsgi_app(environ, start_response)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1985, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.handle_exception(e)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1540, in handle_exception

=C2=A0 =C2=A0 rera= ise(exc_type, exc_value, tb)

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1982, in wsgi_app

=C2=A0 =C2=A0 resp= onse =3D self.full_dispatch_request()

=C2=A0 File "= /Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/fl= ask/app.py", line 1614, in full_dispatch_request

=C2=A0 =C2=A0 rv = =3D self.handle_user_exception(e)






--
Dave Page
Blog: = http://pgsnake.bl= ogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com<= br>The Enterprise PostgreSQL Company
--0000000000006094ce056eabcd4e--