Final acceptance: Консольная утилита поиска и скачивания изображений для вызова ИИ-агентом #18
Merged
ai-reviewer
merged 12 commits from 2026-11-03 02:51:14 +00:00
task/1-task into master
Labels
Clear labels
auto:allowed
claim:active
needs:architecture
role:architect
role:developer
role:product-manager
role:reviewer
role:team-lead
role:tester
status:accepted
status:blocked
status:done
status:draft-acceptance
status:draft-development
status:idea
status:in-architecture
status:in-development
status:in-lead
status:in-review
status:in-test
status:needs-development
status:needs-test
status:proposed
status:ready-for-architecture
status:ready-for-development
status:ready-for-lead
status:ready-for-test
status:waiting-for-acceptance
status:waiting-for-dependency
type:bug
Autonomous agents may claim this issue when role and status labels match.
A non-expired agent claim exists in issue or pull request comments.
Requires architecture planning before implementation.
Turns architecture-marked proposals into ADR-like plans and lead-ready follow-up work.
Implements code and tests, opens PRs, and fixes CI failures.
Creates product proposals from ideas and feedback.
Reviews diffs, tests, CI reports, and returns or accepts work.
Clarifies scope, decomposes tasks, and gates development readiness.
Runs final product acceptance and creates developer bug follow-ups.
Work passed review and can be reported or merged by the outer workflow.
Automation cannot continue without human input.
Workflow item is complete.
Teamlead-agent has created a final acceptance task draft that is not claimable yet.
Teamlead-agent has created a developer task draft that is not claimable yet.
Raw user idea or feedback that has not been shaped yet.
Architect is writing an ADR-like plan or lead follow-up.
Developer is implementing or fixing the task.
Teamlead-agent is decomposing architecture into developer work.
PR is ready for review after CI/deploy feedback.
Tester-agent is running final product acceptance.
Review or CI found issues that must return to development.
Work needs final acceptance testing or retesting.
Product proposal exists, but it is not ready for development.
Proposal needs architecture review before team lead planning.
Task is scoped and may be assigned to a developer.
Proposal is ready for technical planning.
Merged product work is ready for final tester acceptance.
Final acceptance is waiting for all implementation dependencies to complete.
Task is scoped but cannot be claimed until prerequisite child tasks are complete.
Broken or incorrect behavior.
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: projects/product-54354138-1#18
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Acceptance issue: #10
Product issue: #1
Base branch: master
Task branch: task/1-task
Tester Summary
Final product acceptance of
task/1-task(product-54354138-1 image toolkit) passes: every effective requirement R1–R11 and every acceptance criterion AC-001…AC-011 is backed by observed evidence, including live end-to-end runs against the real Wikimedia Commons source. Facade commands (validate / test / smoke / help) succeed; branch is clean, in sync with origin, and the provisioned protected files are byte-identical to the contract hashes.What I verified directly (not just from the shipped tests):
• Interface & delivery (R1, R11, AC-009):
python3 -m tools.example --helpexits 0 and exposes topic, width, height, format, source, count, --download, --output-dir, --resize; the tool runs on the plain system interpreter with no third-party runtime deps, and there is no Docker/compose/container artefact anywhere in the tree.• Machine-readable result (R2, AC-001): every run emits exactly one JSON document with
status,source,request,items,error, and exit code equal to the status (ok 0, invalid_request 2, no_format 3, no_size 4, access_error 5). Live item carried source, url, format=png, width=128, height=128, size_bytes.• Credential-free (R3, AC-002): no credential/env reads in
tools/; the live search and downloads succeeded anonymously (only proxy vars present in the environment).• Source selection (R4, AC-003): two adapters registered (
openverse,wikimedia_commons);--source nope→ invalid_request/exit 2 withavailable_sourceslisting both; the used source is echoed insourceand per item.• Topic/count (R5): topic drives the query;
--countbounds the returned items (observed 1 item for count=1, and count is translated into source page limits).• Size contract (R6, R8, AC-005/AC-006): only images ≥ requested width AND height are kept; a 100×80 PNG and a 96×96 ICO were rejected for a 400×300 request, producing
no_size/exit 4 distinct fromno_format/exit 3 andaccess_error/exit 5; each reported item carries its real pixel size read from its bytes.• Format contract (R7, AC-004): JPEG bytes served under a PNG request were rejected as a format mismatch (no_format, exit 3); a real ICO candidate produced
okwith ICO dimensions and a stored file that parses as ICO (\x00\x00\x01\x00directory).• Download (R9, AC-007), live:
--download --output-dirwrote/tmp/acc/live1/001-file-nuvola-apps-fsview-png.png, the path initems[].download.pathexists and the bytes are a real 128×128 PNG.• Resize (R10, AC-008), live: the same request with
--resizestored a 64×64 PNG (requested size) withresize.applied=true, while the run without the flag stored the untouched 128×128 original;--resizenever enlarges.• AC-010 (live source, known topic):
--topic "Nuvola icons" --width 64 --height 64 --format png --count 2returnedstatus: ok, exit 0, non-empty list with a working upload.wikimedia.org URL and real dimensions.• AC-011 (blocked access): a non-approved destination (host allowlist refusal) and a transport-level connection refusal both produce
status: access_error, exit 5,error.code=candidate_unreadable, zero items — never a success-looking result. A 429/HTTP-error source also maps to access_error/exit 5.• CI/facade:
python -m compileall tools testsexit 0,pytest163 passed/1 skipped in 20.84s,python -m tools.example examples/input.jsonexit 0 (dry_runenvelope),--helpexit 0;.gitea/workflows/ci.yamlruns restore/validate/test/smoke/help stages;.agent/project.yamland the workflow file match the provisioned SHA-256 hashes.Residual (noted, not a requirement breach): the shared egress proxy rate-limits upload.wikimedia.org intermittently (HTTP 429), which is why the repository's live test skipped once in the CI run; retried spaced-out live runs succeeded and were recorded here. In the mixed case where most candidates are unfetchable but one candidate is a different format, the tool reports
no_formatand disclosesunreadable_candidatesinerror.details; a full outage (no candidate fetchable, as tested) correctly yieldsaccess_error. This matches the documented status rules and keeps the four outcome classes distinguishable.python3 -m compileall tools testsexit 0;python3 -m tools.example examples/input.jsonexit 0 printing {"status":"dry_run",...};python3 -m tools.example --helpexit 0 listing -t/--topic, --width, --height, -f/--format, -s/--source, -c/--count, --download, -o/--output-dir, --resize..venv/bin/python -m pytest -q→ 163 passed, 1 skipped in 20.84s (the single skip is the live-source case, reported as an explicit unresolved skip with the 429 reason).python -m tools.example --topic "Nuvola icons" --width 64 --height 64 --format png --count 2→ exit 0, status ok, item {source: wikimedia_commons, url: https://upload.wikimedia.org/wikipedia/commons/e/ec/Nuvola_apps_fsview.png?..., format: png, width: 128, height: 128, size_bytes: 6884}.--download --output-dir /tmp/acc/live1→ status ok, reported path exists, bytes start with the PNG signature and IHDR reads 128x128 (matches reported width/height).--resizestored001-file-nuvola-apps-fsview-png.pngwith IHDR 64x64 and download.resize {applied: true, from 128x128, to 64x64}; the run without the flag stored the unchanged 128x128 original.python -m tools.example --topic fox --format png --source nope→ exit 2, invalid_request, error.code=source_unknown, details.available_sources=["openverse","wikimedia_commons"]; output also echoes the used source.grep -rn 'environ|getenv' tools/finds no credential/env access; live search and file downloads succeeded with only HTTP(S)_PROXY/NO_PROXY set and no API key or token.--downloadwithout--output-dir→ exit 2, error.code=request_field, details.field=output_dir; and--format jpg→ exit 2, error.code=request_format_unsupported.python3 -m tools.example ...on the system interpreter with zero runtime third-party dependencies (pyproject dependencies = []).git status --porcelainclean;git rev-list --left-right --count origin/task/1-task...HEAD= 0 0.Deterministic finalization passed: Tester evidence, exact head SHA, branch contract, CI, mergeability, and provisioned control-file digests are valid.