feat(4shared): add 4shared mirror - #90
Conversation
Final contributor-side review — 4sharedReviewed code head: Result
Remediation covered
Full evidence and screenshots: Pending integration step only: merge HF assets PR #62, then update This comment records contributor-side audit evidence; maintainer approval remains separate. |
|
Taking ownership of the review for this PR (Track B). Plan: build and drive the mirror per the |
…iming-lab#93 aiming-lab#39 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01AkNTAZMziDodR6uqa6QBtP
Review: 4shared (PR #90) — site by @sarendis56, verifiers by reviewerVerdict: APPROVE, conditional on one release-mechanics item (HF #62 merge + Reviewed standalone on the review server (Flask app booted exactly as 1. Mechanical checks — PASS (standalone + full Docker environment)
2. Visual fidelity — PASS
Screenshots: 3. Functional depth — PASS (every path below driven with Playwright; DB writes confirmed)
Screenshots: 4. Task quality — PASS (20/20 accepted; 2 reworded)All catalog facts are synthetic (fictional uploaders "Open Culture Shelf", "Atlas Media Lab", …; invented durations / page counts / versions), so no task is answerable from prior knowledge; answers are stable (fixed
Difficulty: all 20 need ≥ 5 actions; 5 / 17 / 18 / 19 need multi-page comparison or chained actions; 17 (four dependent mutations) and 18 (three pages + login + save) would challenge a frontier agent. After the task-2 re-anchor no task is solvable by clicking the first result. 5. Required fixes before approval
6. Grading contract (reviewer deliverable,
|
| task | exact persisted delta required |
|---|---|
| 6 | +1 downloads (file 81), download_count +1 on 81 only |
| 7 / 8 | +1 favorites (alice, 38) / +1 saved_files (alice, 97); not pre-existing |
| 9 | alice users row: location, bio only, exact values; other users untouched |
| 10 | +1 folders (bob, parent NULL, "Survey Exports") |
| 11 | +1 files (carol, folder 9 Work, exact name, 655360 B, exact description, private, Documents) |
| 12 | file 123: filename/extension/folder_id(3)/modified_at only |
| 13 | file 146: deleted 1 → 0 only |
| 14 | +1 shared_links (alice, 125, download, "Audio volunteers") |
| 15 | +1 comments (bob, 93, exact body) |
| 16 | +1 plan_orders (bob, Premium 100 GB, annual, 77.88, 4242); bob plan/storage_limit_mb only |
| 17 | +1 folder, +1 file (final name, in it, 393216 B, private), +1 view link on it; folder ≤ upload ≤ rename ≤ link timestamps |
| 18 | +1 saved_files (david, 90) after all three detail pages |
| 19 | +1 favorites + 1 downloads (alice, 96), download_count +1 on 96 only |
7. Validation matrix (CONTRIBUTING §C; verify/tests/)
drive_tasks.py boots the site from instance_seed/ for each task, drives it with Chromium and writes agent.py-shaped run dirs (trajectory + screenshots + initial.db/after.db); run_matrix.py derives the negative variants and runs every verifier with --no_llm True:
| variant | expected | result | first failing check (typical) |
|---|---|---|---|
| no-op — homepage only, empty answer, clean DB | FAIL ×20 | 20/20 FAIL | final_answer_nonempty |
| genuine Playwright run | PASS ×20 | 20/20 PASS | — |
| shortcut — correct answer + correct DB, every URL rewritten to the homepage | FAIL ×20 | 20/20 FAIL | searched_* / visited_detail_* / visited_login_page |
| wrong — wrong answer (0-5, 16, 18, 19) or wrong persisted row (6-15, 17) | FAIL ×20 | 20/20 FAIL | answer_has_*, download_row_added, target_favorited_for_alice, upload_private_documents, link_permission_download, … |
state-mismatch — genuine trajectory, after.db = seed |
FAIL ×14 (tasks 6-19) | 14/14 FAIL | *_exact_delta / target_* / file_restored |
agent_demo/eval_judge.py --run_dir <genuine run 7> --verifier True → pass: True success: True reason: all checks passed, exit 0; on the no-op → pass: False … reason: final_answer_nonempty. One verifier bug was found and fixed by this matrix: the comparison-claim reader split sentences on the "." inside …Seas.epub, failing the genuine task-18 run; now only sentence punctuation followed by whitespace splits.
8. Evidence (commands and outputs, condensed)
$ hf download ChilleD/WebHarbor 4shared.tar.gz --repo-type dataset --revision refs/pr/62
f50985a7ba74ba778b22583d1e64a228a9d650b9376509db29b87339e065ff0a tarball/4shared.tar.gz (commit f426447ee209071110a5de80026a72d049bbd97f)
$ python3 scripts/validate_asset_archive.py ../tarball/4shared.tar.gz 4shared
[fetch] validated 30 managed members for 4shared # junk members: none
$ python3 scripts/extract_asset_archive.py ../tarball/4shared.tar.gz sites 4shared
[fetch] installed managed roots for 4shared
$ md5sum instance_seed/4shared.db ; find static/images -type f | wc -l
b577adc216900a6f0e3974a80e51c04c / 23 (16 jpg + 6 ui svg + .gitkeep)
$ python3 -m py_compile sites/4shared/*.py && echo PYCOMPILE_OK -> PYCOMPILE_OK
$ rm -rf instance && cp -a instance_seed instance && python -c "from app import app; app.run(host='127.0.0.1', port=45004, ...)"
GET / -> 200 ; /_health -> {"files":122,"ok":true,"site":"4shared"}
$ md5sum instance/4shared.db instance_seed/4shared.db # boot 1, after read-only sweep, boot 2, boot 3
b577adc216900a6f0e3974a80e51c04c instance/4shared.db
b577adc216900a6f0e3974a80e51c04c instance_seed/4shared.db
$ md5sum instance/4shared.db # after the write-path pass (expected to differ)
4c7f337653bdb6e302508247d02d6c1a
$ sqlite3 seed: users 4 | folders 16 | files 146 (122 public) | favorites 16 | saved_files 12 | downloads 8 | shared_links 4 | comments 12 | plan_orders 1
$ uv run python survey_ro.py (Playwright, read-only)
category music 16 | video 16 | apps 21 | images 16 (16 imgs load, 0 broken) | books 21 | documents 16 | archives 16 | nope 404
search t0 Music n=7 target_pos=5 leaks=[] search t2 Books n=10 target_pos=1 (Pride and Prejudice) leaks=[]
search t3 n=11 pos=6 | t4 n=9 pos=2 | t6 n=6 pos=6 | t7 n=8 pos=6 | t19 n=40 pos=2 | "Boston Celtic" n=0 empty-state | leaks=[] on all
detail t0 id=13 'Atlas Media Lab' 'Duration 10:45 · 48 kHz WAV source · normalized to -16 LUFS.'
detail t1 id=55 'Open Culture Shelf' 'Resolution 3840 × 2160 · ISO 200 · exposure 1/80 s.'
detail t4 id=44 tags=['ZIP','5.8 MB','Apps','Open-source package'] 'Version 5.0.0 · WCAG contrast preview · GPL-3.0.'
detail t5 22 '27:03' / 29 '19:05' ; t6 81 '672 pages · 85 essays · searchable topic index.' ; t18 77 432/61, 73 412/38, 90 512/47 ; t19 96 '46 pages · 12-week … risk register on page 39.'
scrollWidth home_768=768 search_768=768 home_390=390
$ uv run python survey_rw.py (Playwright, write paths) -> every row in §3; bob on alice's private file/share: 404/404, own file 200
$ SITES consistency: shell==control: True | n = 25 | 4shared index 24 -> port 40024 ; EXPOSE 8101 40000-40024 ; # 25 Flask mirror sites
$ pytest -k "registry or docker or documentation or conflict or assets_pin" walmart_careers/tests rotten_tomatoes/tests -> 7 passed
$ uv run python sites/4shared/verify/tests/drive_tasks.py --python <venv> --port 45004 -> 20/20 tasks driven (5-20 steps)
$ uv run python sites/4shared/verify/tests/run_matrix.py -> table in §7 ; ALL EXPECTATIONS MET
$ curl https://huggingface.co/api/datasets/ChilleD/WebHarbor/tree/65c479f8… -> 27 files, 4shared.tar.gz: False (070123d7…: 26 files, False; refs/pr/62: present, 14209943 B; discussion 62: open)
9. Contributor self-audit (review-reports/PR-90-FINAL-AUDIT.md) — claims checked
Confirmed: 20/20 tasks drivable through the UI (my harness reproduces all 20); seed md5 b577adc2…; 122 public records across 7 categories; 16/16 real photographs; tasks 6/7 return 6/8 results with the target at position 6; all footer routes distinct and working; no overflow at 768/390. Not confirmed: "no first-item target" — the original task 2 target was result #1 (fixed by re-anchoring). The audit's screenshots are homepage-only by design; the task-level evidence lives outside the repo, so it was re-derived here rather than trusted.
10. Screenshots
All cited screenshots: https://github.com/JeremyJC67/WebHarbor/tree/pr-screenshots/reviews/4shared
| homepage 1440 px | Premium plans (task 16 ambiguity) |
|---|---|
![]() |
![]() |
| search "classic fiction" in Books — original task-2 target was result #1 | premium checkout confirmed (write path) |
|---|---|
![]() |
![]() |
Full index:
page_home.png, page_home_768.png, page_home_390.png, page_premium.png, category_images.png, category_books.png, search_t0_music_nature_ambience.png, search_t2_books_classic_fiction.png, search_t3_garden_planning.png, search_t6_federalist.png, search_t7_archivepeek.png, search_multiword_boston_celtic.png, detail_t0_target.png, detail_t1_target.png, detail_t4_target.png, detail_t6_target.png, fn_account_alice.png, fn_favorites_after_add.png, fn_saved_after_save.png, fn_my_files_work_after_move.png, fn_trash_after_delete.png, fn_share_after_create.png, fn_shared_page.png, fn_upload_result.png, fn_comment_after_post.png, fn_premium_confirmed.png, fn_account_bob_after_upgrade.png, fn_register_done.png.
Follow-up review —
|
| commit | what changed and why |
|---|---|
27c68e8 |
/premium/checkout 404s on a missing or unknown plan instead of defaulting to 100 GB; share permission and upload visibility/size are explicit and required, invalid input is 400; favourite / comment / share go through viewable_file_or_404; collision-safe upload slugs plus IntegrityError rollback and 400/500 pages; POST-only logout; monotonic Premium pricing (100 GB unchanged); dead homepage queries removed; id tiebreaker on category and related ordering |
964f282 |
the search category tabs render nav_categories, so Documents is reachable by tab |
74ce864 |
.dockerignore excludes review-reports/ — repo-level; 340 KB of review evidence was being COPYd into the image |
be21d83 |
the drive harness selects the now-required visibility field |
7bd9c80 |
.file-icon no longer renders white-on-white on /preview/<id> and /shared/<token>; the 320 px /my-files overflow; WCAG contrast 51 failing pairs → 0 |
Nothing in seed_data.py, tasks.jsonl or instance_seed/ was touched by this pass, so the seed md5 is
unchanged and the task set is the one you and the first review already agreed on.
4. Checks that came back clean, each with the mutation that turns it red
| check | result | mutation proof |
|---|---|---|
MAX_CONTENT_LENGTH |
a real 60 MB multipart → 413 | raise the cap to 256 MB → 200 |
| static-text leaks on list surfaces | none across 20 surfaces | render preview_text on cards → 10:45, 48 kHz, -16 LUFS appear |
| read-only routes do not write | md5 b577adc2… unchanged after three full sweeps |
make /search insert a row → md5 changes |
| cross-user authorization | 0 illegal rows | restore the old guard → 1 row, and the private name leaks |
| ordering is a total order | all 7 categories tie-free, order stable | force a download_count tie → the detector fires |
| upload form has no answer prefill | none | put value="640" back → it equals task 11's answer |
| grading matrix | 20 tasks × 5 variants, all expectations met | the matrix is itself the negative-sample suite |
| verifier ↔ recorder contract | no drift (ast-extracted: steps carry url; no url_after / final_url, already optional) |
— |
| answer-identifier grading | no ground_truth − question subtraction anywhere |
— |
| all 122 public files reachable by name search | no field-set mismatch between the two search routes | — |
| console / network at four widths | 0 broken images, 0 failed requests, 0 external requests, 0 dangling aria references | — |
| registry | control_server ≡ websyn_start (25 entries, index 24 → 40024), EXPOSE 40000-40024, 20 task rows on :40024, no answer key |
— |
5. Left for you to decide
- The ColorScope licence is stated twice and inconsistently — the catalog tag says "Open-source package"
while the notes say "GPL-3.0". A content call, so we left it. - Whether a user should be able to create a share link for a public catalog file they do not own. Plausibly
intended; unchanged. - The fixed
SECRET_KEYlets a forged cookie read/account. We did not change it here, because all
25 sites do the same thing — it is a maintainer-level decision, not yours.
6. Container re-verification of this branch (7bd9c80, full 25-site image)
Docker was unavailable to the audit pass itself; it has now been run. Assets from HF refs/pr/62.
| check | result |
|---|---|
docker build |
ok, 4.71 GB |
| HTTP sweep, alt ports 44000-44024 | 25/25 return 200 |
GET /health |
ok, 25/25 alive and ready, 4shared on internal 40024 |
POST /reset/4shared -> md5 instance vs instance_seed |
b577adc216900a6f0e3974a80e51c04c both |
| dirty request then reset | still b577adc2... |
docker restart then md5 |
still b577adc2... |
POST /reset-all |
ok, 25/25 ready, 1.46 s |
verifier no-op matrix, in-container DBs via docker cp |
20/20 FAIL, 0 errors |
walmart_careers / rotten_tomatoes registry + docs tests |
4 passed, 3,343 subtests |
review-reports/ inside the image |
confirmed absent from the image |
The fixes behave in the image as they did standalone:
GET /logout 405
POST /upload without a session or token 400
GET /no-such-page 404, 3029-byte branded page (was a bare Werkzeug page)
GET /login?next=https://evil.example/pwn redirect_url empty (not followed)
GET /account anonymous 302
search category tabs Documents present (3 matches on /search)
md5 before / after 6 read-only GETs (/, /search, 3 category pages, /premium)
b577adc216900a6f0e3974a80e51c04c / b577adc216900a6f0e3974a80e51c04c -> byte-identical
Two readings to be precise about rather than let them be carried forward as something they are not.
A 300 KB url-encoded body to /register returns 400, not 413: the new field validation rejects the
malformed body before any size limit is reached. The size cap itself is the separate measurement from the
audit, a real 60 MB multipart returning 413. And pytest sites/4shared inside the image collects nothing,
which is expected: this site's harness lives under verify/tests/, which .dockerignore keeps out of the
image on purpose. It runs from a checkout, where it is green.
Raw output of the in-image check:
ls: cannot access '/opt/review-reports': No such file or directory
ls: cannot access '/opt/WebSyn/4shared/verify/tests': No such file or directory
---
15M /opt/WebSyn/4shared
Tooling disclosureAdded after the fact, because it belongs in the public record and not only in our internal notes. The second-pass audit had a general-purpose LLM available to it as a judgment aid — used for For this site I have no record of it changing any conclusion; the findings above came from the probes and No call log was kept, so I cannot enumerate every consultation — that is the honest limit of this |




Summary
Adds a deterministic 4shared mirror as WebHarbor site 24 on port
40023.Review remediation
The final review pass replaces every reported placeholder/fidelity gap and fixes the adjacent workflows found during manual review:
Final per-task and hardening audit
Screenshots
Assets
f426447ee209071110a5de80026a72d049bbd97f4shared.tar.gzSHA-256:f50985a7ba74ba778b22583d1e64a228a9d650b9376509db29b87339e065ff0asites/4shared/ASSET_SOURCES.md.assets-revisionremains unchanged while HF feat(webmd): add WebMD mirror site (20 tasks, hardened) #62 is open. After it merges, this branch needs one follow-up commit pinning the immutable HF merge revision.Validation
sha256:82a343822f5c0622f1cdd92c4dd3f24e9658f889019396bb9394e2ede5054e0f(4,356,239,480bytes)./reset-allreturned 24/24 ready.b577adc216900a6f0e3974a80e51c04c.Seeded state
No GitHub or Hugging Face merge is performed by this contribution update.