Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[chore] Added a workflow to lint YAML files using actionlint #12721

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

KenEkanem
Copy link

Description

This pull request builds on the work done in #11493

  • Use specific version for docker actionlint image
  • Configured renovate.json to track docker image updates
  • Ignored some shellcheck errors since shellcheck isn't always right. List of errors ignored here

Link to tracking issue

#9676

Fixes

  • Addresses potential linting errors in workflow files.

Testing

  • The workflow has been tested to ensure the changes resolve identified issues and maintain functionality.

Documentation

No new documentation added, as this change is self-explanatory within the context of CI.

…e renovate.json

- Use specific version for docker actionlint image
- Configured renovate.json to track  docker image updates
@KenEkanem KenEkanem requested a review from a team as a code owner March 24, 2025 22:13
@KenEkanem KenEkanem requested a review from mx-psi March 24, 2025 22:13
- build-and-test-windows.yaml: (line 42 & 71) Used \ at EOL to explicitly tell the shell to continue on the next
- generate-semantic-conventions-pr.yaml: disabled SC2034 warning
Copy link

codecov bot commented Mar 25, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.54%. Comparing base (622ce90) to head (16d3499).
Report is 7 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #12721   +/-   ##
=======================================
  Coverage   91.53%   91.54%           
=======================================
  Files         483      480    -3     
  Lines       26453    26456    +3     
=======================================
+ Hits        24215    24218    +3     
  Misses       1772     1772           
  Partials      466      466           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@@ -105,5 +105,5 @@ jobs:
url=$(gh pr create --title "$message" \
--body "$body" \
--base main)

# shellcheck disable=SC2034
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a comment explaining why this was disabled?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay. I'll do that.

uses: actions/checkout@v4

- name: Pre-pull Docker Image
run: docker pull rhysd/actionlint:${{ env.ACTIONLINT_VERSION }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a Go tool so we can add it to the internal/tools/go.mod file and install it using make install-tools instead of this. That will allow us to get automatic updates without special renovate configuration

Comment on lines +26 to +31
-ignore 'SC2086' \
-ignore 'SC2046' \
-ignore 'SC2059' \
-ignore 'SC2236' \
-ignore 'SC1001' \
-ignore 'SC2129' \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's move all the configuration to a file https://github.com/rhysd/actionlint/blob/v1.7.7/docs/config.md#configuration-file and add a comment explaining why we are ignoring these

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants