Skip to content
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

[FSSDK-9776] handle duplicate experiment key #523

Merged
merged 11 commits into from
Nov 30, 2023

Conversation

muzahidul-opti
Copy link
Contributor

Summary

When duplicate experiment key found in the data file, SDK returns correct experiment map in OptimizelyConfig

  • Keep latest experiment key, found in the datafile experiment list
  • Add warning log "Duplicate keys found in datafile: {key-name}"

Test plan

  • Add test case for OptimizelyConfig with duplicate key

Issues

@muzahidul-opti muzahidul-opti marked this pull request as ready for review November 24, 2023 17:16
@muzahidul-opti muzahidul-opti requested a review from a team as a code owner November 24, 2023 17:16
Copy link

@mikechu-optimizely mikechu-optimizely left a comment

Choose a reason for hiding this comment

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

Some thoughts but LGTM.

Sources/Optimizely/OptimizelyConfig.swift Outdated Show resolved Hide resolved
Copy link
Collaborator

@jaeopt jaeopt left a comment

Choose a reason for hiding this comment

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

Looks good. Can you check why your code format/styles are different from existing codes?

Sources/Optimizely/OptimizelyConfig.swift Outdated Show resolved Hide resolved
Sources/Optimizely/OptimizelyConfig.swift Outdated Show resolved Hide resolved
@mikechu-optimizely
Copy link

Can I use this as a reference for doing other language SDK updates?

@muzahidul-opti
Copy link
Contributor Author

Can I use this as a reference for doing other language SDK updates?

Sure

@mikechu-optimizely
Copy link

Thanks for the lint fixes. This helps my need for meticulous code. 😄

Also thanks for the reference implementation for me to copy 😁

@muzahidul-opti muzahidul-opti merged commit c2af8fe into master Nov 30, 2023
10 of 12 checks passed
@muzahidul-opti muzahidul-opti deleted the muzahid/handle-duplicate-experiment-key branch November 30, 2023 10:48
muzahidul-opti added a commit that referenced this pull request Dec 5, 2023
Logged for Duplicate keys

(cherry picked from commit c2af8fe)
muzahidul-opti added a commit that referenced this pull request Dec 6, 2023
* Upload task body issue fixed (#521)

(cherry picked from commit a375e2b)

* [FSSDK-9776] handle duplicate experiment key (#523)

Logged for Duplicate keys

(cherry picked from commit c2af8fe)

* [FSSDK-9709] feat: App privacy manifest file added (#522)

* Update CHANGELOG.md

* Update README.md

* Update swift.yml

* Update run_unit_tests.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants