pxscene / pxCore2

Portable framebuffer library and related projects
Other
55 stars 107 forks source link

testRunner_v7.js - test failures - test_getFile.testHttpAccessAllowed #1474

Open dwrobel opened 6 years ago

dwrobel commented 6 years ago

Recently added test_getFile fails when run using node v8.11.1:

./dw.sh ./0400-wayland-node8-gcc-tsan.sh ./dw.sh ./0410-test-testrunner.sh

[Fri Sep 21 2018 09:50:00 GMT+0200 (CEST)] Creating new scene for test test_getFile url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js'
[Fri Sep 21 2018 09:50:00 GMT+0200 (CEST)] test "test_getFile" >>>> SET TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
in loadFileWithSparkPermissionsCheck package.json
local file access allowed for current file !!!
AppSceneContext#loadScenePackage0
enabling pxscene require support
Main Module: readyPromise=[object Promise]
AppSceneContext#loadScenePackage0 done
-----------------> Ready after third
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js] about to notify. xModule.exports:object
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js] about to notify done
Get ready for testScene https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] test "test_getFile" is ready. url=https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
>>>> CLEAR TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] About to remove() scene for url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_textWithoutParent.js?manualTest=0'
set testScene focus for testName test_getFile
test_getFile beforeStart()!
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] >>>>>>>>>>>STARTING HANG PREVENTION TIMEOUT for url:../tests/test_getFile.js
Done executing beforeStart for scene test_getFile
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] test_getFile.testlocalAccessAllowed
in loadFileWithSparkPermissionsCheck browser.js
local file access allowed for current file !!!
local file download succeeded .....
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] test_getFile.testHttpAccessAllowed
in loadFileWithSparkPermissionsCheck http://www.pxscene.org/examples/px-reference/gallery/fancy.js
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] >>>>>>>>>>>CLEARING HANG TIMEOUT FOR TESTS ../tests/test_getFile.js
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] Creating new scene for test test_importResources url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js'
[Fri Sep 21 2018 09:50:02 GMT+0200 (CEST)] test "test_importResources" >>>> SET TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js
in loadFileWithSparkPermissionsCheck package.json
local file access allowed for current file !!!
AppSceneContext#loadScenePackage0
enabling pxscene require support
Main Module: readyPromise=[object Promise]
AppSceneContext#loadScenePackage0 done
-----------------> Ready after fourth
-----------------> progressAnimation
-----------------> Entering progressAnimation
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js] about to notify. xModule.exports:object
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js] about to notify done
Get ready for testScene https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js
[Fri Sep 21 2018 09:50:04 GMT+0200 (CEST)] test "test_importResources" is ready. url=https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js
>>>> CLEAR TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_import_resources.js
[Fri Sep 21 2018 09:50:04 GMT+0200 (CEST)] About to remove() scene for url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js?manualTest=0'
test_getFile.testlocalAccessAllowed: SUCCESS

test_getFile.testHttpAccessAllowed: FAILURE

while it still run fine when using node v6.13.0:

./dw.sh ./0300-wayland-node6-gcc-tsan.sh ./dw.sh ./0310-test-testrunner.sh

