-
Notifications
You must be signed in to change notification settings - Fork 71
Closed
Labels
Ecosystem: Dev Foundationstype: bugcode to address defects in shipped codecode to address defects in shipped code
Description
Describe the bug
I'm messing about with edge functions locally using the CLI, specifically netlify dev
.
I tried adding an excludedPath
as per docs:
https://docs.netlify.com/edge-functions/declarations/#declare-edge-functions-in-netlify-toml
But am getting an error as outlined below.
I had a quick dig, and it looks like as of today, validation only covers the properties 'path', 'function', 'cache'
. (source)
#4585 looks like it might provide a base for sorting out this (and possibly other) validation issues, but am only skimming the surface of this atm!
Steps to reproduce
- Add
excludedPath
to anedge_functions
definition innetlify.toml
[[edge_functions]]
path = "/*"
excludedPath = "/img/*"
function = "common"
- Run
netlify dev
- See error in terminal
CLI command and flags
netlify dev
Configuration
[dev]
command = "npm run start"
[build]
publish = "_site"
command = "npm run build"
functions = "netlify/functions"
[[edge_functions]]
path = "/*"
excludedPath = "/img/*"
function = "common"
CLI output
When resolving config file /{project-dir}/netlify.toml:
Configuration property edge_functions[0] has unknown properties. Valid properties are:
- path
- function
- cache
Invalid syntax
[[edge_functions]]
path = "/*"
excludedPath = "/img/*"
function = "common"
Valid syntax
[[edge_functions]]
path = "/hello"
function = "hello"
Environment
System:
OS: macOS 13.4.1
CPU: (12) arm64 Apple M2 Pro
Memory: 188.86 MB / 16.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 18.14.1 - ~/.nodenv/versions/18.14.1/bin/node
npm: 9.3.1 - ~/.nodenv/versions/18.14.1/bin/npm
npmGlobalPackages:
netlify-cli: 15.8.0
Metadata
Metadata
Assignees
Labels
Ecosystem: Dev Foundationstype: bugcode to address defects in shipped codecode to address defects in shipped code