dutu / poloLender

Free, open source, high performance bot for lending funds on Poloniex exchange
https://github.com/dutu/poloLender
Other
160 stars 47 forks source link

Not lowering offered rates for several hours #32

Closed Shoananas closed 7 years ago

Shoananas commented 7 years ago

Hello,

I feel like there is a strange behaviour and I'm not sure if it is intentional or not.

My last loan was taken at 19h45 UTC (about 1 hours and 15 minutes ago) and my loan offers are still way too high for the current market. Considering the number of loans that are paid back pretty quickly, wouldn't it be better to lower the rate every X minutes if a loan is not taken?

See my screenshot attached please:

loans_2017-05-10_22-55-08

Funny thing though, right after taking the screenshot, these loans have been taken. Still not sure if it's worth it knowing I had these 0.X btc waiting for like 1 hour.

Edit: miscalculation on my part, the question remains the same though.

Edit 2: also, I'm wondering what these logs mean app/web.1: notice: bfxPublic.ticker: Error: ETIMEDOUT I didn't find any ETIMEDOUT in your code, so I guess it is from the API or Heroku?

dutu commented 7 years ago

notice: bfxPublic.ticker: Error: ETIMEDOUT

Indicates a timeout on API call when communicating with bitfinex (for getting BTCUSD rates). The issue is transient and does not impact on bot functionality.

dutu commented 7 years ago

@Shoananas the lending algorithm takes into calculation the average loan holding time. Based on average holding time, the bot will wait shorter or longer before offering loans at lower rates.

At times waiting times may look counterintuitive. For your example above the average loan holding time was +8h and it made more sense to wait longer for higher lending rate.

Please also refer to my explanation for issue "Non optimal trade has happened" https://github.com/dutu/poloLender/issues/30, where the user has experience exactly the opposite: perceived too short waiting time when the average loan holding time was relatively short (~45 minutes).

Then again, taking the average loan holding time into calculation is the one main characteristic of this lending algorithm, and where its power and profitability are. This is also what it differentiates it from other lending bots.

Hope this makes sense.

Shoananas commented 7 years ago

It does, thank you for your explanation. I will use for a while to compare the results with a bot of a friend that is very quick at lending btc (but with lower rates).