fix(worker): restore registered lesson submissions - #1293
Conversation
Signed-off-by: hjqcan <hjqcan@163.com>
Welcome to MisakaNet!Thanks for your first PR! Fix DCO FirstEvery commit needs git commit --amend --signoff --no-edit
git push --force-with-leaseQuick Links
Optional: Local Pre-commit HookFor instant DCO validation before pushing: pip install pre-commit
pre-commit install --hook-type commit-msgFor Agents & CrawlersFound a missing lesson? Submit via MCP (no account needed): curl -sS https://misakanet.org/mcp \
-H 'Content-Type: application/json' \
-H 'MCP-Protocol-Version: 2025-06-18' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"misakanet_submit_intake","arguments":{"problem":"YOUR PROBLEM","source":"your-agent"}}}'CI runs automatically once DCO passes. |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
CI triage: the only red check is the full-repository |
|
@hjqcan This PR has merge conflicts with main. Please rebase: The fix itself (restoring GITHUB_API constants) looks correct. Once conflicts are resolved, this should be good to merge. |
|
/review |
PR Reviewer Guide 🔍(Review updated until commit 317d9e7)Here are some key observations to aid the review process:
|
git fetch origin
git rebase origin/main
# resolve conflicts
git push --force-with-lease |
|
Thanks — the stress-test additions are useful. One correction needed before merge: on current |
|
Heads-up: |
|
Maintainer check-in (2026-08-30): this PR currently shows mergeable=false / dirty — main has moved ahead since your branch (recent merges: data-pipeline fixes, intake E2E tests, Coogen borrowings). Could you rebase onto current main and re-push? All CI checks were green on your head commit, so once rebased it should be ready to merge. Happy to help if you run into rebase conflicts. |
|
/review |
|
Persistent review updated to latest commit 317d9e7 |
|
Automated review (pr-agent) flagged: the new KV-token test installs Also: PR is still mergeable=false (dirty) — main has moved ahead. Please rebase onto current main so we can merge (all CI checks were green on your head commit). |
|
Maintainer rebase check (2026-08-31): I rebased your branch locally onto current main — it rebases cleanly. The only conflict was in workers/register-proxy-sw.js: your branch inlines REPO/GITHUB_API/PUBLIC_DATA_BASE constants, but main now imports them from ./lib/handlers.js (same values). Keeping main's import resolves it; your docs + stress-test changes (the actual fix value) carry over intact. To update the PR: rebase your fork branch onto main and force-push: git fetch upstream main
git rebase upstream/main
git push --force-with-lease origin <your-branch>Worker tests pass (95/96) after the rebase. Once pushed, the PR becomes mergeable. |
Audit失败:多个测试失败问题MCP fallback相关测试失败,共7个测试失败。 失败测试解决方案需要检查MCP fallback逻辑是否正确。可能的原因:
验证修复后可以本地运行以下命令验证: tests/test_mcp_fallback.py::test_fallback_returns_results_instead_of_error PASSED [ 12%] ============================== 8 passed in 0.23s ============================== tests/test_mcp_deepseek_adapter.py::test_deepseek_recovery_smoke_passes PASSED [100%] ============================== 1 passed in 0.10s ============================== 修复后重新提交,audit应该会通过。 |
Summary
Root cause
A live synthetic registration confirmed that a fresh mcp_ token passes both the top-level Bearer check and the write_lesson KV lookup immediately. The request then failed later because commit fd5a541 removed GITHUB_API, REPO, and PUBLIC_DATA_BASE from register-proxy-sw.js without importing or redefining them. The resulting ReferenceError made every complete write_lesson submission fail even though token verification succeeded.
No real token or lesson was submitted during the live smoke test.
Validation
Node ID: hjqcan/goodmemory-maintainer
Closes #1240