Refs #426: Document no-ledger account empty state#538
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughDocumentation clarifying the API response for valid account identifiers with no ledger entries was added to ChangesAccount empty response documentation
Possibly related PRs
🚥 Pre-merge checks | ✅ 6✅ Passed checks (6 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
Juanpablo24-06
left a comment
There was a problem hiding this comment.
Reviewed the doc-only change against the live account API and the local docs checks. The new empty-account example matches the current public response shape for github:mw-smoke-no-ledger-20260527: the account endpoint returns HTTP 200 with exists=false, balance_mrwk="0", zero/null accepted-work summary fields, and the accepted-work endpoint returns an empty list with the same zero summary.
Local validation on this PR branch:
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ./.venv/bin/python -m pytest tests/test_docs_public_urls.py::test_api_examples_document_account_response_shape -q-> 1 passedPYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ./.venv/bin/python scripts/docs_smoke.py-> docs smoke ok./.venv/bin/python -m ruff check tests/test_docs_public_urls.py docs/api-examples.md-> All checks passed
This looks like a narrow, accurate #426 docs addition to me.
adliebe
left a comment
There was a problem hiding this comment.
Reviewed PR #538 at current head 2950178e9fe7cf36c880e397a08b5a0f95174a3b as non-author adliebe.
I do not see a blocker. This is a docs/test-only change, so I checked it against the implemented account surfaces and live public behavior rather than only reading the Markdown.
Evidence:
- Inspected
docs/api-examples.mdandtests/test_docs_public_urls.py; the new example documents the no-ledger account asexists=false,balance_mrwk="0",accepted_awards=0,accepted_mrwk="0", and no latest proof fields. - Inspected
app/accounts.pyandapp/templates/account.html; the API, accepted-work endpoint, and HTML page use the empty accepted-work helpers, so a valid GitHub account with no ledger row keeps the stable zero/empty shape while the page shows the no-ledger empty state. - Live public readback for
github:mw-smoke-no-ledger-20260527returned account APIexists=false,balance_mrwk="0", accepted-work summaryaccepted_awards=0/accepted_mrwk="0", zero accepted-work rows, and HTML HTTP 200 with the no-ledger text.
Validation:
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 ..\mergework\.venv\Scripts\python.exe -m pytest tests/test_docs_public_urls.py::test_api_examples_document_account_response_shape tests/test_account_routes.py::test_registered_account_routes_preserve_api_and_page_shapes tests/test_api_mcp.py::test_account_api_rejects_empty_account_path tests/test_api_mcp.py::test_account_api_keeps_schema_when_accepted_work_proof_is_malformed -qpassed, 4 tests...\mergework\.venv\Scripts\python.exe scripts\docs_smoke.pypassed...\mergework\.venv\Scripts\ruff.exe check tests\test_docs_public_urls.py tests\test_account_routes.py tests\test_api_mcp.py app\accounts.pypassed...\mergework\.venv\Scripts\ruff.exe format --check tests\test_docs_public_urls.py tests\test_account_routes.py tests\test_api_mcp.py app\accounts.pypassed.git diff --check origin/main...HEADpassed.
Verdict: approved. The docs now describe the actual empty-account behavior without adding payout, wallet-secret, off-ramp, liquidity, or private-account claims.
weilixiong
left a comment
There was a problem hiding this comment.
APPROVED — Clean docs-only change documenting no-ledger account empty state. +28/-0, new JSON example + test assertions. Refs #426.
weilixiong
left a comment
There was a problem hiding this comment.
APPROVED — Clean docs-only change documenting no-ledger account empty state. +28/-0, straightforward explanation. No code changes.
|
Reviewed PR #538 at Evidence checked:
Validation:
Assessment: no blocker found in this docs/test slice. The change is narrow, matches the implemented public account behavior, and avoids adding price, liquidity, exchange, bridge, off-ramp, private-key, or fabricated payout claims. |
Bounty #426
Summary
exists: false, zero balance, and empty accepted-work fields.tests/test_docs_public_urls.py.Evidence
GET https://api.mrwk.ltclab.site/api/v1/accounts/github:mw-smoke-no-ledger-20260527-> HTTP 200 JSON withexists=false,balance_mrwk="0", and accepted-work zero/null fields.GET https://api.mrwk.ltclab.site/api/v1/accounts/github:mw-smoke-no-ledger-20260527/accepted-work-> HTTP 200 JSON with summary zero andaccepted_work=[].GET https://mrwk.ltclab.site/accounts/github:mw-smoke-no-ledger-20260527-> HTTP 200 HTML showing0 MRWK, "This account has no ledger activity yet.", "No proof-backed accepted work for this account yet.", and "No ledger entries yet."account_api_context,account_accepted_work_context, andaccount_page_contextinapp/accounts.py.Validation
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 .venv312/bin/python -m pytest tests/test_docs_public_urls.py::test_api_examples_document_account_response_shape -q-> 1 passedPYTEST_DISABLE_PLUGIN_AUTOLOAD=1 .venv312/bin/python -m pytest tests/test_docs_public_urls.py -q-> 23 passedPYTEST_DISABLE_PLUGIN_AUTOLOAD=1 .venv312/bin/python scripts/docs_smoke.py-> docs smoke ok.venv312/bin/python -m ruff check tests/test_docs_public_urls.py-> passedgit diff --check-> cleanNo private keys, seed material, cookies, OAuth state, access tokens, signatures, secrets, price claims, liquidity claims, exchange claims, bridge promises, off-ramp promises, or fabricated payout claims are included.
Summary by CodeRabbit
Release Notes