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

Add auto-expanding running actions step #30058

Merged
merged 10 commits into from
Dec 22, 2024

Conversation

bytedream
Copy link
Contributor

Auto-expands the currently running action step.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Mar 25, 2024
@pull-request-size pull-request-size bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Mar 25, 2024
@KN4CK3R
Copy link
Member

KN4CK3R commented Mar 25, 2024

I think that's a feature some people will like but others will not like it. So a toggle/option may be needed.

@silverwind
Copy link
Member

Seems alright to me, even with no opt-out as GitHub does this too.

@bytedream
Copy link
Contributor Author

I got inspired from GitHub for this. Besides being nice in general (imo), this PR is a useful addition to action auto-scrolling (#30057) . With both merged, when the user opens a running action, it directly jumps to the latest output log, without the need of manually opening the currently running job step and scrolling down.

@silverwind
Copy link
Member

I think this is a valuable feature to have, but I need to get around to testing it first as I don't have a persistent action runner in my dev environment yet, so it's always a bit of a pain to test actions.

@lunny
Copy link
Member

lunny commented Apr 11, 2024

I think this is a valuable feature to have, but I need to get around to testing it first as I don't have a persistent action runner in my dev environment yet, so it's always a bit of a pain to test actions.

You can run a runner with docker in the same dev machine.
I have tested it locally and noticed it will only expand the first step but I haven't took into the code.

@lunny lunny added the topic/ui Change the appearance of the Gitea UI label Sep 17, 2024
@wxiaoguang
Copy link
Contributor

I think that's a feature some people will like but others will not like it. So a toggle/option may be needed.

I could agree with it.

when the user opens a running action, it directly jumps to the latest output log, without the need of manually opening the currently running job step and scrolling down.

The question is why users need to see the "latest output log" for a "running step". Think about 2 cases:

  • Case 1: all steps are done, end users do not need to expand any step to see details, because nothing interesting there.
  • Case 2: a step is running, the user should already know that the step is running, if the step succeeds in the end, then it is case 1: end users do not need to see the logs if they do not care about the details at the moment.

So IMO case1 and case2 are similar: if a user is interested in some steps, they could expand the logs, otherwise no need to expand automatically.

@wxiaoguang
Copy link
Contributor

Or maybe we could use local storage to introduce 2 lightweight config options: "always auto expand", "always auto scroll", then it could satisfy all users.

@pull-request-size pull-request-size bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Dec 22, 2024
@github-actions github-actions bot added modifies/translation modifies/go Pull requests that update Go code modifies/templates This PR modifies the template files labels Dec 22, 2024
@wxiaoguang
Copy link
Contributor

Now it should satisfy all users. @bytedream does it look good to you?

image

@wxiaoguang wxiaoguang added this to the 1.24.0 milestone Dec 22, 2024
@wxiaoguang wxiaoguang added the type/enhancement An improvement of existing functionality label Dec 22, 2024
@bytedream
Copy link
Contributor Author

@wxiaoguang looks good 👍 ty

@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Dec 22, 2024
@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Dec 22, 2024
@wxiaoguang wxiaoguang enabled auto-merge (squash) December 22, 2024 18:32
@wxiaoguang wxiaoguang merged commit 6279646 into go-gitea:main Dec 22, 2024
26 checks passed
zjjhot added a commit to zjjhot/gitea that referenced this pull request Dec 23, 2024
* giteaofficial/main: (62 commits)
  Fix repo avatar conflict (go-gitea#32958)
  [skip ci] Updated licenses and gitignores
  fix trailing comma not matched in the case of alphanumeric issue (go-gitea#32945)
  Add auto-expanding running actions step (go-gitea#30058)
  Fix go-gitea#32954 (go-gitea#32955)
  Use Alpine 3.21 for the docker images (go-gitea#32924)
  Refactor template & test related code (go-gitea#32938)
  Use primary as button color (go-gitea#32949)
  [skip ci] Updated translations via Crowdin
  Add action auto-scroll (go-gitea#30057)
  Fix locale (go-gitea#32937)
  Enable Typescript `strictFunctionTypes` (go-gitea#32911)
  Fix areYouSure confirm (go-gitea#32941)
  Update i18n.go - Language Picker (go-gitea#32933)
  Move some errors to their own sub packages (go-gitea#32880)
  Improve navbar: add "admin" tip, add "active" style (go-gitea#32927)
  Refactor db package and remove unnecessary `DumpTables` (go-gitea#32930)
  show warning on navigation if currently editing comment or title (go-gitea#32920)
  Refactor pprof labels and process desc (go-gitea#32909)
  [skip ci] Updated translations via Crowdin
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. modifies/frontend modifies/go Pull requests that update Go code modifies/js modifies/templates This PR modifies the template files modifies/translation size/L Denotes a PR that changes 100-499 lines, ignoring generated files. topic/ui Change the appearance of the Gitea UI type/enhancement An improvement of existing functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants