Skip to content

Add FedEx WebHarbor mirror - #50

Open
Lxr-max wants to merge 1 commit into
aiming-lab:mainfrom
Lxr-max:add-fedex-site
Open

Add FedEx WebHarbor mirror#50
Lxr-max wants to merge 1 commit into
aiming-lab:mainfrom
Lxr-max:add-fedex-site

Conversation

@Lxr-max

@Lxr-max Lxr-max commented Jun 4, 2026

Copy link
Copy Markdown

Summary

Implementation summary

This PR adds a self-contained FedEx-style logistics mirror under sites/fedex/ with Flask, SQLAlchemy, SQLite, Jinja templates, local CSS/JS, deterministic SVG visuals, seeded tracking timelines, rate estimates, shipment creation, pickup scheduling, invoices, claims, support content, and account flows.

Selected WebSyn port: 40015

Seed row counts

  • users: 4
  • service_levels: 5
  • locations: 15
  • pickup_slots: 45
  • shipments: 60
  • tracking_records: 72
  • tracking_events: 360
  • invoices: 60
  • claims: 12
  • support_articles: 18
  • pickup_requests: 8
  • search_logs: 3+

Benchmark users

Task count and categories

  • 18 tasks in sites/fedex/tasks.jsonl
  • Categories: single-package tracking, multi-package tracking, support/help lookup, rate estimate comparison, location search, mock shipment creation, pickup scheduling, account shipments, invoices, claims, and global search.

Key routes

  • /, /home
  • /track, /track/results, /tracking/<tracking_number>
  • /rate-estimate
  • /ship, /ship/service, /ship/review, /ship/confirmation
  • /pickup
  • /locations, /locations/<location_slug>
  • /support, /support/<article_slug>
  • /search
  • /login, /register, /logout
  • /account, /account/edit, /account/shipments, /invoices, /claims

Verification commands and results

  • py -3 -m py_compile sites/fedex/app.py sites/fedex/seed_data.py sites/fedex/_health.py -> passed
  • py -3 sites/fedex/seed_data.py -> generated deterministic instance_seed/fedex.db and local SVG assets
  • local Flask test-client smoke for homepage, search, login, ship flow, pickup, invoices, and claims -> passed

Docker result

  • docker build -t webharbor:fedex-pr . -> passed
  • Test container: webharbor-fedex-submit
  • Host ports used for verification: 8301 -> 8101, 43000-43015 -> 40000-40015
  • Control plane health -> passed, all 16 registered sites alive

Smoke test result

  • HTTP 200 on /, /home, /track, /track/results, /rate-estimate, /locations, /support, /search?q=delay, /login
  • HTTP flows passed for login/logout, multi-number tracking, shipment creation, shipment confirmation, pickup scheduling, shipment history, invoices, claims, support search, and location search
  • Example generated confirmation values after reset: shipment SH-260061, tracking FDX260000061, pickup PU-2609

Reset + MD5 result

  • POST http://localhost:8301/reset/fedex -> ready: true
  • docker exec webharbor-fedex-submit md5sum /opt/WebSyn/fedex/instance/fedex.db /opt/WebSyn/fedex/instance_seed/fedex.db -> both hashes matched
  • MD5: ea65ea7d0ec6f17af8229806ed8c4317
  • Container restart check also passed; control plane and FedEx homepage still returned healthy / 200

Screenshot paths

Local review-only screenshots were captured at:

  • sites/fedex/scraped_data/submission_review/home.png
  • sites/fedex/scraped_data/submission_review/track.png
  • sites/fedex/scraped_data/submission_review/track_results.png
  • sites/fedex/scraped_data/submission_review/tracking_detail.png
  • sites/fedex/scraped_data/submission_review/rate_estimate.png
  • sites/fedex/scraped_data/submission_review/locations.png
  • sites/fedex/scraped_data/submission_review/support.png
  • sites/fedex/scraped_data/submission_review/login.png
  • sites/fedex/scraped_data/submission_review/mobile_home.png

HF asset status

Known limitations

  • Visual assets are deterministic local SVGs, not official FedEx artwork.
  • No real shipment booking, pickup scheduling, claims filing, address validation, or carrier API integration.
  • scripts/check_assets.sh / scripts/fetch_assets.sh use CRLF-sensitive bash entrypoints in this Windows checkout, so I followed the documented asset workflow with equivalent manual hf/tar commands in PowerShell when needed.
  • Logged-in account screenshots were not captured with full browser automation; those routes were verified via real HTTP smoke instead.

Manual review notes

  • The branch also updates repo-level site counts, exposed port range, and internal skill docs from 15 sites to 16 sites.
  • Runtime artifacts, screenshots, local caches, and HF-managed heavy assets were intentionally left out of the git commit.
  • This is a new website contribution, not a tooling-only PR.

@Susan571

Copy link
Copy Markdown

