Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cloudflare Pages deployment failing #43

Closed
arunthachi opened this issue Dec 14, 2023 · 2 comments
Closed

Cloudflare Pages deployment failing #43

arunthachi opened this issue Dec 14, 2023 · 2 comments
Assignees

Comments

@arunthachi
Copy link

Hi - I am deploying the repo as is into Cloudflare Pages, and I am getting the below error. But in my local it is running fine.

19:21:47.352 | Executing user command: npm run build
-- | --
19:21:48.192 |  
19:21:48.207 | > astros@1.0.1 build
19:21:48.207 | > astro build
19:21:48.207 |  
19:21:50.041 | 12:21:50 AM [vite] Pre-transform error: Failed to load url hast-util-to-string (resolved id: hast-util-to-string) in /opt/buildhome/repo/plugins/rehype-autolink-config.ts. Does the file exist?
19:21:50.042 | 12:21:50 AM [vite] Pre-transform error: Failed to load url hastscript (resolved id: hastscript) in /opt/buildhome/repo/plugins/rehype-autolink-config.ts. Does the file exist?
19:21:50.055 | 12:21:50 AM [vite] Error when evaluating SSR module /plugins/rehype-autolink-config.ts: failed to import "hast-util-to-string"
19:21:50.055 | \|- Error: Cannot find module 'hast-util-to-string' imported from '/opt/buildhome/repo/plugins/rehype-autolink-config.ts'
19:21:50.056 | at nodeImport (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50234:25)
19:21:50.056 | at ssrImport (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50141:30)
19:21:50.056 | at eval (/opt/buildhome/repo/plugins/rehype-autolink-config.ts:3:50)
19:21:50.056 | at instantiateModule (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50203:15)
19:21:50.056 |  
19:21:50.056 | 12:21:50 AM [vite] Error when evaluating SSR module /opt/buildhome/repo/astro.config.mjs: failed to import "/plugins/rehype-autolink-config.ts"
19:21:50.056 | \|- Error: Cannot find module 'hast-util-to-string' imported from '/opt/buildhome/repo/plugins/rehype-autolink-config.ts'
19:21:50.056 | at nodeImport (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50234:25)
19:21:50.057 | at ssrImport (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50141:30)
19:21:50.057 | at eval (/opt/buildhome/repo/plugins/rehype-autolink-config.ts:3:50)
19:21:50.057 | at instantiateModule (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50203:15)
19:21:50.057 |  
19:21:50.057 | 12:21:50 AM [vite] Pre-transform error: Failed to load url html-escaper (resolved id: html-escaper) in /opt/buildhome/repo/plugins/rehype-autolink-config.ts. Does the file exist?
19:21:50.057 | [astro] Unable to load your Astro config
19:21:50.057 |  
19:21:50.515 | Cannot find module 'hast-util-to-string' imported from '/opt/buildhome/repo/plugins/rehype-autolink-config.ts'
19:21:50.515 | Stack trace:
19:21:50.515 | at nodeImport (file:///opt/buildhome/repo/node_modules/.pnpm/vite@5.0.7/node_modules/vite/dist/node/chunks/dep-wTaJK0Jt.js:50234:25)
19:21:50.516 | at eval (/opt/buildhome/repo/plugins/rehype-autolink-config.ts:3:50)
19:21:50.679 | Failed: Error while executing user command. Exited with error code: 1
19:21:50.688 | Failed: build command exited with code: 1
19:21:51.659 | Failed: error occurred while running build command

@zanhk zanhk self-assigned this Jan 6, 2024
@zanhk
Copy link
Member

zanhk commented Jan 6, 2024

Hi @arunthachi sorry i missed this issue, does the problem still persist?

@zanhk
Copy link
Member

zanhk commented Feb 9, 2024

Closing as no updates

@zanhk zanhk closed this as completed Feb 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants