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

chore: allow disabling source map generation with env var #12899

Merged
merged 1 commit into from
Dec 29, 2023

Conversation

DmytroHryshyn
Copy link
Contributor

@DmytroHryshyn DmytroHryshyn commented Dec 20, 2023

What does this PR do?

Adds env var that allows to disable server source maps generation and significantly reduce memory usage.

Requirement/Documentation

Document
See sentry plugin section.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • Chore (refactoring code, technical debt, workflow improvements)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Tests (Unit/Integration/E2E or any other test)
  • This change requires a documentation update

How should this be tested?

set SENTRY_DISABLE_SERVER_WEBPACK_PLUGIN to 1 and build the project. Source maps should not be generated. Build should not crash.

Mandatory Tasks

  • Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.

Copy link

vercel bot commented Dec 20, 2023

@DmytroHryshyn is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions bot added the ❗️ .env changes contains changes to env variables label Dec 20, 2023
Copy link
Contributor

github-actions bot commented Dec 20, 2023

Thank you for following the naming conventions! 🙏 Feel free to join our discord and post your PR link.

Copy link
Contributor

📦 Next.js Bundle Analysis for @calcom/web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

Seventeen Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load % of Budget (350 KB)
/[user]/[type] 251.24 KB 415.52 KB 118.72% (🟢 -2.22%)
/[user]/[type]/embed 251.27 KB 415.55 KB 118.73% (🟢 -2.22%)
/apps/[slug]/[...pages] 545.71 KB 709.99 KB 202.85% (🟡 +0.32%)
/availability 422.41 KB 586.68 KB 167.62% (🟡 +0.35%)
/d/[link]/[slug] 251.09 KB 415.36 KB 118.67% (🟢 -2.21%)
/event-types 543.61 KB 707.88 KB 202.25% (🟡 +0.32%)
/event-types/[type] 419.84 KB 584.12 KB 166.89% (🟡 +0.32%)
/org/[orgSlug]/[user]/[type] 251.48 KB 415.76 KB 118.79% (🟢 -2.22%)
/org/[orgSlug]/[user]/[type]/embed 251.51 KB 415.78 KB 118.79% (🟢 -2.21%)
/org/[orgSlug]/instant-meeting/team/[slug]/[type] 251.1 KB 415.37 KB 118.68% (🟢 -2.22%)
/org/[orgSlug]/team/[slug]/[type] 251.13 KB 415.4 KB 118.69% (🟢 -2.22%)
/settings/organizations/members 420.09 KB 584.37 KB 166.96% (🟡 +0.32%)
/settings/organizations/teams/other/[id]/profile 458.74 KB 623.01 KB 178.00% (🟡 +0.27%)
/settings/teams/[id]/onboard-members 155.92 KB 320.19 KB 91.48% (🟡 +0.31%)
/settings/teams/[id]/profile 459.56 KB 623.83 KB 178.24% (🟡 +0.26%)
/team/[slug]/[type] 251.1 KB 415.37 KB 118.68% (🟢 -2.22%)
/team/[slug]/[type]/embed 251.13 KB 415.4 KB 118.69% (🟢 -2.22%)
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

The "Budget %" column shows what percentage of your performance budget the First Load total takes up. For example, if your budget was 100kb, and a given page's first load size was 10kb, it would be 10% of your budget. You can also see how much this has increased or decreased compared to the base branch of your PR. If this percentage has increased by 20% or more, there will be a red status indicator applied, indicating that special attention should be given to this. If you see "+/- <0.01%" it means that there was a change in bundle size, but it is a trivial enough amount that it can be ignored.

@PeerRich PeerRich added the High priority Created by Linear-GitHub Sync label Dec 22, 2023
Copy link
Contributor

@emrysal emrysal left a comment

Choose a reason for hiding this comment

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

Looks good to merge

@emrysal emrysal enabled auto-merge (squash) December 29, 2023 18:09
@emrysal emrysal disabled auto-merge December 29, 2023 18:21
@emrysal emrysal merged commit 7579417 into calcom:main Dec 29, 2023
16 of 17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
❗️ .env changes contains changes to env variables High priority Created by Linear-GitHub Sync
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants