Commit Graph

121 Commits

Author SHA1 Message Date
Sam Germain
4984595ddf Merge branch 'develop' into margin-db 2021-07-05 01:04:21 -06:00
Sam Germain
20b806528f Set default leverage to 1.0 2021-07-04 23:12:07 -06:00
Sam Germain
d84534cd96 Long tests passing 2021-07-04 22:14:00 -06:00
Sam Germain
356ec4e44a Most of the short tests work again 2021-07-04 04:14:39 -06:00
Sam Germain
6b20a315e3 Updated tests to new persistence 2021-07-04 00:27:54 -06:00
Sam Germain
243173d2be Merge branch 'margin-db' of https://github.com/samgermain/freqtrade into margin-db 2021-07-03 21:24:54 -06:00
Matthias
e358860a69 Fix migrations, revert some parts related to amount properties 2021-07-03 17:03:12 +02:00
Sam Germain
76693800d9 all tests written for margin-db, but a lot fail 2021-07-03 03:09:43 -06:00
Sam Germain
17d562cbc8 Updated ratio calculation, updated short tests 2021-07-02 02:02:00 -06:00
Eugene Schava
d54de72471 "/profit N" command should print best pair for the same period of time, not for all trades 2021-06-28 23:42:09 +03:00
Sam Germain
bf68fbe109 Kraken interest test comes really close to passing 2021-06-28 10:01:18 -06:00
Sam Germain
636de6d629 Made borrowed a computed property 2021-06-28 08:36:47 -06:00
Sam Germain
35a8c7bf53 Turned amount into a computed property 2021-06-28 08:19:20 -06:00
Sam Germain
25b7c7f43b persistence short stoploss test 2021-06-28 05:19:18 -06:00
Sam Germain
1bcab12b8f Added tests for interest and assigning leverage 2021-06-28 03:30:21 -06:00
Sam Germain
562f4309db test_calc_profit on shorts 2021-06-28 02:31:25 -06:00
Sam Germain
c98b9ab768 margin test_trade_close 2021-06-27 23:46:22 -06:00
Sam Germain
26fb904512 Third test should pass, but it's always slightly off 2021-06-27 04:55:30 -06:00
Sam Germain
13ec7610bf Two margin tests pass now, although 3 persistance tests fail due the field in Trade being _leverage instead of leverage 2021-06-27 03:38:56 -06:00
Sam Germain
5667c1ef23 added exception checks to LocalTrade.leverage and LocalTrade.borrowed 2021-06-27 00:19:58 -06:00
Sam Germain
57896e9ee9 Added types to setters 2021-06-26 21:34:58 -06:00
Sam Germain
4bd8a1b595 Set leverage and borowed to computed properties 2021-06-26 21:10:50 -06:00
Sam Germain
b77f39cfcb Wrote 1 test for shorting, not 2 tests, definately not 3 tests, 1 single test 2021-06-26 02:18:00 -06:00
Sam Germain
c6a818eb17 Created interest function 2021-06-22 21:17:14 -06:00
Sam Germain
759f563631 All previous pytests pass 2021-06-22 02:55:53 -06:00
Sam Germain
85632eec05 A lot of the pytests pass now, 1562 pass, 3 fail 2021-06-22 02:22:16 -06:00
Sam Germain
a9bd0700ed Adding templates for leverage/short tests 2021-06-21 21:26:31 -06:00
Sam Germain
9891c6e111 Fixed breaking changes, can run the bot again 2021-06-20 15:34:05 -06:00
Sam Germain
6c7c07d7c6 updated collateral_currency 2021-06-20 15:06:36 -06:00
Sam Germain
62226fe58c Added changes suggested in pull request, except for collateral_currency 2021-06-20 14:49:07 -06:00
Sam Germain
73dbc7a2f4 Added changed to persistance/migrations 2021-06-20 02:25:22 -06:00
Sam Germain
e6a137d5b4 Updated Trade class 2021-06-20 00:58:38 -06:00
Sam Germain
abe0b3e3bd Updated LocalTrade and Order classes 2021-06-19 22:06:51 -06:00
Matthias
c65b4e5d3b Small fix to models 2021-06-13 11:20:22 +02:00
Matthias
756904f985 Set sell_reason to stoploss when closing the trade as stoploss
closes #5101
2021-06-08 21:21:29 +02:00
Matthias
66de5df1d1 Update sqlite init method 2021-05-27 11:38:28 +02:00
Matthias
a01d05997e Add Trade.commit method for easy use 2021-05-27 11:38:28 +02:00
Matthias
6fb32c3594 Use commit instead of .flush() 2021-05-27 11:38:28 +02:00
Matthias
eaa47ff335 Don't use autocommit 2021-05-27 11:38:28 +02:00
Matthias
c31cb67118 Further changes for sqlalchemy 1.4 2021-05-27 11:38:28 +02:00
Matthias
2f79958acb Move declarative_base import to import from .orm 2021-05-27 11:38:28 +02:00
Matthias
cc064f1574 String columns should have a max-length defined
otherwise MySql will not work.
2021-05-22 10:12:23 +02:00
Matthias
6acb2eb2b6 Add average column to orders table 2021-05-21 20:35:39 +02:00
Matthias
6b2a38ccfb Add absolute Profit to apiserver 2021-05-15 19:39:46 +02:00
Matthias
6eb947ae09 Move static Trade functions to right class 2021-04-28 06:37:40 +02:00
Matthias
9f6f3e0862 Address ZeroDivisionExceptiond
closes #4764 closes #4617
2021-04-20 21:41:49 +02:00
Matthias
37c8fd6ad7 Remove arrow from models.py 2021-04-13 11:55:03 +02:00
Matthias
9a58a85347 Don't export "hum" date versions for trade objects.
They are not used and have a rather high performance penalty due to
using arrow.get
2021-04-13 06:17:11 +02:00
Matthias
7132aefd60 Rename Trade.session to Trade._session 2021-04-05 08:46:12 +02:00
Matthias
0407bf755f Use .query.session to make sure the scoped session is used properly 2021-04-05 07:28:51 +02:00