denoland / denoland/deploy_feedback
[Bug]: Fresh + EdgeDB unable to connect to EdgeDB Cloud
- Dominant language
- No language data
- Stars
- 79
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
### Problem description
I have Fresh woking locally and connecting to EdgeDb cloud successfully but when deployed to Deno Deploy I keep getting errors. I have tried many combinations of client config with DSN, instanceName variants using .env and hardcoded but nothing works.
The logs show:
`Database query failed: TypeError: Deno.permissions.querySync is not a function
at getEnv (https://deno.land/x/edgedb@v1.4.1/_src/adapter.shared.deno.ts:3:36)
at parseConnectDsnAndArgs (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.ts:504:21)
at FetchClientPool._parseConnectArguments (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.ts:99:17)
at FetchClientPool._getNormalizedConnectConfig (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:364:46)
at FetchClientPool.getNewConnection (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:375:31)
at ClientConnectionHolder._getConnection (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:62:43)
at ClientConnectionHolder.retryingFetch (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:175:31)
at ClientConnectionHolder.query (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:219:17)
at Client.query (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:594:27)
at eventLoopTick (ext:core/01_core.js:175:7)
29/10/2024, 2:29:49 pm
gcp-australia-southeast1
`
And
`Database query failed: TypeError: Deno.permissions.querySync is not a function
at getEnv (https://deno.land/x/edgedb@v1.4.1/_src/adapter.shared.deno.ts:3:36)
at parseConnectDsnAndArgs (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.ts:504:21)
at FetchClientPool._parseConnectArguments (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.ts:99:17)
at FetchClientPool._getNormalizedConnectConfig (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:364:46)
at FetchClientPool.getNewConnection (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:375:31)
at ClientConnectionHolder._getConnection (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:62:43)
at ClientConnectionHolder.retryingFetch (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:175:31)
at ClientConnectionHolder.query (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:219:17)
at Client.query (https://deno.land/x/edgedb@v1.4.1/_src/baseClient.ts:594:27)
at eventLoopTick (ext:core/01_core.js:175:7)`
Here is my repo: https://github.com/stemil23/Starter_Deno-Fresh_Supabase-Auth_Tailwind/tree/version-1-edgedb-cloud-setup
### Steps to reproduce
1. Clone repo
2. Switch to branch: version-1-edged-cloud-setup
3. Review dbCloud client config.
4. Review deno.json
5. Review routes.dbtest.tsx
`SUPABASE_URL=https://wdeetnfoicojwtvlysjk.supabase.co
SUPABASE_KEY=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6IndkZWV0bmZvaWNvand0dmx5c2prIiwicm9sZSI6ImFub24iLCJpYXQiOjE3Mjk5MDA1ODcsImV4cCI6MjA0NTQ3NjU4N30.8Kcu3IrJFIWTRR_yyBLMvSEEjtzzRsSgr-4o26QNPA8
EDGEDB_CLOUD_KEY=nbwt1_eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9.eyJlZGIuZC5hbGwiOnRydWUsImVkYi5pLmFsbCI6dHJ1ZSwiZWRiLnIuYWxsIjp0cnVlLCJpYXQiOjE3MzAwODA2MzMsImlzcyI6ImF3cy5lZGdlZGIuY2xvdWQiLCJqdGkiOiI4emotd0pUUEVlLVpGUU8wV3RIN0Z3Iiwic3ViIjoiRWdQbnNHbXNFZS16SENlenJ6UlBJUSJ9.mCS67pxX9hWq1jsOVROQIoNYGyvWHu1kV-Iv9oZxcns0yN6iPPSVjchtLen_ko8BkAtBWqcK1x8sgs7_er96eg
EDGEDB_CLOUD_INSTANCE=stemil23/mydb
EDGEDB_DSN=edgedb://mydb--stemil23.c-78.i.aws.edgedb.cloud:5656/branch/main/edgeql `
You can use these I will update them later.
### Expected behavior
Fresh and EdgeDB Cloud work on Deno Deploy as on local dev - Fresh can connect to EdgeDB Cloud DB and retrieve data.
### Environment
Deno 2 on Mac latest OS.
Hav tried various Fresh Git integrations on Deno Deploy and also edited custom deploy.yml without success.
### Possible solution
Determine nature of :Database query failed: TypeError: Deno.permissions.querySync is not a function
at getEnv (https://deno.land/x/edgedb@v1.4.1/_src/adapter.shared.deno.ts:3:36)
at parseConnectDsnAndArgs (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.ts:504:21)
at FetchClientPool._parseConnectArguments (https://deno.land/x/edgedb@v1.4.1/_src/conUtils.
- Use EdgeDB NPM Packages.
- Acknowledge that not possible to currently use EdgeDB cloud for Deno Deploy
- My approach is wrong and we should use fresh.config.ts ?
### Additional context


Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.