Step runs very slow without apparent reason

Hello. I have a Golang project workflow and I have a test step that runs very slow, and I dont understand why.

The step took 1m37 to run, but the command “go test” only took only 5 seconds as you can see in the logs below:

1m 37s
Sun, 01 Nov 2020 09:36:45 GMT
Run go test -tags="test" -v ./...
Sun, 01 Nov 2020 09:38:17 GMT ?   	brunopazlabs	[no test files]
Sun, 01 Nov 2020 09:38:22 GMT === RUN   TestK8sCluster
Sun, 01 Nov 2020 09:38:22 GMT --- PASS: TestK8sCluster (0.00s)
Sun, 01 Nov 2020 09:38:22 GMT PASS
Sun, 01 Nov 2020 09:38:22 GMT ok  	brunopazlabs/internal/infra	0.016s
Sun, 01 Nov 2020 09:38:22 GMT ?   	brunopazlabs/internal/testutils	[no test files]

Anybody have a clue why it took like 1m30 between the start of the step and effecively run the command?

There are no more logs.

Here is the job code:

  test:
    name: Unit Tests
    needs: lint
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-go@v2
        with:
          go-version: ${{ env.GO_VERSION }}

      - uses: actions/cache@v2
        with:
          path: ~/go/pkg/mod
          key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
          restore-keys: |
            ${{ runner.os }}-go-

      - run: go mod download

      - run: go test -tags="test" -v ./...

Thank you.

@brpaz,

You can try to check with the following steps:

  1. Enabling debug logging to see if you can get more details about the step from then debug logs.

  2. Download the project onto your local machine, then run the test step with the same go test command to see if it has the similar question.

  3. Try using a self-hosted runner to see if it has the similar question.