__init__() takes exactly 6 arguments (2 given)
See original GitHub issueHello. Just installed this today. Had to upgrade my numpy to latest version to fix a previous error. After about 10-20minutes, I got this error.
Welcome to Poloniex Lending Bot
Started WebServer, lendingbot status available at http://10.10.10.202:8000/lendingbot.html
2017-01-11 15:29:16 Error: __init__() takes exactly 6 arguments (2 given)
Traceback (most recent call last):
File "lendingbot.py", line 68, in <module>
Lending.cancel_all()
File "/usr/src/poloniexlendingbot/modules/Lending.py", line 100, in cancel_all
loan_offers = api.return_open_loan_offers()
File "/usr/src/poloniexlendingbot/modules/Poloniex.py", line 129, in return_open_loan_offers
loan_offers = self.api_query('returnOpenLoanOffers')
File "/usr/src/poloniexlendingbot/modules/Poloniex.py", line 86, in api_query
raise type(ex), type(ex)(ex.message + ' Requesting %s' % command), sys.exc_info()[2]
TypeError: __init__() takes exactly 6 arguments (2 given)
Unhandled error, please open a Github issue so we can fix it!
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (3 by maintainers)
Top Results From Across the Web
Python: TypeError: __init__() takes exactly 2 arguments (1 ...
The code you used is as follows: player = Player(). This is an issue since the __init__ must be supplied by one parameter...
Read more >How to solve "TypeError: __init__() takes exactly 2 arguments ...
"Takes exactly 2 arguments" means self , which is automatically supplied, +1 other user-specified argument. This is because RemapRange is a ...
Read more >TypeError: __init__() takes exactly 1 argument (2 given)
Getting the error on the line where I try to create the milton instance: class Employee(object): “””Models real-life employees!””” def init(self ...
Read more >TypeError: init() takes exactly 5 arguments (2 given) - Odoo
Server Traceback (most recent call last): File "/home/openerp/openerp/7.0/openerp7/openerp/addons/web/session.py", line 90, in send return ...
Read more >Python TypeError: init takes exactly 1 argument 2 given
Python TypeError: init takes exactly 1 argument 2 given. 13K views 7 years ago. ATOM. ATOM. 6.38K subscribers. Subscribe.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@rnevet Since you already have the exception, instead of raising a new one, you could:
Then change all the str(ex) in lendingbot.py to ex.message.
message will always exist for python Exceptions and you’d be creating it for any random ones that are caught that somehow might not have it. Though they always should.
Or of course, just ignore the original type and raise a new one.
Seems to be running otherwise.