Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Swift support #277

Merged
merged 6 commits into from
Sep 17, 2017
Merged

Swift support #277

merged 6 commits into from
Sep 17, 2017

Conversation

rotemmiz
Copy link
Member

Currently, users who use swift in their projects may not be able to use Detox if their swift version is different than the one shipped in Detox.framework.
From Detox@5.7.0 we will start compiling Detox.framework on the user's machine, to better support different Swift versions.

Relates to #152


program
.option('-r, --runner [runner]', 'Test runner (currently supports mocha)', 'mocha')
.parse(process.argv);

function createFile(dir, content) {
try {
try {
Copy link
Contributor

Choose a reason for hiding this comment

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

We should really add in prettier, these changes just obfuscate the diff.


if (os.platform() === 'darwin') {
const frameworkPath = path.join(os.homedir(), '/Library/Detox');
console.log(`Removing framework binaries from ${frameworkPath}`);
Copy link
Contributor

Choose a reason for hiding this comment

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

Why not use our default log library?

@@ -1,14 +1,18 @@
#!/bin/bash
#!/bin/bash -e
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

@rotemmiz rotemmiz merged commit d882d0e into master Sep 17, 2017
@rotemmiz rotemmiz deleted the SwiftSupport branch September 17, 2017 08:34
@chadlwilson
Copy link

chadlwilson commented Sep 20, 2017

@rotemmiz Is this fix likely to address app crashes on start like the below; which I started getting after an XCode 9 (and implicit Swift 3.2) upgrade? Or should I open a ticket? Just trying to avoid noise for you all if possible.

Exception Type:        EXC_CRASH (SIGABRT)
Exception Codes:       0x0000000000000000, 0x0000000000000000
Exception Note:        EXC_CORPSE_NOTIFY

Termination Reason:    DYLD, [0x4] Symbol missing

Application Specific Information:
dyld: launch, loading dependent libraries
DYLD_FALLBACK_LIBRARY_PATH=/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 10.3.simruntime/Contents/Resources/RuntimeRoot/usr/lib
DYLD_ROOT_PATH=/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 10.3.simruntime/Contents/Resources/RuntimeRoot
DYLD_FALLBACK_FRAMEWORK_PATH=/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS 10.3.simruntime/Contents/Resources/RuntimeRoot/System/Library/Frameworks
DYLD_INSERT_LIBRARIES=/Users/SNIP/SNIP/node_modules/detox/Detox.framework/Detox
DYLD_SHARED_REGION=avoid

Dyld Error Message:
  Symbol not found: __TMp10Foundation13CustomNSError
  Referenced from: /Users/USER/*/Detox.framework/Frameworks/libswiftCoreLocation.dylib
  Expected in: /Users/USER/Library/Developer/CoreSimulator/Devices/8D00526A-B1E0-43FF-9A77-95AB906664D7/data/Containers/Bundle/Application/752CDBE6-5D02-420A-BAC9-87232F20598A/workbench.app/Frameworks/libswiftFoundation.dylib
 in /Users/USER/*/Detox.framework/Frameworks/libswiftCoreLocation.dylib

(Answering my own question - yes this is fixed with Detox 5.7.0 which was released a matter of hours after I added this comment originally!)

@wix wix locked and limited conversation to collaborators Jul 23, 2018
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants