Skip to content
This repository has been archived by the owner on Nov 19, 2018. It is now read-only.

Company Name support #54

Closed
robwithhair opened this issue Jul 20, 2015 · 18 comments
Closed

Company Name support #54

robwithhair opened this issue Jul 20, 2015 · 18 comments
Labels

Comments

@robwithhair
Copy link

Fastlane seems to fail if company name has not been set. Maybe produce could have a company name set in the fast file and if this field is present then it gets filled in?

screen shot 2015-07-20 at 11 36 37

[37m[11:22:29]: �[0m�[32m---------------------�[0m
�[37m[11:22:29]: �[0m�[32m--- �[0m�[32mStep: produce�[0m�[32m ---�[0m
�[37m[11:22:29]: �[0m�[32m---------------------�[0m
�[37m[11:22:32]: �[0m�[32mApp 'Biz Connexions' already exists, nothing to do on the Dev Center�[0m
�[37m[11:22:33]: �[0m�[32mCreating new app 'Biz Connexions' on iTunes Connect�[0m
�[37m[11:22:34]: �[0m�[33mVariable Dump:�[0m
�[37m[11:22:34]: �[0m{:ENVIRONMENT=>nil, :PLATFORM_NAME=>nil, :LANE_NAME=>"deploy", :BUILD_NUMBER=>0}
�[1m�[31m[11:22:34]: �[0m�[0mYou must provide a company name to use on the App Store. You must choose a primary language. Your app information could not be saved. The information for at least one field is missing or is in the wrong format.
�[1m�[31m[11:22:34]: �[0m�[0m�[31mfastlane finished with errors�[0m
/Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/tunes_client.rb:106:in `handle_itc_response': You must provide a company name to use on the App Store. You must choose a primary language. Your app information could not be saved. The information for at least one field is missing or is in the wrong format. (RuntimeError)
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/tunes_client.rb:155:in `create_application!'
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/application.rb:89:in `create!'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/itunes_connect.rb:25:in `create_new_app'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/itunes_connect.rb:12:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/manager.rb:6:in `start_producing'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:20:in `block in run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:18:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:18:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:142:in `block (2 levels) in execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/actions_helper.rb:62:in `execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:128:in `block in execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:127:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:127:in `execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/fast_file.rb:108:in `method_missing'
    from (eval):36:in `block (2 levels) in parse'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane.rb:29:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane.rb:29:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:50:in `block in execute'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:44:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:44:in `execute'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane_manager.rb:36:in `cruise_lane'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/command_line_handler.rb:31:in `handle'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:35:in `block (2 levels) in run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:153:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/runner.rb:428:in `run_active_command'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/runner.rb:68:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/delegates.rb:15:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:124:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:130:in `<top (required)>'
    from /usr/bin/fastlane:23:in `load'
    from /usr/bin/fastlane:23:in `<main>'
Build step 'Execute shell' marked build as failure
Build did not succeed and the project is configured to only push after a successful build, so no pushing will occur.
Finished: FAILURE
@buscarini
Copy link

You just saved my life, because I was getting that error and I hadn't been able to find why this happened.

I think this shouldn't be done automatically, as it can't be changed later (which makes no sense, but anyway). But at least there should be a better error message that states that you should go to iTunes Connect and manually add the company name there.

@KrauseFx
Copy link
Contributor

@robwithhair when is a company name not set? How do I get this alert? Or is it only shown when the first app is being created on iTunes Connect?

@robwithhair
Copy link
Author

@KrauseFx I think this may be something which only occurs once for new developer accounts. Yes, I believe it is only when creating the first app.

@robwithhair
Copy link
Author

@KrauseFx I don't know if there is another way to set or update this field.

@robwithhair
Copy link
Author

@KrauseFx I also noticed there seems to be another issue which may be related to new accounts. Requiring the need to specify a primary language.

�[37m[13:55:54]: �[0m�[32m---------------------�[0m
�[37m[13:55:54]: �[0m�[32m--- �[0m�[32mStep: produce�[0m�[32m ---�[0m
�[37m[13:55:54]: �[0m�[32m---------------------�[0m
�[37m[13:55:58]: �[0m�[32mApp 'Natural Flooring Solutions' already exists, nothing to do on the Dev Center�[0m
�[37m[13:56:02]: �[0m�[32mCreating new app 'Natural Flooring Solutions' on iTunes Connect�[0m
�[37m[13:56:03]: �[0m�[33mVariable Dump:�[0m
�[37m[13:56:03]: �[0m{:ENVIRONMENT=>nil, :PLATFORM_NAME=>nil, :LANE_NAME=>"deploy", :BUILD_NUMBER=>0}
�[1m�[31m[13:56:03]: �[0m�[0mYou must choose a primary language. You must choose a primary language.
�[1m�[31m[13:56:03]: �[0m�[0m�[31mfastlane finished with errors�[0m
/Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/tunes_client.rb:106:in `handle_itc_response': You must choose a primary language. You must choose a primary language. (RuntimeError)
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/tunes_client.rb:155:in `create_application!'
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.1.2/lib/spaceship/tunes/application.rb:89:in `create!'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/itunes_connect.rb:25:in `create_new_app'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/itunes_connect.rb:12:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/produce-0.4.1/lib/produce/manager.rb:6:in `start_producing'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:20:in `block in run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:18:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/produce.rb:18:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:142:in `block (2 levels) in execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/actions/actions_helper.rb:62:in `execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:128:in `block in execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:127:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:127:in `execute_action'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/fast_file.rb:108:in `method_missing'
    from (eval):36:in `block (2 levels) in parse'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane.rb:29:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane.rb:29:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:50:in `block in execute'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:44:in `chdir'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/runner.rb:44:in `execute'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/lane_manager.rb:36:in `cruise_lane'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/lib/fastlane/command_line_handler.rb:31:in `handle'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:35:in `block (2 levels) in run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/command.rb:153:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/runner.rb:428:in `run_active_command'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/runner.rb:68:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.4/lib/commander/delegates.rb:15:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:124:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/fastlane-1.11.0/bin/fastlane:130:in `<top (required)>'
    from /usr/bin/fastlane:23:in `load'
    from /usr/bin/fastlane:23:in `<main>'
Build step 'Execute shell' marked build as failure
Build did not succeed and the project is configured to only push after a successful build, so no pushing will occur.
Finished: FAILURE

@buscarini
Copy link

@KrauseFx Yes, this happens with new accounts. When you manually add the first app there is an additional field at the top requesting the company name (and stating that it can't be changed later)

@KrauseFx
Copy link
Contributor

@buscarini @robwithhair If you help me, I can implement this, as I don't have access to an empty Apple account.

Please open the page and right click Inspect element the Company Name and share this information with me:
screenshot 2015-07-20 15 37 49

@robwithhair
Copy link
Author

@appinstbrandon can you let me know when you get one of these again. I'll let @KrauseFx know the details so we can get this fixed.

@robwithhair
Copy link
Author

@KrauseFx We'll try and capture the info you need next time anyway. On this occasion we worked around the problem so we weren't able to get a grab of the selector.

@buscarini
Copy link

@KrauseFx Same here, sorry but I already added the company name manually. Not sure if I'll need to use a new account in a short time, but if I do I will check it. In any case for now I would suggest just adding an error message for the user to tell him to go to the web and add this parameter manually (maybe you could ask for help there so the first user that needs it can inspect the website and send this info to you)

@robwithhair
Copy link
Author

OK, we've had a few of these. Please find attached a screenshot which I hope will have everything you need.

screen_shot_2015-07-30_at_11 22 27

@KrauseFx
Copy link
Contributor

@robwithhair Thank you! The latest version spaceship already support the company name. I haven't yet updated produce.

Could you try the following:

sudo gem update spaceship
require 'spaceship'
Spaceship::Tunes.login('user', 'password')
Spaceship::Tunes::Application.create!(name: "App Name",
                                              version: "1.0",
                                              sku: "123",
                                              bundle_id: "com.krausefx.app",
                                              company_name: "Company Name")

And replace the values with the actual values. This will create the application already and should fill out the company name as well. This feature was added by @lacostej with fastlane-old/spaceship#70 👍

@robwithhair
Copy link
Author

Hi @KrauseFx,

Where do I put this spaceship code? In my Fastfile? What will happen if the app already exists or the company name is already set?

@robwithhair
Copy link
Author

Unfortunately the support team already created this app manually. Can you advise as to the above and we'll test it next time?

@KrauseFx
Copy link
Contributor

I pushed a new version of produce, so you can now pass the value directly 👍

@robwithhair
Copy link
Author

Awesome, thanks! I'll try that out when we get a dev account without a name.

@indyfromoz
Copy link

I installed produce 1.0.0, version check -

indrajit@poseidon Projects $ produce --version
produce 1.0.0
indrajit@poseidon Projects $ 

Next, I tried to create an app with an empty developer account. All went well till produce tried to create an app in iTC -

[06:49:27]: To not be asked about this value, you can specify it using 'app_version'
Initial version number (e.g. '1.0'): 1.0
/Library/Ruby/Gems/2.0.0/gems/spaceship-0.13.0/lib/spaceship/tunes/tunes_client.rb:148:in `handle_itc_response': You must provide a company name to use on the App Store. You must provide a company name to use on the App Store. (Spaceship::TunesClient::ITunesConnectError)
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.13.0/lib/spaceship/tunes/tunes_client.rb:222:in `create_application!'
    from /Library/Ruby/Gems/2.0.0/gems/spaceship-0.13.0/lib/spaceship/tunes/application.rb:86:in `create!'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/lib/produce/itunes_connect.rb:24:in `create_new_app'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/lib/produce/itunes_connect.rb:11:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/lib/produce/manager.rb:6:in `start_producing'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/bin/produce:33:in `block (2 levels) in run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in `call'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:153:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in `run_active_command'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/runner.rb:68:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in `run!'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/bin/produce:123:in `run'
    from /Library/Ruby/Gems/2.0.0/gems/produce-1.0.0/bin/produce:129:in `<top (required)>'
    from /usr/bin/produce:23:in `load'
    from /usr/bin/produce:23:in `<main>'

I logged in to the iTC portal using Safari, created the app. I tired produce with a new app and this time it worked like a charm!

@KrauseFx - Thanks so much for this great set of tools! You make iOS Development so much easier!!

@fastlane-bot
Copy link

This issue was migrated to fastlane/fastlane#1794. Please post all further comments there.

fastlane is now a mono repo, you can read more about the change in our blog post. All tools are now available in the fastlane main repo 🚀

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

No branches or pull requests

5 participants