Commit Graph

479 Commits (go1.14)

Author SHA1 Message Date
Martin Boehm ee3217aba8 Use common.JSONNumber instead of json.Number 2020-05-10 00:14:14 +02:00
hewigovens 3ba7289587 Add data field to EthereumSpecific 2020-05-09 21:43:33 +02:00
Martin Boehm 997fa661e7 Merge branch 'master' into gomod 2020-05-09 01:50:51 +02:00
Martin Boehm 8a926a0799 Merge branch 'master' of github.com:trezor/blockbook 2020-05-02 17:25:10 +02:00
Martin Boehm 828e10b629 Parsing of ERC20 name, symbol and decimals in different format #400 2020-05-02 17:24:56 +02:00
Scotty0448 7eb4675f54 Update Ravencoin support 2020-04-16 09:55:34 +02:00
ciripel 124dee84fa
SnowGem Support (#342)
* SnowGem Support

* changed bynary_url to debian9.11 source
The Debian Source contain also the fetch_params.sh

* changed sha256 source

* Fix integration tests config file after merge

* Implemented snowgem parser

* fixed paxkedTx

* Fixed testdata tx hex

Co-authored-by: Martin <martin.boehm@1mbsoftware.net>
2020-04-11 16:34:37 +02:00
Martin Boehm c43a7a4feb Merge branch 'gomod' of https://github.com/dajohi/blockbook into gomod 2020-03-21 01:17:42 +01:00
ilmango e99a8eba65
Add BitZeny (ZNY) (#383)
* Add BitZeny

* Fix test packed tx

* Fix exec command template
2020-03-21 00:39:24 +01:00
David Hill 13527bda06 build: go module support 2020-03-05 11:54:42 -05:00
Martin Boehm 53cc6237a7 Format all ethereum addresses as EIP55 2020-03-04 10:17:47 +01:00
Martin Boehm f761dbec2a Fix linting errors 2020-03-03 10:22:11 +01:00
omotenashicoin-project 2d430aa80b added MTNS 2020-02-25 18:24:00 +01:00
Martin Boehm 273b880245 Add load address by serialized address descriptor 2020-02-24 23:11:46 +01:00
Martin Boehm 7e35bac99c Remove etc specific code after upgrade to multi-geth backend 2020-02-11 12:08:03 +01:00
Martin Boehm aceadbb10c Fix formatting and linting errors 2020-01-22 16:07:30 +01:00
Dali e4231a2eaa Add Bitcore (BTX) 2020-01-14 11:57:46 +01:00
random.zebra b7a430574f PIVX (+testnet): Bump backend 3.1.1 -> 4.0.0 (#340)
* PIVX: bump to 4.0.0

* PIVX: remove AccCheckpoint in block version 7

ref https://github.com/PIVX-Project/PIVX/pull/1022

* PIVX: Test block v7 in pivxparser_test
2020-01-03 12:45:40 +01:00
Martin Boehm 1cec22ecba Merge branch 'master' into balanceHistory 2019-12-17 11:52:33 +01:00
Vladyslav Burzakovskyy f6111af5da Add fiat rates functionality (#316)
* Add initial commit for fiat rates functionality

* templates.go: use bash from current user's environment

* bitcoinrpc.go: add FiatRates and FiatRatesParams to config

* blockbook.go: add initFiatRatesDownloader kickoff

* bitcoin.json: add coingecko API URL

* rockdb.go: add FindTicker and StoreTicker functions

* rocksdb_test.go: add a simple test for storing and getting FiatRate tickers

* rocksdb: add FindLastTicker and convertDate, make FindTicker return strings

* rocksdb: add ConvertDate function and CoinGeckoTicker struct, update tests

* blockbook.go, fiat: finalize the CoinGecko downloader

* coingecko.go: do not stop syncing when encountered an error

* rocksdb_test: fix the exported function name

* worker.go: make getBlockInfoFromBlockID a public function

* public.go: apiTickers kickoff

* rocksdb_test: fix the unittest comment

* coingecko.go: update comments

* blockbook.go, fiat: reword CoinGecko -> FiatRates, fix binary search upper bound, remove assignment of goroutine call result

* rename coingecko -> fiat_rates

* fiat_rates: export only the necessary methods

* blockbook.go: update log message

* bitcoinrpc.go: remove fiatRates settings

* use CurrencyRatesTicker structure everywhere, fix time format string, update tests, use UTC time

* add /api/v2/tickers tests, store rates as strings (json.Number)

* fiat_rates: add more tests, metrics and tickers-list endpoint, make the "currency" parameter mandatory

* public, worker: move FiatRates API logic to worker.go

* fiat_rates: add a future date test, fix comments, add more checks, store time as a pointer

* rocksdb_test: remove unneeded code

* fiat_rates: add a "ping" call to check server availability

* fiat_rates: do not return empty ticker, return nil instead if not found

add a test for non-existent ticker

* rocksdb_test: remove Sleep from tests

* worker.go: do not propagate all API errors to the client

* move InitTestFiatRates from rocksdb.go to public_test.go

* public.go: fix FiatRatesFindLastTicker result check

* fiat_rates: mock API server responses

* remove commented-out code

* fiat_rates: add comment explaining what periodSeconds attribute is used for

* websocket.go: implement fiatRates websocket endpoints & add tests

* fiatRates: add getFiatRatesTickersList websocket endpoint & test

* fiatRates: make websocket getFiatRatesByDate accept an array of dates, add more tests

* fiatRates: remove getFiatRatesForBlockID from websocket endpoints

* fiatRates: remove "if test", use custom startTime instead

Update tests and mock data

* fiatRates: finalize websocket functionality

add "date" parameter to TickerList

return data timestamps where needed

fix sync bugs (nil timestamp, duplicate save)

* fiatRates: add FiatRates configs for different coins

* worker.go: make GetBlockInfoFromBlockID private again

* fiatRates: wait & retry on errors, remove Ping function

* websocket.go: remove incorrect comment

* fiatRates: move coingecko-related code to a separate file, use interface

* fiatRates: if the new rates are the same as previous, try five more times, and only then store them

* coingecko: fix getting actual rates, add a timestamp parameter to get uncached responses

* vertcoin_testnet.json: remove fiat rates parameters

* fiat_rates: add timestamp to log message about skipping the repeating rates
2019-12-17 10:40:02 +01:00
Martin Boehm 6f294a6241 Add get balance history for ethereum type coins 2019-12-10 21:08:27 +01:00
Martin Boehm 5600e0d30a Fix formatting/linting issues 2019-11-23 14:34:53 +01:00
Martin Boehm e754a6c0fd Fix incorrect registration of network params in unobtanium and viacoin 2019-11-23 14:34:53 +01:00
Liam Alford 3853520a0f Add DeepOnion (#298)
* Add DeepOnion

* Fix config bugs

* Use base pack/unpck TX

* Fix empty array causing test failure.

* Fix config files and executable.

* Fix sync issue

* Fix integration tetsts
2019-11-23 14:34:53 +01:00
Martin Boehm f7bbffa4c9 Fix formatting/linting issues 2019-11-19 11:15:00 +01:00
Martin Boehm c45312edf1 Fix incorrect registration of network params in unobtanium and viacoin 2019-11-19 11:13:15 +01:00
Liam Alford 4134934031 Add DeepOnion (#298)
* Add DeepOnion

* Fix config bugs

* Use base pack/unpck TX

* Fix empty array causing test failure.

* Fix config files and executable.

* Fix sync issue

* Fix integration tetsts
2019-11-18 17:51:45 +01:00
Martin Boehm 262ca3e2e4 Fix litecoin address parsing issue #254 2019-10-23 14:00:56 +02:00
Martin Boehm 4eff57189d Fix ETH address API - some tokens are missing #271 2019-09-30 17:28:10 +02:00
Martin Boehm ac9a721cc6 Format Ethereum addresses with EIP55 checksum 2019-09-30 17:11:17 +02:00
Martin Boehm 8851c649d5 Fix linting errors 2019-09-23 09:38:48 +02:00
migwi f28c6bcf61 Check unindexed confirmed tx height for decred 2019-09-22 17:31:04 +02:00
migwi d4a7fcabd9 Check if unindexed confirmed tx height exists 2019-09-18 22:35:53 +02:00
Min Khang Aung 24725a21a9 Add CPUchain support (#288)
* Add CPUchain support

* Update cpuchain.json
2019-09-16 22:32:08 +02:00
TheCreator 12c4217f94 Add Unobtanium (#276)
* Create Unobtanium Configs

* Add Unobtanium

* Add Unobtanium

* Add files via upload

* Add files via upload

* Add files via upload

* Add files via upload

* Fix Unobtanium xpub_magic

* Fix Server/Client config files

TODO: Maybe remove reindex: 1 from additional params.

* Fix xpub

* Reduce the polling interval

As suggested by martinboehm, copied from viacoin

* Remove GetBlockHeader

Fails Integration tests.
2019-09-15 22:53:51 +02:00
Martin Boehm 3a8da67752 Fix linting errors 2019-08-21 23:11:50 +02:00
Migwi Ndung'u 5ea4bbded6 Fix decred's xpub decoding (#249)
* Add the decred xpub decoding implementation

* Fix the address decoding

* Resolve the extended public key path

* Add tests for DeriveAddressDescriptors and DeriveAddressDescriptorsFromTo methods

* Add TestDerivationBasePath

* Add tests for pack and unpack methods
2019-08-21 19:31:23 +02:00
James Scaur d6375a19dd Add support for DIVI (#228)
* Add Divi Project (DIVI) support

* Remove PivX comments, add Divi RPC tests

* Merge with latest Blockbook state

* Fix permissions issue with automatic setup

* Recreate integration tests with block 430894

* Remove GetBlockHeader test

* Increase frequency of mempool sync
2019-08-21 19:07:35 +02:00
Martin Boehm be393c6d5d Update dependency of btcutil library 2019-08-04 12:54:54 +02:00
Martin Boehm 39f2c73f3e Add coinbase flag (boolean) to UTXO response #236 2019-07-23 12:52:18 +02:00
Panu 63b4719179 Bump Zcoin to 0.13.8.2 and support sigma transaction (#235)
* Added support for sigma

* Bump Zcoin to 0.13.7.10

* Change exclude files list
2019-07-19 19:37:33 +02:00
Migwi Ndung'u 91691ed7e7 Add decred support (#216) 2019-07-07 22:41:01 +02:00
CodeFace 4eaeb25a5e qtum feerate check
it seems there is an issue with qtum core rpc that "estimatesmartfee" can return feerate lower than minFeeRate sometimes
2019-06-27 10:00:02 +02:00
Martin Boehm 480523a2b3 Fix linting issues 2019-06-11 17:22:24 +02:00
Martin Boehm d52bd0352d Handle error on ethereum openRPC 2019-06-11 16:30:21 +02:00
Martin Boehm d5f11561ac Catch and log panic in blockbook main 2019-06-11 16:27:47 +02:00
Martin Boehm c4487ac94b Try to reconnect ethereum RPC in case of network failure 2019-06-10 16:48:31 +02:00
Martin Boehm 34e5599362 Try to reconnect ethereum RPC in case of network failure 2019-06-10 13:48:46 +02:00
Martin Boehm d7d596bf4b Stop passing error details to prometheus metrics 2019-06-04 13:09:15 +02:00
Martin Boehm c409a350c9 Try to reconnect ethereum RPC 2019-06-03 17:48:09 +02:00