forgejo/web_src/js/components
Mathieu Fenniak d9252f53a3 Fix bug where Action UI may occasionally not load logs (#6122)
In the combination of events where the user is viewing an action that is completed (and therefore no interval-based loading of logs is occurring), and `loadJob` is called while `loadJob` is already running (commonly from expanding two log sections back-to-back), the second request for loading would be discarded and never occur.

To fix this, the invocation of `loadJob` keeps track of the log cursors it is attempting to load, and an aborted invocation stores its attempted load.  If `loadJob` succeeds in loading and finds that an attempt was aborted while it was busy, it will reload the data.

Steps to reproduce:
- Open an Action UI that is already "Done".
- Click on two steps in rapid succession to expand their logs.
- (Race condition) As long as the second click is registered while the first log chunk is being loaded, its data won't load.

## Checklist

The [contributor guide](https://forgejo.org/docs/next/contributor/) contains information that will be helpful to first time contributors. There also are a few [conditions for merging Pull Requests in Forgejo repositories](https://codeberg.org/forgejo/governance/src/branch/main/PullRequestsAgreement.md). You are also welcome to join the [Forgejo development chatroom](https://matrix.to/#/#forgejo-development:matrix.org).

### Tests

- I added test coverage for Go changes...  (**not applicable**)
  - [ ] in their respective `*_test.go` for unit tests.
  - [ ] in the `tests/integration` directory if it involves interactions with a live Forgejo server.
- I added test coverage for JavaScript changes...
  - [x] in `web_src/js/*.test.js` if it can be unit tested.
  - [ ] in `tests/e2e/*.test.e2e.js` if it requires interactions with a live Forgejo server (see also the [developer guide for JavaScript testing](https://codeberg.org/forgejo/forgejo/src/branch/forgejo/tests/e2e/README.md#end-to-end-tests)).

### Documentation

- [ ] I created a pull request [to the documentation](https://codeberg.org/forgejo/docs) to explain to Forgejo users how to use this change.
- [x] I did not document these changes and I do not expect someone else to do it.

### Release notes

- [ ] I do not want this change to show in the release notes.
- [x] I want the title to show in the release notes with a link to this pull request.
- [ ] I want the content of the `release-notes/<pull request number>.md` to be be used for the release notes instead of the title.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/6122
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Reviewed-by: Otto <otto@codeberg.org>
Reviewed-by: Gusted <gusted@noreply.codeberg.org>
Co-authored-by: Mathieu Fenniak <mathieu@fenniak.net>
Co-committed-by: Mathieu Fenniak <mathieu@fenniak.net>
2024-12-05 18:08:11 +00:00
..
ActionRunStatus.vue Fix incorrect tailwind migration (#30007) 2024-03-26 19:04:27 +01:00
ActivityHeatmap.vue Enforce trailing comma in JS on multiline (#30002) 2024-03-26 19:04:27 +01:00
ContextPopup.test.js ui: update pull request icons 2024-08-22 17:06:10 +02:00
ContextPopup.vue ui: update pull request icons (#4455) 2024-07-16 14:38:46 +00:00
DashboardRepoList.vue Fix checkbox bug on private/archive filter (#32236) 2024-10-13 14:17:08 +03:00
DiffCommitSelector.vue [PORT] Fix a number of typescript issues (gitea#32308) 2024-11-04 09:15:06 +01:00
DiffFileList.vue Migrate font-family to tailwind (#30118) 2024-03-30 07:17:32 +01:00
DiffFileTree.vue Migrate margin and padding helpers to tailwind (#30043) 2024-03-30 07:17:29 +01:00
DiffFileTreeItem.vue Enforce trailing comma in JS on multiline (#30002) 2024-03-26 19:04:27 +01:00
PullRequestMergeForm.test.js fix: Don't double escape delete branch text 2024-10-19 22:05:35 +02:00
PullRequestMergeForm.vue Add branch auto deletion for scheduled PRs 2024-10-31 03:49:15 +01:00
RepoActionView.test.js Fix bug where Action UI may occasionally not load logs (#6122) 2024-12-05 18:08:11 +00:00
RepoActionView.vue Fix bug where Action UI may occasionally not load logs (#6122) 2024-12-05 18:08:11 +00:00
RepoActivityTopAuthors.vue [UI] Fix misalignment of authors for repo acctivity 2024-08-18 21:18:29 +02:00
RepoBranchTagSelector.vue fix: replace v-html with v-text in branch search inputbox 2024-09-06 11:59:11 +02:00
RepoCodeFrequency.vue Have time.js use UTC-related getters/setters (#30857) 2024-05-12 20:03:09 +02:00
RepoContributors.vue Fix Activity Page Contributors dropdown (#31264) 2024-06-18 20:05:23 +02:00
RepoRecentCommits.vue Have time.js use UTC-related getters/setters (#30857) 2024-05-12 20:03:09 +02:00
ScopedAccessTokenSelector.vue [UI] Fix scoped-access-token 2024-07-24 21:48:51 +02:00