Skip to content

Fixed log level ordering to standard#293

Merged
matux merged 1 commit into
masterfrom
log_level_order
Jun 6, 2023
Merged

Fixed log level ordering to standard#293
matux merged 1 commit into
masterfrom
log_level_order

Conversation

@matux

@matux matux commented Jun 6, 2023

Copy link
Copy Markdown
Collaborator

Description of the change

This PR fixes the ordering of log levels which was very wrong. This issue was reported today.

This incorrect ordering introduces issues when defining minimum level for logging since we use the integer ordering of the enum to check whether we should record a log or not.

This can be seen in the shouldSkipReporting: function in RollbarLogger: https://github.com/rollbar/rollbar-apple/blob/master/RollbarNotifier/Sources/RollbarNotifier/RollbarLogger.m#L179

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Maintenance
  • New release

Related issues

Checklists

Development

  • Lint rules pass locally
  • The code changed/added as part of this pull request has been covered with tests
  • All tests related to the changed code pass in development

Code review

  • This pull request has a descriptive title and information useful to a reviewer. There may be a screenshot or screencast attached
  • "Ready for review" label attached to the PR and reviewers assigned
  • Issue from task tracker has a link to this pull request
  • Changes have been reviewed by at least one other engineer

@matux matux self-assigned this Jun 6, 2023
@shortcut-integration

Copy link
Copy Markdown

This pull request has been linked to Shortcut Story #126937: Apple SDK: Fix ordering of logging levels.

@cyrusradfar cyrusradfar self-requested a review June 6, 2023 20:53

@cyrusradfar cyrusradfar left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Thanks for the quick turn. One nit. Although we appreciate the rename helps standardize to a convention, but in the future, consider breaking into two PRs so we can limit the risk of the quick fix.

@matux

matux commented Jun 6, 2023

Copy link
Copy Markdown
Collaborator Author

Thanks for the quick turn. One nit. Although we appreciate the rename helps standardize to a convention, but in the future, consider breaking into two PRs so we can limit the risk of the quick fix.

I understand, couldn't help the OCD, next time I'll do a proper separate PR!

@ijsnow ijsnow left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🦦

@matux matux force-pushed the log_level_order branch from 1bb812f to 63dba45 Compare June 6, 2023 22:13
@matux matux force-pushed the log_level_order branch from 63dba45 to ecb1133 Compare June 6, 2023 22:39
@matux matux merged commit ef7a934 into master Jun 6, 2023
@matux matux deleted the log_level_order branch June 6, 2023 22:59
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.

Priority of RollbarLevel.Info and RollbarLevel.Debug is inverted - version 3.0.0

3 participants