Troubleshooting

Installation Issues

Package Manager - Cannot perform upm operation: Unable to add package

Confirm the URL doesn't have a trailing whitespace at the end. The Unity Package Manager will fail to find the package if a trailing whitespace is appended.

Package Manager - 'HEAD': cannot update ref 'refs/heads/master'

Some Unity versions, such as 2019.4.24f1 and 2020.3.2f1, have a bug on UPM and fail to install with the error 'HEAD': cannot update ref 'refs/heads/master'. Unity has resolved this issue on newer releases. Learn more by checking the Unity Issue Tracker.

PrecompiledAssemblyException: Multiple precompiled assemblies with the same name

The Sentry UPM package includes multiple DLLs within it. One or more of those DLLs might have already been provided by other packages. Unity's package manager does not resolve those dependency conflicts which means it has to be resolved manually:

  1. Choose which DLL you want to remove.
  2. Embed the package so you can modify it. This means you copy the package from Unity's global cache into your project's package directory and it should be version controlled.
  3. Remove the conflicting DLL.

The name of the conflicting DLL is provided through the PrecompiledAssemblyException entry in the editor console.

Background information

Sentry SDK for Unity targets .NET Standard 2.0. It's based on the Sentry SDK for .NET which supports many versions of .NET and Mono. Starting from .NET 5.0 the .NET SDK has no dependencies. Unity has announced its intention to support .NET 6:

We would like to have something out in a preview in the fall of 2021 to coincide with .NET 6 release from Microsoft.

With this release, Sentry's SDK for Unity will have no dependencies to any external DLLs and such DLL conflict issues that UPM is unable to handle will no longer be something you need to deal with when using Sentry for Unity.

Build Issues

Target Integrity - Building for iOS Simulator, but the linked and embedded framework 'Sentry.framework' was built for iOS.

Our Unity SDK currently supports native iOS when building for device only. Support for the iOS simulators is planned.

Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) to suggesting an update ("yeah, this would be better").