Hi,
I'm constantly getting a 404 not found error for one of my static files, "desala.txt", every time I deploy my app.
Here is my website file hierarchy:
Code of my app.yaml:
runtime: python
env: flex
entrypoint: gunicorn -b :$PORT server:app
manual_scaling:
instances: 1
runtime_config:
python_version: 3
Console log when I visit my site:
However, visiting https://voltaic-phalanx-XXXXXX.uw.r.appspot.com/static/desala.txt works and shows that it exists. How am I getting this error and how do I fix it?
Solved! Go to Solution.
Actually found out the error was in my search.js file:
let lines = await readFile("./desala.txt").then(data => data.split("\n"));
I changed this line to:
let lines = await readFile("/static/desala.txt").then(data => data.split("\n"));
And the error was resolved. Thanks Robina for the assist.
Actually found out the error was in my search.js file:
let lines = await readFile("./desala.txt").then(data => data.split("\n"));
I changed this line to:
let lines = await readFile("/static/desala.txt").then(data => data.split("\n"));
And the error was resolved. Thanks Robina for the assist.