Skip to content

Error when parsing the bash script in reactor/reactor-core's GitHub Action workflow #107

@tromai

Description

@tromai

DESCRIPTION
In one of the integration tests run (not for main and staging) - https://github.com/oracle-samples/macaron/actions/runs/4443293977/jobs/7800423867?pr=67#step:8:3644.
There is an error where our bash parser couldn't parse the bash script here - https://github.com/reactor/reactor-core/blob/9ca0484e13e8f2369fa42b595da5e6d21c5d865b/.github/workflows/publish.yml#LL131C7-L135C26.
This is the error message of Macaron for this repository:

2023-03-17 01:59:10,787 [INFO] =====================================
2023-03-17 01:59:10,788 [INFO] Analyzing io.projectreactor:reactor-core
2023-03-17 01:59:10,788 [INFO] Repo path: https://github.com/reactor/reactor-core
2023-03-17 01:59:10,788 [INFO] =====================================
2023-03-17 01:59:10,788 [INFO] Preparing the repository for the analysis (path=https://github.com/reactor/reactor-core, branch=, digest=)
2023-03-17 01:59:10,788 [INFO] The path to repo https://github.com/reactor/reactor-core is a remote path.
2023-03-17 01:59:11,171 [INFO] Cloning the repo https://github.com/reactor/reactor-core to /home/runner/work/macaron/macaron/output/git_repos/github_com/reactor/reactor-core
2023-03-17 01:59:15,431 [INFO] Stashing any uncommitted changes.
2023-03-17 01:59:15,534 [INFO] Forcefully reset the repository.
2023-03-17 01:59:15,730 [INFO] Find branch main in the remote's refs of the local repository. The branch is checked out directly.
2023-03-17 01:59:15,831 [INFO] Successfully checked out branch main.
2023-03-17 01:59:15,834 [INFO] Pulling the latest changes of branch main fast-forward only.
2023-03-17 01:59:16,139 [INFO] Successfully checked out commit 9ca0484e13e8f2369fa42b595da5e6d21c5d865b.
2023-03-17 01:59:16,143 [INFO] The full name of this repository is reactor/reactor-core
2023-03-17 01:59:16,146 [INFO] Running the analysis on branch main, commit_sha 9ca0484e13e8f2369fa42b595da5e6d21c5d865b, commit_date: 2023-03-14T16:15:35+02:00
2023-03-17 01:59:16,153 [INFO] Detect git service github for reactor/reactor-core.
2023-03-17 01:59:16,153 [INFO] Checking if the repo reactor/reactor-core uses build tool gradle
2023-03-17 01:59:16,158 [INFO] The repo uses gradle build tool.
2023-03-17 01:59:16,159 [INFO] The repo uses github_actions CI service.
Error: -17 01:59:16,176 [ERROR] Error while parsing bash script: Command '['/home/runner/work/macaron/macaron/src/macaron/bin/bashparser', '-input', 'git config --local user.name \'reactorbot\'\ngit config --local user.email \'[email protected]\'\ngit tag -m "Release milestone ${{ needs.prepare.outputs.fullVersion }}" v${{ needs.prepare.outputs.fullVersion }} ${{ github.sha }}\ngit push --tags\n']' returned non-zero exit status 2.
Error: -17 01:59:16,178 [ERROR] Error while parsing bash script: Command '['/home/runner/work/macaron/macaron/src/macaron/bin/bashparser', '-input', 'git config --local user.name \'reactorbot\'\ngit config --local user.email \'[email protected]\'\ngit tag -m "Release version ${{ needs.prepare.outputs.fullVersion }}" v${{ needs.prepare.outputs.fullVersion }} ${{ github.sha }}\ngit push --tags\n']' returned non-zero exit status 2.
2023-03-17 01:59:16,180 [CRITICAL] Could not find any available runners. Stop the analysis...

This repository is analyzed as the dependency of `https://github.com/micronaut-projects/micronaut-core, branch=3.8.x, digest=68f9bb0a78fa930865d37fca39252b9ec66e4a43

REPRODUCE
The bug could be reproduced by running Macaron with this command: macaron -t $GITHUB_TOKEN -o output analyze -rp https://github.com/reactor/reactor-core -b main -d 9ca0484e13e8f2369fa42b595da5e6d21c5d865b --skip-deps

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions