Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Problem building with 0.7.0 and Carthage #57

Open
rickkas7 opened this issue May 8, 2017 · 8 comments
Open

Problem building with 0.7.0 and Carthage #57

rickkas7 opened this issue May 8, 2017 · 8 comments

Comments

@rickkas7
Copy link

rickkas7 commented May 8, 2017

My Carthage build fails when I use the spark-setup-ios version 0.7.0.

I have this in my Cartfile:

github "spark/spark-setup-ios" ~> 0.7.0

When I carthage update I get this:

*** Fetching spark-setup-ios
*** Fetching AFNetworking
*** Fetching onepassword-extension
*** Fetching spark-sdk-ios
*** Downloading AFNetworking.framework binary at "3.1.0"
*** Checking out AFNetworking at "3.1.0"
*** Checking out onepassword-extension at "d99f5d7a4c7328f8e3a8d1e7aff455d1072e0c19"
*** Checking out spark-sdk-ios at "0.6.1"
*** Checking out spark-setup-ios at "0.7.0"

The error is:

Controller.m:246:42: error: no visible @interface for 'SparkCloud' declares the selector 'createCustomer:password:productId:accountInfo:completion:'
            [[SparkCloud sharedInstance] createCustomer:email password:self.passwordTextField.text productId:[SparkSetupCustomization sharedInstance].productId accountInfo:nil completion:^(NSError *error) {
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/rickk/Documents/tempmon/11ios_objc_carthage/TempMon11/Carthage/Checkouts/spark-setup-ios/Classes/UI/SparkUserSignupViewController.m:286:42: error: no visible @interface for 'SparkCloud' declares the selector 'createUser:password:accountInfo:completion:'
            [[SparkCloud sharedInstance] createUser:email password:self.passwordTextField.text accountInfo:accountInfo completion:^(NSError *error) {
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.

I'm guessing that this is happening because it's pulling in spark-setup-ios 0.6.1, not the 0.7.0 version that has productID support.

The spark-setup-ios 0.7.0 works fine with CocoaPods.

@idokleinman
Copy link
Contributor

You mean it's pulling sdk 0.6.1...
I'll look into that. might be a simple fix
thanks for reporting

@idokleinman
Copy link
Contributor

Well, 0.6.X SDK does have the support for product endpoints (product id)..
Can you try setting your to contain:
github "spark/spark-sdk-ios" == 0.6.0

I suspect something with 0.6.1 (I was about to deprecate the SDK to switch to the renamed one particle-sdk-ios but have run into issues with the rename in the setup lib so I'll have to wait on that)

@rickkas7
Copy link
Author

rickkas7 commented May 9, 2017

I changed the Cartfile to be:

github "spark/spark-sdk-ios" == 0.6.0
github "spark/spark-setup-ios" ~> 0.7.0

and removed Cartfile.resolved and Carthage and the change appeared to be picked up:

*** Fetching spark-setup-ios
*** Fetching spark-sdk-ios
*** Fetching AFNetworking
*** Fetching onepassword-extension
*** Downloading AFNetworking.framework binary at "3.1.0"
*** Checking out AFNetworking at "3.1.0"
*** Checking out onepassword-extension at "d99f5d7a4c7328f8e3a8d1e7aff455d1072e0c19"
*** Checking out spark-sdk-ios at "0.6.0"
*** Checking out spark-setup-ios at "0.7.0"

However I'm still getting the same error:

/Users/rickk/Documents/11ios_objc_carthage/TempMon11/Carthage/Checkouts/spark-setup-ios/Classes/UI/SparkUserSignupViewController.m:246:42: error: no visible @interface for 'SparkCloud' declares the selector 'createCustomer:password:productId:accountInfo:completion:'
            [[SparkCloud sharedInstance] createCustomer:email password:self.passwordTextField.text productId:[SparkSetupCustomization sharedInstance].productId accountInfo:nil completion:^(NSError *error) {
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/rickk/Documents/11ios_objc_carthage/TempMon11/Carthage/Checkouts/spark-setup-ios/Classes/UI/SparkUserSignupViewController.m:286:42: error: no visible @interface for 'SparkCloud' declares the selector 'createUser:password:accountInfo:completion:'
            [[SparkCloud sharedInstance] createUser:email password:self.passwordTextField.text accountInfo:accountInfo completion:^(NSError *error) {
             ~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.

I am able to build spark-setup-ios 0.6.0 with the Cartfile:

github "spark/spark-setup-ios" == 0.6.0

@gitjoost
Copy link

gitjoost commented May 11, 2017

With cart file:

github "AFNetworking/AFNetworking" ~> 3.0.0
github "spark/spark-sdk-ios" == 0.6.0
github "spark/spark-setup-ios" ~> 0.7.0
github "AgileBits/onepassword-extension" "add-framework-support"

The build fails all together for me:

*** Fetching onepassword-extension
*** Fetching spark-setup-ios
*** Fetching spark-sdk-ios
*** Fetching AFNetworking
*** Downloading AFNetworking.framework binary at "3.1.0"
*** Checking out AFNetworking at "3.1.0"
*** Checking out onepassword-extension at "d99f5d7a4c7328f8e3a8d1e7aff455d1072e0c19"
*** Checking out spark-sdk-ios at "0.6.0"
*** Checking out spark-setup-ios at "0.7.0"
*** xcodebuild output can be found in /var/folders/9b/3s6sgnkj5hg3lcz3824_qlh00000gn/T/carthage-xcodebuild.lQUNYQ.log
*** Building scheme "AFNetworking iOS" in AFNetworking.xcworkspace
*** Building scheme "OnePasswordExtension" in 1Password Extension Demos.xcworkspace
*** Building scheme "ParticleSDK" in spark-sdk.xcworkspace
*** Building scheme "ParticleDeviceSetupLibrary" in SparkSetup.xcworkspace
Build Failed
	Task failed with exit code 65:
	/usr/bin/xcrun xcodebuild -workspace /Users/joost/Library/Mobile\ Documents/com~apple~CloudDocs/projects/XCode/particleAUTHtest\ copy/Carthage/Checkouts/spark-setup-ios/SparkSetup.xcworkspace -scheme ParticleDeviceSetupLibrary -configuration Release -derivedDataPath /Users/joost/Library/Caches/org.carthage.CarthageKit/DerivedData/spark-setup-ios/0.7.0 -sdk iphoneos ONLY_ACTIVE_ARCH=NO BITCODE_GENERATION_MODE=bitcode CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY= CARTHAGE=YES clean build

This usually indicates that project itself failed to compile. Please check the xcodebuild log for more details: /var/folders/9b/3s6sgnkj5hg3lcz3824_qlh00000gn/T/carthage-xcodebuild.lQUNYQ.log

Setting
github "spark/spark-setup-ios" == 0.6.0 builds the project but .productMode and .productId are unknown to SparkSetupCustomization.sharedInstance()

@peternoyes
Copy link

We are running into this as well. Is there any way to work around it?

@KemperVreden
Copy link

+1 Running into this as well ... Workarounds? Fixes?

@idokleinman
Copy link
Contributor

idokleinman commented Aug 3, 2017

Trying to tackle this right now, TBH not sure what's wrong there as the dependency of SDK 0.6.1 DOES in fact contain the aforementioned product-mode functions... no real idea why it does not compile.
if you guys have any ideas do let me know

@davidgs
Copy link

davidgs commented Aug 16, 2017

Having the same issue with the build.

[[SparkCloud sharedInstance] requestPasswordResetForCustomer:self.emailTextField.text productId:[SparkSetupCustomization sharedInstance].productId completion:passwordResetCallback];

Cartfile:
github "AFNetworking/AFNetworking" ~> 3.0.0 github "spark/spark-sdk-ios" == 0.6.0 github "spark/spark-setup-ios" ~> 0.7.0 github "AgileBits/onepassword-extension" "add-framework-support"

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

No branches or pull requests

6 participants