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

New install hangs at "iOS App Secret is already set in ios/APPNAME/AppCenter-Config.plist" #471

Closed
atrauzzi opened this issue Nov 24, 2018 · 27 comments
Labels

Comments

@atrauzzi
Copy link

As the title says, if I add app center to a new project, it just hangs with this as the last message.

iOS App Secret is already set in ios/APPNAME/AppCenter-Config.plist

Current versions of everything, running on Windows.

@iamclement
Copy link
Contributor

Hi @atrauzzi, we are looking into the issue. I'll keep you posted. Thanks

@iamclement iamclement added the bug label Nov 28, 2018
@iamclement
Copy link
Contributor

It should work an macOS though. If you have to use Windows you can still try renaming the ios folder from your project to something else so the script won't try to link iOS. But I suspect that there is something bigger going on.

@atrauzzi
Copy link
Author

I'm not going to employ a workaround for one SDK.

I think your process just needs detect that it's not on macOS and not attempt that step.

Can I just say this is like the third MS/Azure project that has resorted to suggesting a kludgey workaround as a solution? You guys need to outlaw workarounds from your culture.

@guperrot
Copy link
Member

guperrot commented Nov 28, 2018

We are not suggesting work arounds as permanent solutions but as temporary way to unblock SDK users until we have a SDK fix and a new SDK release, which will take some time. If the issue is labeled bug, then it's usually part of the next monthly release and this bug is on our internal backlog.

@guperrot
Copy link
Member

Just to clarify: you only have the Android application and trying to develop it from Windows? Do you use the iOS app?

@atrauzzi
Copy link
Author

I will be once I'm done getting the Android configuration figured out.

@guperrot
Copy link
Member

But react-native is not supported on Windows for iOS development, you are planning to use a Mac later on?

@atrauzzi
Copy link
Author

atrauzzi commented Nov 29, 2018

Obviously. Why would you assume I wasn't going to?

@guperrot
Copy link
Member

I am not assuming anything, just gathering information to scope the fix, as you could have been in this case: https://stackoverflow.com/a/43461466/598520 (but we don't support pure js expo as we have native code).

So the scope is just to make react-native link works on Android from Windows.

@atrauzzi
Copy link
Author

Yupyup. No desire to have iOS building on Windows. I'll take care of that from macOS when the time comes.

@bmourat
Copy link
Contributor

bmourat commented Dec 2, 2018

Does it hangs the terminal or it looks like it is waiting for input? I've just checked in my Windows machine, everything works fine, but sometimes it stops at similar step but for android:

Android App Secret is already set in android/app/src/main/assets/appcenter-config.json

But once i press enter the linking process continues, does this sound like your case or your linking process is completely stuck?

@atrauzzi
Copy link
Author

atrauzzi commented Dec 2, 2018

Totally stuck.

@bmourat
Copy link
Contributor

bmourat commented Dec 3, 2018

You said that you are using current versions of everything, running on Windows. This means your Node version is 11, correct?

@JayUnt
Copy link

JayUnt commented Dec 4, 2018

I had the same ios issue. When i moved my ios folder out of the project, it now gets stuck after i answer "For the Android app, should user tracking be enabled automatically?" It gets stuck no matter which option I answer with.

@bmourat
Copy link
Contributor

bmourat commented Dec 5, 2018

@JayUnt
Could you please provide your versions of:

  • Node
  • npm
  • react-native
  • react-native-cli

@JayUnt
Copy link

JayUnt commented Dec 6, 2018

@bmourat

Node: 11.3.0
npm: 6.1.0
react-native: 0.57.7
react-native-cli: 2.0.1

Thanks

@guperrot
Copy link
Member

1.11.0 should no longer hangs on Windows.

It mightdisplay an error for Cocopods not installed but will proceed with all the steps instead of hanging.

@jlkalberer
Copy link

jlkalberer commented Jan 5, 2019

This still hangs on 1.11.0

I had the app secret already set for codepush if that makes a difference.


I'm trying to run this on my Windows machine. I normally do my development here and just want to build/test for Android.

I tried deleting the ~/ios folder but it freezes on the next step where it asks:

? For the Android app, should user tracking be enabled automatically? Enable Automatically

@jlkalberer
Copy link