Review — Add FedEx WebHarbor mirror (#50)

Verdict: Request changes (one blocker), then Approve. The code is correct and the full
runtime suite passes once assets exist; the only blocker is the missing HF asset upload.

Mechanical

  • Registration synced in all 3 places (websyn_start.sh, control_server.py,
    Dockerfile EXPOSE 40000-40015). Nice extras: CRLF-strip on entrypoint and SITE_COUNT
    parametrized readiness loop. py_compile OK.
  • Blocker: ./scripts/build.sh fails at check_assets.sh
    MISSING (required): sites/fedex/instance_seed. No fedex.tar.gz exists on
    ChilleD/WebHarbor@main and .assets-revision isn't bumped. Please generate
    instance_seed/fedex.db, pack fedex.tar.gz, upload to HF, and bump .assets-revision.
  • ✅ After I generated the seed locally and built the 16-site image: all 16 sites → 200,
    /reset/fedex is byte-identical (md5 matches instance_seed), /reset-all parallel
    in ~1.1s. Seed is idempotent.

Visual fidelity: PASS

Correct FedEx purple branding, nav, and a full tracking timeline (screenshot:
fedex_track.png). Text/logo site — no product photography needed. (Live FedEx is
bot-walled, so a literal side-by-side isn't possible; IA matches the upstream tracking flow.)

Functional depth: PASS

Tracking shows the delay reason; support search resolves the exception article; /account/*
correctly 302-gate when logged out; login as alice.j@test.com works and account
shipments/invoices/claims load.

Task quality: 18/18 PASS

All entities verified present (5 tracking numbers, 4 seeded users, named locations/articles).
Tasks are genuinely multi-step (auth → account drill-down; create-shipment and
schedule-pickup are ≥5 steps) with good near-miss distractors. Task web URL :40015
matches the registered port. No answer leaks observed.

Required before approval: upload the FedEx asset tarball to HF + bump .assets-revision.

@jackjin1997

Copy link
Copy Markdown
Contributor

Claiming this PR for the end-to-end WebHarbor review completion pass. I will build from this branch, rerun the human environment and task checks, resolve the HF asset and revision blocker, update the tasks where needed, add deterministic verifiers and judge rubrics for all 18 tasks, validate them against agent trajectories and an independent fresh strong-model review, then open a new Review: fedex PR and link it here. Please avoid duplicating this review while I work on it.

@jackjin1997

Copy link
Copy Markdown
Contributor

End-to-end review update — S1 environment QA

I reran the review on a current-main integration while preserving the contributor commit (1c1dd02) and moving FedEx to the current 17th-site slot (40016). The runtime asset pair was frozen to current baseline 54882a6 plus the exact FedEx HF candidate commit c6d0c54 (archive SHA-256 09678e01efa2331f4a2262df3fd388e92afb0aa048e38512304b6b9a050dec38).

Mechanical checks: pass

  • 17/17 site homepages returned HTTP 200.
  • Control-plane health was green for 17/17 sites before and after reset-all.
  • /reset/fedex restored the DB byte-identically (ea65ea7d0ec6f17af8229806ed8c4317 on both runtime and seed DBs).
  • Native-container reset-all runs completed in 8.75s, 6.49s, and 6.43s, all 17/17 ready.
  • Real Chromium passed top-level navigation, seven populated detail pages, 768px responsive layout, multi-package tracking, three searches (including multi-word), valid rate quotes, auth, registration/re-login, account edit persistence, shipment creation, and pickup creation.

Changes required before S1 can pass

  1. Four HF SVG assets are invalid XML and fail to render. Literal & characters need to be escaped in:

    • location-bellevue-office-wa.svg
    • location-los-angeles-arts-ca.svg
    • location-miami-brickell-fl.svg
    • location-washington-navy-yard-dc.svg

    Chromium visibly shows a broken Bellevue image on the homepage, and xmllint rejects all four.

  2. Malformed rate weight returns HTTP 500. float(form_state["weight_lb"]) at sites/fedex/app.py:438 raises ValueError; the form should return a visible validation error instead.

  3. Malformed pickup package count returns HTTP 500. int(request.form.get("package_count", "1")) at sites/fedex/app.py:628 raises ValueError; this also needs user-visible validation.

  4. The required CRUD-remove check is not implementable. After creating shipments and pickup requests, the UI exposes no remove/delete/cancel action. Please add an appropriate deterministic cancellation/removal workflow and persistence check.

The live FedEx page returned a branded FedEx | System Down permission page, so detailed side-by-side upstream comparison was limited; the accessible brand palette and overall feel were still checked. I used the Dockerfile's exact base and dependency pins with native container DBs and read-only extracted static assets; the full copied-asset image build remains to be rerun after the fixes.

Per the earliest-incomplete-gate rule, I am stopping at S1_ENV_QA: I have not accepted the 18-task contract, authored verifiers/rubrics, or started agent trajectories yet. Once the code and HF assets are updated, I will rerun the complete S1 checklist before proceeding.

@jackjin1997

Copy link
Copy Markdown
Contributor

Reviewer-owned repair is now in progress per maintainer direction; no contributor handoff is needed.

The remaining S1 gate is the official full Docker image build and 17-site reset/health rerun. I will link the separate Draft Review: fedex PR once the review artifacts and gates are complete.

@jackjin1997

Copy link
Copy Markdown
Contributor

The reviewer-owned follow-up is now open as Draft: #82

It preserves @Lxr-max attribution and branch history, contains the environment/task/verifier repairs, and pins the exact paired HF candidate from https://huggingface.co/datasets/ChilleD/WebHarbor/discussions/50. S1-S4 have passed; I am continuing with the independent blind review and reconciliation before marking it Ready.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants