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

Configure OptimizelyLogLevel based on bundle type #1007

Merged
merged 3 commits into from
Jan 3, 2020

Conversation

ifbarrera
Copy link
Contributor

@ifbarrera ifbarrera commented Jan 2, 2020

📲 What

Configures the Optimizely SDK's log level based on the bundle type. For debug builds, the log level is .debug, which gives us as much debugging information as possible. For release builds, the log level is set to .error which is the highest possible log level, only logging severe errors.

🤔 Why

To prevent excessive logging on release builds.

🛠 How

Added an additional output type KSROptimizelyLogLevel to the configureOptimizely output which will either be .debug or .error depending on the main bundle type.

♿️ Accessibility

N/A

🏎 Performance

N/A

✅ Acceptance criteria

  • Run the app on a debug build. Observe in the console the following log: [OPTIMIZELY] [DEBUG] SDK Version: 3.1.0
  • Run the app on a release build. The console should not log any messages related to Pptimizely, with the exception of 🔮 Optimizely SDK Successfully Configured

Copy link
Contributor

@justinswart justinswart left a comment

Choose a reason for hiding this comment

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

Nice! Just had the naming suggestion.

@ifbarrera ifbarrera merged commit a25bc41 into feature-optimizely Jan 3, 2020
@ifbarrera ifbarrera deleted the optimizely-logger branch January 3, 2020 17:21
@ifbarrera ifbarrera mentioned this pull request Jan 3, 2020
ifbarrera pushed a commit that referenced this pull request Jan 8, 2020
* [NT-580, NT-702] Optimizely integration and Testable Client (#989)

* wip - optimizely ab test set up

* wip - optimizely struct

* wip - optimizely

* wip - optimizely refactor

* wip - optimizely

* wip - a testable optimizely client

* wip - a testable optimizely client swift format

* wip - optimixely refactor

* wip - optimizely fix tests

* wip - optimizely appdelegate test

* wip - optimizely fix

* wip - optimizely test environment

* wip - optimizely

* wip - remove func

* [NT-580] Optimizely Integration Updates (#999)

* Testing configuration result

* Linking Optimizely with Framework instead of main app target

* Updating targets

* Cleaning up targets etc

* Removing commented out line

* Formatting

* Remove test code

* Line length

* Add OptimizelyResultType with tests

* Formatting and adding weak self

* Line length

* Chaining the variant enum into the guard

Co-authored-by: Isabel Barrera <ifbarrera@me.com>

* [NT-703] Pledge CTA A/B Experiment (#994)

* wip - optimizely ab test set up

* wip - optimizely struct

* wip - optimizely

* wip - optimizely refactor

* wip - optimizely

* wip - a testable optimizely client

* wip - a testable optimizely client swift format

* wip - optimixely refactor

* wip - optimizely fix tests

* wip - optimizely appdelegate test

* wip - optimizely fix

* wip - optimizely test environment

* wip - optimizely

* wip - remove func

* See rewards experimental copy

* wip - optimizely a/b experiment

* snapshot testing

* Formatting

* Fixing targets, tests

* Cleaning up warnings

* Removing Optimizely imports

* Specify control group in VC test

* Merge

* MockUUID and shared function

* Formatting

Co-authored-by: Isabel Barrera <ifbarrera@me.com>

* Configure OptimizelyLogLevel based on bundle type (#1007)

* Setting OptimizelyLogLevel based on bundle type

* Formatting

* Adding OptimizelyLogLevelType as a file

Co-authored-by: Christella <cdolm92@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants