Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

PR file list keeps the old base after the base branch changes outside VS Code

Đang mở
#9,076 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 2 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
68/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
github, typescript, vscode

Hướng nghiên cứu

Start by tracing the Pull Requests view refresh flow through pr.refreshList, createOrUpdatePullRequestModel(), and getChangeModels() in dist/extension.js, as identified in the issue. Check how cached file changes are invalidated when the base branch changes, then reproduce with a PR whose new base changes the file diff. Done means Refresh shows the same file changes as GitHub’s “Files changed” tab without reloading the window.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

  • Extension version: 0.170.0
  • VSCode Version: 1.142.0
  • OS: Windows 11
  • Repository Clone Configuration (single repository/fork of an upstream repository): single repository
  • GitHub Product (GitHub.com/GitHub Enterprise version x.x.x): GitHub.com

Steps to Reproduce:

  1. Have an open PR listed in the Pull Requests view.
  2. Change its base branch outside VS Code, for example with gh pr edit <number> --base <branch>, to a branch where the PR's files differ.
  3. Expand the PR in the Pull Requests view, then click Refresh and expand it again.

Result: the file list still compares against the old base. In my case, files that the new base already has as renamed show as deleted and added. Only Developer: Reload Window fixes it. GitHub's "Files changed" tab shows them as modified.

Expected: Refresh shows the files against the new base.

From reading dist/extension.js (not debugged): pr.refreshList calls forceClearCache(), and createOrUpdatePullRequestModel() keeps the existing model and calls update(), which sets the new base. Nothing clears _fileChanges, and getChangeModels() reuses it while it isn't empty.

Ngôn ngữ chính
TypeScript
Star
2.6k
Fork
804
Merge trung bình
2 ngày 1 giờ
Pull request đã merge (30 ngày)
42

Chuẩn bị môi trường

Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/vscode-pull-request-github

Tất cả issue của microsoft/vscode-pull-request-github

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.