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

fix: fix broken formatting of first comment in case of command output truncation #4980

Merged
merged 8 commits into from
Oct 24, 2024

Conversation

benoittoulme
Copy link
Contributor

@benoittoulme benoittoulme commented Oct 4, 2024

what

  • fix the wrapping of the comments to make it collapsible in case of truncation of the command output.
    Before this fix:
image

After this fix:
image

why

  • in a previous PR, I introduced a markdown to display a warning message in case of truncation of a command output
    chore: use markdown to display github comments truncation header #4885
  • Because of the truncation of the command output, we are missing the <details> wrapping, that allows to display the rest of the message properly. My previous PR attempted to fix the formatting and worked in my tests, unfortunately, it missed re-introducing the wrapping.
  • This causes the first comment to display entirely in case of truncation of the command output, instead of appearing collapsed.

tests

deployed atlantis 0.30.0 and tested the comment markdown on a github comment.

references

@benoittoulme benoittoulme requested review from a team as code owners October 4, 2024 07:45
@benoittoulme benoittoulme requested review from jamengual, nitrocode and X-Guardian and removed request for a team October 4, 2024 07:45
@github-actions github-actions bot added go Pull requests that update Go code provider/github labels Oct 4, 2024
@benoittoulme benoittoulme changed the title fix broken formatting fix broken formatting of first comment in case of command output truncation Oct 4, 2024
@dosubot dosubot bot added the bug Something isn't working label Oct 4, 2024
@benoittoulme benoittoulme changed the title fix broken formatting of first comment in case of command output truncation chore: fix broken formatting of first comment in case of command output truncation Oct 4, 2024
@X-Guardian
Copy link
Contributor

Hi @benoittoulme, can you add before and after screenshots for this to the description as evidence that it is fixed, and I will then get it merged for you.

The PR description should also have a fix: prefix, not chore: so that it ends up in the correct section in the changelog.

@X-Guardian X-Guardian added the waiting-on-response Waiting for a response from the user label Oct 23, 2024
@benoittoulme benoittoulme changed the title chore: fix broken formatting of first comment in case of command output truncation fix: fix broken formatting of first comment in case of command output truncation Oct 24, 2024
@benoittoulme
Copy link
Contributor Author

Hi @benoittoulme, can you add before and after screenshots for this to the description as evidence that it is fixed, and I will then get it merged for you.

The PR description should also have a fix: prefix, not chore: so that it ends up in the correct section in the changelog.

I updated the description of the PR with 2 screenshots.

@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Oct 24, 2024
@X-Guardian
Copy link
Contributor

Thanks @benoittoulme, merging now.

@X-Guardian X-Guardian merged commit 7f4a420 into runatlantis:main Oct 24, 2024
33 of 35 checks passed
a1k0u pushed a commit to a1k0u/atlantis that referenced this pull request Nov 1, 2024
… truncation (runatlantis#4980)

Co-authored-by: PePe Amengual <2208324+jamengual@users.noreply.github.com>
Signed-off-by: a1k0u <alko7enko@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working go Pull requests that update Go code lgtm This PR has been approved by a maintainer provider/github waiting-on-response Waiting for a response from the user
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants