next.js icon indicating copy to clipboard operation
next.js copied to clipboard

Deployment error "Invalid request: should be object"

Open silvioprog opened this issue 2 years ago • 1 comments

Verify canary release

  • [X] I verified that the issue exists in the latest Next.js canary release

Provide environment information

Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 21.6.0: Thu Sep 29 20:13:56 PDT 2022; root:xnu-8020.240.7~1/RELEASE_ARM64_T6000
Binaries:
  Node: 16.13.0
  npm: 8.19.2
  Yarn: 1.22.19
  pnpm: 7.3.0
Relevant packages:
  next: 13.0.3
  eslint-config-next: N/A
  react: 18.2.0
  react-dom: 18.2.0

Which example does this report relate to?

with-postgres

What browser are you using? (if relevant)

No response

How are you deploying your application? (if relevant)

Vercel

Describe the Bug

When trying to deploy the example using the button Deploy and pass the environment variable DATABASE_URL, it raises the following error Invalid request: should be object:

Screen Shot 2022-11-16 at 7 06 37 PM

Expected Behavior

It should deploy the application properly.

To Reproduce

Click to the button Deploy available here, the pass this value: postgresql://user:pass@host/user/database?ssl=false.

⚠️ NOTE: this value is just a sample, but I have been trying a real value and having the same error. ⚠️

silvioprog avatar Nov 16 '22 22:11 silvioprog

Note: if you add the same variable DATABASE_URL with the suggested sample value (or a real value) to the Vercel Settings or GitHub Secrets, it works like a charm.

silvioprog avatar Nov 16 '22 22:11 silvioprog