Malformed revision manifests cause server errors
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
Start by reading the existing manifest validation used by the revision file's Source tab, then trace the manifest consumers named in the issue across the project pages, file detail pages, upload operations, and REST API. Check how each consumer handles malformed stored data and how operations avoid changes when validation fails. Done means affected pages show a meaningful error without manifest-derived information, and dependent operations are refused without changes.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Plugin Version
v0.1.0
NetBox Version
v4.7.6
Python Version
3.12
Steps to Reproduce
- Create an upload-backed Script Project and upload a Script.
- Once the revision is active, overwrite its manifest using
nbshell:from netbox_scripts.models import ScriptProjectRevision ScriptProjectRevision.objects.filter(pk=<revision_id>).update(manifest=[None]) - Open any of the following pages or attempt to upload another Script:
- Script Project's Script Files tab
- Script Project's Revision Files tab
- Script File detail page
- Revision's Files tab
- Revision file's File tab
The last three pages are affected by the changes introduced in #224.
Expected Behavior
The affected pages remain usable and display a meaningful error, consistent with the revision file's Source tab. Information and links derived from an invalid manifest are not displayed.
Operations that depend on the manifest are refused without making changes.
Observed Behavior
The affected pages and operations fail with an HTTP 500 error, for example:
TypeError: 'NoneType' object is not subscriptable
Several consumers access the stored manifest without validating it first. This also affects the REST API.
The revision file's Source tab already handles this gracefully by displaying "The stored manifest cannot be trusted."
All manifest consumers should handle malformed manifests consistently by reusing the existing manifest validation mechanism.
The issue was identified during the implementation and review of #24 (#224).
- Ngôn ngữ chính
- Python
- Star
- 9
- Fork
- 0
- Merge trung bình
- 18 giờ 59 phút
- Pull request đã merge (30 ngày)
- 93
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- 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 netbox-community/netbox-scripts
-
app: scripts Bucket: KTLO status: backlog type: housekeeping
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 88/100
netbox-community/netbox-scripts#281 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
app: scripts Bucket: Improve complexity: low status: backlog type: feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
netbox-community/netbox-scripts#244 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Correct the documentation of a Project's current revisionCó thể đã có người làm @pheus đã nhận hôm nay. Đang mởapp: scripts Bucket: KTLO status: accepted type: documentation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
netbox-community/netbox-scripts#233 · 1 người được giao ·
Maintainer thường phản hồi trong vòng 1 ngày
-
app: scripts complexity: medium status: backlog type: feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 64/100
netbox-community/netbox-scripts#229 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
app: scripts status: backlog type: housekeeping
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
netbox-community/netbox-scripts#228 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của netbox-community/netbox-scripts
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
plone/plone.observability#114 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:docs type:docs
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
jejjohnson/gauss_flows#246 ·
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 78/100
openvax/varcode#824 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Add SAS as a cable typeĐang mởnetbox status: needs triage type: feature
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
netbox-community/netbox#23868 ·
Maintainer thường phản hồi trong vòng 2 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
emeryberger/CSrankings#15757 ·
Maintainer thường phản hồi trong vòng 9 ngày