thrasher-corp / gocryptotrader

A cryptocurrency trading bot and framework supporting multiple exchanges written in Golang.
MIT License
2.96k stars 792 forks source link

exchange/stream: toggle stream auto subscribe #1488

Open shazbert opened 4 months ago

shazbert commented 4 months ago

PR Description

Fixes # (issue)

Type of change

Please delete options that are not relevant and add an x in [] as item is complete.

How has this been tested

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration and also consider improving test coverage whilst working on a certain feature or package.

Checklist

codecov[bot] commented 4 months ago

Codecov Report

Attention: Patch coverage is 46.66667% with 16 lines in your changes are missing coverage. Please review.

Project coverage is 37.93%. Comparing base (1e95ae9) to head (3353d6d).

:exclamation: Current head 3353d6d differs from pull request most recent head c236b25. Consider uploading reports for the commit c236b25 to get more accurate results

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488/graphs/tree.svg?width=650&height=150&src=pr&token=41784B23TS&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp)](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp) ```diff @@ Coverage Diff @@ ## master #1488 +/- ## ========================================== + Coverage 37.91% 37.93% +0.01% ========================================== Files 411 411 Lines 147198 147204 +6 ========================================== + Hits 55817 55836 +19 + Misses 83588 83587 -1 + Partials 7793 7781 -12 ``` | [Files](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp) | Coverage Δ | | |---|---|---| | [exchanges/exchange.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=exchanges%2Fexchange.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-ZXhjaGFuZ2VzL2V4Y2hhbmdlLmdv) | `80.33% <100.00%> (+0.88%)` | :arrow_up: | | [internal/testing/exchange/exchange.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=internal%2Ftesting%2Fexchange%2Fexchange.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-aW50ZXJuYWwvdGVzdGluZy9leGNoYW5nZS9leGNoYW5nZS5nbw==) | `63.63% <50.00%> (-3.76%)` | :arrow_down: | | [engine/websocketroutine\_manager.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=engine%2Fwebsocketroutine_manager.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-ZW5naW5lL3dlYnNvY2tldHJvdXRpbmVfbWFuYWdlci5nbw==) | `53.76% <0.00%> (+0.36%)` | :arrow_up: | | [exchanges/sharedtestvalues/customex.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=exchanges%2Fsharedtestvalues%2Fcustomex.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-ZXhjaGFuZ2VzL3NoYXJlZHRlc3R2YWx1ZXMvY3VzdG9tZXguZ28=) | `2.23% <0.00%> (ø)` | | | [exchanges/stream/websocket.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=exchanges%2Fstream%2Fwebsocket.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-ZXhjaGFuZ2VzL3N0cmVhbS93ZWJzb2NrZXQuZ28=) | `85.74% <80.00%> (-0.32%)` | :arrow_down: | | [engine/rpcserver.go](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488?src=pr&el=tree&filepath=engine%2Frpcserver.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp#diff-ZW5naW5lL3JwY3NlcnZlci5nbw==) | `42.11% <0.00%> (ø)` | | ... and [30 files with indirect coverage changes](https://app.codecov.io/gh/thrasher-corp/gocryptotrader/pull/1488/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=thrasher-corp)
gloriousCode commented 4 months ago

Makes sense, but is there a particular exchange that this was affecting so that I may attempt to replicate your issue?

shazbert commented 4 months ago

Makes sense, but is there a particular exchange that this was affecting so that I may attempt to replicate your issue?

.\gocryptotrader --enableallpairs [WARN] | WEBSOCKET | 01/03/2024 09:44:06 | Kucoin exchange backlog in websocket processing detected

For Kucoin and others with lots of subs.