Skip to content

ci: specify master branch for meshery checkout in e2etests#195

Open
2004Pruthvi wants to merge 4 commits intomeshery-extensions:masterfrom
2004Pruthvi:fix/ci-checkout-branch
Open

ci: specify master branch for meshery checkout in e2etests#195
2004Pruthvi wants to merge 4 commits intomeshery-extensions:masterfrom
2004Pruthvi:fix/ci-checkout-branch

Conversation

@2004Pruthvi
Copy link
Copy Markdown

Description
This PR addresses the issue where the e2etests workflow was checking out the meshery/meshery repository in a "detached HEAD" state. By explicitly specifying ref: master, we ensure that the subsequent steps (like publishing compatibility docs) have the correct branch context to perform a push.

Changes

  • Updated actions/checkout in .github/workflows/e2etests.yaml to include ref: master.
  • Bumped actions/checkout version to v4 for stability.

Fixes

Fixes #190

Signed-off-by: pruthvi@2004 <pruthviraj462004@gmail.com@2004Pruthvi.noreply.github.com>
@2004Pruthvi
Copy link
Copy Markdown
Author

Hi @leecalcote / @theBeginner86, I've just submitted a PR to fix this. I've updated the e2etests.yaml to explicitly checkout the master branch, which should resolve the detached HEAD failure during doc publishing. Looking forward to your feedback!

@2004Pruthvi 2004Pruthvi force-pushed the fix/ci-checkout-branch branch from 580ebe6 to a38d680 Compare March 19, 2026 17:05
Signed-off-by: pruthvi@2004 <165915900+2004Pruthvi@users.noreply.github.com>
@2004Pruthvi 2004Pruthvi force-pushed the fix/ci-checkout-branch branch from a38d680 to e8c8dee Compare March 19, 2026 17:09
@leecalcote leecalcote requested a review from Copilot March 19, 2026 17:12
@leecalcote
Copy link
Copy Markdown
Member

Running build checks...

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates CI configuration to ensure the E2E workflow checks out the meshery/meshery repo on a named branch (avoiding detached HEAD) and modernizes parts of the repo’s golangci-lint configuration.

Changes:

  • Pin meshery/meshery checkout in e2etests workflow to ref: master to avoid detached HEAD.
  • Update .golangci.yml to newer linter configuration schema (depguard rules, mnd rename, gosec excludes, gci sections).
  • Remove some prior golangci-lint configuration (skip-dirs, service block, comments).

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
.golangci.yml Migrates/adjusts golangci-lint config and removes prior exclusions/version pin block.
.github/workflows/e2etests.yaml Ensures the external repo checkout targets master explicitly.
Comments suppressed due to low confidence (1)

.golangci.yml:1

  • The config adds linters-settings.mnd and an exclude-rules entry for mnd, but mnd is not enabled (with disable-all: true, it won’t run). If the intent is to actually enforce magic-number checks, add mnd under linters.enable; otherwise, remove the mnd settings/exclude rule to avoid confusing dead configuration.
linters-settings:

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 77 to +80
with:
repository: meshery/meshery
token: ${{ secrets.GH_ACCESS_TOKEN }}
ref: master
- internal/cache
- internal/renameio
- internal/robustio
timeout: 5m
Comment on lines +3 to +9
rules:
main:
files:
- $all
deny:
- pkg: "github.com/sirupsen/logrus"
desc: "logging is allowed only by logutils.Log"
Comment on lines +42 to +47
mnd:
checks:
- argument
- case
- condition
- return
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

Signed-off-by: pruthvi@2004 <165915900+2004Pruthvi@users.noreply.github.com>
Copy link
Copy Markdown

@lekaf974 lekaf974 left a comment

Choose a reason for hiding this comment

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

if you modify this use latest version please

echo "version=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
fi
- uses: actions/checkout@master
- uses: actions/checkout@v4
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggested change
- uses: actions/checkout@v4
- uses: actions/checkout@v6

ref: master
- name: DownloadJSON
uses: actions/download-artifact@v2
uses: actions/download-artifact@v4
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggested change
uses: actions/download-artifact@v4
uses: actions/download-artifact@v8

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

hank you for the catch, @lekaf974! I've updated the workflow to use checkout@v6 and download-artifact@v8 as suggested. Ready for another look.

…fact@v8)

Signed-off-by: pruthvi@2004 <165915900+2004Pruthvi@users.noreply.github.com>
@2004Pruthvi
Copy link
Copy Markdown
Author

Also, could someone please approve the workflows so CI checks can run?

@2004Pruthvi 2004Pruthvi requested a review from lekaf974 March 23, 2026 05:04
@2004Pruthvi
Copy link
Copy Markdown
Author

Hi @lekaf974, I’ve addressed all the requested changes and updated the workflow versions (checkout@v6, download-artifact@v8).

Could you please take another look when you have time? Thanks!

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.

[CI] branch is not specified during checkout in e2etests

4 participants