Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,555,409
Community Members
 
Community Events
184
Community Groups

Error saying my pipeline has a step section empty or null

I keep receiving this error message:

There is an error in your bitbucket-pipelines.yml at [pipelines > branches > fixing-yaml > 0 > parallel > 4]. To be precise: The step section is empty or null.

It doesn't make any sense to me, I have nothing empty. even Atlassian's validator online says it's all good.

Also, the pipeline works fine, until I add another step, and it shows that.

clone:
depth: full

definitions:
caches:
sonar: ~/.sonar

steps:
- step: &lint
name: Lint
script:
- echo "Add linting here"

- step: &aws
name: AWS oidc setup
image: amazon/aws-cli
oidc: true
script:
- export AWS_REGION=us-east-1
- yum update
- yum install -y jq

- step: &sonarqube
name: SAST - SonarQube
runs-on:
- self.hosted
- linux
script:
- pipe: sonarsource/sonarqube-scan:1.0.0
variables:
SONAR_HOST_URL: ${SONAR_HOST_URL}
SONAR_TOKEN: ${SONAR_TOKEN}

-
step: &unit-test
name: Unit Test
script:
- echo "Add Unit Tests here"

-
step: &build
name: Build
script:
- ./cicd/build.sh
services:
- docker
caches:
- docker

- step: &deliver
name: Deliver
script:
- ./cicd/promote.sh

pipelines:
default: # Runs on every commit for branches not defined elsewhere
# - step: *sonarqube
- parallel:
- step: *lint
- step: *unit-test
- step: *build

pull-requests:
'**': # this runs as default for any branch not elsewhere defined
# - step: *sonarqube
- parallel:
- step: *lint
- step: *unit-test
- step: *build

branches: # these will run on every push of the branch
master:
# - step: *sonarqube
- parallel:
- step: *lint
- step: *aws
- step: *unit-test
- step: *build
- step: *deliver
This code results in that error:
There is an error in your bitbucket-pipelines.yml at [pipelines > branches > fixing-yaml > 0 > parallel > 4]. To be precise: The step section is empty or null.
But, if I simply remove the last step, leaving as:
...

...

branches: # these will run on every push of the branch
master:
# - step: *sonarqube
- parallel:
- step: *lint
- step: *aws
- step: *unit-test
- step: *build
It works fine. I can't make sense of it. Any help or suggestions?

1 answer

1 accepted

0 votes
Answer accepted

Nevermind.. Found my error... I had a few spaces missing.. indentation. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events