internlm/SWE-Fixer-Train-110K huggingface dataset:
Repository: rotki/rotki

Issue:
Compound historical profit is wrong if you have assets deposited
## Problem Definition

For example this address has some assets deposited and the historical interest is shown the same as the deposited amount

![2020-11-03_16-26](https://user-images.githubusercontent.com/1658405/98005545-727c3a80-1df1-11eb-8d10-2d6f12aac2bc.png)

## Task

Figure out why and fix this. Can test live, but won't be able to test with actual data in the CI as accounts move their stuff around


Discussion:

Resolving patch:
diff --git a/rotkehlchen/chain/bitcoin/xpub.py b/rotkehlchen/chain/bitcoin/xpub.py
--- a/rotkehlchen/chain/bitcoin/xpub.py
+++ b/rotkehlchen/chain/bitcoin/xpub.py
@@ -270,7 +270,7 @@ def check_for_new_xpub_addresses(self) -> None:
                     )
                     continue
 
-        log.debug(
-            f'Attempt to derive new addresses from xpub: {xpub_data.xpub.xpub} '
-            f'and derivation_path: {xpub_data.derivation_path} finished',
-        )
+                log.debug(
+                    f'Attempt to derive new addresses from xpub: {xpub_data.xpub.xpub} '
+                    f'and derivation_path: {xpub_data.derivation_path} finished',
+                )
diff --git a/rotkehlchen/chain/ethereum/compound.py b/rotkehlchen/chain/ethereum/compound.py
--- a/rotkehlchen/chain/ethereum/compound.py
+++ b/rotkehlchen/chain/ethereum/compound.py
@@ -608,7 +608,22 @@ def _process_events(
 
         for address, bentry in balances.items():
             for asset, entry in bentry['lending'].items():
-                profit_so_far[address][asset] += entry.balance
+                profit_amount = (
+                    profit_so_far[address][asset].amount +
+                    entry.balance.amount +
+                    assets[address][asset].amount
+                )
+                if profit_amount < 0:
+                    log.error(
+                        f'In compound we calculated negative profit. Should not happen. '
+                        f'address: {address} asset: {asset} ',
+                    )
+                else:
+                    usd_price = Inquirer().find_usd_price(Asset(asset))
+                    profit_so_far[address][asset] = Balance(
+                        amount=profit_amount,
+                        usd_value=profit_amount * usd_price,
+                    )
 
             for asset, entry in bentry['borrowing'].items():
                 remaining = entry.balance + loss_assets[address][asset]


Test patch:
Repository: rotki/rotki

Issue:
Replace defi protocol icons fetched from Zerion SDK
## Problem Definition

We need to remove the reliance on Zerion SDK's metadata for icons since it is deprecated and it will be removed.

> As for icons -- metadata for protocols has been deprecated and will be removed in the next release, so you should not rely on it (yes, we stopped downloading icons for the latest protocols)



Discussion:

Resolving patch:
diff --git a/rotkehlchen/chain/ethereum/zerion.py b/rotkehlchen/chain/ethereum/zerion.py
--- a/rotkehlchen/chain/ethereum/zerion.py
+++ b/rotkehlchen/chain/ethereum/zerion.py
@@ -41,11 +41,10 @@ class DefiProtocol(NamedTuple):
     name: str
     description: str
     url: str
-    icon_link: str
     version: int
 
     def serialize(self) -> Dict[str, str]:
-        return {'name': self.name, 'icon': self.icon_link}
+        return {'name': self.name}
 
 
 class DefiBalance(NamedTuple):
@@ -158,7 +157,6 @@ def all_balances_for_account(self, account: ChecksumEthAddress) -> List[DefiProt
                 name=entry[0][0],
                 description=entry[0][1],
                 url=entry[0][2],
-                icon_link=entry[0][3],
                 version=entry[0][4],
             )
             for adapter_balance in entry[1]:


Test patch:
diff --git a/rotkehlchen/tests/api/test_defi.py b/rotkehlchen/tests/api/test_defi.py
--- a/rotkehlchen/tests/api/test_defi.py
+++ b/rotkehlchen/tests/api/test_defi.py
@@ -26,7 +26,6 @@ def test_query_defi_balances(rotkehlchen_api_server, ethereum_accounts):  # pyli
         first_entry = result[AAVE_TEST_ACC_1][0]
         assert first_entry['protocol'] is not None
         assert first_entry['protocol']['name'] is not None
-        assert first_entry['protocol']['icon'] is not None
         assert first_entry['balance_type'] in ('Asset', 'Debt')
         assert first_entry['base_balance'] is not None
         assert first_entry['underlying_balances'] is not None
diff --git a/rotkehlchen/tests/integration/test_blockchain.py b/rotkehlchen/tests/integration/test_blockchain.py
--- a/rotkehlchen/tests/integration/test_blockchain.py
+++ b/rotkehlchen/tests/integration/test_blockchain.py
@@ -115,7 +115,7 @@ def test_multiple_concurrent_ethereum_blockchain_queries(blockchain):
     def mock_query_defi_balances():
         blockchain.defi_balances = {
             addr1: [DefiProtocolBalances(
-                protocol=DefiProtocol('a', 'b', 'c', 'd', 1),
+                protocol=DefiProtocol('a', 'b', 'c', 1),
                 balance_type='Asset',
                 base_balance=DefiBalance(
                     token_address=A_DAI.ethereum_address,
Repository: rotki/rotki

Issue:
Add YFI as supported collateral type in makerdao vaults
## Abstract

YFI was just added a supported collateral in makerdao vaults. We should also support that type of vault.

![2020-11-13_01-41](https://user-images.githubusercontent.com/1658405/99013739-7dea0700-2551-11eb-9868-cf416b606565.png)


## Task

Add support for it (is super easy)


Discussion:

Resolving patch:
diff --git a/rotkehlchen/chain/ethereum/makerdao/vaults.py b/rotkehlchen/chain/ethereum/makerdao/vaults.py
--- a/rotkehlchen/chain/ethereum/makerdao/vaults.py
+++ b/rotkehlchen/chain/ethereum/makerdao/vaults.py
@@ -18,6 +18,7 @@
 from rotkehlchen.chain.ethereum.utils import asset_normalized_value, token_normalized_value
 from rotkehlchen.constants import ZERO
 from rotkehlchen.constants.assets import (
+    A_BAL,
     A_BAT,
     A_COMP,
     A_DAI,
@@ -31,9 +32,11 @@
     A_USDC,
     A_USDT,
     A_WBTC,
+    A_YFI,
     A_ZRX,
 )
 from rotkehlchen.constants.ethereum import (
+    MAKERDAO_BAL_A_JOIN,
     MAKERDAO_BAT_A_JOIN,
     MAKERDAO_CAT,
     MAKERDAO_CDP_MANAGER,
@@ -55,6 +58,7 @@
     MAKERDAO_USDT_A_JOIN,
     MAKERDAO_VAT,
     MAKERDAO_WBTC_A_JOIN,
+    MAKERDAO_YFI_A_JOIN,
     MAKERDAO_ZRX_A_JOIN,
 )
 from rotkehlchen.constants.timing import YEAR_IN_SECONDS
@@ -89,6 +93,8 @@
     'COMP-A': MAKERDAO_COMP_A_JOIN,
     'LRC-A': MAKERDAO_LRC_A_JOIN,
     'LINK-A': MAKERDAO_LINK_A_JOIN,
+    'BAL-A': MAKERDAO_BAL_A_JOIN,
+    'YFI-A': MAKERDAO_YFI_A_JOIN,
 }
 COLLATERAL_TYPE_MAPPING = {
     'BAT-A': A_BAT,
@@ -106,6 +112,8 @@
     'COMP-A': A_COMP,
     'LRC-A': A_LRC,
     'LINK-A': A_LINK,
+    'BAL-A': A_BAL,
+    'YFI-A': A_YFI,
 }
 
 
diff --git a/rotkehlchen/constants/assets.py b/rotkehlchen/constants/assets.py
--- a/rotkehlchen/constants/assets.py
+++ b/rotkehlchen/constants/assets.py
@@ -36,6 +36,7 @@
 
 A_BTC = Asset(S_BTC)
 A_BCH = Asset('BCH')
+A_BAL = Asset('BAL')
 A_BSV = Asset('BSV')
 A_ETH = Asset(S_ETH)
 A_ETH2 = Asset('ETH2')
diff --git a/rotkehlchen/constants/ethereum.py b/rotkehlchen/constants/ethereum.py
--- a/rotkehlchen/constants/ethereum.py
+++ b/rotkehlchen/constants/ethereum.py
@@ -105,6 +105,8 @@ def abi(name: str) -> List[Dict[str, Any]]:
 MAKERDAO_COMP_A_JOIN = EthereumConstants().contract('MAKERDAO_COMP_A_JOIN')
 MAKERDAO_LRC_A_JOIN = EthereumConstants().contract('MAKERDAO_LRC_A_JOIN')
 MAKERDAO_LINK_A_JOIN = EthereumConstants().contract('MAKERDAO_LINK_A_JOIN')
+MAKERDAO_BAL_A_JOIN = EthereumConstants().contract('MAKERDAO_BAL_A_JOIN')
+MAKERDAO_YFI_A_JOIN = EthereumConstants().contract('MAKERDAO_YFI_A_JOIN')
 
 MAKERDAO_CAT = EthereumConstants().contract('MAKERDAO_CAT')
 MAKERDAO_JUG = EthereumConstants().contract('MAKERDAO_JUG')


Test patch:
Repository: rotki/rotki

Issue:
AMPL balance is counted double
## Problem Definition

A user reported that their AMPL balance is counted double.

I reproduced it. I suspect it's zerion's defi sdk again.

## Task

Solve it


Discussion:

Resolving patch:
diff --git a/rotkehlchen/chain/manager.py b/rotkehlchen/chain/manager.py
--- a/rotkehlchen/chain/manager.py
+++ b/rotkehlchen/chain/manager.py
@@ -89,6 +89,8 @@
     'yearn.finance • Vaults': True,  # True means all
     # Synthetix SNX token is in all_assets.json
     'Synthetix': ['SNX'],
+    # Ampleforth's AMPL token is in all_assets.json
+    'Ampleforth': ['AMPL'],
 }
 
 
diff --git a/rotkehlchen/externalapis/beaconchain.py b/rotkehlchen/externalapis/beaconchain.py
--- a/rotkehlchen/externalapis/beaconchain.py
+++ b/rotkehlchen/externalapis/beaconchain.py
@@ -128,10 +128,18 @@ def _query(
 
         return json_ret['data']
 
-    def get_balance(self, validator_indices: List[int]) -> Dict[int, ValidatorBalance]:
-        """Get the balance of all the validators given from the indices list
+    def get_balance_history(self, validator_indices: List[int]) -> Dict[int, ValidatorBalance]:
+        """Get the balance history of all the validators given from the indices list
 
-        Queries in chunks of 100 due to api limitations
+        https://beaconcha.in/api/v1/docs/index.html#/Validator/get_api_v1_validator__indexOrPubkey__balancehistory
+
+        Queries in chunks of 100 due to api limitations.
+
+        NOTICE: Do not use yet. The results seem incosistent. The list can accept
+        up to 100 validators, but the balance history is for the last 100 epochs
+        of each validator, limited to 100 results. So it's not really useful.
+
+        Their devs said they will have a look as this may not be desired behaviour.
 
         May raise:
         - RemoteError due to problems querying beaconcha.in API


Test patch:
diff --git a/rotkehlchen/tests/external_apis/test_beaconchain.py b/rotkehlchen/tests/external_apis/test_beaconchain.py
--- a/rotkehlchen/tests/external_apis/test_beaconchain.py
+++ b/rotkehlchen/tests/external_apis/test_beaconchain.py
@@ -39,14 +39,15 @@ def _assert_valid_balance_entry(entry):
     assert entry.epoch >= 0
 
 
-def test_get_balance_single(session_beaconchain):
-    balance_map = session_beaconchain.get_balance([9])
+def test_get_balance_history_single(session_beaconchain):
+    balance_map = session_beaconchain.get_balance_history([9])
     _assert_valid_balance_entry(balance_map[9])
 
 
-def test_get_balance_more_than_100(session_beaconchain):
+@pytest.mark.skip('Seems the endpoint behaviour is not consistent with the docs atm')
+def test_get_balance_history_more_than_100(session_beaconchain):
     indices = list(range(1, 105))
-    balance_map = session_beaconchain.get_balance(indices)
+    balance_map = session_beaconchain.get_balance_history(indices)
     assert len(indices) == len(balance_map)
     for index in indices:
         _assert_valid_balance_entry(balance_map[index])
Repository: rotki/rotki

Issue:
Support Kraken's ETH staked balances
## Abstract

https://blog.kraken.com/post/6988/ethereum-hodlers-earn-staking-rewards-and-support-the-upgrade-to-ethereum-2-0/

## Specification

As a first step just properly show the Staked eth balances.

For actual staking rewards and support we should implement: https://github.com/rotki/rotki/issues/569


Discussion:

Resolving patch:
diff --git a/rotkehlchen/assets/asset.py b/rotkehlchen/assets/asset.py
--- a/rotkehlchen/assets/asset.py
+++ b/rotkehlchen/assets/asset.py
@@ -127,6 +127,7 @@
     'ANT': 'ANT',
     'KEEP': 'KEEP',
     'TBTC': 'TBTC',
+    'ETH2': 'ETH2',
 }
 
 WORLD_TO_BINANCE = {
diff --git a/rotkehlchen/assets/converters.py b/rotkehlchen/assets/converters.py
--- a/rotkehlchen/assets/converters.py
+++ b/rotkehlchen/assets/converters.py
@@ -463,7 +463,7 @@ def asset_from_kraken(kraken_name: str) -> Asset:
     if kraken_name.endswith('.S') or kraken_name.endswith('.M'):
         # this is a staked coin. For now since we don't show staked coins
         # consider it as the normal version. In the future we may perhaps
-        # differentiate between them in the balances
+        # differentiate between them in the balances https://github.com/rotki/rotki/issues/569
         kraken_name = kraken_name[:-2]
 
     # Some names are not in the map since kraken can have multiple representations


Test patch:
diff --git a/rotkehlchen/tests/exchanges/test_kraken.py b/rotkehlchen/tests/exchanges/test_kraken.py
--- a/rotkehlchen/tests/exchanges/test_kraken.py
+++ b/rotkehlchen/tests/exchanges/test_kraken.py
@@ -31,6 +31,7 @@ def test_coverage_of_kraken_balances(kraken):
     got_assets.remove('USD.M')
     got_assets.remove('XBT.M')
     got_assets.remove('KSM.S')
+    got_assets.remove('ETH2.S')
     got_assets.remove('EUR.HOLD')
     got_assets.remove('FLOW.S')
     got_assets.remove('FLOWH.S')
Repository: rotki/rotki

Issue:
Allow users to add a beaconcha.in api key
## Abstract

We are using the [beaconcha.in API](https://beaconcha.in/api/v1/docs/index.html) for eth2 stuff at the moment. They are a pretty cool opensource beacon chain explorer. By default queries there have a limit of 10 queries per minute. In rotki we try to respect that limit by incrementally backing off if we get a 429 from them.

But a way to get around that limit and also support a cool project would be for a user who needs more queries to purchase an API key and increase the limits: https://beaconcha.in/pricing

## Task

- [ ] Allow addition of a beaconcha.in API key from the frontend
- [ ] Save an optional API key from the user in the beaconcha.in object and use it if it exists, much like we do in ethescan and cryptocompare.


Discussion:

Resolving patch:
diff --git a/rotkehlchen/externalapis/beaconchain.py b/rotkehlchen/externalapis/beaconchain.py
--- a/rotkehlchen/externalapis/beaconchain.py
+++ b/rotkehlchen/externalapis/beaconchain.py
@@ -31,7 +31,7 @@ class BeaconChain(ExternalServiceWithApiKey):
     """
 
     def __init__(self, database: 'DBHandler', msg_aggregator: MessagesAggregator) -> None:
-        super().__init__(database=database, service_name=ExternalService.ETHERSCAN)
+        super().__init__(database=database, service_name=ExternalService.BEACONCHAIN)
         self.msg_aggregator = msg_aggregator
         self.session = requests.session()
         self.warning_given = False
@@ -52,6 +52,9 @@ def _query(
             query_str = f'{self.url}{module}/{endpoint}/{encoded_args}'
         else:
             query_str = f'{self.url}{module}/{encoded_args}/{endpoint}'
+        api_key = self._get_api_key()
+        if api_key is not None:
+            query_str += '?apikey={api_key}'
         times = QUERY_RETRY_TIMES
         backoff_in_seconds = 10
 


Test patch:
diff --git a/frontend/app/tests/unit/components/settings/api-keys/external-services.spec.ts b/frontend/app/tests/unit/components/settings/api-keys/external-services.spec.ts
--- a/frontend/app/tests/unit/components/settings/api-keys/external-services.spec.ts
+++ b/frontend/app/tests/unit/components/settings/api-keys/external-services.spec.ts
@@ -5,6 +5,7 @@ import Vuetify from 'vuetify';
 import ExternalServices from '@/components/settings/api-keys/ExternalServices.vue';
 import { ExternalServiceKeys } from '@/model/action-result';
 import store from '@/store/store';
+import '../../../i18n';
 
 Vue.use(Vuetify);
Repository: rotki/rotki

Issue:
Suport the v2 Aave tokens
## Abstract

The v2 Aave tokens are detected thanks to the defi SDK and taken into account in the balance query. But they are not shown in the dashboard.

## Task

Add support for them and also show them in the Dashboard


Discussion:

Resolving patch:
diff --git a/rotkehlchen/assets/asset.py b/rotkehlchen/assets/asset.py
--- a/rotkehlchen/assets/asset.py
+++ b/rotkehlchen/assets/asset.py
@@ -135,6 +135,7 @@
     'AAVE': 'AAVE',
     'MANA': 'MANA',
     'GRT': 'GRT',
+    'FLOW': 'FLOW',
 }
 
 WORLD_TO_BINANCE = {


Test patch:
diff --git a/rotkehlchen/tests/exchanges/test_kraken.py b/rotkehlchen/tests/exchanges/test_kraken.py
--- a/rotkehlchen/tests/exchanges/test_kraken.py
+++ b/rotkehlchen/tests/exchanges/test_kraken.py
@@ -38,9 +38,7 @@ def test_coverage_of_kraken_balances(kraken):
     got_assets.remove('USD.HOLD')
     got_assets.remove('FLOW.S')
     got_assets.remove('FLOWH.S')
-    # Ignore the following assets as well
-    got_assets.remove('FLOW')
-    got_assets.remove('FLOWH')
+    got_assets.remove('FLOWH')  # what is FLOWH?
 
     diff = expected_assets.symmetric_difference(got_assets)
     if len(diff) != 0:
diff --git a/rotkehlchen/tests/fixtures/accounting.py b/rotkehlchen/tests/fixtures/accounting.py
--- a/rotkehlchen/tests/fixtures/accounting.py
+++ b/rotkehlchen/tests/fixtures/accounting.py
@@ -171,7 +171,7 @@ def create_inquirer(
     if not should_mock_current_price_queries:
         return inquirer
 
-    def mock_find_usd_price(asset):  # pylint: disable=unused-argument
+    def mock_find_usd_price(asset, ignore_cache: bool = False):  # pylint: disable=unused-argument
         return mocked_prices.get(asset, FVal('1.5'))
 
     inquirer.find_usd_price = mock_find_usd_price  # type: ignore
diff --git a/rotkehlchen/tests/unit/test_assets.py b/rotkehlchen/tests/unit/test_assets.py
--- a/rotkehlchen/tests/unit/test_assets.py
+++ b/rotkehlchen/tests/unit/test_assets.py
@@ -97,6 +97,8 @@ def test_cryptocompare_asset_support(cryptocompare):
         'MUST',    # Must (Cometh) but Must protocol in CC
         'SDT-2',   # Stake DAO token but TerraSDT in CC
         'BAC',     # Basis Cash but BACoin in CC
+        'IHF',     # waiting until cryptocompare fixes historical price for this. https://github.com/rotki/rotki/pull/2176  # noqa: E501
+        'FLOW',    # FLOW from dapper labs but "Flow Protocol" in CC
     )
     for identifier, asset_data in AssetResolver().assets.items():
         potential_support = (
@@ -281,7 +283,7 @@ def test_coingecko_identifiers_are_reachable(data_dir):
 def test_assets_json_meta():
     """Test that all_assets.json md5 matches and that if md5 changes since last
     time then version is also bumped"""
-    last_meta = {'md5': '931775d33b57e0431c85538d658caa08', 'version': 45}
+    last_meta = {'md5': '7969237a9e90ff27d35c29e2ff2fe895', 'version': 47}
     data_dir = Path(__file__).resolve().parent.parent.parent / 'data'
     data_md5 = file_md5(data_dir / 'all_assets.json')
Repository: rotki/rotki

Issue:
Ledger action should export rotki identifier and not name to CSV
## Problem Definition

The ledger action CSV export contains names and not the rotki identifier for each asset. Change the below to be `action.asset.identifier`

https://github.com/rotki/rotki/blob/74bf51c4e6de32b938778620d88723f663c85ff3/rotkehlchen/csv_exporter.py#L507

Pull Request for this should be made against the **bugfixes** branch.

## Task

Fix it. Include the identifier in the export, not the name.




Discussion:

Resolving patch:
diff --git a/rotkehlchen/csv_exporter.py b/rotkehlchen/csv_exporter.py
--- a/rotkehlchen/csv_exporter.py
+++ b/rotkehlchen/csv_exporter.py
@@ -504,7 +504,7 @@ def add_ledger_action(
             'time': self.timestamp_to_date(action.timestamp),
             'type': str(action.action_type),
             'location': str(action.location),
-            'asset': str(action.asset),
+            'asset': action.asset.identifier,
             'amount': str(action.amount),
             f'profit_loss_in_{self.profit_currency.identifier}': profit_loss_in_profit_currency,
         })


Test patch:
Repository: rotki/rotki

Issue:
Using a cryptocompare API key can result in api call errors
## Problem Definition

As can be seen by the [OSX nightlies](https://github.com/rotki/rotki/runs/1803162702?check_suite_focus=true) we have had some failures related to cryptocompare.

It seems that we only use cryptocompare api keys in OSX due to the rate limiting. I don't remember exactly why. But this is why we did not see a failure elsewhere in the tests.

## Task

Fix the bug


Discussion:

Resolving patch:
diff --git a/rotkehlchen/externalapis/cryptocompare.py b/rotkehlchen/externalapis/cryptocompare.py
--- a/rotkehlchen/externalapis/cryptocompare.py
+++ b/rotkehlchen/externalapis/cryptocompare.py
@@ -312,7 +312,8 @@ def _api_query(self, path: str) -> Dict[str, Any]:
         log.debug('Querying cryptocompare', url=querystr)
         api_key = self._get_api_key()
         if api_key:
-            querystr += f'&api_key={api_key}'
+            querystr += '?' if '?' not in querystr else '&'
+            querystr += f'api_key={api_key}'
 
         tries = CRYPTOCOMPARE_QUERY_RETRY_TIMES
         while tries >= 0:


Test patch:
diff --git a/rotkehlchen/tests/external_apis/test_cryptocompare.py b/rotkehlchen/tests/external_apis/test_cryptocompare.py
--- a/rotkehlchen/tests/external_apis/test_cryptocompare.py
+++ b/rotkehlchen/tests/external_apis/test_cryptocompare.py
@@ -429,3 +429,17 @@ def is_price_not_valid(hour_price_data):
                 f'with a smaller timestamp.'
             )
             test_warnings.warn(UserWarning(warning_msg))
+
+
+@pytest.mark.parametrize('include_cryptocompare_key', [True])
+def test_cryptocompare_query_with_api_key(cryptocompare):
+    """Just try to query cryptocompare endpoints with an api key
+
+    Regression test for https://github.com/rotki/rotki/issues/2244
+    """
+    # call to an endpoint without any args
+    response = cryptocompare._api_query('v2/news/')
+    assert response and isinstance(response, list)
+    # call to endpoint with args
+    price = cryptocompare.query_current_price(A_ETH, A_USD)
+    assert price is not None
Repository: rotki/rotki

Issue:
Staked Cream price appears incorrectly
In version 1.13.0 of Rotki the staked Cream price and logo appear incorrectly. The CRM's price and logo show up instead of CREAM's.

The previous version of Rotki was showing the price correctly but the logo was still incorrect.

I think cryptocompare is used as price oracle for CREAM.


Discussion:

Resolving patch:
diff --git a/rotkehlchen/icons.py b/rotkehlchen/icons.py
--- a/rotkehlchen/icons.py
+++ b/rotkehlchen/icons.py
@@ -26,7 +26,7 @@ class IconManager():
     a point query the same icon but that's fine and not worth of locking mechanism as
     it should be rather rare and worst case scenario once in a blue moon we waste
     an API call. In the end the right file would be written on disk.
-"""
+    """
 
     def __init__(self, data_dir: Path, coingecko: Coingecko) -> None:
         self.icons_dir = data_dir / 'icons'


Test patch:
diff --git a/rotkehlchen/tests/unit/test_assets.py b/rotkehlchen/tests/unit/test_assets.py
--- a/rotkehlchen/tests/unit/test_assets.py
+++ b/rotkehlchen/tests/unit/test_assets.py
@@ -99,6 +99,9 @@ def test_cryptocompare_asset_support(cryptocompare):
         'BAC',     # Basis Cash but BACoin in CC
         'IHF',     # waiting until cryptocompare fixes historical price for this. https://github.com/rotki/rotki/pull/2176  # noqa: E501
         'FLOW',    # FLOW from dapper labs but "Flow Protocol" in CC
+        'NCT-2',   # Name change token but Polyswarm in CC
+        'NDX',     # newdex token but Index token in CC
+        'ARCH-2',  # Archer DAO Governance token but Archcoin in CC
     )
     for identifier, asset_data in AssetResolver().assets.items():
         potential_support = (
@@ -185,7 +188,7 @@ def test_coingecko_identifiers_are_reachable(data_dir):
 def test_assets_json_meta():
     """Test that all_assets.json md5 matches and that if md5 changes since last
     time then version is also bumped"""
-    last_meta = {'md5': '673a4f1efdfd06086fe53baf79236842', 'version': 50}
+    last_meta = {'md5': 'e1a3a3d5f8d988176a6f1143cdfa3d6b', 'version': 51}
     data_dir = Path(__file__).resolve().parent.parent.parent / 'data'
     data_md5 = file_md5(data_dir / 'all_assets.json')