feat: add attribute logging in selectPlacements#1143
feat: add attribute logging in selectPlacements#1143jaissica12 merged 13 commits intodevelopmentfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds a devPassedAttributes field to the selectPlacements functionality to improve debugging capabilities. The devPassedAttributes field preserves the original, unmapped attributes passed by developers, while attributes contains the transformed attributes after mapping and enrichment.
Changes:
- Added
devPassedAttributesfield to the enriched options passed tokit.selectPlacementscontaining the original unmapped attributes - Updated all test expectations in
roktManager.spec.tsto verify thatdevPassedAttributesis correctly passed through - Added two new test cases specifically for
devPassedAttributesbehavior
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/roktManager.ts | Added devPassedAttributes: attributes to the enriched options object passed to kit.selectPlacements |
| test/jest/roktManager.spec.ts | Updated existing test expectations to include devPassedAttributes and added two new test cases verifying original attributes are preserved |
Comments suppressed due to low confidence (3)
src/roktManager.ts:32
- The
IRoktSelectPlacementsOptionsinterface should includedevPassedAttributesas an optional property to properly type the enriched options object that includes this field. Without this, the code at line 247 adds a property that is not part of the declared interface, creating a type mismatch. AdddevPassedAttributes?: IRoktPartnerAttributes;to the interface.
export interface IRoktSelectPlacementsOptions {
attributes: IRoktPartnerAttributes;
identifier?: string;
}
src/roktManager.ts:42
- The
IRoktLauncherinterface referencesIRoktSelectPlacementsOptionswhich should includedevPassedAttributesas an optional field. Once the interface is updated, this signature will automatically reflect the correct type.
selectPlacements: (options: IRoktSelectPlacementsOptions) => Promise<IRoktSelection>;
src/roktManager.ts:67
- The
IRoktKitinterface referencesIRoktSelectPlacementsOptionswhich should includedevPassedAttributesas an optional field. Once the interface is updated, this signature will automatically reflect the correct type.
selectPlacements: (options: IRoktSelectPlacementsOptions) => Promise<IRoktSelection>;
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@jaissica12 new requirements for this are to just add console logging to the core SDK to log the initial attributes. please follow this Apple PR https://github.com/mParticle/mparticle-apple-sdk/pull/533/changes for the proper wording |
@rmi22186 Added console logging in the core SDK for initial attributes and also updated related kit PR |
c055a4f to
391d2f3
Compare
|
# [2.56.0](v2.55.0...v2.56.0) (2026-02-04) ### Features * add attribute logging in selectPlacements ([#1143](#1143)) ([fdaef93](fdaef93))
|
🎉 This PR is included in version 2.56.0 🎉 The release is available on:
Your semantic-release bot 📦🚀 |



Background
What Has Changed
roktManager.tsroktManager.spec.tsfor corresponding changeScreenshots/Video
Checklist
Additional Notes
Reference Issue (For employees only. Ignore if you are an outside contributor)