侧面Bitrise步骤失败,因为它找不到结果目录

时间:2019-08-07 08:20:59

标签: android go bitrise

我正在尝试使“侧翼位上升”步骤起作用,但是在运行所有错误为Failed to export artifacts, error: open ./results: no such file or directory的测试之后,它最终还是失败了。

我已尝试在该步骤(位于here中)研究Go代码,以尝试了解应该在哪里创建目录,但是我无法弄清楚。

如果我在本地运行Flank,则一切运行正常。

这是该步骤的完整输出:

------------------------------------------------------------------------------+

| (4) flank@0.1.0                                                              |
+------------------------------------------------------------------------------+
| id: flank                                                                    |
| version: 0.1.0                                                               |
| collection: https://github.com/bitrise-io/bitrise-steplib.git                |
| toolkit: go                                                                  |
| time: 2019-08-07T01:57:04Z                                                   |
+------------------------------------------------------------------------------+
|                                                                              |
Config:
- ServiceAccountJSON: *****
- ConfigPath: android/flank.yml
- Version: latest
- CommandFlags: 
Downloading binary
- Done
Running test
- Detected platform: android
$ java "-jar" "/tmp/flank-bin214923599/flank.jar" "android" "run" "-c" "android/flank.yml"
AndroidArgs
    gcloud:
      results-bucket: test-lab-c3at6r97r91bu-jwmcsninvtajk
      results-dir: null
      record-video: true
      timeout: 15m
      async: false
      results-history-name: null
      # Android gcloud
      app: /bitrise/deploy/app-debug.apk
      test: /bitrise/deploy/app-debug-androidTest.apk
      auto-google-login: true
      use-orchestrator: true
      directories-to-pull:
      performance-metrics: true
      test-runner-class: null
      test-targets:
      device:
        - model: Nexus5X
          version: 26
          locale: en
          orientation: portrait
      flaky-test-attempts: 0
    flank:
      max-test-shards: 4
      shard-time: -1
      repeat-tests: 1
      smart-flank-gcs-path: 
      smart-flank-disable-upload: false
      files-to-download:
      test-targets-always-run:
      disable-sharding: false
      project: android-app-248901
      local-result-dir: flank
      # Android Flank Yml
      additional-app-test-apks:
RunTests
  Uploading app-debug-androidTest.apk .  Uploading app-debug.apk .
  Smart Flank cache hit: 0% (0 / 33)
  Shard times: 80s, 80s, 80s, 90s
  33 tests / 4 shards
  4 matrix ids created in 0m 3s
  https://console.developers.google.com/storage/browser/test-lab-c3at6r97r91bu-jwmcsninvtajk/2019-08-07_01-57-10.546000_hAvO/
