Bash: an assignment in a loop body that reads the loop variable is not listed on later commands
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 48/100
Hướng nghiên cứu
The issue names no source files or tests; start by locating how SST records assignment facts for commands inside Bash loop bodies, then trace the handling of assignments that read the loop variable. Add or find coverage for the provided for loop example and verify later git status occurrences list the assignment with a proven value or Unknown, while MayAffectProcessEnvironment remains true unless the complete-environment rule proves otherwise.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Problem
An assignment inside a loop body that reads the loop variable does not appear in the assignment facts of the later commands in that body.
Example:
for i in 1 2; do GIT_DIR=/tmp/r$i; git status; done
- If
GIT_DIRis in the launch environment,git statusruns withGIT_DIR=/tmp/r1and then withGIT_DIR=/tmp/r2. - SST does not list the
GIT_DIRassignment on thegit statusoccurrence.
Impact
A consumer that reads the assignment facts (for example, an approval digest) does not see that the environment of git status can change.
Expected
- List the assignment on each later command in the body, with the value set when SST proves it (
/tmp/r1,/tmp/r2), or Unknown. - Keep
MayAffectProcessEnvironmenttrue unless the complete-environment rule (https://github.com/Aaronontheweb/ShellSyntaxTree/pull/248) proves otherwise.
Found by the review of https://github.com/Aaronontheweb/ShellSyntaxTree/pull/248 (dev has the same gap).
- Ngôn ngữ chính
- C#
- Star
- 15
- Fork
- 0
- Merge trung bình
- 9 giờ 8 phút
- Pull request đã merge (30 ngày)
- 46
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của Aaronontheweb/ShellSyntaxTree
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 57/100
Aaronontheweb/ShellSyntaxTree#244 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Aaronontheweb/ShellSyntaxTree#236 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
Aaronontheweb/ShellSyntaxTree#235 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 38/100
Aaronontheweb/ShellSyntaxTree#227 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
enhancement
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
Aaronontheweb/ShellSyntaxTree#190 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của Aaronontheweb/ShellSyntaxTree
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
stryker-mutator/stryker-net#3892 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
MobiFlight/MobiFlight-Connector#3419 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
`Source` with an `avares://` URI and a `#fragment` throws instead of scrolling to the anchorĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Kryptos-FR/MarkView.Avalonia#105 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[辞書]Đang mở提案 辞書
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
microsoft/fluentui-blazor#5410 ·
Maintainer thường phản hồi trong vòng 1 ngày