FastlaneCore::Helper::AppcenterHelper:Class (NameError) 的未定义局部变量或方法“所有者”

Posted

技术标签:

【中文标题】FastlaneCore::Helper::AppcenterHelper:Class (NameError) 的未定义局部变量或方法“所有者”【英文标题】:undefined local variable or method `owner' for FastlaneCore::Helper::AppcenterHelper:Class (NameError) 【发布时间】:2019-06-20 07:34:44 【问题描述】:

当我尝试使用 Fastlane 将 ios 应用程序分发到 appcenter 时,我收到类似 [!] undefined local variable or method `owner' for FastlaneCore::Helper::AppcenterHelper:Class (NameError) 的错误。

+------+------------------+-------------+ |快车道总结 | +--------+------------------+-------------+ |步骤 |行动 |时间(秒)| +--------+------------------+-------------+ | ??? |应用中心_上传 | 1 | +--------+------------------+-------------+

[11:49:06]:fastlane 完成错误

在 fastlane/fastlane 上寻找相关的 GitHub 问题...

➡️ appcenter上传错误 https://github.com/fastlane/fastlane/issues/14907 [关闭] 1 ???? 5 天前

????您可以 ⌘ + 双击链接直接在浏览器中打开它们。 /Users/capgemini/.gem/gems/fastlane-plugin-appcenter-1.0.1/lib/fastlane/plugin/appcenter/helper/appcenter_helper.rb:373:in get_app': [!] undefined local variable or methodowner' for FastlaneCore::Helper::AppcenterHelper :类(名称错误) 来自 /Users/capgemini/.gem/gems/fastlane-plugin-appcenter-1.0.1/lib/fastlane/plugin/appcenter/actions/appcenter_upload_action.rb:173:in get_or_create_app' from /Users/capgemini/.gem/gems/fastlane-plugin-appcenter-1.0.1/lib/fastlane/plugin/appcenter/actions/appcenter_upload_action.rb:201:inrun' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:256:in block (2 levels) in execute_action' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/actions/actions_helper.rb:50:inexecute_action' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:235:in block in execute_action' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:227:inchdir' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:227:in execute_action' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:157:intrigger_action_by_name' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/fast_file.rb:154:in method_missing' from Fastfile:51:inblock in parsing_binding' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/lane.rb:33:in call' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:49:inblock in execute' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:45:in chdir' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/runner.rb:45:inexecute' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/lane_manager.rb:56:in cruise_lane' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/command_line_handler.rb:36:inhandle' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/commands_generator.rb:108:in block (2 levels) in run' from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:incall' 来自 /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in run' from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:inrun_active_command' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in run!' from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:inrun!' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/commands_generator.rb:333:in run' from /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/commands_generator.rb:41:instart' 来自 /Users/capgemini/.gem/gems/fastlane-2.125.2/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in take_off' from /Users/capgemini/.gem/gems/fastlane-2.125.2/bin/fastlane:23:in' 来自 /Users/capgemini/.gem/bin/fastlane:22:in load' from /Users/capgemini/.gem/bin/fastlane:22:in'

【问题讨论】:

您的车道上似乎有一个红宝石错误,但根据您提供给我们的信息很难知道。你能用出错的车道更新它吗?同样在此链接上,您可以找到如何在 *** 中提问:***.com/help/how-to-ask 这是我在快速文件中编写的用于分发到 appcenter 通道的通道:distribute do appcenter_upload( api_token: "api-token", owner_name: "my id", app_name: "ConferenceDialer" , ipa: "./conf-out/conf-dialer.ipa", notify_testers: true ) 结束 请努力在这里发帖。编辑您的问题并在此处添加此代码。 【参考方案1】:

看看下面的link。

源代码中有一个错误隐藏了正确的错误。我也体验了一下得到了:[!] undefined local variable or methodowner' for FastlaneCore::Helper::AppcenterHelper:Class (NameError)

不管我改变了什么。我的“真正”错误是 app_name (并且 owner_name 很难弄清楚)是错误的。这个post 帮助了我。希望它可以帮助您解决真正的问题。

【讨论】:

以上是关于FastlaneCore::Helper::AppcenterHelper:Class (NameError) 的未定义局部变量或方法“所有者”的主要内容,如果未能解决你的问题,请参考以下文章