PollMatrices
  0m  0s matrix-q7z6s7e7ji13a Nexus5X-26 VALIDATING
  0m 15s matrix-q7z6s7e7ji13a Nexus5X-26 PENDING
  0m 45s matrix-q7z6s7e7ji13a Nexus5X-26 Starting attempt 1.
  0m 45s matrix-q7z6s7e7ji13a Nexus5X-26 RUNNING
  1m 45s matrix-q7z6s7e7ji13a Nexus5X-26 Started logcat recording.
  1m 45s matrix-q7z6s7e7ji13a Nexus5X-26 Preparing device.
  2m 15s matrix-q7z6s7e7ji13a Nexus5X-26 Logging in to Google account on device.
  2m 15s matrix-q7z6s7e7ji13a Nexus5X-26 Installing apps.
  2m 30s matrix-q7z6s7e7ji13a Nexus5X-26 Retrieving Pre-Test Package Stats information from the device.
  2m 30s matrix-q7z6s7e7ji13a Nexus5X-26 Retrieving Performance Environment information from the device.
  2m 30s matrix-q7z6s7e7ji13a Nexus5X-26 Started crash detection.
  2m 30s matrix-q7z6s7e7ji13a Nexus5X-26 Started crash monitoring.
  2m 30s matrix-q7z6s7e7ji13a Nexus5X-26 Started performance monitoring.
  2m 45s matrix-q7z6s7e7ji13a Nexus5X-26 Started video recording.
  2m 45s matrix-q7z6s7e7ji13a Nexus5X-26 Starting instrumentation test.
  6m 31s matrix-q7z6s7e7ji13a Nexus5X-26 Completed instrumentation test.
  6m 46s matrix-q7z6s7e7ji13a Nexus5X-26 Stopped performance monitoring.
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Stopped crash monitoring.
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Retrieving Post-test Package Stats information from the device.
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Stopped logcat recording.
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Logging out of Google account on device.
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Done. Test time = 239 (secs)
  7m 16s matrix-q7z6s7e7ji13a Nexus5X-26 Starting results processing. Attempt: 1
  7m 31s matrix-q7z6s7e7ji13a Nexus5X-26 Completed results processing. Time taken = 12 (secs)
  7m 31s matrix-q7z6s7e7ji13a Nexus5X-26 FINISHED
  7m 31s matrix-q7z6s7e7ji13a FINISHED
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Starting attempt 1.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Started logcat recording.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Preparing device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Logging in to Google account on device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Installing apps.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Retrieving Pre-Test Package Stats information from the device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Retrieving Performance Environment information from the device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Started crash detection.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Started crash monitoring.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Started performance monitoring.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Started video recording.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Starting instrumentation test.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Completed instrumentation test.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Stopped performance monitoring.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Stopped crash monitoring.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Stopped logcat recording.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Retrieving Post-test Package Stats information from the device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Logging out of Google account on device.
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Done. Test time = 249 (secs)
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Starting results processing. Attempt: 1
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 Completed results processing. Time taken = 11 (secs)
  7m 32s matrix-2ay0yj5na36d8 Nexus5X-26 FINISHED
  7m 32s matrix-2ay0yj5na36d8 FINISHED
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Starting attempt 1.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Started logcat recording.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Preparing device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Logging in to Google account on device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Installing apps.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Retrieving Pre-Test Package Stats information from the device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Retrieving Performance Environment information from the device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Started crash detection.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Started crash monitoring.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Started performance monitoring.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Started video recording.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Starting instrumentation test.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Completed instrumentation test.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Stopped performance monitoring.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Stopped crash monitoring.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Stopped logcat recording.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Retrieving Post-test Package Stats information from the device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Logging out of Google account on device.
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Done. Test time = 248 (secs)
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 Starting results processing. Attempt: 1
  7m 32s matrix-83si0hz9imz4a Nexus5X-26 RUNNING
  7m 47s matrix-83si0hz9imz4a Nexus5X-26 Completed results processing. Time taken = 12 (secs)
  7m 47s matrix-83si0hz9imz4a Nexus5X-26 FINISHED
  7m 47s matrix-83si0hz9imz4a FINISHED
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Starting attempt 1.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Started logcat recording.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Preparing device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Logging in to Google account on device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Installing apps.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Retrieving Pre-Test Package Stats information from the device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Retrieving Performance Environment information from the device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Started crash detection.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Started performance monitoring.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Started crash monitoring.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Started video recording.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Starting instrumentation test.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Completed instrumentation test.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Stopped performance monitoring.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Stopped crash monitoring.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Retrieving Post-test Package Stats information from the device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Stopped logcat recording.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Logging out of Google account on device.
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Done. Test time = 255 (secs)
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 Starting results processing. Attempt: 1
  7m 47s matrix-2cwsozznj0yn3 Nexus5X-26 RUNNING
  9m 17s matrix-2cwsozznj0yn3 Nexus5X-26 Completed results processing. Time taken = 105 (secs)
  9m 17s matrix-2cwsozznj0yn3 Nexus5X-26 FINISHED
  9m 17s matrix-2cwsozznj0yn3 FINISHED
FetchArtifacts
  ....
  Updating matrix file
CostReport
  Virtual devices
    $0.32 for 19m
MatrixResultsReport
  4 / 4 (100.00%)
Exporting artifacts
Failed to export artifacts, error: open ./results: no such file or directory
|                                                                              |
+---+---------------------------------------------------------------+----------+
| x | flank@0.1.0 (exit code: 1)                                    | 570 sec  |
+---+---------------------------------------------------------------+----------+
| Issue tracker: https://github.com/bitrise-steplib/bitrise-step-flank/issues  |
| Source: https://github.com/bitrise-steplib/bitrise-step-flank                |
+---+---------------------------------------------------------------+----------+

1 个答案:

答案 0 :(得分:1)

啊,找到了。原来,您需要将flank.yml中的local-results-dir设置为results,以匹配Bitrise步骤所期望的。在github页面上的flank.yml中,默认为'flank'

## Local folder to store the test result. Folder is DELETED before each run to ensure only artifacts from the new run are saved.
 local-result-dir: results