Skip to content

Ambiguous use of init when using XCode Cloud #199

Description

@femmedecentral

I've been using Rollbar / Rollbar ReactNative successfully for some time, including using it as part of my automatic build pipeline in XCode Cloud. I've been working on things unrelated to Rollbar for the last couple of months and am trying to create a new build using XCode Cloud, and the only errors I seem to be running into with the new build are related to the Rollbar library / integration.

First, I ran into this issue:

RollbarCrash

Error
No type named 'set_terminate' in namespace 'std'
RollbarCrashMonitor_CPPException.cpp:223

Error
No type named 'terminate_handler' in namespace 'std'
RollbarCrashMonitor_CPPException.cpp:66

Error
No member named 'set_terminate' in namespace 'std'
RollbarCrashMonitor_CPPException.cpp:219

But I found a couple of workarounds, either adding pod 'RollbarNotifier', '~> 3.3.2'
or adding

if [target.name](http://target.name/) == 'RollbarCrash'
        file_path = 'Pods/RollbarCrash/RollbarNotifier/Sources/RollbarCrash/Monitors/RollbarCrashMonitor_CPPException.cpp'
        contents = File.read(file_path)
        unless contents.include?('#include <exception>')
          File.open(file_path, 'w') do |file|
            file.puts('#include <exception>')
            file.puts(contents)
          end
        end
      end

to the post install phase of my podfile seemed to clear that up, but now I'm stuck on a new issue:

RollbarReport

Error
Ambiguous use of 'init'
BinaryImage.swift:44

Error
Ambiguous use of 'init'
Report.swift:86

Nothing I do seems to work around this. I've tried updating from "rollbar-react-native": "1.0.0-beta.2" to "rollbar-react-native": "1.0.0-beta.4" and back around, reinstalling both rollbar and rollbar-react-native and nothing seems to help. I can build an archive locally using XCode, but I'd much prefer if my XCode Cloud process works because it has all the correct configs to package a build for production.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions