cloudflare / pages-action

MIT License
475 stars 99 forks source link

Post-upload fails #104

Closed mrowles closed 12 months ago

mrowles commented 12 months ago

As of about 5 hours ago, I am receiving this odd issue after a successful deployment to Cloudflare:

npm WARN exec The following package was not found and will be installed: wrangler@2.20.1 npm WARN deprecated rollup-plugin-inject@3.0.2: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-inject. npm WARN deprecated sourcemap-codec@1.4.8: Please use @jridgewell/sourcemap-codec instead Uploading... (193/194) Uploading... (194/194) ✨ Success! Uploaded 1 files (193 already uploaded) (1.78 sec)

✨ Deployment complete! Take a peek over at https://xxx.pages.dev/ npm notice npm notice New minor version of npm available! 10.1.0 -> 10.2.0 npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.2.0 npm notice Run npm install -g npm@10.2.0 to update! npm notice undefined:1 <!DOCTYPE html> ^

SyntaxError: Unexpected token < in JSON at position 0 at JSON.parse () at Response.json (/home/runner/work/_actions/cloudflare/pages-action/v1/index.js:13368:23) at processTicksAndRejections (node:internal/process/task_queues:96:5) at async createPagesDeployment (/home/runner/work/_actions/cloudflare/pages-action/v1/index.js:22105:9) at async /home/runner/work/_actions/cloudflare/pages-action/v1/index.js:22175:29

holm commented 12 months ago

We are seeing this also. We assumed this was due to the incident, but indications are on the status page that it has been fixed.

lovasoa commented 12 months ago

Cloudflare's API seems to be timing out (504 gateway timeout) and returning html instead of json for the error message. Tried with curl -v "https://api.cloudflare.com/client/v4/accounts/$ACCOUNT_ID/pages/projects/$PROJECT/deployments" -H 'Authorization: Bearer XXX

Detailed curl http logs ``` curl -v "https://api.cloudflare.com/client/v4/accounts/$ACCOUNT_ID/pages/projects/$PROJECT/deployments" -H 'Authorization: Bearer XXX * Trying 104.19.192.176:443... * Connected to api.cloudflare.com (104.19.192.176) port 443 (#0) * ALPN, offering h2 * ALPN, offering http/1.1 * CAfile: /etc/ssl/certs/ca-certificates.crt * CApath: /etc/ssl/certs * TLSv1.0 (OUT), TLS header, Certificate Status (22): * TLSv1.3 (OUT), TLS handshake, Client hello (1): * TLSv1.2 (IN), TLS header, Certificate Status (22): * TLSv1.3 (IN), TLS handshake, Server hello (2): * TLSv1.2 (IN), TLS header, Finished (20): * TLSv1.2 (IN), TLS header, Supplemental data (23): * TLSv1.3 (IN), TLS handshake, Encrypted Extensions (8): * TLSv1.3 (IN), TLS handshake, Certificate (11): * TLSv1.3 (IN), TLS handshake, CERT verify (15): * TLSv1.3 (IN), TLS handshake, Finished (20): * TLSv1.2 (OUT), TLS header, Finished (20): * TLSv1.3 (OUT), TLS change cipher, Change cipher spec (1): * TLSv1.2 (OUT), TLS header, Supplemental data (23): * TLSv1.3 (OUT), TLS handshake, Finished (20): * SSL connection using TLSv1.3 / TLS_AES_256_GCM_SHA384 * ALPN, server accepted to use h2 * Server certificate: * subject: C=US; ST=California; L=San Francisco; O=Cloudflare, Inc.; CN=sni.cloudflaressl.com * start date: May 4 00:00:00 2023 GMT * expire date: May 2 23:59:59 2024 GMT * subjectAltName: host "api.cloudflare.com" matched cert's "api.cloudflare.com" * issuer: C=US; O=Cloudflare, Inc.; CN=Cloudflare Inc ECC CA-3 * SSL certificate verify ok. * Using HTTP2, server supports multiplexing * Connection state changed (HTTP/2 confirmed) * Copying HTTP/2 data in stream buffer to connection buffer after upgrade: len=0 * TLSv1.2 (OUT), TLS header, Supplemental data (23): * TLSv1.2 (OUT), TLS header, Supplemental data (23): * TLSv1.2 (OUT), TLS header, Supplemental data (23): * Using Stream ID: 1 (easy handle 0x5620af2fdb90) * TLSv1.2 (OUT), TLS header, Supplemental data (23): > GET /client/v4/accounts/AAA/pages/projects/BBB/deployments HTTP/2 > Host: api.cloudflare.com > user-agent: curl/7.81.0 > accept: */* > authorization: Bearer XXX > * TLSv1.2 (IN), TLS header, Supplemental data (23): * TLSv1.3 (IN), TLS handshake, Newsession Ticket (4): * TLSv1.3 (IN), TLS handshake, Newsession Ticket (4): * old SSL session ID is stale, removing * TLSv1.2 (IN), TLS header, Supplemental data (23): * TLSv1.2 (OUT), TLS header, Supplemental data (23): * TLSv1.2 (IN), TLS header, Supplemental data (23): < HTTP/2 504 < date: Mon, 09 Oct 2023 15:18:19 GMT < content-type: text/html; charset=UTF-8 < content-length: 6432 < cf-ray: 81379736b99b0358-CDG < cache-control: private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0 < expires: Thu, 01 Jan 1970 00:00:01 GMT < set-cookie: __cflb=0H28vgHxwvgAQtjUGUSTLLCMLmdTy1vPuSmDRSSrp4d; SameSite=Lax; path=/; expires=Mon, 09-Oct-23 17:48:20 GMT; HttpOnly < referrer-policy: same-origin < x-frame-options: SAMEORIGIN < set-cookie: __cfruid=XXX; path=/; domain=.api.cloudflare.com; HttpOnly; Secure; SameSite=None < server: cloudflare < * TLSv1.2 (IN), TLS header, Supplemental data (23): api-gateway.api.cloudflare.com | 504: Gateway time-out

Gateway time-out Error code 504

* TLSv1.2 (IN), TLS header, Supplemental data (23): Visit cloudflare.com for more information.
2023-10-09 15:18:19 UTC
You

Browser

Working
* TLSv1.2 (IN), TLS header, Supplemental data (23):
Paris

Cloudflare

Working
api-gateway.api.cloudflare.com * TLSv1.2 (IN), TLS header, Supplemental data (23):

Host

Error

What happened?

The web server reported a gateway time-out error.

What can I do?

Please try again in a few minutes.

* TLSv1.2 (IN), TLS header, Supplemental data (23): * Connection #0 to host api.cloudflare.com left intact ```
WalshyDev commented 12 months ago

This is resolved now :) https://www.cloudflarestatus.com/incidents/64wsqjxnljn3 https://www.cloudflarestatus.com/incidents/msghx93bcjjd