Skip to content

Comments

fix: eslint no-restricted-imports app-store rule#23845

Merged
anikdhabal merged 1 commit intomainfrom
fix-invalid-eslintrc-rule-no-restricted-imports
Sep 15, 2025
Merged

fix: eslint no-restricted-imports app-store rule#23845
anikdhabal merged 1 commit intomainfrom
fix-invalid-eslintrc-rule-no-restricted-imports

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

@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 15, 2025 0:52am
cal-eu Ignored Ignored Sep 15, 2025 0:52am

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 15, 2025

Walkthrough

The .eslintrc.js configuration was updated for the packages/app-store override of the no-restricted-imports rule. The allowTypeImports: false setting was removed from the outer rule options and added inside the single object within patterns that restricts @calcom/trpc/* and @trpc/* imports, alongside the existing group and message fields. No other changes were made to the ESLint configuration.

Possibly related PRs

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title Check ✅ Passed The title "fix: eslint no-restricted-imports app-store rule" accurately and concisely describes the primary change in the diff: a fix to the ESLint no-restricted-imports configuration for the app-store. It names the relevant rule and scope and uses the conventional "fix:" prefix, making the intent clear to reviewers. The title is short, specific, and free of extraneous noise.
Description Check ✅ Passed The PR description is on-topic and explains the intent (fixing the ESLint no-restricted-imports rule for app-store) while including guidance for demos, testing, and required checklist items. However it contains placeholders for issue numbers (Fixes #XXXX, CAL-XXXX) and unchecked, contradictory checklist lines that appear to be boilerplate rather than accurate status. Despite those shortcomings, the description is related to the changeset and therefore meets the lenient relevance criterion.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.
✨ Finishing touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix-invalid-eslintrc-rule-no-restricted-imports

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.

@graphite-app graphite-app bot requested a review from a team September 15, 2025 12:52
@keithwillcode keithwillcode added core area: core, team members only foundation platform Anything related to our platform plan labels Sep 15, 2025
@graphite-app graphite-app bot requested a review from a team September 15, 2025 12:52
@dosubot dosubot bot added the app-store area: app store, apps, calendar integrations, google calendar, outlook, lark, apple calendar 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: 0

🧹 Nitpick comments (1)
.eslintrc.js (1)

28-35: Block the bare '@calcom/trpc' root import in .eslintrc.js

Verified: no bare '@calcom/trpc' imports currently exist in packages/app-store; still add this lint rule to prevent regressions.

         "no-restricted-imports": [
           "error",
           {
+            paths: [
+              {
+                name: "@calcom/trpc",
+                message:
+                  "tRPC imports are blocked in packages/app-store. Move UI to apps/web/components/apps or introduce an API boundary.",
+                allowTypeImports: false,
+              },
+            ],
             patterns: [
               {
                 group: ["@calcom/trpc/*", "@trpc/*"],
                 message:
                   "tRPC imports are blocked in packages/app-store. Move UI to apps/web/components/apps or introduce an API boundary.",
                 allowTypeImports: false,
               },
             ],
           },
         ],
📜 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 f0210d0 and 0b937bd.

📒 Files selected for processing (1)
  • .eslintrc.js (1 hunks)
⏰ Context from checks skipped due to timeout of 180000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Install dependencies / Yarn install & cache
🔇 Additional comments (1)
.eslintrc.js (1)

32-33: Confirm allowTypeImports belongs to @typescript-eslint and verify package versions

File: .eslintrc.js lines 32–33 — allowTypeImports is not a core ESLint top‑level option; it's provided by @typescript-eslint (no-restricted-imports) and is set per paths/patterns entry (not a global rule option). The verification script found no package.json to confirm versions — verify installed ESLint and @typescript-eslint versions and ensure the rule is the plugin variant (@typescript-eslint/no-restricted-imports). allowTypeImports defaults to false (redundant).

@github-actions
Copy link
Contributor

github-actions bot commented Sep 15, 2025

E2E results are ready!

@ThyMinimalDev ThyMinimalDev reopened this Sep 15, 2025
@anikdhabal anikdhabal merged commit 7e415b4 into main Sep 15, 2025
133 of 142 checks passed
@anikdhabal anikdhabal deleted the fix-invalid-eslintrc-rule-no-restricted-imports branch September 15, 2025 17:10
@coderabbitai coderabbitai bot mentioned this pull request Sep 23, 2025
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app-store area: app store, apps, calendar integrations, google calendar, outlook, lark, apple calendar core area: core, team members only foundation platform Anything related to our platform plan ready-for-e2e size/XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants