-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
Summary
I follow the instructions provided in the exercise step 1, and then cannot proceed to step 2. However, if I ignore the provided instructions, and add in a generic "job" I can proceed to step 2.
How to reproduce
I follow the instructions for "Step 1: Create a workflow" which are as follows
- Open "skills-hello-github-actions" repo
- Create a new branch named "welcome-workflow
- In the "welcome-workflow" branch, navigate to the .GitHub/workflows directory
- Create a new file named "welcome.yml" in the .GitHub/workflows directory with the following content:
name: Post welcome comment
on:
pull_request:
types: [opened]
permissions:
pull-requests: write - Commit changes directly to the "welcome-workflow" branch
- Wait for "Mona" to check your work and proceed
The exercise never proceeds to step 2. Refreshing the page makes no difference. I just see "please, follow the steps above."
When I check the "Actions" section, I see a red "X" for "Add GitHub Actions workflow for welcome comment" which shows as being for the "welcome-workflow" branch.
When I examine the details of this message I see:
"Check failure on line 1 in .github/workflows/welcome.yml
GitHub Actions
/ .github/workflows/welcome.yml
Invalid workflow file
(Line: 1, Col: 1): Required property is missing: jobs"
The exercise contains a statement "[!NOTE] This is an incomplete workflow file. It is normal if you receive an error message. One step at a time! 😎" which I assume is related to the error that I see, however, the presence of this error appears to prevent the exercise from proceeding.
Below is a screenshot of the error that I see.
How I resolved the issue
I've tried modifying the welcome.yml contents to include a job, and after refreshing the page, the exercise immediately proceeded to step 2. This is the full code that I used to correct the issue:
"name: Post welcome comment
on:
pull_request:
types: [opened]
permissions:
pull-requests: write
jobs:
welcome:
runs-on: ubuntu-latest
steps:
- name: Placeholder step
run: echo "Workflow initialized"
The following screenshot shows that i've now successfully proceeded to the next exercise step, but only after I did not follow the step 1 instructions:
