-
Couldn't load subscription status.
- Fork 0
fix: Fix duplicate identify events in a session #117
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
Conversation
|
bugbot run |
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.
Pull Request Overview
This PR implements wallet provider switching improvements and deduplication logic for analytics tracking. The changes focus on better handling of provider switching scenarios and preventing duplicate identify events within the same session.
- Adds session-based tracking to prevent duplicate identify events for the same wallet/provider combination
- Improves provider switching logic with better state management and race condition prevention
- Enhances event tracking with provider identification through RDNS inclusion
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/utils/base.ts | Enhanced action descriptor generation to include RDNS for connect/disconnect events |
| src/constants/base.ts | Added new session key constant for wallet identification tracking |
| src/FormoAnalytics.ts | Major refactoring of provider switching logic, added duplicate prevention, and improved state management |
Comments suppressed due to low confidence (2)
src/FormoAnalytics.ts:912
- Missing closing brace for the if statement. The code block starting with this condition is not properly closed.
hasChainId: !!nextChainId
src/FormoAnalytics.ts:913
- The condition check for duplicate RDNS values is added but the existing logic inside is not properly wrapped. This will cause the push operation to always execute regardless of the condition, defeating the purpose of the duplicate check.
});
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
bugbot run |
|
bugbot run |
|
bugbot run |
|
🎉 This PR is included in version 1.19.9 🎉 |
Merge #116 first