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

Steps coming out ugly #131

Open
mattwynne opened this issue Oct 6, 2020 · 13 comments
Open

Steps coming out ugly #131

mattwynne opened this issue Oct 6, 2020 · 13 comments
Labels
question Further information is requested

Comments

@mattwynne
Copy link

I've added your lovely plugin to our build as advised in the readme, but we're seeing something a bit disappointing in the "steps" output in Slack:

image

Any idea what we're doing wrong?

@satterly
Copy link
Contributor

satterly commented Oct 6, 2020

Enable debug and run again...

Set the ACTIONS_STEP_DEBUG secret to true.

@mattwynne
Copy link
Author

Thanks for the quick response.

Here's the output:

  with:
    status: success
    steps: {
    "58764083063d40139891dda6fb4654d2": {
      "outputs": {},
      "outcome": "success",
      "conclusion": "success"
    }
  }

Is it because we haven't named the steps, maybe?

@satterly
Copy link
Contributor

satterly commented Oct 7, 2020

Yes, I'm surprised it displayed the steps at all -- GitHub must have changed something. From the README ...

Note: Only steps that have a "step id" will be reported on.

@satterly satterly added the question Further information is requested label Oct 24, 2020
@bconway
Copy link

bconway commented Nov 9, 2020

Has anyone figured out what the extra alphanumeric ID refers? I have multiple steps defined by IDs (per the docs), and they all show up as expected, plus this garbage one first.

@rpherrera
Copy link

This is happening to me as well. Same issue, same outputs.
Has anyone figured how to fix that?

I am using v1.2.2.
Thanks!

@satterly
Copy link
Contributor

@rpherrera I think it has something to do with using a matrix of job configurations. Are you using strategy.matrix in the workflow? https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions#jobsjob_idstrategymatrix

@rpherrera
Copy link

@satterly nope.

Here is how I am using it:

      - name: Send an alert on Slack informing the job status
        uses: act10ns/slack@v1.2.2
        with:
          status: ${{job.status}}
          steps: ${{toJson(steps)}}
        env:
          SLACK_WEBHOOK_URL: ${{secrets.WEBHOOK_URL}}
        if: always()

I have tried all the previous tags all the way to the very first release and the outputs are roughly the same:

:heavy_check_mark: 3519285ff45844b4a046c11ea0634c6d
:heavy_check_mark: d386e8b4af8246d4837dcb403a0fbf05

Thanks for answering promptly, by the way.

@yongchand
Copy link

Any new updates for this issue? :(

@satterly satterly reopened this Jan 1, 2022
@hos-dimabutyrin
Copy link

This functionality works if you add id to your steps. Id's will appear instead of steps names in the slack message.

@bconway
Copy link

bconway commented Oct 6, 2022

This functionality works if you add id to your steps. Id's will appear instead of steps names in the slack message.

That is only true for steps after the 0th. As an example:

    steps:
      - name: Deps
        # Names are duplicated as IDs for use by Notify
        id: Deps
        run: |
          ...
      - name: Clone
        id: Clone
        uses: actions/checkout@v2
      - name: Build_and_Test
        id: Build_and_Test
        run: make test
      - name: Push
        id: Push
        ...

Result:

Screen Shot 2022-10-06 at 8 03 35 AM

And sometimes still more than one:

    steps:
      - name: Deps
        # Names are duplicated as IDs for use by Notify
        id: Deps
        run: |
          ...
      - name: Clone
        id: Clone
        uses: actions/checkout@v2
      - name: Restart_MQTT
        id: Restart_MQTT
        # Restart MQTT after volumes have been checked out
        uses: docker://docker
        with:
          args: docker restart mqtt
      - name: Build_and_Test
        id: Build_and_Test
        run: make test
      - name: Push
        id: Push
        ...

Screen Shot 2022-10-06 at 8 06 01 AM

@hos-dimabutyrin
Copy link

Well for me it works differently:
Screenshot at Oct 06 16-10-23

@adamc-formlogic
Copy link

adamc-formlogic commented Aug 11, 2023

I think I've figured this out. When I run a workflow on a Github-hosted runner, I don't get the extra garbage step, and the list of steps in the UI is:

  • Set up job
  • (whatever I name my step)
  • Complete job

But when I run the exact same workflow on a self-hosted runner, I get the extra step, and the list is:

  • Set up job
  • Set up runner
  • (my step)
  • Complete runner
  • Complete job

My hypothesis is that the "Set up runner" step does not have an ID assigned and that's where this extra step/hash is coming from.

@bconway
Copy link

bconway commented Aug 12, 2023

Unfortunately, I have only ever used GitHub-hosted runners and see the results above.

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

No branches or pull requests

7 participants