quarto-dev / quarto-dev/quarto-cli

Bad error message when netlify API errors out

Open
#10,036 0 comments 0 reactions 1 assignee View on GitHub

@cscheid is already working on this.

Since Jun 17, 2024.

enhancement publishing
Dominant language
JavaScript
Stars
6k
Forks
458
Avg merge
1d 9h
Merged PRs (30d)
41

Description

The bad error message reported in the discussion comes from

https://github.com/quarto-dev/quarto-cli/blob/c3b39f746cd21b38f843cecd879af707f2efa7d4/src/publish/netlify/api/core/request.ts#L282-L284

We should do better than that.

Discussed in https://github.com/quarto-dev/quarto-cli/discussions/9992

Originally posted by EllaKaye June 13, 2024

Description

Hello. I have a Quarto website which I publish manually to Netlify. Today, I purchased a new domain name for the site and this seems to have messed up publishing. When I ran quarto publish netlify as usual, I was asked: Publish update to: new-site-url which I said yes to, and also confirmed the email account. Quarto then built the site fine, but then when it was getting ready to publish it, I got the following error message:

ERROR: ApiError: Generic Error

Stack trace:
    at catchErrorCodes (file:///Applications/quarto/bin/quarto.js:100453:15)
    at file:///Applications/quarto/bin/quarto.js:100474:17
    at eventLoopTick (ext:core/01_core.js:183:11)

I realised I hadn't updated _publish.yml with the new URL, so I did that and tried again but got the same error (though the site ID hasn't changed and the old netlify.app domain is still associated with it).

On the site's netlify page, it says the production is "prepared" and that "Netlify's robots are busy deploying your site to our CDN", but the Deploy log is blank except a spinning cursor (it's been spinning for 15 minutes and the site usually deploys in 2 seconds). I'm not sure if this is a Quarto issue or a Netlify one.

Any idea what might be going on here and how to fix it?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.