r4stl1n / condex Goto Github PK
View Code? Open in Web Editor NEWBittrex Console Index Fund Management Tool
License: MIT License
Bittrex Console Index Fund Management Tool
License: MIT License
Condex should have the ability to equality weight the unlocked portion of the portfolio.
We need a simple way to migrate DB functionality on schema changes.
Ideas:
I am working on adding checks to verify the percentages prior to adding or updating coins.
Currently the total allocation can exceed 100%
Condex should add the ability to lock and unlock coins without having to recalculate the specific percentages associated.
We need a way to check to make sure a wallet/pair isn't offline for whatever reason before attempting a buy and also make sure it can short circuit the loop if need be. The system should:
right now the last parameter is required and the add will fail if it's not provided. This should be defaulted to false if the parameter isn't provided.
When trying to apply indexequalweight to very large numbers of coins, a rounding issue causes missing percentages for last coins in the index as there is not enough percentage left over to be assigned.
eg. indexequalweight on 198 coins rounds up to 0.51 instead of 0.505 so missing about 1% to assign to last 2 coins
Make sure that there's protection around rebalancing so that trade fees don't negate much of what the engine is trying to accomplish
Condex should be able to export and import its index settings to allow for easy sharing and modification of a given index.
The exported data should be in json format.
It seems that there's still an issue with calculating the minimum trade order but only in some occasions. Bittrex has 2 thresholds a trade must pass in order to hit the books:
This issue seems to be happening only when the system is attempting to bring a coin up from -100% off target.
It is attempting to get the current market for the pair which includes the minimum trade size for the pair. It then makes a call to get the ticker for the current pair and multiplies the last price * the minimum trade size to get a value. This is often lower than the minimum BTC trade value so I'm not sure what's going on there.
Fringe case was found when trying to convert a preexisting index from coincube to condex. If the BTC value is low enough adding multiple indexed coins can cause condex to not allow adding a coin to the index.
We should remove this check to allow easy migration from coincube to condex. However this check should be reran before starting the index to ensure that all coins meet the minimum requirements.
Currently "Index Remove" allows an individual to remove BTC fromt heir index. This breaks all future coin additions and cripples the trade engine.
Our code currently requires individuals to hold btc in their index to rebalance.
The unrealized gain is currently being calculated incorrectly has the values are always tied to equal 100%. This is incorrect has they should be independently calculated against the individual coins gains and losses.
By default condex utilizes sqlite to manage its database. Unfortunately if a machine has low read write speed it can cause the sqlite database to get locked during writing. In rare cases it can cause a coin lock to not get deleted causing the entire index to lock up.
We need to create a simple setup guide to setup a mysql database and have condex to be configured for it. This will ensure that there isn't a issue with writing to the file system.
When updating an index it throws an invalid argument error.
Traceback (most recent call last): File "main.py", line 155, in <module> ConDex().cmdloop() File "/usr/lib/python2.7/cmd.py", line 142, in cmdloop stop = self.onecmd(line) File "/usr/lib/python2.7/cmd.py", line 221, in onecmd return func(arg) File "main.py", line 89, in do_index icm.index_update_coin(command_split[1],command_split[2], command_split[3]) File "/home/phoenix/condex/managers/IndexCommandManager.py", line 168, in index_update_coin if DatabaseManager.update_index_coin_model(coin.upper(), float(percentage), 0.0,0.0, lockCoin): TypeError: update_index_coin_model() takes exactly 4 arguments (5 given) (.env) %
This is due to the fact that the function call supplies 5 arguments but the definition only takes in 4 arguments.
DatabaseManager.update_index_coin_model(coin.upper(), float(percentage), 0.0,0.0, lockCoin):
But update_index_coin_model, only takes
def update_index_coin_model(ticker, desiredPercentage, distanceFromTarget, locked):
ConDex> show coins
+----------+-------+------+-------+-------+-------+-------+-------+------+-------+-------+
| Avalible | Coins | . | . | . | . | . | . | . | . | . |
+----------+-------+------+-------+-------+-------+-------+-------+------+-------+-------+
| SC | FLO | ENRG | KORE | WAVES | MLN | BAT | INFX | DCR | GUP | RADS |
| PIVX | 2GIVE | LBC | DGB | VOX | QRL | KMD | BNT | BCH | LMC | WINGS |
| XMR | VTR | DCT | BLITZ | EDG | STRAT | ION | XWC | THC | SPR | GNO |
| FLDC | RBY | XMY | VRC | RDD | VRM | GBYTE | ETH | AUR | ZCL | NAV |
| GRS | BTG | MCO | START | PART | ZEN | IOC | FUN | PAY | VTC | TKS |
| XAUR | GBG | LUN | PDC | BLOCK | RISE | FTC | STORJ | MER | MTL | INCNT |
| TRUST | EMC | EMC2 | BURST | BRX | GEO | SBD | PPC | DNT | SEQ | PTOY |
| APX | ARK | LTC | XVG | ENG | CLUB | BTCD | EXCL | GLD | NEOS | XRP |
| SALT | NXS | IOP | DASH | XZC | SWT | VIB | ETC | MONA | MANA | COVAL |
| LSK | DTB | BAY | NEO | SHIFT | 1ST | BRK | UNB | CVC | QTUM | AEON |
| PINK | XLM | SYS | CFI | FAIR | CPC | RLC | ADA | PTC | TRST | MEME |
| TIX | SWIFT | SYNX | BITB | NXC | OK | UBQ | ADX | BYC | VIA | TRIG |
| MYST | NMR | ADT | TX | NLG | XMG | XEM | CURE | XST | REP | DGD |
| STEEM | CRB | CANN | HMQ | EXP | QWARK | MUSIC | ARDR | GNT | FCT | BCY |
| SNRG | ANT | ZEC | GAME | CLAM | XVC | ABY | EFL | CRW | DYN | EBST |
| CLOAK | LGD | MAID | SNGLS | SLS | DMD | NXT | AMP | BLK | RCN | OMNI |
| SLR | XCP | POT | BSD | DOPE | NBT | GRC | PKB | SPHR | POWR | GCR |
| XEL | AGRS | DOGE | GAM | SNT | XDN | SIB | ERC | EGC | GOLOS | MUE |
+----------+-------+------+-------+-------+-------+-------+-------+------+-------+-------+
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.