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

Rename "metaData" to "metadata" #450

Merged
merged 2 commits into from
Feb 5, 2020

Conversation

robinmacharg
Copy link
Contributor

@robinmacharg robinmacharg commented Jan 28, 2020

Goal

Rename internal occurrences of "metaData" with "metedata" for cross-platform consistency and as a basis for subsequent work. This change leaves alone any occurrences that are destined for the Bugsnag HTTP API since this has not changed. For completeness: If API-related occurrences are changed at a later date they will have to account for both "metaData" and "metadata" validly existing in on-disk events.

Design

Simple manual refactor, file by file, using repeated case-sensitive text search and avoiding API interacting occurrences. One gotcha was the mention in the module.modulemap that caused compilation errors with erroneous root cause.

Changeset

Multiple files affected (not all visible from an XCode full-text search):

M	OSX/module.modulemap
M	Source/Bugsnag.h
M	Source/Bugsnag.m
M	Source/BugsnagBreadcrumb.m
M	Source/BugsnagConfiguration.h
M	Source/BugsnagConfiguration.m
M	Source/BugsnagEvent.h
M	Source/BugsnagEvent.m
M	Source/BugsnagKeys.h
M	Source/BugsnagMetadata.h
M	Source/BugsnagMetadata.m
M	Source/BugsnagNotifier.h
M	Source/BugsnagNotifier.m
M	Tests/BugsnagEventTests.m
M	Tests/BugsnagSinkTests.m
M	iOS/BugsnagTests/BugsnagEventFromKSCrashReportTest.m
M	iOS/module.modulemap
M	tvOS/module.modulemap

Tests

Existing tests were modified for consistency and all passed.

Review

Outstanding Questions

  • This pull request is ready for:
    • Initial review of the intended approach, not yet feature complete
    • Structural review of the classes, functions, and properties modified
    • Final review
  • The correct target branch has been selected (master for fixes, next for
    features)
  • Consistency across platforms for structures or concepts added or modified
  • Consistency between the changeset and the goal stated above
  • Internal consistency with the rest of the library - is there any overlap between existing interfaces and any which have been added?
  • Usage friction - is the proposed change in usage cumbersome or complicated?
  • Performance and complexity - are there any cases of unexpected O(n^3) when iterating, recursing, flat mapping, etc?
  • Concurrency concerns - if components are accessed asynchronously, what issues will arise
  • Thoroughness of added tests and any missing edge cases
  • Idiomatic use of the language

Copy link
Contributor

@kattrali kattrali left a comment

Choose a reason for hiding this comment

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

This change leaves external API-related occurrences as they are.

What does this part mean? As in the HTTP public interface or library public interface?

iOS/BugsnagTests/BugsnagKSCrashSysInfoParserTest.m Outdated Show resolved Hide resolved
@robinmacharg
Copy link
Contributor Author

This change leaves external API-related occurrences as they are.

What does this part mean? As in the HTTP public interface or library public interface?

Correct: HTTP. Any occurrences of "metaData" - capital-D - that are sent to the main Bugsnag API have been left as-is. I'll edit the commit message to clarify this.

@robinmacharg robinmacharg force-pushed the robinmacharg/rename-metadata-class branch 4 times, most recently from b8099cf to 016607b Compare February 5, 2020 13:20
@kattrali
Copy link
Contributor

kattrali commented Feb 5, 2020

The changeset itself looks good, the tests are either failing and/or warning because the Xcode project files for tvOS and macOS (tvOS/Bugsnag.xcodeproj and OSX/Bugsnag.xcodeproj) need to be updated with new filenames.

@robinmacharg robinmacharg force-pushed the robinmacharg/rename-metadata-class branch 2 times, most recently from 9ecef69 to e7661b0 Compare February 5, 2020 20:43
@robinmacharg robinmacharg force-pushed the robinmacharg/rename-metadata-class branch from e7661b0 to a707db8 Compare February 5, 2020 21:30
@robinmacharg robinmacharg merged commit 89a4eb1 into spec-compliance Feb 5, 2020
@robinmacharg robinmacharg deleted the robinmacharg/rename-metadata-class branch February 5, 2020 22:22
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.

2 participants