aodn / aodn-portal-v2

GNU General Public License v3.0
0 stars 0 forks source link

AS AN aodn developer I WANT to investigate the weird output SO THAT they are not confusing #195

Open HavierD opened 1 month ago

HavierD commented 1 month ago

Acceptance Criteria

  1. solve the problem mentioned in task list
  2. It is a low priority ticket.

Notes

  1. Currently, the playwright test output has error "Must provide a proper URL as target". (more information will put in comment). Could you please investigate it:
## Tasks
- [ ] Whether it is a big issue in ui test
- [ ] If this error output doesn't affect the playwright test, can we don't print them, or use warning instead of error
- [ ] Clean up any AWS resources created during backlog work
- [ ] DOD [Link to checklist](https://www.notion.so/imos-world/Definition-of-Done-DoD-b98281f003a44ce890dfba5af2f00337)

PRs

1.

Dependencies

1.

Demo

1.

HavierD commented 1 month ago

VITE v5.4.8 ready in 346 ms web-1 | web-1 | ➜ Local: http://localhost:5173/ web-1 | ➜ Network: http://172.18.0.2:5173/ tests-1 | Server started successfully tests-1 | ============================= test session starts ============================== tests-1 | platform linux -- Python 3.10.12, pytest-8.2.2, pluggy-1.5.0 tests-1 | rootdir: /app tests-1 | configfile: pytest.ini tests-1 | plugins: metadata-3.1.1, html-4.1.1, base-url-2.1.0, xdist-3.6.1, playwright-0.4.4 tests-1 | collected 18 items tests-1 | web-1 | 2:35:48 AM [vite] page reload playwright/reports/test-report.html tests-1 | tests/detail_page/test_about_tab.py . [ 5%] tests-1 | tests/detail_page/test_associated_records_tab.py . [ 11%] tests-1 | tests/detail_page/test_citation_tab.py . [ 16%] web-1 | 2:36:26 AM [vite] http proxy error: Must provide a proper URL as target web-1 | Error: Must provide a proper URL as target web-1 | at ProxyServer. (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61274:36) web-1 | at viteProxyMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61605:15) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at viteCachedTransformMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61738:5) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at cors (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41792:7) web-1 | at file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41828:17 web-1 | at originCallback (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41818:15) web-1 | 2:36:26 AM [vite] http proxy error: Must provide a proper URL as target web-1 | Error: Must provide a proper URL as target web-1 | at ProxyServer. (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61274:36) web-1 | at viteProxyMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61605:15) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at viteCachedTransformMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61738:5) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at cors (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41792:7) web-1 | at file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41828:17 web-1 | at originCallback (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41818:15) web-1 | 2:36:29 AM [vite] http proxy error: Must provide a proper URL as target web-1 | Error: Must provide a proper URL as target web-1 | at ProxyServer. (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61274:36) web-1 | at viteProxyMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61605:15) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at viteCachedTransformMiddleware (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61738:5) web-1 | at call (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41320:7) web-1 | at next (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41264:5) web-1 | at cors (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41792:7) web-1 | at file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41828:17 web-1 | at file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41828:17 web-1 | at originCallback (file:///app/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:41818:15) tests-1 | tests/search/test_search.py .. [100%] tests-1 |

AR-RIFAT commented 1 month ago

@HavierD If you run the web server without specifying a value for VITE_API_HOST in the .env file, these errors are shown when the website makes any API request. Similarly, in the GitHub workflow, there is no .env file, which results in errors.

In UI tests, this should not be an issue, as all API requests are mocked.