Repository navigation
Config UI: raise device test timeout to 15s - #33118
Merged
Merged
Conversation
EEBus connections need headroom for ship-go's connection backoff plus the SHIP handshake, which regularly exceeds the previous 10s.
Contributor
There was a problem hiding this comment.
Hey - I've found 1 issue
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path="server/http_config_helper.go" line_range="208" />
<code_context>
+// deviceTestTimeout limits the device configuration test. EEBus devices need
+// headroom for ship-go's connection backoff plus the SHIP handshake.
+const deviceTestTimeout = 15 * time.Second
+
func startDeviceTimeout() (context.Context, context.CancelFunc, chan struct{}) {
</code_context>
<issue_to_address>
**issue (bug_risk):** The 15-second timeout still cancels the configuration context before a device with a saturated ship-go backoff can connect: the backoff alone can take up to 20 seconds, and the dial plus SHIP handshake occurs afterward. The UI therefore continues to report `context canceled` for those devices.
**Triggers:** When ship-go's per-SKI attempt counter is in the saturated 10-20 second backoff range.
**Suggested fix:** Reset the per-SKI attempt counter when registering a test, or set the timeout to exceed the maximum backoff plus the expected dial and handshake duration.
</issue_to_address>Sourcery assessment
Approval pending. 1 finding to address first.
Blocking findings: server/http_config_helper.go:208
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Bumps ship-go to andig/ship-go@3331556, which cancels the accumulated retry backoff and any pending delay timer when a remote service is registered. A device test no longer inherits a 10-20s connection delay from earlier failed attempts.
andig
marked this pull request as draft
August 23, 2026 12:38
andig
marked this pull request as ready for review
September 1, 2026 14:25
# Conflicts: # go.mod # go.sum
2 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
follows #33384
The device configuration test cancels its context after 10s. For EEBus devices that is not enough: ship-go delays each connection attempt by a randomized backoff, and only then dials, with the SHIP handshake on top.
From a Wolf CHA trace in #25058 the delays were 14.2s, 12.9s, 10.2s and 5.2s, with 3-9s for dial plus handshake. Every test aborted exactly 10s after
registering ski, so the connection never had a chance to complete and the UI reportedcannot create charger type 'eebus-ohpcf': context canceled.The backoff reset that made up the second half of this PR landed separately in #33384, so what remains here is the headroom: with the reset a test starts from the
0-3srange, and 15s covers the dial and handshake on top.🤖 Generated with Claude Code