-
Notifications
You must be signed in to change notification settings - Fork 210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: timeouts on version discovery #4476
Conversation
Parametrize timeout of api version discovery using env variable. Set it to low value only when testing offline nodes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fedimint-client should not use environment variables.
libraries using env variables is super weird.
we should move env variables checking to fedimint-cli
The problem with that is getting the setting deep into the client. Eventually we'll need a general solution for things like this to also override the default esplora server etc., but for now this seems like the only reasonable-effort way to adjust the timeout in tests without breaking clients on slow connections. |
I agree, but it isn't a big crime and that can be a follow-up. We'll have some builder pattern on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dpc Thanks for tackling this. I think we can close #4398, but feel free to keep open if you want to refactor the misdemeanor in a followup.
@maan2003 I share your discomfort with using env vars to trigger different logic in prod vs tests. I'm approving since I prefer the tradeoff to fix the broken behavior in prod first, which can be refactored in a fast follow.
@bradleystachurski Seems like the nix stale timeout you landed recently also didn't help? :( https://github.com/fedimint/fedimint/actions/runs/8181905886/job/22372424769 It's always the ndk-bundle (which is probably relatively large), so maybe it's not completely stuck but just sometimes get very slow? |
@dpc Should we try temporarily bumping the cross compile timeout? |
Worth giving a shot, I guess. Can you make a PR? |
We started getting slow test and timeouts in the CI: https://github.com/fedimint/fedimint/actions/runs/8198894922/job/22423145415 caused by fedimint#4476. Turns out there are other tests just degraded federation tests that run with degraded federations. Generally in dev shell, tests and CI, we can just default to 10 seconds timeout, should be enough even under heavy load.
We started getting slow test and timeouts in the CI: https://github.com/fedimint/fedimint/actions/runs/8198894922/job/22423145415 caused by fedimint#4476. Turns out there are other tests just degraded federation tests that run with degraded federations. Generally in dev shell, tests and CI, we can just default to 10 seconds timeout, should be enough even under heavy load.
We started getting slow test and timeouts in the CI: https://github.com/fedimint/fedimint/actions/runs/8198894922/job/22423145415 caused by fedimint#4476. Turns out there are other tests just degraded federation tests that run with degraded federations. Generally in dev shell, tests and CI, we can just default to 10 seconds timeout, should be enough even under heavy load.
When working locally I've noticed test failing due to too short api discovery timeout.
Parametrize timeout of api version discovery using env variable. Set it to low value only when testing offline nodes.