Comments (4)
Issue happens with Cloudflare & Node.. So no adapter specific issue.
from astro.
cc @bholmesdev
from astro.
Hi @hkbertoson, thanks for reporting! I see you're using the Cloudflare adapter. Did you try the following?
- Add the
nodejs_als
flag to your wrangler config. This allows a Node-specific API that actions relies on
# wrangler.toml
compatibility_flags = [ "nodejs_als" ]
- Mark this Node API as external in your vite config:
import {defineConfig} from "astro/config";
import cloudflare from '@astrojs/cloudflare';
export default defineConfig({
adapter: cloudflare({}),
output: 'server',
vite: {
ssr: {
external: ['node:async_hooks'],
},
},
})
I was also unable to reproduce this bug with the node adapter as @alexanderniebuhr noted above. If you can share a minimal reproduction with the node adapter that displays this issue, please share!
from astro.
@bholmesdev I just took that assumption based on screenshots from here https://discord.com/channels/830184174198718474/1255555330646216785
That thread shows that the Cloudflare specific issue can be fixed with the solution you posted but that then the same error as node appears. I think it might be an issue on how it is used in this specific case.
from astro.
Related Issues (20)
- Using Experimental Actions causes Build Error
- i18n `getRelativeLocaleUrl` with `manual` routing strategy and i18n middleware returns wrong URL
- Script handles problems HOT 5
- Unstyled React Component After Build
- `vite.build.assetsInlineLimit` parameter is invalid
- Include an image's absolute URL in the ImageMetaData when images are processed in Content Collections to allow @vercel/og to render Astro's images
- uncaught error in the middle of the stream while rendering HOT 3
- preact + node adapter: hydration issues HOT 1
- [Container API] NoMatchingRenderer error when using the solid renderer HOT 1
- Issue with FOUC when moving from home page to other pages and vice versa.
- Change comma color in light theme on error page
- If the -- open flag is used, any modifications to the packagist.json file will reopen the browser at this time
- Astro check everything inside `dist` folder HOT 3
- Render client framework twice
- 4.11 not pruning `satori` build chunks, increasing build sizes HOT 3
- `astro check` fails after update astro from v4.11.0 to v4.11.3
- astro:env does not generate .astro/env.d.ts in develoment mode HOT 8
- Improved astro:env errors HOT 7
- Drop node v21, add node v22? (minor) HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from astro.