Skip to content

Conversation

@armcknight
Copy link
Member

@armcknight armcknight commented Nov 7, 2023

I was seeing this runtime error trying to run tvOS tests locally:

2023-11-06 17:07:22.055807-0900 xctest[3004:27207] [general] Error loading /Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/SentryProfilerTests.xctest/SentryProfilerTests (177):  dlopen(/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/SentryProfilerTests.xctest/SentryProfilerTests, 0x0109): Library not loaded: /Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a
  Referenced from: <2D742D1E-D6A4-37DB-88B5-1F09B59C9473> /Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/SentryProfilerTests.xctest/SentryProfilerTests
  Reason: tried: '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (code signature in <BD2663C2-EC67-3F39-947C-38D605E44EF8> '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' not valid for use in process: Trying to load an unsigned library), '/Applications/Xcode15/Xcode.app/Contents/Developer/Platforms/AppleTVSimulator.platform/Developer/usr/lib/libSentryTestUtils.a' (no such file), '/Library/Developer/CoreSimulator/Volumes/tvOS_21J353/Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS 17.0.simruntime/Contents/Resources/RuntimeRoot/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (no such file), '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (code signature in <BD2663C2-EC67-3F39-947C-38D605E44EF8> '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' not valid for use in process: Trying to load an unsigned library), '/Library/Developer/CoreSimulator/Volumes/tvOS_21J353/Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS 17.0.simruntime/Contents/Resources/RuntimeRoot/usr/lib/libSentryTestUtils.a' (no such file)
2023-11-06 17:07:22.177921-0900 xctest[3004:27207] [Default] The bundle “SentryProfilerTests.xctest” couldn’t be loaded. Try reinstalling the bundle.
2023-11-06 17:07:22.178012-0900 xctest[3004:27207] [Default] (dlopen(/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/SentryProfilerTests.xctest/SentryProfilerTests, 0x0109): Library not loaded: /Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a
  Referenced from: <2D742D1E-D6A4-37DB-88B5-1F09B59C9473> /Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/SentryProfilerTests.xctest/SentryProfilerTests
  Reason: tried: '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (code signature in <BD2663C2-EC67-3F39-947C-38D605E44EF8> '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' not valid for use in process: Trying to load an unsigned library), '/Applications/Xcode15/Xcode.app/Contents/Developer/Platforms/AppleTVSimulator.platform/Developer/usr/lib/libSentryTestUtils.a' (no such file), '/Library/Developer/CoreSimulator/Volumes/tvOS_21J353/Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS 17.0.simruntime/Contents/Resources/RuntimeRoot/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (no such file), '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' (code signature in <BD2663C2-EC67-3F39-947C-38D605E44EF8> '/Users/andrewmcknight/Library/Developer/Xcode/DerivedData/Sentry-gnnqqmcfqpqmmhcjxfzwadgjajnt/Build/Products/Test-appletvsimulator/libSentryTestUtils.a' not valid for use in process: Trying to load an unsigned library), '/Library/Developer/CoreSimulator/Volumes/tvOS_21J353/Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS 17.0.simruntime/Contents/Resources/RuntimeRoot/usr/lib/libSentryTestUtils.a' (no such file))
Program ended with exit code: 83

This overrides the default value for this setting which is "dynamic library", whereas this target is actually a static lib.

@armcknight armcknight changed the title test: fix dyld error not being able to run on tvOS test: fix dyld error causing tvOS tests to fail to launch Nov 7, 2023
Copy link
Member

@philipphofmann philipphofmann left a comment

Choose a reason for hiding this comment

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

LGTM.

@armcknight armcknight merged commit e5dcbd5 into main Nov 7, 2023
@armcknight armcknight deleted the armcknight/test/tvos-build branch November 7, 2023 18:54
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.

3 participants