fastlane / fastlane

🚀 The easiest way to automate building and releasing your iOS and Android apps

Home Page:https://fastlane.tools

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

supply after gradle bundleRelease can't find the aab

jab11 opened this issue · comments

New Issue Checklist

Issue Description

When an android project has gradle buildDir specified globally, fastlane supply fails after build.
The same process succeeds when gradle uses the default buildDir.
Fastfile is based on examples in documentation.

Command executed

fastlane deploy

Complete output when running fastlane, including the stack trace and command used
$ fastlane deploy
[✔] 🚀
[02:09:56]: fastlane detected a Gemfile in the current directory
[02:09:56]: However, it seems like you didn't use `bundle exec`
[02:09:56]: To launch fastlane faster, please use
[02:09:56]:
[02:09:56]: $ bundle exec fastlane deploy
[02:09:56]:
[02:09:56]: Get started using a Gemfile for fastlane https://docs.fastlane.tools/getting-started/ios/setup/#use-a-gemfile
[02:09:59]: ------------------------------
[02:09:59]: --- Step: default_platform ---
[02:09:59]: ------------------------------
[02:09:59]: Driving the lane 'android deploy' 🚀
[02:09:59]: --------------------------------------
[02:09:59]: --- Step: bundleintegrationRelease ---
[02:09:59]: --------------------------------------
[02:09:59]: $ gradlew bundleintegrationRelease -p .
[02:10:00]: ▸ > Configure project :app
[02:10:00]: ▸ Warning: The 'kotlin-android-extensions' Gradle plugin is deprecated. Please use this migration guide (https://goo.gle/kotlin-android-extensions-deprecation) to start working with View Binding (https://developer.android.com/topic/libraries/view-binding) and the 'kotlin-parcelize' plugin.
[02:10:00]: ▸ WARNING:API 'BaseVariant.getApplicationIdTextResource' is obsolete and has been replaced with 'VariantProperties.applicationId'.
[02:10:00]: ▸ It will be removed in version 7.0 of the Android Gradle plugin.
[02:10:00]: ▸ For more information, see TBD.
[02:10:00]: ▸ To determine what is calling BaseVariant.getApplicationIdTextResource, use -Pandroid.debug.obsoleteApi=true on the command line to display more information.
...
[02:10:00]: ▸ BUILD SUCCESSFUL in 1s
[02:10:00]: ▸ 88 actionable tasks: 1 executed, 87 up-to-date
[02:10:01]: Couldn't find any new signed apk files...
[02:10:01]: ----------------------------------
[02:10:01]: --- Step: upload_to_play_store ---
[02:10:01]: ----------------------------------

+------------------------------------+----------------------------------------------------------+
| Summary for supply 2.205.2 |
+------------------------------------+----------------------------------------------------------+
| skip_upload_metadata | true |
| skip_upload_images | true |
| skip_upload_screenshots | true |
| track | internal |
| release_status | draft |
| package_name | ### |
| metadata_path | ./fastlane/metadata/android |
| json_key | fastlane/pc-api.json |
| skip_upload_apk | false |
| skip_upload_aab | false |
| skip_upload_changelogs | false |
| track_promote_release_status | completed |
| validate_only | false |
| check_superseded_tracks | false |
| timeout | 300 |
| deactivate_on_promote | true |
| changes_not_sent_for_review | false |
| rescue_changes_not_sent_for_review | true |
| ack_bundle_installation_warning | false |
+------------------------------------+----------------------------------------------------------+

[02:10:02]: Preparing to upload for language 'en-US'...
+-------------------------------------+----------------+
| Lane Context |
+-------------------------------------+----------------+
| DEFAULT_PLATFORM | android |
| PLATFORM_NAME | android |
gradle.projectsLoaded {
| LANE_NAME | android deploy |
| GRADLE_BUILD_TYPE | Release |
| GRADLE_FLAVOR | integration |
| GRADLE_ALL_APK_OUTPUT_PATHS | [] |
| GRADLE_ALL_AAB_OUTPUT_PATHS | [] |
| GRADLE_ALL_OUTPUT_JSON_OUTPUT_PATHS | [] |
| GRADLE_ALL_MAPPING_TXT_OUTPUT_PATHS | [] |
+-------------------------------------+----------------+
[02:10:03]: Cannot find changelog because no version code given - please specify :version_code

+------+--------------------------+-------------+
| fastlane summary |
+------+--------------------------+-------------+
| Step | Action | Time (in s) |
+------+--------------------------+-------------+
| 1 | default_platform | 0 |
| 2 | bundleintegrationRelease | 1 |
| 💥 | upload_to_play_store | 1 |
+------+--------------------------+-------------+

[02:10:03]: fastlane finished with errors

[!] Cannot find changelog because no version code given - please specify :version_code

Environment

🚫 fastlane environment 🚫

Stack

Key Value
OS 12.4
Ruby 2.7.0
Bundler? false
Git git version 2.30.1
Installation Source ~/.rbenv/versions/2.7.0/bin/fastlane
Host macOS 12.4 (21F79)
Ruby Lib Dir ~/.rbenv/versions/2.7.0/lib
OpenSSL Version OpenSSL 1.1.1d 10 Sep 2019
Is contained false
Is homebrew false
Is installed via Fabric.app false
Xcode Path /Applications/Xcode.app/Contents/Developer/
Xcode Version 13.3.1
Swift Version 5.6

System Locale

Error
No Locale with UTF8 found 🚫

fastlane files:

`./fastlane/Fastfile`
# This file contains the fastlane.tools configuration
# You can find the documentation at https://docs.fastlane.tools
#
# For a list of all available actions, check out
#
#     https://docs.fastlane.tools/actions
#
# For a list of all available plugins, check out
#
#     https://docs.fastlane.tools/plugins/available-plugins
#

# Uncomment the line if you want fastlane to automatically update itself
# update_fastlane

default_platform(:android)

platform :android do
  desc "Runs all the tests"
  lane :test do
    gradle(task: "test")
  end

  desc "Submit a new Beta Build to Crashlytics Beta"
  lane :beta do
    gradle(task: "clean assembleRelease")
    crashlytics
  
    # sh "your_script.sh"
    # You can also use other beta testing services here
  end

  desc "Deploy a new version to the Google Play"
  lane :deploy do
    gradle(
            task: "bundle",
            flavor: "integration",
            build_type: "Release"
    )
    upload_to_play_store(
           skip_upload_metadata: true,
          skip_upload_images: true,
          skip_upload_screenshots: true,
          track: "internal",
	  release_status: 'draft'
    )
  end
end
`./fastlane/Appfile`
json_key_file("fastlane/pc-api-5830702901187969167-50-fb77eb5dc5ce.json") # Path to the json secret file - Follow https://docs.fastlane.tools/actions/supply/#setup to get one
package_name("de.doget.app") # e.g. com.krausefx.app

fastlane gems

Gem Version Update-Status
fastlane 2.205.2 ✅ Up-To-Date

Loaded fastlane plugins:

No plugins Loaded

Loaded gems
Gem Version
did_you_mean 1.4.0
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 2.0.0
unicode-display_width 1.7.0
terminal-table 1.8.0
plist 3.5.0
CFPropertyList 3.0.2
public_suffix 4.0.5
addressable 2.8.0
multipart-post 2.0.0
word_wrap 1.0.0
optparse 0.1.1
tty-screen 0.8.1
tty-cursor 0.7.1
tty-spinner 0.9.3
artifactory 3.0.15
babosa 1.0.3
colored 1.2
highline 2.0.3
commander 4.6.0
excon 0.76.0
faraday 1.0.1
unf_ext 0.0.7.7
unf 0.1.4
domain_name 0.5.20190701
http-cookie 1.0.3
faraday-cookie_jar 0.0.6
faraday_middleware 1.0.0
fastimage 2.2.0
gh_inspector 1.1.3
json 2.3.0
mini_magick 4.10.1
naturally 2.2.0
rubyzip 2.3.0
security 0.1.3
xcpretty-travis-formatter 1.0.0
dotenv 2.7.6
bundler 2.1.2
simctl 1.6.8
jwt 2.2.1
uber 0.1.0
declarative 0.0.20
declarative-option 0.1.0
representable 3.0.4
retriable 3.1.2
mini_mime 1.0.2
memoist 0.16.2
multi_json 1.15.0
os 1.1.1
signet 0.16.0
googleauth 1.1.0
httpclient 2.8.3
webrick 1.6.0
google-apis-core 0.4.1
google-apis-playcustomapp_v1 0.7.0
google-apis-androidpublisher_v3 0.15.0
google-cloud-env 1.3.3
google-cloud-errors 1.0.1
google-cloud-core 1.6.0
google-apis-iamcredentials_v1 0.10.0
google-apis-storage_v1 0.11.0
rake 13.0.1
digest-crc 0.6.1
google-cloud-storage 1.36.0
emoji_regex 3.0.0
jmespath 1.4.0
aws-partitions 1.350.0
aws-eventstream 1.1.0
aws-sigv4 1.2.1
aws-sdk-core 3.104.3
aws-sdk-kms 1.36.0
aws-sdk-s3 1.75.0
uri 0.10.0
rexml 3.2.5
nanaimo 0.3.0
colored2 3.1.2
claide 1.0.3
atomos 0.1.3
xcodeproj 1.21.0
forwardable 1.3.1
logger 1.4.2
cgi 0.1.0
timeout 0.1.0
stringio 0.1.0
ipaddr 1.2.2
openssl 2.1.2
ostruct 0.2.0
strscan 1.0.3
date 3.0.0
io-console 0.5.3
delegate 0.1.0
fileutils 1.4.1
zlib 1.1.0
singleton 0.1.0
open3 0.1.0
yaml 0.1.0
psych 3.1.0
mutex_m 0.1.0

generated on: 2022-05-18

Fastfile:

default_platform(:android)

platform :android do
  desc "Runs all the tests"
  lane :test do
    gradle(task: "test")
  end

  desc "Submit a new Beta Build to Crashlytics Beta"
  lane :beta do
    gradle(task: "clean assembleRelease")
    crashlytics
  
    # sh "your_script.sh"
    # You can also use other beta testing services here
  end

  desc "Deploy a new version to the Google Play"
  lane :deploy do
    gradle(
            task: "bundle",
            flavor: "integration",
            build_type: "Release"
    )
    upload_to_play_store(
           skip_upload_metadata: true,
          skip_upload_images: true,
          skip_upload_screenshots: true,
          track: "internal",
	  release_status: 'draft'
    )
  end
end

init.gradle

gradle.projectsLoaded {
    rootProject.allprojects {
        buildDir = "/Users/batora/.gradle/build/${rootProject.name}/${project.name}"
    }
}

I am also facing exact same issue. Is your issue resloved? any recommendation how to solve this issue.? Can any one please help?
PCC CNA Login

the only solution seems to be to use the default buildDir

ezoic increase your site revenue