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

fix: use the right Blobs context in serve #6506

Closed
wants to merge 2 commits into from
Closed

Conversation

eduardoboucas
Copy link
Member

Summary

netlify serve is a bit special in that it first runs a build and then starts a server. In production, these steps have different Blobs contexts — API access should be used at build time and edge access should be used at runtime. This PR makes the serve command respect that.

Part of COM-580.

@eduardoboucas eduardoboucas requested a review from a team as a code owner April 10, 2024 09:07
Copy link

github-actions bot commented Apr 10, 2024

📊 Benchmark results

Comparing with 1908078

  • Dependency count: 1,313 (no change)
  • Package size: 294 MB ⬆️ 0.00% increase vs. 1908078
  • Number of ts-expect-error directives: 1,007 ⬇️ 0.10% decrease vs. 1908078

@@ -143,6 +157,7 @@ export const serve = async (options: OptionValues, command: BaseCommand) => {
const inspectSettings = generateInspectSettings(options.edgeInspect, options.edgeInspectBrk)
const url = await startProxyServer({
addonsUrls,
blobsContext: runtimeBlobsContext,
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was missing entirely, so edge functions were not getting a Blobs context.

Skn0tt
Skn0tt previously approved these changes Apr 10, 2024
Copy link
Member

@JGAntunes JGAntunes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please GitHub let us merge this PR 🙏

@eduardoboucas
Copy link
Member Author

Superseded by #6507.

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

Successfully merging this pull request may close these issues.

None yet

3 participants