-
Notifications
You must be signed in to change notification settings - Fork 365
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
fix: use correct paths when deploying edge functions on Windows #4760
Conversation
📊 Benchmark resultsComparing with f8cc372 Package size: 221 MB(no change)
Legend
|
@@ -10,7 +9,7 @@ const distPath = getPathInProject([EDGE_FUNCTIONS_FOLDER]) | |||
|
|||
const deployFileNormalizer = (file) => { | |||
const isEdgeFunction = file.root === distPath | |||
const normalizedPath = isEdgeFunction ? path.join(PUBLIC_URL_PATH, file.normalizedPath) : file.normalizedPath |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This effectively a URL, not a filesystem path. So it needs to use the UNIX format regardless of the host platform.
@@ -113,8 +113,7 @@ if (process.env.NETLIFY_TEST_DISABLE_LIVE !== 'true') { | |||
}) | |||
}) | |||
|
|||
// TODO: Re-add when feature flag is no longer needed. | |||
test.serial.skip('should deploy Edge Functions when directory exists', async (t) => { | |||
test.serial('should deploy Edge Functions when directory exists', async (t) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test would've caught this, but we never enabled it after the public beta. 😞
Summary
The paths we supply to the
files
hash needs to be in the unix format.