github / github/vscode-github-actions
Linter lints old version when comparing diffs
- Ngôn ngữ chính
- TypeScript
- Star
- 660
- Fork
- 213
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Mô tả
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Create & **commit** the following workflow:
```yaml
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
name: Build
on:
pull_request:
branches:
- main
permissions:
contents: read
jobs:
build:
name: Build
runs-on: ubuntu-latest
outputs:
build_id: ${{ steps.build.build_id }}
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
show-progress: false
- name: Build
id: build
shell: bash
run: |
echo "Building"
echo "build_id=12345" >> "$GITHUB_OUTPUT"
```
1. Notice the linting warning on `${{ steps.build.build_id }}`: `Context access might be invalid: build_id`.
1. Delete the following lines, save but do NOT commit:
```yaml
outputs:
build_id: ${{ steps.build.build_id }}
```
1. In the diff window compare the changes
1. (BUG 1) (while diff is open) Notice the LEFT window showing the linting warning, which also shows up under 'PROBLEMS'

1. (while diff is open) Double click the warning under problems and notice it opens a locked (denoted the padlock next to the name) version of the previous, unedited version of `build.yaml`.

1. Close the diff & locked old version of `build.yaml`
1. (BUG 2) Notice the linting error is still there under 'PROBLEMS'

1. (BUG 2 related) When double clicking linting warning it opens up the same locked (denoted the padlock next to the name) version of the previous, unedited version of `build.yaml`.
1. (BUG 1) Now when hitting 'CTRL+P' to switch between files there are 2 entries for `build.yaml` which are indistinguishable, yet refer to different versions:

**Expected behavior**
Only errors on the new version are reported.
**Screenshots**
See reproduction
**Extension Version**
`v0.26.2`
**Additional context**
Add any other context about the problem here.
Hướng dẫn đóng góp
Hướng nghiên cứu
No source files or tests are named. Reproduce the workflow in VS Code with extension v0.26.2, then trace how diagnostics and opened documents are associated while the diff is displayed and after it closes. Done means only the edited version reports errors, warnings do not open a locked old file, and the file switcher has no duplicate entries.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- github-actions, typescript, vscode
- Lĩnh vực
- devtools, tooling
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100