Setup workflow and scheduled workflow in the same configuration

Hi,

I’m trying to use setup workflow to handle specific edge case in our build process.

But I’m facing an issue when trying to make it work with scheduled workflow. Basically we need a CircleCI config where we can use scheduled workflow and setup workflow together.

Using this config CircleCI throw this error: “Max number of workflows exceeded.”

version: 2.1

setup: true

orbs:
  continuation: circleci/continuation@0.1.2
  node: circleci/node@4.2.1

jobs:
  scheduled_job:
    docker:
      - image: cimg/base:2021.02
    steps:
      - run:
          name: Install npm
          command: npm install

  setup_job:
    executor: continuation/default
    steps:
      - run:
          name: Generate config
          command: |
            ./generate_config > generated_config.yml
      - continuation/continue:
          configuration_path: generated_config.yml

workflows:
  scheduled:
    triggers:
      - schedule:
          cron: '0 0 * * 1'
          filters:
            branches:
              only:
                - master
    jobs:
      - scheduled_job

  setup:
    jobs:
      - setup_job

How setup workflow and scheduled job can works together ?

Kind regards

3 Likes

I have the same problem as this. I’m waiting for the response too.

1 Like

This is something that we’re aware of not working. We’re working on getting it fixed up, though don’t have an ETA yet. We’ll keep you posted, though. Thanks!

(Gotta get that staff tag on here, heh, so don’t mind the lack of that.)

1 Like

Hi, is there any news on this? It’s been 3 weeks. Right now I have to manually trigger scheduled workflow every day. It’s ironic that an automation tool like CircleCI is forcing me to do manual work like this. Please fix this soon.

Ideally I would wish that the scheduled workflows are generated by setup workflow. But if you guys want the original config file .circleci/config.yml to define both setup workflow and scheduled workflows, I’m OK too.

I am interested in this too. I’ll follow this thread to get notified

Any updates on this ?

Hi All!

While we don’t have an ETA on the ability to utilize scheduled workflows in conjunction with dynamic configs, I can say the team is actively working on it. In the meantime, I created the following workaround that should allow you to run scheduled workflows on a dynamic config enabled project:

I hope the above helps in the meantime, I do know the ability to use both these features together is a high priority for the team.