Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'NoneType' object has no attribute 'get' #10

Open
johndba opened this issue Mar 28, 2017 · 1 comment
Open

'NoneType' object has no attribute 'get' #10

johndba opened this issue Mar 28, 2017 · 1 comment

Comments

@johndba
Copy link

johndba commented Mar 28, 2017

Hello .. trying out the trading bot stakemachine by Xeroc and Mauritsvdvijgh ( many thanks for the work put in there ) I have it installed but when running against a test node ( before trying it out on the real exchange ) it fails at one line. Running on Ubuntu 14.04.5 LTS (Trusty Tahr) python3 in virtualenvs to make sure there are no Python version problems.
============config.yml==============
witness_url: "ws://104.196.5.69:8090"
prefix: "BTS"
safe_mode: FALSE
account: "johntest"
wif: "5XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"

market_separator: ":"

reserves:
BTS: 100
BTC: 100

bots:
MakerWall:
module: "stakemachine.strategies.maker"
bot: "MakerSellBuyWalls"
markets:
- "BTS:BTC"
target_price: "last"
target_price_offset_percentage: 0
spread_percentage: 5
volume_percentage: 10
symmetric_sides: True
only_buy: False
only_sell: False
============config.yml==============
OUTPUT ->
vagrant@vagrant-ubuntu-trusty-64:~/stakemachine$ stakemachine -c config.yml once
2017-03-29 07:32:25,637 - stakemachine - INFO - Configuration: {
"safe_mode": false,
"reserves": {
"BTC": 100,
"BTS": 100
},
"prefix": "BTS",
"market_separator": ":",
"bots": {
"MakerWall": {
"spread_percentage": 5,
"markets": [
"BTS:BTC"
],
"symmetric_sides": true,
"bot": "MakerSellBuyWalls",
"volume_percentage": 10,
"target_price": "last",
"target_price_offset_percentage": 0,
"module": "stakemachine.strategies.maker",
"only_sell": false,
"only_buy": false
}
},
"witness_url": "ws://104.196.5.69:8090",
"account": "johntest"
}
2017-03-29 07:32:29,082 - stakemachine.bot - INFO - Executing bot MakerWall
Traceback (most recent call last):
File "/usr/local/bin/stakemachine", line 9, in
load_entry_point('stakemachine==0.0.2', 'console_scripts', 'stakemachine')()
File "/usr/local/lib/python3.4/dist-packages/stakemachine-0.0.2-py3.4.egg/stakemachine/main.py", line 142, in main
File "/usr/local/lib/python3.4/dist-packages/stakemachine-0.0.2-py3.4.egg/stakemachine/bot.py", line 137, in once
File "/usr/local/lib/python3.4/dist-packages/stakemachine-0.0.2-py3.4.egg/stakemachine/strategies/maker.py", line 221, in place
AttributeError: 'NoneType' object has no attribute 'get'

Line 221 is
if quote not in amountSettings.get("amounts"):
log.warn("You have mentioned %s in 'assets' " % quote +
"but have not defined an amount")

@Ashaman-
Copy link

Ashaman- commented Jun 3, 2017

I'm getting the same in both a python3.6 and python3.5 venv.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants