Skip to content

Comments

chore: use local platform libraries instead of npm package#23834

Merged
ThyMinimalDev merged 9 commits intomainfrom
use-local-platform-libraries
Sep 16, 2025
Merged

chore: use local platform libraries instead of npm package#23834
ThyMinimalDev merged 9 commits intomainfrom
use-local-platform-libraries

Conversation

@ThyMinimalDev
Copy link
Contributor

What does this PR do?

  • Fixes #XXXX (GitHub issue number)
  • Fixes CAL-XXXX (Linear issue number - should be visible at the bottom of the GitHub issue description)

Visual Demo (For contributors especially)

A visual demonstration is strongly recommended, for both the original and new change (video / image - any one).

Video Demo (if applicable):

  • Show screen recordings of the issue or feature.
  • Demonstrate how to reproduce the issue, the behavior before and after the change.

Image Demo (if applicable):

  • Add side-by-side screenshots of the original and updated change.
  • Highlight any significant change(s).

Mandatory Tasks (DO NOT REMOVE)

  • I have self-reviewed the code (A decent size PR without self-review might be rejected).
  • I have updated the developer docs in /docs if this PR makes changes that would require a documentation change. If N/A, write N/A here and check the checkbox.
  • I confirm automated tests are in place that prove my fix is effective or that my feature works.

How should this be tested?

  • Are there environment variables that should be set?
  • What are the minimal test data to have?
  • What is expected (happy path) to have (input and output)?
  • Any other important info that could help to test that PR

Checklist

  • I haven't read the contributing guide
  • My code doesn't follow the style guidelines of this project
  • I haven't commented my code, particularly in hard-to-understand areas
  • I haven't checked if my changes generate no new warnings

@ThyMinimalDev ThyMinimalDev requested a review from a team September 15, 2025 08:18
@ThyMinimalDev ThyMinimalDev requested a review from a team as a code owner September 15, 2025 08:18
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 15, 2025

Walkthrough

  • apps/api/v2/Dockerfile: Adds a build step to run the platform-libraries workspace build after yarn install and before the API v2 build (runs yarn workspace @calcom/platform-libraries run build prior to yarn workspace @calcom/api-v2 run build).
  • apps/api/v2/package.json: Updates the @calcom/platform-libraries dependency version from npm:@calcom/platform-libraries@0.0.359 to \*, removing the pinned version.

Possibly related PRs

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description Check ❓ Inconclusive The PR description is mainly the repository's generic template with placeholders (e.g., "Fixes #XXXX") and unchecked mandatory checklist items and does not summarize the concrete edits in the diff such as the Dockerfile build step or the package.json dependency change. Because it lacks a clear summary, rationale, exact issue references, and minimal testing instructions, the description is too vague to guide reviewers. Under the "very vague or generic" criterion this check is therefore inconclusive. Please update the PR description to briefly summarize the actual changes (mention apps/api/v2/Dockerfile and apps/api/v2/package.json) and explain why the local platform libraries are used instead of the npm package. Include exact issue numbers or explicitly state "N/A", provide minimal test steps (build commands and expected outcomes), and confirm completion of the mandatory checklist and any documentation updates. This will allow reviewers to validate the change and run the required tests.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The title "chore: use local platform libraries instead of npm package" is concise and accurately captures the primary change in this PR: switching from the published npm package to local platform libraries. The raw_summary shows a Dockerfile build step added for @calcom/platform-libraries and apps/api/v2/package.json changed from a pinned npm:@calcom/platform-libraries@0.0.359 to "*", which aligns with the title. The phrasing is clear, developer-focused, and suitable as a single-line PR title.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch use-local-platform-libraries

📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 6d733cf and 9d6f423.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (1)
  • apps/api/v2/Dockerfile (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • apps/api/v2/Dockerfile

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Please see the documentation for more information.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@vercel
Copy link

vercel bot commented Sep 15, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
cal Ignored Ignored Sep 16, 2025 10:31am
cal-eu Ignored Ignored Sep 16, 2025 10:31am

@keithwillcode keithwillcode added core area: core, team members only foundation platform Anything related to our platform plan labels Sep 15, 2025
@dosubot dosubot bot added the ⬆️ dependencies Pull requests that update a dependency file label Sep 15, 2025
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (2)
apps/api/v2/package.json (1)

41-41: Force local workspace resolution; avoid plain "*" for safety

Use the workspace protocol to guarantee linking to the local package and prevent accidental registry resolution in edge environments.

Apply this diff:

-    "@calcom/platform-libraries": "*",
+    "@calcom/platform-libraries": "workspace:*",
.github/workflows/unit-tests.yml (1)

24-24: Confirm 'local' script and mitigate heavy CI work

Found @calcom/platform-libraries "local" script: node scripts/local.js && rm -rf dist && yarn build:dev && cd ../../.. && yarn — it runs a dev build and re-runs yarn (costly in CI); replace with a lightweight CI prep, add caching for node_modules/build artifacts, or move these steps to a separate job. Invoked from .github/workflows/unit-tests.yml (yarn workspace @calcom/platform-libraries local).

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Disabled knowledge base sources:

  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 7e876e3 and da0e463.

⛔ Files ignored due to path filters (1)
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (4)
  • .github/workflows/e2e-api-v2.yml (1 hunks)
  • .github/workflows/unit-tests.yml (1 hunks)
  • apps/api/v2/Dockerfile (1 hunks)
  • apps/api/v2/package.json (1 hunks)
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-09-02T12:29:32.592Z
Learnt from: CR
PR: calcom/cal.com#0
File: AGENTS.md:0-0
Timestamp: 2025-09-02T12:29:32.592Z
Learning: Run integration tests with `yarn test <filename> -- --integrationTestsOnly`

Applied to files:

  • .github/workflows/unit-tests.yml
📚 Learning: 2025-09-02T12:29:32.592Z
Learnt from: CR
PR: calcom/cal.com#0
File: AGENTS.md:0-0
Timestamp: 2025-09-02T12:29:32.592Z
Learning: Run specific end-to-end tests with `yarn e2e <filename> --grep "<testName>"`

Applied to files:

  • .github/workflows/e2e-api-v2.yml
🔇 Additional comments (1)
.github/workflows/e2e-api-v2.yml (1)

74-75: Standardize prep: keep "build" unless E2E needs local-linking

Found scripts for @calcom/platform-libraries: local = "node scripts/local.js && rm -rf dist && yarn build:dev && cd ../../.. && yarn"; build = "yarn vite build". Keep the current "build" step if E2E only needs a Vite production build; switch to "local" only if E2E requires the local/linking flow.

File: .github/workflows/e2e-api-v2.yml (lines 74-75)

If switching to local, apply this diff:

-          yarn workspace @calcom/platform-libraries build
+          yarn workspace @calcom/platform-libraries local

@github-actions
Copy link
Contributor

github-actions bot commented Sep 16, 2025

E2E results are ready!

@ThyMinimalDev ThyMinimalDev merged commit 65448c0 into main Sep 16, 2025
41 checks passed
@ThyMinimalDev ThyMinimalDev deleted the use-local-platform-libraries branch September 16, 2025 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core area: core, team members only ⬆️ dependencies Pull requests that update a dependency file foundation platform Anything related to our platform plan ready-for-e2e size/S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants