Issue importing a scancode.io JSON results into VirtualCodebase
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
- 48/100
Hướng nghiên cứu
Bắt đầu trong commoncode/resource.py, khoảng dòng 671, và theo dõi cách các tài nguyên JSON của scancode.io được nạp vào VirtualCodebase. Tái hiện trường hợp walk() với các tài nguyên có tên example.zip và example.zip-extract, sau đó xác minh rằng các phần tử con được nhập vẫn giữ nguyên các tên tệp đầy đủ đó và việc duyệt tiếp tục vượt qua virtual_root.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
We're encountering the issue where we cannot walk a VirtualCodebase created from a scancode.io scan (prior to v31.0.0). When the scan is loaded into VirtualCodebase, and we call walk(), only the virtual_root is returned. This is due to the scancode.io Resource names not containing the extensions. The full filename is required for a VirtualCodebase to work since we keep the filenames of the children of each Resource (https://github.com/nexB/commoncode/blob/main/src/commoncode/resource.py#L671). If the filename isn't the complete filename, then the Resource will never find the child Resource when walking.
For example, in the problematic scan, the two resources at the root have the paths example.zip and example.zip-extract, but their names are both example. When loaded into a VirtualCodebase, the virtual_root has two children, but their names are both example, when it should be example.zip and example.zip-extract. Since virtual_root/example does not exist in resources_by_path of the VirtualCodebase, then we cannot continue the walk.
- Ngôn ngữ chính
- Python
- Star
- 4
- Fork
- 25
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
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
- Đọ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 aboutcode-org/commoncode
-
Consider that Resource.parent can be None when removing resources from the codebaseCó thể đã có người làm @Mirochill đã nhận 177 ngày trước. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
aboutcode-org/commoncode#84 ·
-
Click 8.5.0: omitted boolean flags incorrectly trigger conflicting_options validationCó thể đã có người làm Có pull request liên kết đang mở hoặc đã được merge. Đang mở
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 66/100
aboutcode-org/commoncode#112 ·
-
Revisit cliutils.pyĐang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
aboutcode-org/commoncode#102 · 1 bình luận ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
aboutcode-org/commoncode#101 · 1 bình luận ·
-
mass-scan: Create library to collect a whole project version from Software HeritageCó thể làm lại được @chinyeungli đã nhận 264 ngày trước và không có pull request nào đang mở. Đang mở
aboutcode-org/commoncode#77 · 7 bình luận · 1 người được giao ·
Tất cả issue của aboutcode-org/commoncode
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
GoogleCloudPlatform/professional-services-data-validator#1899 ·
Maintainer thường phản hồi trong vòng 4 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
mohanraj00/entelos#200 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Dead url in mise.tomlĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 68/100
-
sweep
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
bketelsen/truenas-mcp#77 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Console writes URL credentials to the local log, though AGENTS.md says secrets never reach diskĐang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
sandbox-quantum/switch#2163 ·
Maintainer thường phản hồi trong vòng 1 ngày