Skip to content
This repository has been archived by the owner on Feb 10, 2025. It is now read-only.

astro with astro/netlify not working properly on netlify #442

Closed
1 task
anabrnjasevic opened this issue Nov 14, 2024 · 0 comments
Closed
1 task

astro with astro/netlify not working properly on netlify #442

anabrnjasevic opened this issue Nov 14, 2024 · 0 comments
Labels
needs repro Issue needs a reproduction

Comments

@anabrnjasevic
Copy link

Astro Info

Astro                    v4.16.12
Node                     v20.9.0
System                   Linux (x64)
Package Manager          npm
Output                   server
Adapter                  @astrojs/netlify
Integrations             @astrojs/tailwind
                         @astrojs/sitemap

Describe the Bug

I am using astrojs/netlify adapter .The output it produces creates such folder structure such that functions are deeply nested, so I tried to do this in netlify.toml

  node_bundler = "esbuild" 
  directory = ".netlify/v1/functions/ssr/.netlify/build"```
   
Now it seems to find the function but it throws error

` error decoding lambda response: error decoding lambda response: unexpected end of JSON input`

I don't know whether it's an astro problem, or netlify problem, I just can't make them work. The rest of the routes, for static pages work fine, this only happens for dynamic routes

this is astro.config

import { defineConfig } from ‘astro/config’;
import tailwind from ‘@astrojs/tailwind’;
import sitemap from ‘@astrojs/sitemap’;
import netlify from ‘@astrojs/netlify/functions’;

export default defineConfig({
output: ‘server’,
adapter: netlify(),
integrations: [
tailwind(),
sitemap(),
],
});


{
“name”: “usa-salvage-yards”,
“type”: “module”,
“version”: “0.0.1”,
“scripts”: {
“dev”: “astro dev”,
“start”: “astro dev”,
“build”: “astro build”,
“preview”: “astro preview”,
“astro”: “astro”
},
“dependencies”: {
“@astrojs/netlify”: “^5.5.4”,
“@astrojs/sitemap”: “^3.2.1”,
“@astrojs/tailwind”: “^5.1.2”,
“astro”: “^4.16.12”,
“nodemailer”: “^6.9.16”,
“papaparse”: “^5.4.1”,
“tailwindcss”: “^3.4.15”
},
“devDependencies”: {
“@types/nodemailer”: “^6.4.16”,
“@types/papaparse”: “^5.3.15”
}
}

What's the expected result?

it should render those pages

Link to Minimal Reproducible Example

can't

Participation

  • I am willing to submit a pull request for this issue.
@bluwy bluwy added the needs repro Issue needs a reproduction label Nov 15, 2024
@ascorbic ascorbic closed this as not planned Won't fix, can't repro, duplicate, stale Jan 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
needs repro Issue needs a reproduction
Projects
None yet
Development

No branches or pull requests

3 participants