[Fri Sep 21 2018 10:12:28 GMT+0200 (CEST)] Creating new scene for test test_getFile url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js'
[Fri Sep 21 2018 10:12:28 GMT+0200 (CEST)] test "test_getFile" >>>> SET TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
in loadFileWithSparkPermissionsCheck package.json
local file access allowed for current file !!!
AppSceneContext#loadScenePackage0
enabling pxscene require support
Main Module: readyPromise=[object Promise]
AppSceneContext#loadScenePackage0 done
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js] about to notify. xModule.exports:object
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js] about to notify done
Get ready for testScene https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] test "test_getFile" is ready. url=https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
>>>> CLEAR TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js
set testScene focus for testName test_getFile
test_getFile beforeStart()!
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] >>>>>>>>>>>STARTING HANG PREVENTION TIMEOUT for url:../tests/test_getFile.js
Done executing beforeStart for scene test_getFile
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] test_getFile.testlocalAccessAllowed
in loadFileWithSparkPermissionsCheck browser.js
local file access allowed for current file !!!
local file download succeeded .....
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] test_getFile.testHttpAccessAllowed
in loadFileWithSparkPermissionsCheck http://www.pxscene.org/examples/px-reference/gallery/fancy.js
Received data
remote file download success
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] >>>>>>>>>>>CLEARING HANG TIMEOUT FOR TESTS ../tests/test_getFile.js
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] Creating new scene for test exit test url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js'
[Fri Sep 21 2018 10:12:30 GMT+0200 (CEST)] test "exit test" >>>> SET TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js
-----------------> Ready after first
in loadFileWithSparkPermissionsCheck package.json
local file access allowed for current file !!!
AppSceneContext#loadScenePackage0
enabling pxscene require support
Main Module: readyPromise=[object Promise]
AppSceneContext#loadScenePackage0 done
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js] about to notify. xModule.exports:object
Main module[https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js] about to notify done
Get ready for testScene https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js
[Fri Sep 21 2018 10:12:32 GMT+0200 (CEST)] test "exit test" is ready. url=https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js
>>>> CLEAR TIMEOUT FOR SCENE LOAD FOR https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_exit.js
[Fri Sep 21 2018 10:12:32 GMT+0200 (CEST)] About to remove() scene for url='https://px-apps.sys.comcast.net/pxscene-samples/examples/px-reference/test-run/../tests/test_getFile.js?manualTest=0'
test_getFile.testlocalAccessAllowed: SUCCESS
test_getFile.testHttpAccessAllowed: SUCCESS
conniefry commented 6 years ago

Internal reference: XRE2-1751

madanagopalt commented 5 years ago

please share the repo,which I can download and repro the issue

dwrobel commented 5 years ago

Please just use the master branch from https://github.com/pxscene/pxCore.

Steps to reproduce:

  1. cd ci/builds

  2. ./dw.sh

  3. ./0010-external-breakpad.sh

  4. ./0020-external-dukluv.sh

  5. ./0030-external-nanosvg.sh

  6. To speed up running test and to avoid facing other failures: a) remove all other tests from tests/pxScene2d/testRunner/tests.json and keep only test_getFile.js b) remove all tests from tests/pxScene2d/testRunner/testsDesktop.json

To clean from any previous build, compile using node 6 and execute test please run the following:

  1. ./0299-clean.sh
  2. ./0300-wayland-node6-gcc-tsan.sh
  3. ./0310-test-testrunner.sh

To clean from any previous build, compile using node 8 and execute test please run the following:

  1. ./0399-clean.sh
  2. ./0400-wayland-node8-gcc-tsan.sh
  3. ./0410-test-testrunner.sh

Please ignore known Spark crash on exit while executing tests/pxScene2d/testRunner/testsExit.json.

madanagopalt commented 5 years ago

Thanks Damien, will try it. Could you please try once more , I have added logs in test_getFile to print the error code during failure.

Also, is it not possible to directly download node8 code as part of spark repo and try as replacement instead of ci build steps?.

dwrobel commented 5 years ago

Thanks Damien, will try it. Could you please try once more , I have added logs in test_getFile to print the error code during failure.

Here is the build: https://semaphoreci.com/dwrobel/pxcore/branches/master-next/builds/8. I see it failed.

To get a logs please open the above link and then click on the ./ci/builds/ci-semaphoreci.sh entry. Tail of the log will be shown on the screen, link to the full log is in the beginning (search for: 'Download complete log'). If you need you need to trigger any new build, please make PR against this branch.

madanagopalt commented 5 years ago

Thanks Damien,I got the logs as you suggested and got the problem and looks some api inconsistency. Please let me know how to get the node v8 code you are using without ci builds steps, in the same way we are using with 6.9.0.

dwrobel commented 5 years ago

Please let me know how to get the node v8 code

You can download sources within docker using the following steps: $ ./ci/builds/dw.sh $ sudo dnf debuginfo-install node8-shared Then you can start debugging the code: $ DBG="gdb --args" examples/pxScene2d/src/Spark-testrunner.sh

Source code repository + patches can be found here. I hope you can build it on your machine. In case you have some problems please refer to the .spec used to build it or to the complete build log.

dwrobel commented 5 years ago

test_getFile seems to be removed from test list, if it was removed permanently, can we close this?