question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

New version bittrex not working

See original GitHub issue

I had a code running without any problems. I updated the bittrex.py file and now I get an error:

Traceback (most recent call last): File “C:/Lori/Adam/bitcoin/cryptoarb/rsi_bot.py”, line 50, in <module> balance_btc = xchange.fetch_balance()[‘BTC’][‘total’] File “C:\Python27\lib\site-packages\ccxt\bittrex.py”, line 201, in fetch_balance response = self.accountGetBalances() File “C:\Python27\lib\site-packages\ccxt\bittrex.py”, line 616, in request response = self.fetch2(path, api, method, params, headers, body) File “C:\Python27\lib\site-packages\ccxt\base\exchange.py”, line 258, in fetch2 request = self.sign(path, api, method, params, headers, body) File “C:\Python27\lib\site-packages\ccxt\bittrex.py”, line 584, in sign self.check_required_credentials() AttributeError: ‘bittrex’ object has no attribute ‘check_required_credentials’

OS: Win7
Programming Language: Python 2.7
CCXT version: 10.477
Exchange: Bittrex
Method: fetch_ohlcv()

This is my code… so far it worked allright, now it wont work because of the error message. What is wrong? Thank you in advance!

import ccxt
import time
import pandas as pd
from stockstats import StockDataFrame as sdf
from openpyxl import load_workbook

proxies = [
    '',  # no proxy by default
    'https://crossorigin.me/',
    'https://cors-anywhere.herokuapp.com/',
]

wait_time = 600 # seconds
counter = 1
max_rsi = 31.0
min_vol = 0.1 # btc
min_gain = 0.015
stop_loss_ratio = 0.15



stop_loss_rate = 1 - stop_loss_ratio

while(True):

    # -----------------------------------------------
    # connection

    maxRetries = 30
    for numRetries in range(0, maxRetries):
        try:
            currentProxy = proxies[(numRetries + 1) % len(proxies) - 1]
            xchange = ccxt.bittrex({'proxy': currentProxy,
                                     'apiKey': 'XXX',
                                     'secret': 'XXX'
                                     })
            xchange.load_markets()
            symbols_list = xchange.symbols
            break
        except :
           print 'Proxy fail:', currentProxy
           print 'numRetries:', numRetries
           if currentProxy == 'https://cors-anywhere.herokuapp.com/' :
               print 'waiting'
               time.sleep(30)

    # -----------------------------------------------
    # check if we are in BTC and have no open orders

    balance_btc = xchange.fetch_balance()['BTC']['total']

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
hunsnowboardercommented, Dec 26, 2017

Sorry for my late reply. I had very strange issues and finally figured out what the problem was. I did not update ccxt for a while now only some of the exchanges.

So I did a thorough update of everything and now it works like a charm. Thank you again for your continuous support and help! Have a happy new year!

1reaction
hunsnowboardercommented, Dec 26, 2017

Yes, it solved my problem!

Thank you very much for your help!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Site Status - Bittrex
This page displays status information for Bittrex's wallets and markets, updated on a 5-minute interval. If you are experiencing a problem that is...
Read more >
Bittrex down? Current outages and problems. - Downdetector
User reports indicate no current problems at Bittrex. Bittrex is a digital asset exchange that facilitates trading of digital currencies including Bitcoin.
Read more >
Bittrex (@BittrexExchange) / Twitter
Looking for a #crypto exchange that's secure, US-based, and offers over 150 coins & tokens? Join Bittrex and for a limited time receive...
Read more >
Bittrex.com - Is Bittrex Down Right Now?
Can't Access Bittrex - Troubleshooting Instructions ... browser to make sure that you have the most recent version of the web page. ......
Read more >
Log In Issues - Bittrex Support
Here are the links to download the latest versions for iOS and Android. If you are on web, clear your browser cache and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found