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

[7.17] ci(slack-message): fix the error (backport #13493) #13495

Merged
merged 2 commits into from
Jun 25, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Jun 25, 2024

Motivation/summary

The reporting is not working but failing when sending the notification with the below error:

Error: Error: Need to provide valid JSON payload

I think there is a corner case when using : | ... and the json contains a multiline value...

channel-id: #apm-server
    payload: {
    "attachments": [
      {
        "pretext": "Workflow <https://github.com/elastic/apm-server/actions/runs/9649427993/attempts/1|benchmarks> triggered (`schedule`)",
        "color": "danger",
        "text": "Nightly APM Server benchmarks failed! SDH Duty assignee, please have a look and follow this <https://github.com/elastic/observability-dev/blob/main/docs/apm/apm-server/runbooks/benchmarks.md|Runbook>!
  ",
        "fields": [
          {
            "title": "Workflow",
            "short": true,
            "value": "<https://github.com/elastic/apm-server/actions/runs/9649427993/attempts/1|benchmarks #520>"
          },
          {
            "title": "Ref",
            "short": true,
            "value": "`main`"
          }
        ],
        "footer": "<https://github.com/elastic/apm-server|elastic/apm-server>",
        "footer_icon": "https://slack-imgs.com/?c=1&o1=wi32.he32.si&url=https%3A%2F%2Fslack.github.com%2Fstatic%2Fimg%2Ffavicon-neutral.png"
      }
    ]
  }

Checklist

For functional changes, consider:

  • Is it observable through the addition of either logging or metrics?
  • Is its use being published in telemetry to enable product improvement?
  • Have system tests been added to avoid regression?

How to test these changes

Related issues


This is an automatic backport of pull request #13493 done by [Mergify](https://mergify.com).

(cherry picked from commit fd02bb0)

# Conflicts:
#	.github/workflows/benchmarks.yml
@mergify mergify bot added backport conflicts There is a conflict in the backported pull request labels Jun 25, 2024
@mergify mergify bot assigned v1v Jun 25, 2024
Copy link
Contributor Author

mergify bot commented Jun 25, 2024

Cherry-pick of fd02bb0 has failed:

On branch mergify/bp/7.17/pr-13493
Your branch is up to date with 'origin/7.17'.

You are currently cherry-picking commit fd02bb051.
  (fix conflicts and run "git cherry-pick --continue")
  (use "git cherry-pick --skip" to skip this patch)
  (use "git cherry-pick --abort" to cancel the cherry-pick operation)

Unmerged paths:
  (use "git add <file>..." to mark resolution)
	both modified:   .github/workflows/benchmarks.yml

no changes added to commit (use "git add" and/or "git commit -a")

To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally

@v1v v1v enabled auto-merge (squash) June 25, 2024 20:22
@mergify mergify bot merged commit f8a86f0 into 7.17 Jun 25, 2024
12 checks passed
@mergify mergify bot deleted the mergify/bp/7.17/pr-13493 branch June 25, 2024 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport conflicts There is a conflict in the backported pull request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant