It seems that storing data in the database no longer works in local dev mode. This used to work.
It's possible an update to sst removed the feature, or there is an issue with the link between localhost and dynamodb.
You can still test features storing or getting from dynamodb by repeatedly doing deploy-dev, but that is much less ergonomic for long term development.
Here are the relevant logs when running on localhost:
getting user data
Error: Cannot access bound resources. This usually happens if the "sst/node" package is used on the client-side. Ensure that it's only called in your server functions.
at Object.get (file:///home/pv/Code/app.geo.ca-v2/node_modules/sst/node/util/index.js:23:27)
at getUserData (/home/pv/Code/app.geo.ca-v2/packages/web-app/src/lib/db/user.ts:18:44)
at async load (/home/pv/Code/app.geo.ca-v2/packages/web-app/src/routes/[lang]/map-browser/+page.server.ts:54:16)
at async load_server_data (/home/pv/Code/app.geo.ca-v2/packages/web-app/node_modules/@sveltejs/kit/src/runtime/server/page/load_data.js:45:18)
at async eval (/home/pv/Code/app.geo.ca-v2/packages/web-app/node_modules/@sveltejs/kit/src/runtime/server/page/index.js:161:13)
It seems that storing data in the database no longer works in local dev mode. This used to work.
It's possible an update to sst removed the feature, or there is an issue with the link between localhost and dynamodb.
You can still test features storing or getting from dynamodb by repeatedly doing deploy-dev, but that is much less ergonomic for long term development.
Here are the relevant logs when running on localhost: