Re: [pgAdmin4] [PATCH] History Tab rewrite in React

From: George Gelashvili <ggelashvili(at)pivotal(dot)io>
To: Dave Page <dpage(at)pgadmin(dot)org>
Cc: Joao Pedro De Almeida Pereira <jdealmeidapereira(at)pivotal(dot)io>, Matthew Kleiman <mkleiman(at)pivotal(dot)io>, Murtuza Zabuawala <murtuza(dot)zabuawala(at)enterprisedb(dot)com>, pgadmin-hackers <pgadmin-hackers(at)postgresql(dot)org>
Subject: Re: [pgAdmin4] [PATCH] History Tab rewrite in React
Date: 2017-05-26 22:30:01
Message-ID: CAHowoHZJtKn8F9XuiK2yFT=_OcgG7Ctx83iiFab17PwexajfDQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-hackers

okay

We recreated the patches over new master.
Please apply the patches attached after "feature test timeouts" is merged
into master, as that should resolve "waiting for app to start"

Thanks!
George and Joao

On Fri, May 26, 2017 at 4:39 PM, Dave Page <dpage(at)pgadmin(dot)org> wrote:

> Hi
>
> That fixed the JS tests, however, the feature tests are completely
> broken now - the browser fails to load the app, so they just timeout:
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.connect_to_server_feature_test.
> ConnectsToServerFeatureTest)
> Test database connection
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.copy_selected_query_results_
> feature_test.CopySelectedQueryResultsFeatureTest)
> Test Copying Query Results
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.pg_datatype_validation_test.
> PGDataypeFeatureTest)
> Test checks for PG data-types output
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.query_tool_journey_test.
> QueryToolJourneyTest)
> Tests the path through the query tool
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.table_ddl_feature_test.
> TableDdlFeatureTest)
> Test table DDL generation
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.xss_checks_panels_and_query_tool_
> test.CheckForXssFeatureTest)
> Test XSS check for panels and query tool
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ======================================================================
> ERROR: runTest (pgadmin.feature_tests.xss_checks_pgadmin_debugger_test.
> CheckDebuggerForXssFeatureTest)
> Tests to check if Debugger is vulnerable to XSS
> ----------------------------------------------------------------------
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> base_feature_test.py",
> line 36, in setUp
> self.page.wait_for_app()
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 187, in wait_for_app
> self._wait_for("app to start", page_shows_app)
> File "/Users/dpage/git/pgadmin4/web/regression/feature_utils/
> pgadmin_page.py",
> line 191, in _wait_for
> "Timed out waiting for " + waiting_for_message)
> File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-
> packages/selenium/webdriver/support/wait.py",
> line 80, in until
> raise TimeoutException(message, screen, stacktrace)
> TimeoutException: Message: Timed out waiting for app to start
>
>
> ----------------------------------------------------------------------
> Ran 166 tests in 113.200s
>
> FAILED (errors=7, skipped=16)
>
> =============Running the test cases for 'PostgreSQL 9.6'=============
> runTest (pgadmin.browser.server_groups.servers.databases.
> casts.tests.test_cast_add.CastsAddTestCase)
> Check Cast Node ... 2017-05-26 16:27:56,754: ERROR pgadmin: 'Mock'
> object does not support item assignment
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_
> groups/servers/__init__.py",
> line 774, in connect
> server_types=ServerType.types()
> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/driver/
> psycopg2/__init__.py",
> line 309, in connect
> os.environ['PGAPPNAME'] = '{0} - {1}'.format(config.APP_NAME, conn_id)
> TypeError: 'Mock' object does not support item assignment
> FAIL
> ERROR
> runTest (pgadmin.browser.server_groups.servers.databases.
> casts.tests.test_cast_delete.CastsDeleteTestCase)
> Check Cast Node ... 2017-05-26 16:27:56,840: ERROR pgadmin: 'Mock'
> object does not support item assignment
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_
> groups/servers/__init__.py",
> line 774, in connect
> server_types=ServerType.types()
> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/driver/
> psycopg2/__init__.py",
> line 309, in connect
> os.environ['PGAPPNAME'] = '{0} - {1}'.format(config.APP_NAME, conn_id)
> TypeError: 'Mock' object does not support item assignment
> FAIL
> ERROR
> runTest (pgadmin.browser.server_groups.servers.databases.
> casts.tests.test_cast_get.CastsGetTestCase)
> Check Cast Node ... Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_
> groups/servers/databases/casts/tests/utils.py",
> line 51, in create_cast
> " FUNCTION AS IMPLICIT" % (source_type, target_type))
> ProgrammingError: cast from type money to type bigint already exists
>
> 2017-05-26 16:27:56,960: ERROR pgadmin: 'Mock' object does not support
> item assignment
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_
> groups/servers/__init__.py",
> line 774, in connect
> server_types=ServerType.types()
> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/driver/
> psycopg2/__init__.py",
> line 309, in connect
> os.environ['PGAPPNAME'] = '{0} - {1}'.format(config.APP_NAME, conn_id)
> TypeError: 'Mock' object does not support item assignment
> FAIL
> ERROR
> runTest (pgadmin.browser.server_groups.servers.databases.
> casts.tests.test_cast_put.CastsPutTestCase)
> Check Cast Node ... 2017-05-26 16:27:57,060: ERROR pgadmin: 'Mock'
> object does not support item assignment
> Traceback (most recent call last):
> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/server_
> groups/servers/__init__.py",
> line 774, in connect
> server_types=ServerType.types()
> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/driver/
> psycopg2/__init__.py",
> line 309, in connect
> os.environ['PGAPPNAME'] = '{0} - {1}'.format(config.APP_NAME, conn_id)
> TypeError: 'Mock' object does not support item assignment
> FAIL
> ERROR
>
> On Wed, May 24, 2017 at 10:22 AM, Joao Pedro De Almeida Pereira
> <jdealmeidapereira(at)pivotal(dot)io> wrote:
> > Hi Hackers!
> >
> > Please find attached the two patches, now including a new grunt task to
> run
> > the tests only once that can be used in CI. For development, use grunt
> > test, for ci or to run tests only once, use grunt test-ci. This is
> > documented in the README file.
> >
> > Also note, these patches were generated using git diff as per
> > https://www.pgadmin.org/docs/pgadmin4/dev/submitting_patches.html.
> Sorry for
> > any inconvenience from generating a patch in an alternate manner earlier.
> >
> > Thanks,
> > Joao & Matt
> >
> > On Wed, May 24, 2017 at 9:36 AM, Matthew Kleiman <mkleiman(at)pivotal(dot)io>
> > wrote:
> >>
> >> Hi Dave,
> >>
> >> This one is our bad! We didn't create a grunt task to run the tests only
> >> once, as you would in CI. grunt tests currently runs the tests and
> continues
> >> to watch for changes, running the tests again each time the source code
> is
> >> modified. We will create a task that is suitable to run in CI.
> >>
> >> In the meantime, if you have any free time during the day today and
> would
> >> like to schedule a sync call with us, that would help us to tighten the
> >> feedback loop.
> >>
> >> Thanks,
> >> Joao & Matt
> >>
> >> On Tue, May 23, 2017 at 4:44 PM, Dave Page <dpage(at)pgadmin(dot)org> wrote:
> >>>
> >>> On Tue, May 23, 2017 at 12:12 PM, Joao Pedro De Almeida Pereira
> >>> <jdealmeidapereira(at)pivotal(dot)io> wrote:
> >>> > Okay
> >>> >
> >>> > Can you try removing web/node_modules and web/yarn.lock, and running
> >>> > $ yarn install
> >>> > $ grunt tests
> >>> >
> >>> > We think this might be due to a bad version of phantomjs-prebuilt.
> >>> >
> >>> > If that still fails, can you try running grunt as "yarn run grunt
> >>> > tests"?
> >>>
> >>> I'm on a different machine now, and here grunt just seems to never
> >>> exit when it's doing anything. For example, I ran this a few minutes
> >>> ago, it finished in seconds and has been sitting here ever since:
> >>>
> >>> (pgadmin4)snake:web dpage$ grunt tests
> >>> Running "eslint:target" (eslint) task
> >>>
> >>> Running "karma:unit" (karma) task
> >>>
> >>> webpack: Compiled successfully.
> >>> webpack: Compiling...
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> webpack: wait until bundle finished:
> >>> (node:4902) DeprecationWarning: loaderUtils.parseQuery() received a
> >>> non-string value which can be problematic, see
> >>> https://github.com/webpack/loader-utils/issues/56
> >>> parseQuery() will be replaced with getOptions() in the next major
> >>> version of loader-utils.
> >>> 23 05 2017 16:41:54.549:WARN [karma]: No captured browser, open
> >>> http://localhost:9876/
> >>>
> >>> webpack: Compiled successfully.
> >>> PhantomJS 2.1.1 (Mac OS X 0.0.0): Executed 87 of 88 (skipped 1)
> >>> SUCCESS (1.353 secs / 1.328 secs)
> >>>
> >>> I'm quite unimpressed with it so far :-(
> >>>
> >>> --
> >>> Dave Page
> >>> Blog: http://pgsnake.blogspot.com
> >>> Twitter: @pgsnake
> >>>
> >>> EnterpriseDB UK: http://www.enterprisedb.com
> >>> The Enterprise PostgreSQL Company
> >>
> >>
> >
>
>
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>
>
> --
> 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
0001-Bring-React-into-the-codebase.diff text/plain 283.3 KB
0002-Creates-query-history-list.diff text/plain 49.2 KB

In response to

Responses

Browse pgadmin-hackers by date

  From Date Subject
Next Message Surinder Kumar 2017-05-27 13:02:33 Re: [pgAdmin4][PATCH] Improvements to Query Results Grid User Experience
Previous Message George Gelashvili 2017-05-26 22:26:38 feature test timeouts