Skip to content
Latchkey

GitLab "jobs config should contain at least one visible job"

GitLab parsed .gitlab-ci.yml but resolved zero runnable jobs. Every job is hidden, only a template, or filtered out - so there is nothing for a pipeline to contain.

What this error means

Pipeline creation is refused with "jobs config should contain at least one visible job", even though the YAML is otherwise well-formed. No pipeline appears on the commit or merge request.

gitlab-ci
This GitLab CI configuration is invalid: jobs config should contain at least one visible job

Common causes

Every job is dot-prefixed (hidden)

A job whose name begins with a dot (.build) is a hidden template and never runs on its own. If all jobs are hidden, none are visible.

All jobs filtered out by rules

When every job's rules/only/except evaluates false for the current ref, tag, or pipeline source, the resolved pipeline is empty and rejected.

How to fix it

Add a concrete job that consumes the template

  1. Keep shared keys in a dot-prefixed template, but add a real job that extends it.
  2. Confirm at least one job name has no leading dot.
  3. Re-validate in CI/CD - Editor; it should report the pipeline as valid.
.gitlab-ci.yml
.build_template:
  script: make build

build:
  extends: .build_template   # a real, visible job

Make sure rules cover this pipeline

  1. Review each job's rules/only against the branch, tag, and $CI_PIPELINE_SOURCE.
  2. Add a fallback rule (for example if: $CI_COMMIT_BRANCH) so normal pushes run something.
  3. Preview the surviving jobs in the Pipeline Editor against your target ref.

How to prevent it

  • Keep at least one always-on job such as a lint or smoke check.
  • Reserve dot-prefixes strictly for templates, never for real work.
  • Preview rule evaluation in the editor before merging rule changes.

Frequently asked questions

What causes ""at least one visible job""?
A job whose name begins with a dot (.build) is a hidden template and never runs on its own. If all jobs are hidden, none are visible.
How do I fix "at least one visible job"?
Add a concrete job that consumes the template

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card