Getting config errors when use requires on workflows

android
circle.yml
workflow

#1

Hi, recently I’ve been working on how to dividing some jobs I usually do for creating an Android’s build in Circle. Basically what I’m doing right now is first to build the app and if it success, upload the apk to a Slack channel. When I created two different workflows in order to get the debug build and the release build, I’m getting a config error. Honestly I don’t know what’s wrong, I researched about it but I didn’t find anything.

I’m seeing the next error:

We weren’t able to start this workflow.
Encountered errors trying to create workflows from this config: contains? not supported on type: clojure.lang.LazySeq

version: 2
jobs:
  build: #Get dependencies and init build
    docker:
      - image: circleci/android:api-27-alpha #SDK version
    working_directory: ~/code
    steps:
    - checkout
    - run: echo "Starting..."
    - restore_cache:
          key: jars-{{ checksum "build.gradle" }}-{{ checksum  "app/build.gradle" }}
    - run:
          name: Download Dependencies
          command: ./gradlew androidDependencies
    - save_cache:
          paths:
            - ~/.gradle
          key: jars-{{ checksum "build.gradle" }}-{{ checksum  "app/build.gradle" }}
  debug-build: #Do debug build
    - run:
          name: Initial debug build
          command: ./gradlew clean assembleDebug --no-daemon --stacktrace
    - store_artifacts:
          path: app/build/outputs/apk/
          destination: apks/
    - run:
          name: Uploading debug build to Slack
          command: |
            export GIT_COMMIT_DESC=$(git log --format=oneline -n 1 | sed -E 's/^[^ ]+ (.*)$/\1/g')
            curl -F file=@app/build/outputs/apk/debug/app-debug.apk -F channels=$SLACK_CHANNEL -F token=$SLACK_API_TOKEN -F title="${CIRCLE_PROJECT_REPONAME} | branch -> ${CIRCLE_BRANCH} | commit -> ${GIT_COMMIT_DESC}"  https://slack.com/api/files.upload 
  release-build: #Do release build
    - run:
          name: Initial release build
          command: ./gradlew clean assembleRelease --no-daemon --stacktrace
    - store_artifacts:
          path: app/build/outputs/apk/
          destination: apks/
    - run:
          name: Upload release build to Slack
          command: |
            export GIT_COMMIT_DESC=$(git log --format=oneline -n 1 | sed -E 's/^[^ ]+ (.*)$/\1/g')
            curl -F file=@app/build/outputs/apk/release/app-release.apk -F channels=$SLACK_CHANNEL -F token=$SLACK_API_TOKEN -F title="${CIRCLE_PROJECT_REPONAME} | branch -> ${CIRCLE_BRANCH} | commit -> ${GIT_COMMIT_DESC}"  https://slack.com/api/files.upload

workflows:
  version: 2
  build:
    jobs:
      - build
      - debug-build:
          requires:
            - build
          filters:
            branches:
              only: circleImprovements
      - release-build:
          requires:
            - build
          filters:
            branches:
              only: master

#2

That error isn’t very readable. Would you post it as text, by editing your question? That will also help future readers looking for the same thing, since it will make the content searchable.


#3

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.