stampchain-io / btc_stamps

Bitcoin Stamps Indexer
https://stampchain.io
GNU Affero General Public License v3.0
14 stars 5 forks source link

SRC-101 Activation [skip-version] #457

Closed reinamora137 closed 2 weeks ago

reinamora137 commented 2 weeks ago

failing src20 checks with: EDIT: updated src20 tests.

======================================================================
ERROR: test_src20_variations (test_src20.TestSrc20Variations.test_src20_variations) [SRC-20 token transfer, scenario No.9 (Variant 4)]
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/btc_stamps/btc_stamps/indexer/test_src20.py", line 52, in test_src20_variations
    stamp_data_instance = StampData(
                          ^^^^^^^^^^
TypeError: StampData.__init__() missing 2 required positional arguments: 'prev_tx_hash' and 'destination_nvalue'

======================================================================
ERROR: test_src20_variations (test_src20.TestSrc20Variations.test_src20_variations) [SRC-20 token mint, scenario No.10 (Variant 1)]
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/btc_stamps/btc_stamps/indexer/test_src20.py", line 52, in test_src20_variations
    stamp_data_instance = StampData(
                          ^^^^^^^^^^
TypeError: StampData.__init__() missing 2 required positional arguments: 'prev_tx_hash' and 'destination_nvalue'

minor lint errors:

./src/index_core/src101.py:63:5: C901 'Src101Validator.process_values' is too complex (24)
./src/index_core/src101.py:122:13: E722 do not use bare 'except'
./src/index_core/src101.py:136:12: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:143:36: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:150:12: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:171:25: F841 local variable 'int_key' is assigned to but never used
./src/index_core/src101.py:172:21: E722 do not use bare 'except'
./src/index_core/src101.py:187:9: E722 do not use bare 'except'
./src/index_core/src101.py:224:26: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:229:9: E722 do not use bare 'except'
./src/index_core/src101.py:249:5: C901 'Src101Validator._process_tokenid_value' is too complex (15)
./src/index_core/src101.py:250:12: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:269:17: F841 local variable 'e' is assigned to but never used
./src/index_core/src101.py:278:14: E721 do not compare types, for exact checks use `is` / `is not`, for instance checks use `isinstance()`
./src/index_core/src101.py:287:13: F841 local variable 'e' is assigned to but never used
./src/index_core/src101.py:436:5: C901 'Src101Processor.handle_mint' is too complex (27)
./src/index_core/src101.py:516:17: F841 local variable 'e' is assigned to but never used
./src/index_core/src101.py:532:21: F841 local variable 'inner_e' is assigned to but never used
./src/index_core/src101.py:616:13: F841 local variable 'src101_preowner' is assigned to but never used
./src/index_core/src101.py:662:5: C901 'Src101Processor.handle_renew' is too complex (13)
./src/index_core/src101.py:757:5: C901 'Src101Processor.handle_setrecord' is too complex (12)
./src/index_core/src101.py:797:16: E713 test for membership should be 'not in'
./src/index_core/src101.py:819:46: E712 comparison to True should be 'if cond is True:' or 'if cond:'
./src/index_core/src101.py:827:16: E713 test for membership should be 'not in'
./src/index_core/src101.py:933:5: E722 do not use bare 'except'
./src/index_core/src101.py:937:1: C901 'check_src101_inputs' is too complex (19)
./src/index_core/src101.py:1001:1: C901 'update_src101_owners' is too complex (15)
./src/index_core/src101.py:1114:58: E712 comparison to True should be 'if cond is True:' or 'if cond:'