Skip to content
Latchkey

Conan profile "ERROR: Invalid setting" in CI

Conan validated the active profile against its settings model and a value is not allowed. Most often the profile pins a compiler.version that Conan does not list for that compiler, or names a compiler the runner does not have.

What this error means

conan install fails with "ERROR: Invalid setting 'X' is not a valid 'settings.compiler.version' value" and prints the list of accepted values.

Conan
ERROR: Invalid setting '14' is not a valid 'settings.compiler.version' value.
Possible values are ['4.1', ..., '12', '13']
Read "http://docs.conan.io/2/knowledge/faq.html#error-invalid-setting"

Common causes

The profile pins a version Conan does not know

The runner has a newer compiler than the Conan settings model lists, so the pinned compiler.version is rejected.

A profile written for a different compiler

The profile declares compiler=gcc on an image that only has clang, or mixes settings that do not match the installed toolchain.

How to fix it

Autodetect the profile on the runner

Let Conan build a default profile from the actual installed compiler instead of a hardcoded one.

Terminal
conan profile detect --force
conan install . --build=missing

Upgrade Conan so it knows the compiler version

A newer Conan ships an updated settings model that includes recent compiler versions.

Terminal
pip install --upgrade conan
conan profile detect --force

How to prevent it

  • Prefer conan profile detect in CI over a pinned profile that can drift from the runner.
  • Keep Conan current so its settings model matches the runner toolchain.
  • If you pin a profile, match it to the exact compiler the runner image installs.

Frequently asked questions

What causes ""Invalid setting""?
The runner has a newer compiler than the Conan settings model lists, so the pinned compiler.version is rejected.
How do I fix "Invalid setting"?
Let Conan build a default profile from the actual installed compiler instead of a hardcoded one.

Related guides

References

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