Test invalid positive-integer environment settings
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ó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức phù hợp với người mới
- 72/100
Hướng nghiên cứu
Tìm MAX_FILE_SIZE trong repository và trước tiên đọc phần phân tích cấu hình của nó cùng các test lân cận. Bổ sung coverage tập trung cho các giá trị hợp lệ, không phải số nguyên, bằng không và âm; được coi là hoàn thành khi các thiết lập không hợp lệ tạo ra lỗi cấu hình rõ ràng và các thiết lập hợp lệ vẫn tiếp tục hoạt động.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
AUT-02 · Authentication and configuration
Difficulty: intermediate · Status: ready
This is a focused contribution against current main. No unmerged feature PR is required.
Why this is useful
positive_int validates values but parsing errors are not covered
Start here
Source audit: 9d8ac3e01df1. Read these files on current main too, because paths may change after the audit:
Scope and intended output
Add the focused test file tests/roadmap/auth/test_numeric_settings.py. Change runtime code only if the acceptance criteria explicitly request a behavior fix; otherwise report newly discovered behavior separately.
Acceptance criteria
- Cover zero, negative, noninteger, and valid values for all numeric settings
- Run import-sensitive cases in isolated subprocesses
- Assert no model or provider work occurs
Verification
uv run pytest tests/roadmap/auth/test_numeric_settings.py -q
uv run pylint app tests
Create the named focused test file before running its command. Tests must be deterministic, mock external services, and avoid paid calls. Run bash scripts/check.sh before submitting a Python change.
Dependencies
None. Keep the PR based on current upstream main.
Out of scope
- Unrelated refactors, broad formatting, endpoint renames, or extra dependencies without agreement.
- Live cloud provisioning, paid model calls, real private messages, or credentials in fixtures/logs.
- Implementing neighboring roadmap issues in the same PR.
Getting help and submitting
Comment with your intended approach and ask when expected behavior is unclear. Check for an existing PR before starting; there is no deadline for a volunteer contribution. A useful reproduction or partial finding is welcome.
Use the issue's criteria as the review checklist. Include the commands actually run and any limitations. Link the issue; use Fixes only when its entire agreed scope is complete. If CONTRIBUTING.md is not yet on main, the contributor-roadmap PR provides the onboarding guide.
Original issue before the source audit (historical context)
Problem
MAX_FILE_SIZE is parsed directly with int(), so invalid, zero, or negative values produce confusing startup or runtime behavior.
Acceptance criteria
- Reject non-integer values with a clear configuration error.
- Reject zero and negative values.
- Add focused tests for valid and invalid configuration values.
- Ngôn ngữ chính
- Python
- Star
- 3
- Fork
- 10
- Merge trung bình
- 8 giờ 46 phút
- Pull request đã merge (30 ngày)
- 16
Chuẩn bị môi trường
Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. 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 ashrafee-dev/scamshield-api
-
area:testing contributor-roadmap difficulty:intermediate help wanted status:ready
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
ashrafee-dev/scamshield-api#291 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:docs contributor-roadmap difficulty:beginner documentation good first issue help wanted status:ready
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 84/100
ashrafee-dev/scamshield-api#287 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:docs contributor-roadmap difficulty:beginner documentation good first issue help wanted status:ready
Độ khó 2/5 Nửa ngày Mức phù hợp với người mới 84/100
ashrafee-dev/scamshield-api#286 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:docs contributor-roadmap difficulty:beginner documentation good first issue help wanted status:ready
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
ashrafee-dev/scamshield-api#285 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:docs contributor-roadmap difficulty:beginner documentation good first issue help wanted status:ready
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
ashrafee-dev/scamshield-api#283 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của ashrafee-dev/scamshield-api
Issue tương tự
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
ansys/pyansys-common-mcp#213 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100
freedomofpress/dangerzone#1594 ·
Maintainer thường phản hồi trong vòng 3 ngày
-
priority:P1 status:in-review type:bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
randomparity/kdive#3317 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area:ci
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 90/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 66/100
mesonbuild/meson#16281 ·
Maintainer thường phản hồi trong vòng 1 ngày