Opening import file for module <framework>: Permission denied - xcode
I set up a remote Git repository and Xcode Server on another computer, then created a bot in Xcode.
Every time I try to do a new integration, it fails with an error like this:
Assertion: Opening import file for module 'Accelerate': Permission denied
File: <filename>.swift:9
If I comment everything in this file, bot starts showing same error for another framework (and another .swift file). It can be either Swift or Objective-C framework.
Search Paths for this project is: $(PROJECT_DIR), and Always Search User Paths is set to Yes
I'm using Xcode 7.2 beta 2, but I was facing the same issue on Xcode 7.1 from the App Store. I tried restarting Xcode and both server and development Macs, it doesn't help. The project compiles and runs successfully on my development machine.
Server Logs: (xcsbuildd.log)
[BuildService] Previous integration is needed but not loaded yet, fetching.
[BuildService] Previous integration loaded successfully.
[BuildService] Completed integration step XCSCheckoutIntegrationStep without error
[BuildService, Info] Asset packs will be hosted at <server url here>
[BuildService] Current server devices are needed but not loaded yet, fetching.
[BuildService] Devices loaded successfully.
[BuildService, Info] Current server platforms are needed but not loaded yet, fetching.
[BuildService, Info] Platforms loaded successfully.
[BuildService] Creating arguments list for integrate
[BuildService] Integration will not perform analyze action
[BuildService] Integration will perform test action
[BuildService] Integration use scheme-level code coverage enabled setting
[BuildService] Additional build arguments are "(
)"
[BuildService, Info] Creating test device destination arguments for device testing
[BuildService, Info] Create test device destination arguments from device specification
[BuildService, Info] Including device iPhone 6 Plus (A3E8ED2D-4D13-420E-8CE1-6D484E65CD03)
[BuildService, Info] Destination arguments are (
"-skipUnsupportedDestinations",
"-destination-timeout",
30,
"-DVTDeviceLogLevel=3",
"-DVTDeviceSearchLogLevel=3",
"-iPhoneSimulatorLogLevel=3",
"-iPhoneConnectLogLevel=3",
"-destination",
"id=A3E8ED2D-4D13-420E-8CE1-6D484E65CD03"
)
[BuildService] Integrate arguments list is (
"/usr/bin/xcrun",
xcodebuild,
test,
"-IDETestOperationsObserverDebugLogLevel=3",
"-IDEBuildOperationMaxPercentageOfConcurrentCompileTasks=80",
"-IDEBuildOperationQueueSetResourceManagementLogLevel=2",
"-DTDKSupportWirelessDevices=NO",
"-IDEPostProgressNotifications=YES",
"-DVTAllowServerCertificates=YES",
"-DVTSigningCertificateSourceLogLevel=3",
"-DVTSigningCertificateManagerLogLevel=3",
"-DTDKProvisioningProfileExtraSearchPaths=/Library/Developer/XcodeServer/ProvisioningProfiles",
"-DTDKDisableSymbolCopying=YES",
"-scheme",
Newsfeeder,
"-skipUnavailableActions",
"-project",
"/Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/Source/Newsfeeder/Newsfeeder.xcodeproj",
"-derivedDataPath",
"/Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/DerivedData",
"-skipUnsupportedDestinations",
"-destination-timeout",
30,
"-DVTDeviceLogLevel=3",
"-DVTDeviceSearchLogLevel=3",
"-iPhoneSimulatorLogLevel=3",
"-iPhoneConnectLogLevel=3",
"-destination",
"id=A3E8ED2D-4D13-420E-8CE1-6D484E65CD03",
"-DVTSuppressExternalDeviceLocation=NO",
"-resultBundlePath",
"/Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild_result.bundle"
)
[BuildService] NSTask environment: {
"DEVELOPER_DIR" = "/Library/Developer/XcodeServer/CurrentXcodeSymlink/Contents/Developer";
PATH = "/Applications/Xcode-beta.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin";
XCS = 1;
"XCS_BOT_ID" = 1770e1afb8f775d8c92855beba002640;
"XCS_BOT_NAME" = "Newsfeeder Bot";
"XCS_BOT_TINY_ID" = 8466E19;
"XCS_DERIVED_DATA_DIR" = "/Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/DerivedData";
"XCS_INTEGRATION_ID" = 1770e1afb8f775d8c92855beba008e0d;
"XCS_INTEGRATION_NUMBER" = 2;
"XCS_INTEGRATION_RESULT" = unknown;
"XCS_INTEGRATION_TINY_ID" = B989BD8;
"XCS_OUTPUT_DIR" = "/Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d";
"XCS_SOURCE_DIR" = "/Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/Source";
"XCS_XCODEBUILD_LOG" = "/Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild.log";
}
[BuildService] Running task /usr/bin/nice /usr/bin/xcrun xcodebuild test -IDETestOperationsObserverDebugLogLevel=3 -IDEBuildOperationMaxPercentageOfConcurrentCompileTasks=80 -IDEBuildOperationQueueSetResourceManagementLogLevel=2 -DTDKSupportWirelessDevices=NO -IDEPostProgressNotifications=YES -DVTAllowServerCertificates=YES -DVTSigningCertificateSourceLogLevel=3 -DVTSigningCertificateManagerLogLevel=3 -DTDKProvisioningProfileExtraSearchPaths=/Library/Developer/XcodeServer/ProvisioningProfiles -DTDKDisableSymbolCopying=YES -scheme Newsfeeder -skipUnavailableActions -project /Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/Source/Newsfeeder/Newsfeeder.xcodeproj -derivedDataPath /Library/Developer/XcodeServer/Integrations/Caches/1770e1afb8f775d8c92855beba002640/DerivedData -skipUnsupportedDestinations -destination-timeout 30 -DVTDeviceLogLevel=3 -DVTDeviceSearchLogLevel=3 -iPhoneSimulatorLogLevel=3 -iPhoneConnectLogLevel=3 -destination id=A3E8ED2D-4D13-420E-8CE1-6D484E65CD03 -DVTSuppressExternalDeviceLocation=NO -resultBundlePath /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild_result.bundle
[BuildService, Info] Monitoring /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild.log for activity.
[BuildService, Info] Done monitoring xcodebuild.log for activity.
[BuildService] Scheme actions record is needed but not loaded yet, fetching.
[BuildService] Scheme actions record loaded successfully.
[BuildService] Completed integration step XCSBuildIntegrationStep without error
[BuildService] Last integration with build results is needed but not loaded yet, fetching.
[BuildService] Last integration with build results loaded successfully.
[BuildService] Build results summary: {
analyzerWarningChange = 0;
analyzerWarningCount = 0;
codeCoveragePercentage = 0;
codeCoveragePercentageDelta = 0;
errorChange = 0;
errorCount = 1;
improvedPerfTestCount = 0;
regressedPerfTestCount = 0;
testFailureChange = 0;
testFailureCount = 0;
testsChange = 0;
testsCount = 0;
warningChange = 0;
warningCount = 0;
}
[BuildService] Integration commit history are needed but not loaded yet, fetching.
[BuildService] Integration commits loaded successfully.
[BuildService] Completed integration step XCSProcessBuildResultsIntegrationStep without error
[BuildService] Matched device <XCSDevice 0x7fc77e82eaf0>
{"modelUTI":"com.apple.iphone-6-plus-b4b5b9","connected":"YES","modelCode":"iPhone7,1","simulator":"YES","osVersion":"9.2","modelName":"iPhone 6 Plus","supported":"YES","deviceUDID":"A3E8ED2D-4D13-420E-8CE1-6D484E65CD03","identifier":"A3E8ED2D-4D13-420E-8CE1-6D484E65CD03","enabledForDevelopment":"YES","architecture":"x86_64","isServer":"NO","tinyID":"A3E8ED2","doc_type":"device","trusted":"YES","platformIdentifier":"com.apple.platform.iphonesimulator","name":"iPhone 6 Plus","retina":"YES"} to server device <XCSDevice 0x7fc77e398d70>
{"osVersion":"9.2","connected":"YES","simulator":"YES","modelCode":"iPhone7,1","deviceType":"com.apple.iphone-simulator","modelName":"iPhone 6 Plus","revision":"6-71966f4a54eb01b83604036d5b31c53c","modelUTI":"com.apple.iphone-6-plus-b4b5b9","doc_type":"device","trusted":"YES","name":"iPhone 6 Plus","supported":"YES","identifier":"A3E8ED2D-4D13-420E-8CE1-6D484E65CD03","enabledForDevelopment":"YES","platformIdentifier":"com.apple.platform.iphonesimulator","ID":"11f2b4085b58a3769cd320245b004ab9","architecture":"x86_64","retina":"NO","isServer":"NO","tinyID":"37889F2"}
[BuildService] Processing device: <XCSDevice 0x7fc77e398d70>
{"osVersion":"9.2","connected":"YES","simulator":"YES","modelCode":"iPhone7,1","deviceType":"com.apple.iphone-simulator","modelName":"iPhone 6 Plus","revision":"6-71966f4a54eb01b83604036d5b31c53c","modelUTI":"com.apple.iphone-6-plus-b4b5b9","doc_type":"device","trusted":"YES","name":"iPhone 6 Plus","supported":"YES","identifier":"A3E8ED2D-4D13-420E-8CE1-6D484E65CD03","enabledForDevelopment":"YES","platformIdentifier":"com.apple.platform.iphonesimulator","ID":"11f2b4085b58a3769cd320245b004ab9","architecture":"x86_64","retina":"NO","isServer":"NO","tinyID":"37889F2"}
[BuildService] Completed integration step XCSProcessTestResultsIntegrationStep without error
adding: xcodebuild_result.bundle/ (stored 0%)
adding: xcodebuild_result.bundle/1_Test/ (stored 0%)
adding: xcodebuild_result.bundle/1_Test/action.xcactivitylog (stored 0%)
adding: xcodebuild_result.bundle/1_Test/build.xcactivitylog (deflated 1%)
adding: xcodebuild_result.bundle/Info.plist (deflated 79%)
[BuildService] Uploading file /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild_result.bundle.zip
[BuildService] Uploading file /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/buildService.log
[BuildService] Uploading file /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/xcodebuild.log
[BuildService] Uploading file /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/sourceControl.log
[BuildService] Uploading file /Library/Developer/XcodeServer/Integrations/Integration-1770e1afb8f775d8c92855beba008e0d/Session-2015-11-04_16:54:03-zpFYIF.log to relative path (null)
[BuildService] Completed integration step XCSUploadFilesIntegrationStep without error
[BuildService] Integration executor is finished. Exiting.
[BuildService] Registering build service socket listeners
[BuildService] Done registering build service socket listeners
I had the same error when I tried to build and run the tests for my own framework on continuous integration server (Xcode Service Bots). The problem was first observed after upgrading my Server app to Version 5.1 (15S5127) and Xcode to Version 7.3 (7D175).
In my case the solution turned out to be quite surprising. It took me lots of time to realise that the problem only shows up when I use Nimble framework. When I remove import Nimble from my test and use standard XCTest assertions, the problem goes away.
What helped in my case was making sure that before integration, the Nimble framework is rebuilt. I am using Nimble with Carthage, so I only had to add the following command in the Before Integration Trigger:
cd NimbleCarthageProblem && /usr/local/bin/carthage bootstrap --platform iOS
See also screenshot:
After that it builds and tests run successfully.
From your logs I can't see if you are using Nimble - if you do not, than it means that the problem is somewhere else and I just experienced its another revelation.
I still do not understand why is the problem only happening on the build server during integration. Even if I log into build machine, check out the source code, and build it with Xcode right there - everything is fine. It only fails on the bot during integration. The solution is not ideal for another reason: Nimble has to be rebuilt before each integration and cannot just be included in the source code (if one finds this a better approach).
If I hope someone else will find the actual solution. I do not blame Nimble - it is most certainty a combination of things.
I created an example project where the problem and the solution are described in more details. It can be found here: https://github.com/mczenko/NimbleCarthageProblem.
Related
Genexus17 could not reach web server
I am following Udemy tutorials with Genexus 17 trial version. After I create my first transaction, and click F5 to Execute/Deploy to cloud, it displays the following error: ========== DeveloperMenu Compilation for Default (.NET Framework) started ========== "C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe" /nologo /p:Configuration=Release /p:FrameworkPath="C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319" /v:q /m "C:\Models\TravelAgency3\CSharpModel\build\LastBuild.sln" Success: DeveloperMenu Compilation for Default (.NET Framework) ========== Web config update started ========== Updating web config ... Success: Web config update Building file gx_last_transfer.zip... Uploading 7 Kbytes Deploying website ========== Execution started ========== ... waiting for server ... error: Could not reach web server or something went wrong running your application at https://trialapps3.genexus.com/Idf34a868f535909f93e51fbc52ebdb90f/developermenu.html please try again. Status code: 404 NotFound.. If the problem persists, follow the steps described in https://wiki.genexus.com/commwiki/wiki?49557 Failed: Execution Failed: Run Developer Menu
File developermenu.html is not deployed to cloud when "Short File Name" is not enabled in your Windows installation. Anyway, the application seems to be well deployed. There are three solutions: What this html has is a link to each object of the KB, so what you can do is to include the name of the object to be executed in the URL. Example: https://trialapps3.genexus.com/Idf34a868f535909f93e51fbc52ebdb90f/customer.aspx Another possibility is to create a Webpanel main (https://wiki.genexus.com/commwiki/servlet/wiki?7407,Main%20program%20property) that calls the rest of the objects (eg using a button or a link) and execute that main. Perhaps the easiest is to edit Packages\rundotnet.config file including this line: *.html
Xcode Unit Test binary files work in Simulator but not on device
I have a Unit Test for batch processing of data. I have added the test data by dragging the files into the Test target (without the copy if needed option). When testing in Simulator, it can find the files just fine In the Unit Test, I access the folder by doing func readFolder(folderPath: String) -> [String] { let folderPath = "/\(folderPath)"+"/\(subfolder)" var files = try! FileManager.default.contentsOfDirectory(atPath: Bundle(for: type(of: self)).resourcePath!+folderPath) ... However, once I run that test on my device I get Failed to load test bundle from file:///private/var/containers/Bundle/Application/../Processing.app/PlugIns/ProcessingTests.xctest/: Error Domain=NSCocoaErrorDomain Code=3588 "dlopen(/var/containers/Bundle/Application/.../Processing.app/PlugIns/ProcessingTests.xctest/ProcessingTests, 0x0109): tried: '/var/containers/Bundle/Application/.../Processing.app/PlugIns/ProcessingTests.xctest/ProcessingTests' (code signature invalid (errno=1) sliceOffset=0x00000000, codeBlobOffset=0x0001F1B0, codeBlobSize=0x00004C30 for '/private/var/containers/Bundle/Application/.../Processing.app/PlugIns/ProcessingTests.xctest/ProcessingTests'), '/usr/local/lib/ProcessingTests' (no such file), '/usr/lib/ProcessingTests' (no such file), ... The bundle “ProcessingTests” couldn’t be loaded. Try reinstalling the bundle. How can I access the files located in the Unit Tests without having to add them to the actual app target? I want to avoid this since I think it's best to isolate the tests as much as possible from the app itself so adding the test data to the test target makes more sense.
The error message is misleading. I had to change the team for signing for the Test and everything worked out.
Automatic appended .xctrunner in my XCUITest bundle id while running on device
After updating to Xcode 11.3, my all test cases stopped working because of the unnecessary text .xctrunner appended with bundle id. Example- If I am giving bundle id as abc.com then it's showing abc.com.xctrunner at run time.
XCode 11 changed the format for building xcuitest. To run UI test on device create AppId and Profiles for "$YOUR_TEST_BUNDLE_ID.xctrunner". Set bundle Id for test target without xctrunner like "$YOUR_TEST_BUNDLE_ID" Here is my Fastlane match config for iOS and Catalyst. PRODUCT_BUNDLE_IDENTIFIER = com.test PROVISIONING_PROFILE_SPECIFIER[sdk=*] = match Development com.test.xctrunner PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*] = match Development com.test.xctrunner catalyst One Annoying Xcode issues is, Signing & Capabilities for UITest target shows status error. Because profiles don't match but no build error and UI test works just fine. Status error is bit hidden but love to resolve it.
MS Test hangs when tried to execute the tests without installing visual studio
To execute the tests using MSTest I have already copied required dlls to specific folder. It is not giving me any exception. Added logging to MsTest.exe.config though no logs are generated in a file mentioned MSTest.exe.config. Command is: C:\01Jenkins\MsTest\MSTest.exe /testcontainer:"C:\abc.dll " /resultsfile:C:abc\TestResults\testresult2.trx /category:"xyz" Loading C:\abc.dll... Starting execution... It gets stuck at the above point Any type of solution would be appreciated.
deploying debug app to playbook gives "failure 881 required signatures missing (RDK, AUTHOR)"
I am using Marmalade to build a PlayBook app, but I think my question applies to PlayBook apps in general. I have successfully created a debugtoken.bar file and have installed it on my device. When I go to try to install a built application.bar file on the device, I get: [execute] "blackberry-deploy.bat -device 192.168.1.114 -password ******* -installApp -package deployments\default\playbook\release\Quote Unquote.bar" Info: Sending request: Install Info: Action: Install Info: File size: 6400334 Info: Installing ... Info: Processing 6400334 bytes actual_dname:: actual_id:: actual_version:: result::failure 881 required signatures missing (RDK, AUTHOR) ERROR: error running blackberry-deploy ***ERROR*** Note that this is the Marmalade deploy tool running the standard PlayBook installer. What I don't understand is: I thought the point of using a debugtoken.bar file was that you could install unsigned apps. I have in fact successfully deployed these unsigned apps using the Marmalade deploy tool just like this. But I was having problems signing the app for distribution, so I went back and did everything from scratch, requested new code signing keys from RIM, made a new debugtoken.bar file and installed it, etc. And now I'm worse off than I was before because I can't even install to the device now. So again: My understanding is that the point of debugtoken.bar was to be able to deploy to the device before actually signing the application.bar for distribution. So what does this error message even mean?
To answer my own question: For deploying a "debug" build to a device, it's critical to have Application-Development-Mode: true in the MANIFEST.MF within the .bar file. A stupid mistake, but I'll leave this up in case it helps anyone...
Taking a look to the QNX deployment plugin "C:\Marmalade\6.1\s3e\deploy\plugins\qnx\qnx.py" I found that 'FOR DEVELOPMENT' option is false if the 'playbook_keystore' is given so I just cleared the signing section on the Marmalade System Deployment Tool and it is not longer trying to sign it