-
Notifications
You must be signed in to change notification settings - Fork 69
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
Remove adroll #4029
Remove adroll #4029
Conversation
Warning Rate limit exceeded@piekczyk has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 20 minutes and 2 seconds before requesting another review. How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. WalkthroughThe changes involve the complete removal of the Changes
Poem
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (2)
- analytics/adroll.ts (0 hunks)
- pages/_app.tsx (1 hunks)
Files not reviewed due to no reviewable changes (1)
- analytics/adroll.ts
Additional context used
Biome
pages/_app.tsx
[error] 160-160: Avoid using unnecessary Fragment.
A fragment is redundant if it contains only one child, or if it is the child of a html element, and is not a keyed fragment.
(lint/complexity/noUselessFragments)
// Use when there is a need to load extra script required for marketing | ||
// Example usage: | ||
// <Script dangerouslySetInnerHTML={{ __html: scriptToBeLoaded }} async /> | ||
<></> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tip
Codebase Verification
Remaining AdRoll References Detected
The AdRoll-related code has not been fully removed. Please address the following instances to ensure complete elimination:
-
runtime.config.js
adRollAdvId: process.env.ADROLL_ADV_ID,
adRollPixId: process.env.ADROLL_PIX_ID,
-
public/locales/en/common.json
&public/locales/cn/common.json
- Descriptions referencing AdRoll cookies.
-
features/content/cookie/en.tsx
- Multiple
<td>Adroll</td>
entries. - Usage of
__adroll_fpc
.
- Multiple
-
analytics/manageCookie.ts
- Comments related to AdRoll instance management.
-
README.md
- References to
ADROLL_PIX_ID
andADROLL_ADV_ID
. - Descriptions mentioning AdRoll Pixel.
- References to
-
Dockerfile.production
- Environment variables for
ADROLL_ADV_ID
andADROLL_PIX_ID
.
- Environment variables for
Please ensure that all AdRoll-related configurations, comments, and documentation are thoroughly removed to maintain codebase integrity.
Analysis chain
Approve AdRoll removal and suggest minor improvement
The removal of the AdRoll script is correctly implemented, aligning with the PR objective. The comment provides clear guidance for future marketing script additions, which is helpful.
However, we can make a small improvement:
Consider removing the empty fragment on line 160 as it's unnecessary:
{cookiesValue?.enabledCookies?.marketing && (
// Use when there is a need to load extra script required for marketing
// Example usage:
// <Script dangerouslySetInnerHTML={{ __html: scriptToBeLoaded }} async />
- <></>
)}
This change addresses the static analysis hint and slightly improves code cleanliness.
Let's verify the complete removal of AdRoll-related code:
Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash
# Description: Check for any remaining AdRoll-related code
# Test 1: Search for 'adroll' or 'AdRoll' in all files
echo "Searching for 'adroll' or 'AdRoll' in all files:"
rg -i 'adroll'
# Test 2: Check for any remaining imports from 'analytics/adroll'
echo "Checking for imports from 'analytics/adroll':"
rg "from 'analytics/adroll'"
# Test 3: Check if the 'analytics/adroll.ts' file still exists
echo "Checking if 'analytics/adroll.ts' file exists:"
fd 'adroll.ts' analytics
Length of output: 1606
Tools
Biome
[error] 160-160: Avoid using unnecessary Fragment.
A fragment is redundant if it contains only one child, or if it is the child of a html element, and is not a keyed fragment.
(lint/complexity/noUselessFragments)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Outside diff range and nitpick comments (2)
analytics/manageCookie.ts (1)
Line range hint
1-16
: Consider reviewing overall analytics strategyGiven that AdRoll support is being removed, it might be a good time to review the overall analytics strategy:
- Verify if mixpanel is still the preferred analytics tool and if its implementation is up-to-date.
- Address the TODO comment about deleting user data for mixpanel. This is important for compliance with data protection regulations.
- Consider if any other marketing or analytics tools need to be adjusted or removed alongside AdRoll.
It would be beneficial to create a task to implement the user data deletion feature for mixpanel, as mentioned in the TODO comment. This ensures compliance with data protection regulations and provides a complete analytics management solution.
.github/workflows/aws-staging.yaml (1)
Line range hint
1-176
: Suggestion: Improve workflow documentationThe workflow is well-structured and follows best practices. To further improve it, consider adding comments or documentation for each major step in the workflow. This will make it easier for other developers to understand and maintain the workflow in the future.
For example, you could add comments like:
# Step 1: Set up the environment - name: Setup node uses: actions/setup-node@v3 with: node-version: 18.19.1 # Step 2: Check for required secrets - name: Check required secrets env: # ... (environment variables) # Step 3: Build the application - name: Build standalone app id: build-app env: # ... (environment variables) # Step 4: Deploy to AWS - name: Configure AWS credentials uses: aws-actions/configure-aws-credentials@v2 with: # ... (AWS credentials) # Step 5: Run e2e tests - name: Trigger e2e tests in e2e-tests repository env: E2E_TESTS_PAT: ${{ secrets.E2E_TESTS_PAT }} run: | # ... (e2e test trigger command)This documentation will provide a clear overview of the workflow's structure and purpose.
Tools
actionlint
48-48: shellcheck reported issue in this script: SC2086:info:4:27: Double quote to prevent globbing and word splitting
(shellcheck)
Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Files selected for processing (11)
- .env.template (0 hunks)
- .github/workflows/aws-prod.yaml (0 hunks)
- .github/workflows/aws-staging.yaml (2 hunks)
- .github/workflows/dockerhub.yaml (0 hunks)
- Dockerfile.production (0 hunks)
- README.md (1 hunks)
- analytics/manageCookie.ts (1 hunks)
- features/content/cookie/en.tsx (1 hunks)
- public/locales/cn/common.json (1 hunks)
- public/locales/en/common.json (1 hunks)
- runtime.config.js (0 hunks)
Files not reviewed due to no reviewable changes (5)
- .env.template
- .github/workflows/aws-prod.yaml
- .github/workflows/dockerhub.yaml
- Dockerfile.production
- runtime.config.js
Files skipped from review due to trivial changes (1)
- public/locales/en/common.json
Additional comments not posted (6)
analytics/manageCookie.ts (1)
8-8
: Confirm if marketing cookie disable method should remain emptyThe comment about AdRoll has been removed, which aligns with the PR objective of removing AdRoll support. However, the
disable
method for the marketing cookie remains an empty function.Please confirm if this is intentional or if additional logic should be added to properly disable marketing cookies now that AdRoll is removed.
To verify the usage of this method across the codebase, you can run the following script:
This will help ensure that leaving this method empty doesn't introduce any unintended behavior.
Verification successful
Marketing cookie disable method is unused and safe to remain empty
The
manageCookie.marketing.disable
method does not appear to be used anywhere in the codebase. Leaving it as an empty function does not introduce any unintended behavior.Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Search for usage of manageCookie.marketing.disable rg --type typescript "manageCookie\.marketing\.disable"Length of output: 92
Script:
#!/bin/bash # Search for usage of manageCookie.marketing.disable with correct file type rg --type ts "manageCookie\.marketing\.disable"Length of output: 49
Script:
#!/bin/bash # Search for usage of manageCookie.marketing.disable without specifying file type rg "manageCookie\.marketing\.disable"Length of output: 39
.github/workflows/aws-staging.yaml (1)
49-49
: LGTM: AdRoll secrets correctly removed from required secrets checkThe removal of AdRoll-related secrets (
ADROLL_ADV_ID_STAGING
andADROLL_PIX_ID_STAGING
) from therequired_secrets
array is consistent with the PR objective of removing AdRoll support. The remaining secrets and the logic for checking required secrets remain intact, which is correct.README.md (2)
37-39
: LGTM: Improved readability of NPM_TOKEN noteThe reformatting of the NPM_TOKEN note improves readability without changing the content. This is a good minor improvement to the documentation.
Line range hint
1-1
: LGTM: Removal of AdRoll-related environment variablesThe removal of ADROLL_PIX_ID and ADROLL_ADV_ID environment variables from the README is consistent with the PR objective of removing AdRoll support. This change appropriately cleans up the documentation.
To ensure completeness, please run the following command to check if there are any remaining references to AdRoll in the codebase:
If this command returns any results, those occurrences should be reviewed and removed if appropriate.
features/content/cookie/en.tsx (2)
Line range hint
1-382
: Overall assessment of Cookie Policy changesThe modifications to the Cookie Policy align with the PR objective of removing AdRoll support. The targeted advertising cookies section has been updated to remove specific AdRoll information. However, there are a few points to consider for future updates:
- The placeholder row in the targeted advertising cookies table should be revisited once new marketing strategies are implemented.
- The introductory paragraph for the targeted advertising cookies section may need to be updated if no such cookies are currently in use.
- Ensure that the "Last updated" date at the beginning of the document is adjusted to reflect these changes.
While these changes are approved as they meet the immediate goal of removing AdRoll references, it's important to create a follow-up task to complete the updates to this section once new marketing strategies are determined.
376-382
: Update required for targeted advertising cookies sectionThe changes in this section reflect the removal of AdRoll-related cookie information, which aligns with the PR objective of removing AdRoll support. However, there are a few points to consider:
The TODO comment indicates that this section needs to be updated once new marketing strategies are applied. This should be tracked to ensure it's not overlooked in future updates.
The placeholder row with "-" symbols might be confusing for users. Consider either removing this row entirely if there are currently no targeted advertising cookies, or adding a note explaining that no targeted advertising cookies are currently in use.
Ensure that the "Cookies for targeted advertising" paragraph above the table is still relevant. If there are no longer any targeted advertising cookies, this paragraph might need to be updated or removed as well.
Consider the following actions:
- Create a tracking issue for updating this section once new marketing strategies are in place.
- Decide whether to remove the placeholder row or add an explanatory note.
- Review and update the introductory paragraph for this section if necessary.
To ensure consistency across the codebase, let's check for any other references to AdRoll or targeted advertising cookies:
Verification successful
AdRoll Removal Verified Successfully
- No additional AdRoll references found in the codebase.
- The "Cookies for targeted advertising" section in
features/content/cookie/en.tsx
has been appropriately updated.Scripts executed
The following scripts were executed for the analysis:
Script:
#!/bin/bash # Search for AdRoll or targeted advertising references echo "Searching for AdRoll references:" rg -i "adroll" echo "Searching for targeted advertising references:" rg -i "targeted advertising"Length of output: 295
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Remove adroll
Changes 👷♀️
- removed adroll supportHow to test 🧪
Summary by CodeRabbit
Bug Fixes
Chores