I’ve installed the circleci cli in Ubuntu running in WSL2. I used the manual installation method and already have docker installed and running. I executed the circleci setup command and all seems well there.
When I run circleci config validate on the basic say-hello workflow file, I get the following error:
Error: config compilation request returned an error: %!w()
I ran the update command and a new one installed. The config validation still fails, but I get a little more information now with the update:
Error: config compilation request returned an error: invalid character ‘I’ looking for beginning of value
I will dig into that some more. However, it does happen for all my config files, which includes the say-hello one, as well as a handful of other ones I have that are actively running in CircleCI.
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/configuration-reference
version: 2.1
# Define a job to be invoked later in a workflow.
# See: https://circleci.com/docs/configuration-reference/#jobs
jobs:
say-hello:
# Specify the execution environment. You can specify an image from Docker Hub or use one of our convenience images from CircleCI's Developer Hub.
# See: https://circleci.com/docs/configuration-reference/#executor-job
docker:
- image: cimg/base:stable
# Add steps to the job
# See: https://circleci.com/docs/configuration-reference/#steps
steps:
- checkout
- run:
name: "Say hello"
command: "echo Hello, World!"
# Orchestrate jobs using workflows
# See: https://circleci.com/docs/configuration-reference/#workflows
workflows:
say-hello-workflow:
jobs:
- say-hello
Running the suggested tests (plus a circleci version command) below.
$ circleci version
0.1.26343+7b38e08 (release)
$ file .circleci/config.yml
.circleci/config.yml: ASCII text
$ circleci config validate -c .circleci/config.yml
Error: config compilation request returned an error: invalid character 'I' looking for beginning of value
I know I’ve been successful with the cli in WSL in the past on other machines. This is a new setup to me.
I neglected to put the yamllint result there too. It passes with the following (I think not relevant) issues:
test.yaml
3:1 warning missing document start "---" (document-start)
9:81 error line too long (149 > 80 characters) (line-length)
Yes, I’m testing with the exact one I pasted above. Also, I’ve tested with 4 other config.yml files that are actively working and building in CircleCI, all with the same circleci cli error above.