Skip to content

Fix #437: too little flips sent - #455

Closed
ekwav-agent wants to merge 6 commits into
Coflnet:mainfrom
ekwav-agent:ekwav-agent/task_hf46jalpoquuph5544rq
Closed

ekwav-agent wants to merge 6 commits into
Coflnet:mainfrom
ekwav-agent:ekwav-agent/task_hf46jalpoquuph5544rq

Conversation

@ekwav-agent

Copy link
Copy Markdown
Contributor

Summary

I made a small fix in this repo, but it is not the main cause of issue #437. The main fix is still the unmerged Coflnet/SkyBackendForFrontend#122.

What I fixed. Services/Donut/DonutFlipSubscriptionService.cs had the same bug you traced in #122. When a player reconnects, the new socket gets the same connection ID as the old one. If the old socket closes afterwards, RemoveConnection removed the entry by ID only, which deleted the new socket's live subscription. Now it only removes the entry if it still belongs to the closing socket. The two places in DeliverAsync that drop a failed send got the same guard, so a failure on the old socket can't remove a new one registered in the meantime. This only affects Donut-server connections. The reporter was on Hypixel with prem+, which goes through FlipperService in SkyBackendForFrontend. The copy of that repo I cloned from its default branch still removes by ID only (FlipperService.cs:126), and the Dockerfile builds from that branch. Their flips only benefit once #122 is merged and this image is rebuilt.

Test. Services/Donut/DonutFlipSubscriptionService.Tests.cs registers an old and a new connection with the same ID, closes the old one, then delivers a Donut flip. It checks the new connection receives it exactly once.

  • With the original production file: fails on the assertion ("Expected invocation on the mock once, but was 0 times").
  • With the patch: passes. I ran the exact command in /workspace/.coflnet-regression.json and it passed. That command starts a dotnet/sdk:10.0 container, clones the same four dependencies as the Dockerfile, and runs only this test.
  • I didn't see any new compiler warnings from the changed files. I didn't run the full Docker build; that's left to the host gate.

Production evidence. None. observe report failed for both report IDs (111d89 at 2026-08-25T21:22:02Z and 8a1b6c at 2026-08-26T19:28:29Z) with "server rejected our request for an unknown reason". The reports are about a month old, so they are probably outside the seven-day window. I don't claim this race is proven to be the cause. The only basis is your trace-assisted finding in the follow-up comment. The reporter's own last messages also say blockHighCompetition had been turned on and was blocking about 66% of their flips, which accounts for part of the gap. No auction details or customer identifiers were used or exposed.

Scope.

  • I didn't change /cofl flip always; that companion coverage stays in PR Fix #437: too little flips sent #438.
  • Authentication, payments, player data, command permissions and report tracing are untouched.
  • The untracked dotfiles, host and scripts in the workspace came from the sandbox, not from me.

Related issue: #437.

Validation

6/6 validation checks passed.

Review: separate codex session recorded.

Review notes

  • Round 1: This Donut-only fix does not establish or resolve the reported Hypixel cause; the retained market-evidence file contains zero records.
  • Round 1: Review was read-only; the Docker build and declared base-fail/patch-pass regression remain for the host gate.
Task provenance and validation receipts

Task: task_hf46jalpoquuph5544rq

Base branch: main

Base commit: 7bce2f2f4e793a022346e802d7265a0ec24f39de

  • container_build (exit 0) — sha256:7ae14db6cca992ad3d0818eaff67ddb14081eeca7ebb9eb71634e29ddcfe2ab9
  • regression_sibling_clone_dev (exit 0) — sha256:1ffc3522361915cd562491f72ccb82ceede9ee5f038baf7356c751d617903945
  • regression_sibling_clone_SkyFilter (exit 0) — sha256:4f708cfe05ce21d6620adc04d71f51c531e545e1b2e1efd31ac08bc2f0e40543
  • regression_sibling_clone_SkyBackendForFrontend (exit 0) — sha256:aa006ad6d3b1d807d447333fb623569ccd5f549dc8ae2e2f47a5e4551a696e3f
  • regression_sibling_clone_websocket-sharp (exit 0) — sha256:35b4b751913a036b1e475ea2cbd1af29ee65b6ff707bfd8f960c015ced9dcec0
  • regression_base_fail_patch_pass (exit 0) — trusted-harness exact command, isolated checkout servers, and reviewed test overlays: overlay_derivation=applied:1 sibling_setup_exit=0 overlay_setup_exit=0 overlay_review_digest=unavailable overlay_receipt_sha256=unavailable base_setup_exit=0 base_setup_log_sha256=unavailable server_isolation_exit=0 base_exit=1 base_log_sha256=b17f02e07fe712512db7d19a77b57bf2fb4b935e781dbe9769fdd12f362dfac0 patched_exit=0 patched_log_sha256=8a9deb868bc54fa343462b139066e1492302e449c8a6fce6e9ba4ee5c825aaea

Human review is required; the automation identity cannot approve or merge this PR.

@ekwav-agent
ekwav-agent requested a review from Ekwav September 27, 2026 02:34
@Ekwav

Ekwav commented Oct 3, 2026

Copy link
Copy Markdown
Member

Closing as superseded by #456, which removed the Donut server integration (all of Services/Donut/). This PR only patched DonutFlipSubscriptionService and added a test for it, so after resolving the conflict in favour of the deletion nothing mergeable remains — the test references types that no longer exist. The equivalent reconnect fix for Hypixel connections (#437) is Coflnet/SkyBackendForFrontend#122.

@Ekwav Ekwav closed this Oct 3, 2026
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.

2 participants