I debugged this a bit further and found that the script is freezing on this line - https://github.com/SBoudrias/Inquirer.js/blob/master/packages/inquirer/lib/ui/baseUI.js#L15

Basically what happens is the second time that line is called it freezes. So the first prompt always works but the second one breaks. I don't know enough about stdin to figure out what's going on beyond that.

It looks like it may something to do with this - nodejs/node#17495


I found that if I commented this line that things would "work" a bit better. There are memory leaks but it gets past the second prompt - https://github.com/SBoudrias/Inquirer.js/blob/master/packages/inquirer/lib/ui/baseUI.js#L57

@guperrot guperrot reopened this Jan 10, 2019
@MatkovIvan
Copy link
Contributor

Hi @jlkalberer,

I cannot reproduce it with the new version of the SDK. Could you please share what versions of node/npm/rn do you use? Does it happen only in your project or do you able to reproduce it on empty one?

@jlkalberer
Copy link

I think I'm using the latest version of the SDK - https://github.com/Brewskey/Brewskey.App/blob/v2/package.json#L22-L24

I'm using yarn for my project instead of npm if that matters.

Windows 10 - Version 1803 (OS Build 17134.523)
yarn - 1.9.4
npm - 6.0.1
node - v10.13.0

I'll create an empty project over the weekend to test

@jlkalberer
Copy link

Ok, I tried it with a fresh product and ran the following commands

react-native init
yarn add appcenter appcenter-analytics appcenter-crashes --exact
react-native link

The process froze after this output

rnpm-install info Linking appcenter ios dependency
rnpm-install info Platform 'ios' module appcenter has been successfully linked
rnpm-install info Linking appcenter android dependency
rnpm-install info Platform 'android' module appcenter has been successfully linked
Configuring AppCenter Analytics for Android
? What secret does your Android app use? [None]
App Secret for Android written to android\app\src\main\assets\appcenter-config.json
Configuring AppCenter for iOS
Adding AppCenter configuration file...
? What secret does your iOS app use? [None]
App Secret for iOS written to ios\test\AppCenter-Config.plist
Patching file ios/test/AppDelegate.m
Added code to initialize iOS AppCenter SDK in ios/test/AppDelegate.m
Installing Cocoapods dependencies...
Could not configure AppCenter for iOS. Error Reason - Could not find "pod" command. Is CocoaPods installed?
rnpm-install info Linking appcenter-analytics ios dependency
rnpm-install info Platform 'ios' module appcenter-analytics has been successfully linked
rnpm-install info Linking appcenter-analytics android dependency
rnpm-install info Platform 'android' module appcenter-analytics has been successfully linked
Configuring AppCenter Analytics for Android
Android App Secret is already set in android/app/src/main/assets/appcenter-config.json
? For the Android app, should user tracking be enabled automatically? Enable Automatically
Configuring AppCenter Analytics for iOS
Adding AppCenter configuration file...
iOS App Secret is already set in ios/test/AppCenter-Config.plist

@bmourat
Copy link
Contributor

bmourat commented Jan 14, 2019

Hi @jlkalberer
The problem here seems to be the compatibility of the inquirer plugin with different node versions. For example with node version 8.15.0 it works as expected, but with last node version 11.6.0 it freezes. So this is not the bug of the sdk but inquirer plugin compatibility issue. What node version are you using?

@jlkalberer
Copy link

I'm not at my computer now but I believe it's the latest version of Node so this totally makes sense.

Is there an issue open in node for this? I'd guess that there could be a really simple repo like calling the createInterface function two times.


In the meantime, I think I'm OK as I can just use my Mac for linking or just target an older node version.

@iamclement
Copy link
Contributor

Closing the issue since it's a compatibility issue of the inquirer plugin.

@atrauzzi
Copy link
Author

Will you guys report it upstream and link to this issue?

@michaelmarriott
Copy link

michaelmarriott commented Feb 6, 2019

Getting the exact same issue.

Node: 10.4.2
npm: 6.1.0
react-native: 0.57.1
react-native-cli: 2.0.1

Found resolution:

as per link above from [jlkalberer]

feathers-plus/generator-feathers-plus#103
[eddyystop]

  • Remove node_modules/inquirer
  • npm i -d inquirer

fixed my problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants