QCDIS / NaaVRE-dev-environment

Integrated development environment for NaaVRE
Apache License 2.0
0 stars 0 forks source link

Setup local development environment #7

Open skoulouzis opened 4 months ago

skoulouzis commented 4 months ago

https://github.com/QCDIS/NaaVRE-dev-environment

Goal: reproduce steps from the NaaVRE tutorial locally

xpsky147 commented 4 months ago

When deploying the NaaVRE-dev-environment, I prepared to Run NaaVRE locally. Following the README of NaaVRE for testing, after running the command pytest --ignore=docker --ignore=cypress, the following was displayed:

short test summary info =============================================
FAILED jupyterlab_vre/tests/test_argo.py::ArgoTest::test_argo_api - AssertionError: unexpectedly None : ARGO_URL not set
FAILED jupyterlab_vre/tests/test_env_vars.py::TestEnvironmentVariables::test_env_vars - AssertionError: unexpectedly None
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_cells_handler - AssertionError: 200 != 500
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_execute_workflow_handler - AssertionError: 200 != 500
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_files_updated - AssertionError: 200 != 500
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_notebook_download_handler - AssertionError: 500 != 200
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_search_handler - json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
FAILED jupyterlab_vre/tests/test_handlers.py::HandlersAPITest::test_search_rating_handler - AssertionError: 500 != 200
 8 failed, 8 passed, 46 warnings in 50.37s ====================================

When was I asked to set ARGO_URL? In export_VARS ARGO_URL is not mentioned.

gpelouze commented 4 months ago

@xpsky147 test_argo.py and the need for $ARGO_URL are obsolete, as communication with Argo has been moved to https://github.com/QCDIS/VREPaaS/. We will create a separate task to scrape this from the code, and update the examples.

In the mean time, you can use

ARGO_URL=https://naavre-dev.minikube.test/argowf/
ARGO_API_TOKEN="Bearer TOKEN"

To get the token, follow the README: https://github.com/QCDIS/NaaVRE-dev-environment?tab=readme-ov-file#start-the-services-needed-by-naavre

skoulouzis commented 4 months ago

Install ubuntu VM

xpsky147 commented 4 months ago

I'm trying to deploy the project on an Ubuntu 22.04 virtual machine. I've tried to resolve the issues encountered as much as possible. Currently, after running 'tilt up', all 10 resources are healthy and the services can be accessed. In the 'Start NaaVRE' section, I tried option 1: 'Run NaaVRE locally'. I followed the instructions from https://github.com/QCDIS/NaaVRE/blob/main/README.md#development. I started Jupyter in both 'Build the extension' and 'Running the development environment', but testing still resulted in 8 failed and 8 passed. I'm not sure if I should try starting NaaVRE with options 2 and 3.

gpelouze commented 4 months ago

@xpsky147 which are the tests that fail, and what error messages do you get? This is usually related to environment variables configuration. Make sure that you have created and referenced the cells GitHub repository (documentation).

xpsky147 commented 4 months ago

The errors during testing are similar to the ones encountered previously. I am unsure about what other environment variables need to be set besides export_VARS. I did not follow the instructions at https://github.com/QCDIS/VREPaaS. Regarding the Cells repository, I forked QCDIS/NaaVRE-cells and generated a token: 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. Then, following the README file, I filled in my CELL_GITHUB and CELL_GITHUB_TOKEN in ./services/naavre/helm/values-integration.yaml and ./services/naavre-dev/helm/values-dev.yaml and export_VARS. I also edited services/vrepaas/helm/values.yaml with the token Bearer ey... The error message during testing is as follows: Error-info

xpsky147 commented 4 months ago

Sorry for the trouble, but I encountered an issue after running the command tilt enable n-a-a-vre-dev. It ran for quite some time without any issues, but eventually, it ended up like the screenshot below. I've attempted it three times, and each time it gets stuck at this point. When I opened https://registry.yarnpkg.com/@material-ui/icons/-/icons-4.11.2.tgz, I received an ESOCKETTIMEDOUT error, displaying: code "ResourceNotFound" message "/@material-ui/icons/-/icons-4.11.2.tgz: does not exist" Image

skoulouzis commented 4 months ago

Cnnot reproduce. The experiment loads correctly in my case

skoulouzis commented 4 months ago

Seems that at some point the VM doesn't; have internet access