Skip to content

Conversation

@lforst
Copy link
Contributor

@lforst lforst commented Jun 26, 2024

When bumping next, Vercel's NFT logic seems to have changed and we were pulling in weird additional files like .git/objects and webpack caches. We identified that this was due to mdx.ts using process.cwd() and path concatenations which was confusing NFT, making it think pretty much everything in the root of the repo was needed to run the app. This caused us to be over the 300 MB limit for AWS lambdas.

Entails:

  • All kinds of related patch and minor bumps to Next.js and MDX
  • Minor QoL improvement in vercel.json
  • A more statically analyzable src/mdx.ts file

Fixes #10491

@vercel
Copy link

vercel bot commented Jun 26, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sentry-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 26, 2024 10:54am

@codecov
Copy link

codecov bot commented Jun 26, 2024

Bundle Report

Changes will increase total bundle size by 1.19MB ⬆️

Bundle name Size Change
sentry-docs-server 7.32MB 236.11kB ⬇️
sentry-docs-edge-server 249.7kB 230.2kB ⬇️
sentry-docs-client 7.87MB 1.65MB ⬆️

@lforst lforst requested a review from a team as a code owner June 26, 2024 08:06
Luca Forstner added 2 commits June 26, 2024 10:11
@lforst
Copy link
Contributor Author

lforst commented Jun 26, 2024

From 180MB

Screenshot 2024-06-26 at 12 52 29

to 15MB

Screenshot 2024-06-26 at 12 52 38

"sidecar": "yarn spotlight-sidecar",
"test": "jest"
"test": "jest",
"build-trace": "npx next@canary internal turbo-trace-server .next/trace"
Copy link
Member

Choose a reason for hiding this comment

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

Should we keep that?

Copy link
Member

@chargome chargome left a comment

Choose a reason for hiding this comment

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

🚀

@chargome
Copy link
Member

Fixes #10491

return frontMatter;
}

export function getAllFilesFrontMatter(folder: string = 'docs') {
Copy link
Collaborator

Choose a reason for hiding this comment

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

this folder shouldn't be hardcoded as we need to pass it as a parameter for developer docs for example later on

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Right now it doesn't need to be. We can add it back if needed. We shouldn't add code for the mere possibility of needing it.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I just mentioned it since this is deleting something that was already there, but I see what you mean

@lforst lforst merged commit 088fec6 into master Jun 26, 2024
@lforst lforst deleted the lforst-bump-nextjs branch June 26, 2024 11:46
lforst added a commit that referenced this pull request Jun 26, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Jul 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unable to bump Next.js to the newest version

5 participants