Repository navigation
fix(research-edition): patch both aw-qt port fallbacks - #1584
TimeToBuildBob wants to merge 2 commits into
Conversation
aw-qt#144 added a second `default_port = 5666 if is_testing(profile) else 5600` fallback in `dashboard_auth`, alongside the existing one in `_read_server_port`. The patcher's exact-substring match then found two copies and refused to build, so the nightly `[latest submodules]` release went red for every Qt leg while the pinned tree still had one copy. Match the expression without indentation and allow one or two occurrences, rewriting every one of them: the pinned aw-qt has only `_read_server_port`, the upstream tip has both. `dashboard_auth` compares a config file's port against the live one and the generated research config leaves `port` commented out, so it must fall back to 5667 too or the tray opens an unauthenticated dashboard against the research server. A count outside the declared set still aborts, so a future third copy cannot slip through unpatched. Git-Session-Id: a478cc17-38ae-55f2-aed4-9ebb5029dcde
|
What changed: 2 files, +74/-7 in Review guideKey files
Suggested verification
Auto-posted by |
[Medium impact] The PR appears safe to merge, with two non-blocking findings from the previous review still open. FindingsSummaryThe patcher now accepts one or two copies of the Qt port fallback and rewrites every accepted copy to use port 5667.
Reviews (2) · Last reviewed commit: "fix(research-edition): patch both aw-qt ..." · Reviewed by Greptile |
Git-Session-Id: 032ccdc3-dbca-5df5-ae18-103dd80fd43d
🤖 AI code reviewAdds a Safe to merge — no P0/P1 findingsConfidence 5/5 ✅ No thread-worthy findings. Advisory notes follow; they are retained without opening review threads. 1 advisory finding (summary-only, not scored)These P2 guard, heuristic, trade-off, or documentation claims are retained for judgment without opening review threads.
With How this was verified: In Files changed (2) — the diff as I read it
Reviewed Maintainer commands
|
Review findings addressed — maintainer handoff
Recommendation: no reported finding remains to fix; await current-head CI/review evidence, then maintainer judgment. No merge performed. |
What
scripts/patch_research_edition_profile.pyrefuses to build when a patch target is ambiguous. aw-qt#144 added a second copy of the port fallback:in
dashboard_auth(), next to the existing one in_read_server_port(). The patcher's 4-space-indented target string then matched both (it is a substring of the 12-space copy), so the nightly[latest submodules]run failed every Qt leg with:Nightly run: https://github.com/ActivityWatch/activitywatch/actions/runs/45932774740
Fix
counts=(1, 2)on the patch: the pinned aw-qt (c31456c) has only_read_server_port, the upstream tip has both call sites. Every allowed occurrence is rewritten; any other count still aborts, so a future third copy cannot slip through unpatched.dashboard_authmatters for the research build: it compares a config file'sportagainst the live one, and the generated research config is written with every value commented out, so its own fallback must be 5667 or the tray opens an unauthenticated dashboard against the research server.Verification
patch_research_edition_profile.py qt --checkpasses against aw-qt at the pinned SHA and at the upstream tip (c825b78).patch_research_edition_profile.py tauri --checkpasses.pytest scripts/tests/test_patch_research_edition_profile.py— 38 passed, including two new tests for the multi-site count (rewrites both copies; a third copy fails closed).No submodule pins changed.
Note: the pr-overlap guard flagged #1576 because it also touches these two files. The changes are independent (that one is the Windows uninstall Run value, this one is the aw-qt port fallback), and they sit in different regions, so I opened this separately rather than stacking an unrelated fix onto a packaging PR.