stable/freqtrade
creslinux efbeabf141 Added Local RPC client
- added only "Daily" call so far, submitting for early review/feedback

This depends on zerorpc as a requirement.
simple examples here:
http://www.zerorpc.io/

Installed with pip3 install zerorpc

localRCP is enabled/disabled from within config.json
e.g
    "localrpc": {
        "enabled": true
       },

The server is enabled from within existing rpc manager
and makes use of the existing superclass (RPC)

Though making use of the existing hardwork done in rpc.py
It *should be easy to add the other Telegram calls into local_rpy_server.py

The server is wrapped in a thread to be non-blocking
The server and client accept serialised calls or not, used in daily to return json
The client can be used from command line or in a python script

As example, from cmdline for last 3 days Daily

/Users/creslin/PycharmProjects/freqtrade_new/.env/bin/zerorpc tcp://127.0.0.1:4242 daily 3
connecting to "tcp://127.0.0.1:4242"
False
('[\n'
 '    [\n'
 '        "2018-06-08",\n'
 '        "0.00000000 BTC",\n'
 '        "0.000 USDT",\n'
 '        "0 trade"\n'
 '    ],\n'
 '    [\n'
 '        "2018-06-07",\n'
 '        "0.00000000 BTC",\n'
 '        "0.000 USDT",\n'
 '        "0 trade"\n'
 '    ],\n'
 '    [\n'
 '        "2018-06-06",\n'
 '        "0.00000000 BTC",\n'
 '        "0.000 USDT",\n'
 '        "0 trade"\n'
 '    ]\n'
 ']')

Programitcally this would be:
import zerorpc

c = zerorpc.Client()
c.connect("tcp://127.0.0.1:4242")

for item in c.daily(3):
    print item
2018-06-08 18:35:01 +00:00
..
exchange improve log message 2018-06-06 20:30:42 +02:00
optimize use .copy() to avoid Pandas mistake. drop first row because of shifting 2018-06-07 17:29:40 +03:00
rpc Added Local RPC client 2018-06-08 18:35:01 +00:00
strategy add ignore explanation 2018-06-02 14:18:57 +02:00
tests Merge pull request #864 from freqtrade/feature/overhaul-db-handling 2018-06-07 22:18:10 +02:00
vendor add missing import 2017-11-20 22:26:32 +01:00
__init__.py handle sqlalchemy NoSuchModuleError 2018-06-07 21:35:57 +02:00
__main__.py Add __main__.py to improve how to launch the bot 2018-06-03 08:57:13 -07:00
analyze.py remove type:ignore 2018-06-02 14:10:15 +02:00
arguments.py Merge branch 'develop' of freqtrade into feature/overhaul-db-handling 2018-06-07 17:33:37 +02:00
configuration.py fix db-url handling if passed via CLI args 2018-06-07 20:15:31 +02:00
constants.py define constants.DEFAULT_DB_DRYRUN_URL and fix StaticPool conditions 2018-06-07 17:29:43 +02:00
fiat_convert.py Merge pull request #817 from gcarq/feature/gdax 2018-06-03 17:49:20 +03:00
freqtradebot.py remove obsolete param 2018-06-07 05:27:27 +02:00
indicator_helpers.py fix typing 2018-05-30 22:09:20 +02:00
main.py handle sqlalchemy NoSuchModuleError 2018-06-07 21:35:57 +02:00
misc.py type anotation fixes 2018-05-30 22:38:09 +02:00
persistence.py handle sqlalchemy NoSuchModuleError 2018-06-07 21:35:57 +02:00
state.py Add a Enum class State that contains Bot running states 2018-03-03 09:33:54 +08:00