Commit graph

753 commits

Author SHA1 Message Date
pbattu123
b68e6ce854
Fix unit test failures (#289)
* fixed unit test failures from the recent merges

* fixed unit test failures from the recent merges
2020-02-20 23:38:38 +05:30
gladcow
544112c63b
[SON-209] Create P2SH address with custom redeemScript (#271)
* Create redeem script for SONs primary wallet

* Add importaddress call

Allows to watch for related transactions without private keys import

* Get UTXO set for watched addresses

* createrawtransaction call

* signing PW spending transaction

* unit test for btc tx serialization

* sending PW transfer in test

* BIP143 tx signing

* use bech32 address format

* use single sha256 for lock script

* Digest fix

* working signing

* separate signing

* test partially signed PW transfer
2020-02-19 17:16:27 +05:30
obucinac
a8eb4227aa
Support multiple SON nodes per software instance (#282)
* Extend GPO.active_sons to contain votes and all public keys

* Introduce son_wallet_object

* son_wallet_object operations

* son_wallet_object operations

* son_wallet_object operations completed, basic tests added

* Create son_wallet_object on new set of SONs, to initiate primary wallet recreation

* son_wallet_object API and cli wallet commands

* Send RPC command to bitcoin node to recreate multisig wallet

* Send RPC command to bitcoin node to recreate multisig wallet

* Send RPC command to bitcoin node to recreate multisig wallet

* Wallet recreation by scheduled SON only, some cosmetic refactoring

* Wallet recreation by scheduled SON only, some cosmetic refactoring

* Updating wallet info through operation instead through database.modify() for persistance

* SON wallet transfer object and operations, for tracking assets deposit/withdrawal

* Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp

Co-Authored-By: gladcow <jahr@yandex.ru>

* Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp

Co-Authored-By: gladcow <jahr@yandex.ru>

* Fix #include <graphene/chain/son_wallet_transfer_object.hpp>

* SON wallet transfer object and operations, for tracking assets deposit/withdrawal

* SON wallet transfer object and operations, for tracking assets deposit/withdrawal

* Refactor primary wallet recreation

* Refactor primary wallet recreation

* PW recreation refactoring, prevent duplicated recreations, update wallet address through proposal

* PW recreation refactoring, prevent duplicated recreations, update wallet address through proposal

* Quickfix for checking payer in evaluator

* Quickfix for checking payer in evaluator

* Fix failing son_wallet_tests

- Check for son_btc_account is temporarely disabled

* Remove redundant file

* Squashed commit of the following:

commit a688bb93ed
Author: obucinac <obucinac@users.noreply.github.com>
Date:   Tue Feb 4 19:31:45 2020 +0100

    son_wallet_object operations and multisig wallet recreation by RPC (#263)

    * Extend GPO.active_sons to contain votes and all public keys

    * Introduce son_wallet_object
    * son_wallet_object operations
    * Create son_wallet_object on new set of SONs, to initiate primary wallet recreation
    * son_wallet_object API and cli wallet commands
    * Send RPC command to bitcoin node to recreate multisig wallet
    * Updating wallet info through operation instead through database.modify() for persistance
    * Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp
    * Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp
    * Fix #include <graphene/chain/son_wallet_transfer_object.hpp>
    * Refactor primary wallet recreation
    * PW recreation refactoring, prevent duplicated recreations, update wallet address through proposal
    * Quickfix for checking payer in evaluator
    * Fix failing son_wallet_tests
    - Check for son_btc_account is temporarely disabled
    * Remove redundant file
    Co-authored-by: gladcow <jahr@yandex.ru>

commit 6e61d6b055
Author: satyakoneru <satyakoneru.iiith@gmail.com>
Date:   Tue Feb 4 00:14:39 2020 +1100

    SON233 - Provide correct downtime metrics to user (#278)

* Remove duplicated item in CMakeLists.txt

* Issue tokens to the user who deposited Bitcoin, WIP...

* Add son_wallet_transfer_process_operation

* Issue tokens to the user who deposited Bitcoin, WIP...

* Support multiple SON nodes per software instance

* Add is_active_son guards for sidechain events processing

* Add is_active_son guards, fix sending proposals and aprovals

* Managing GRAPHENE_SON_ACCOUNT and issuing assets on Bitcoin deposit

* Fix bad param

* Fix aprovals on already approved or invalid proposals

* Move transfer inside son_wallet_transfer_process_operation

* Fix merging issue

* Add cmake command line option SUPPORT_MULTIPLE_SONS

* Temoprary disable account history tests for tracking accounts

Co-authored-by: gladcow <jahr@yandex.ru>
2020-02-19 17:06:58 +05:30
pbattu123
046ee5b75c
Merge pull request #257 from peerplays-network/feature/GRPH-205
Backport ElasticSearch plugins from BitShares
2020-02-13 08:46:45 -04:00
pbattu123
0b280882af
Merge beatrice(GPOS changes) with master (#270)
* Created unit test for #325

* remove needless find()

* issue - 154: Don't allow to vote when vesting balance is 0

* Increase block creation timeout to 2500ms

* increase delay for node connection

* remove cache from cli get_account

* add cli tests framework

* Adjust newly merged code to new API

* Merged changes from Bitshares PR 1036

* GRPH-76 - Short-cut long sequences of missed blocks

Fixes database::update_global_dynamic_data to speed up counting missed blocks.
(This also fixes a minor issue with counting - the previous algorithm would skip missed blocks for the witness who signed the first block after the gap.)

* Improved resilience of block database against corruption

* Moved reindex logic into database / chain_database, make use of additional blocks in block_database

Fixed tests wrt db.open

* Enable undo + fork database for final blocks in a replay

Dont remove blocks from block db when popping blocks, handle edge case in replay wrt fork_db, adapted unit tests

* Log starting block number of replay

* Prevent unsigned integer underflow

* Fixed lock detection

* Dont leave _data_dir empty if db is locked

* Writing the object_database is now almost atomic

* Improved consistency check for block_log

* Cut back block_log index file if inconsistent

* Fixed undo_database

* Added test case for broken merge on empty undo_db

* exclude second undo_db.enable() call in some cases

* Add missing change

* change bitshares to core in message

* Merge pull request #938 from bitshares/fix-block-storing

Store correct block ID when switching forks

* Fixed integer overflow issue

* Fix for for history ID mismatch ( Bitshares PR #875 )

* Update the FC submodule with the changes for GRPH-4

* Merged Bitshares PR #1462 and compilation fixes

* Support/gitlab (#123)

* Updated gitlab process

* Fix undefined references in cli test

* Updated GitLab CI

* Fix #436 object_database created outside of witness data directory

* supplement more comments on database::_opened variable

* prevent segfault when destructing application obj

* Fixed test failures and compilation issue

* minor performance improvement

* Added comment

* Fix compilation in debug mode

* Fixed duplicate ops returned from get_account_history

* Fixed account_history_pagination test

* Removed unrelated comment

* Update to fixed version of fc

* Skip auth check when pushing self-generated blocks

* Extract public keys before pushing a transaction

* Dereference chain_database shared_ptr

* Updated transaction::signees to mutable

and
* updated get_signature_keys() to return a const reference,
* get_signature_keys() will update signees on first call,
* modified test cases and wallet.cpp accordingly,
* no longer construct a new signed_transaction object before pushing

* Added get_asset_count API

* No longer extract public keys before pushing a trx

and removed unused new added constructor and _get_signature_keys() function from signed_transaction struct

* changes to withdraw_vesting feature(for both cdd and GPOS)

* Comments update

* update to GPOS hardfork ref

* Remove leftover comment from merge

* fix for get_vesting_balance API call

* braces update

* Allow sufficient space for new undo_session

* Throw for deep nesting

* node.cpp: Check the attacker/buggy client before updating items ids

The peer is an attacker or buggy, which means the item_hashes_received is
not correct.

Move the check before updating items ids to save some time in this case.

* Create .gitlab-ci.yml

* Added cli_test to CI

* fixing build errors (#150)

* fixing build errors

vest type correction

* fixing build errors

vest type correction

* fixes 

new Dockerfile

* vesting_balance_type correction

vesting_balance_type changed to normal

* gcc5 support to Dockerfile

gcc5 support to Dockerfile

* use random port numbers in app_test (#154)

* Changes to compiple with GCC 7(Ubuntu 18.04)

* proposal fail_reason bug fixed (#157)

* Added Sonarcloud code_quality to CI (#159)

* Added sonarcloud analysis (#158)

* changes to have separate methods and single withdrawl fee for multiple vest objects

* 163-fix, Return only non-zero vesting balances

* Support/gitlab develop (#168)

* Added code_quality to CI

* Update .gitlab-ci.yml

* Point to PBSA/peerplays-fc commit f13d063 (#167)

* [GRPH-3] Additional cli tests (#155)

* Additional cli tests

* Compatible with latest fc changes

* Fixed Spacing issues

* [GRPH-106] Added voting tests (#136)

* Added more voting tests

* Added additional option

* Adjust p2p log level (#180)

* merge gpos to develop (#186)

* issue - 154: Don't allow to vote when vesting balance is 0

* changes to withdraw_vesting feature(for both cdd and GPOS)

* Comments update

* update to GPOS hardfork ref

* fix for get_vesting_balance API call

* braces update

* Create .gitlab-ci.yml

* fixing build errors (#150)

* fixing build errors

vest type correction

* fixing build errors

vest type correction

* fixes 

new Dockerfile

* vesting_balance_type correction

vesting_balance_type changed to normal

* gcc5 support to Dockerfile

gcc5 support to Dockerfile

* Changes to compiple with GCC 7(Ubuntu 18.04)

* changes to have separate methods and single withdrawl fee for multiple vest objects

* 163-fix, Return only non-zero vesting balances

* Revert "Revert "GPOS protocol""

This reverts commit 67616417b7.

* add new line needed to gpos hardfork file

* comment temporally cli_vote_for_2_witnesses until refactor or delete

* fix gpos tests

* fix gitlab-ci conflict

* Fixed few error messages

* error message corrections at other places

* Updated FC repository to peerplays-network/peerplays-fc (#189)

Point to fc commit hash 6096e94 [latest-fc branch]

* Project name update in Doxyfile (#146)

* changes to allow user to vote in each sub-period

* Fixed GPOS vesting factor issue when proxy is set

* Added unit test for proxy voting

* Review changes

* changes to update last voting time

* resolve merge conflict

* unit test changes and also separated GPOS test suite

* delete unused variables

* removed witness check

* eliminate time gap between two consecutive vesting periods

* deleted GPOS specific test suite and updated gpos tests

* updated GPOS hf

* Fixed dividend distribution issue and added test case

* fix flag

* clean newlines gpos_tests

* adapt gpos_tests to changed flag

* Fix to roll in GPOS rules, carry votes from 6th sub-period

* check was already modified

* comments updated

* updated comments to the benefit of reviewer

* Added token symbol name in error messages

* Added token symbol name in error messages (#204)

* case 1: Fixed last voting time issue

* get_account bug fixed

* Fixed flag issue

* Fixed spelling issue

* remove non needed gcc5 changes to dockerfile

* GRPH134- High CPU Issue, websocket changes (#213)

* update submodule branch to refer to the latest commit on latest-fc branch (#214)

* Improve account maintenance performance (#130)

* Improve account maintenance performance

* merge fixes

* Fixed merge issue

* Fixed indentations and extra ';'

* Update CI for syncing gitmodules (#216)

* Added logging for the old update_expired_feeds bug

The old bug is https://github.com/cryptonomex/graphene/issues/615 .

Due to the bug, `update_median_feeds()` and `check_call_orders()`
will be called when a feed is not actually expired, normally this
should not affect consensus since calling them should not change
any data in the state.

However, the logging indicates that `check_call_orders()` did
change some data under certain circumstances, specifically, when
multiple limit order matching issue (#453) occurred at same block.
* https://github.com/bitshares/bitshares-core/issues/453

* Minor performance improvement for price::is_null()

* Use static refs in db_getter for immutable objects

* Minor performance improvement for db_maint

* Minor code updates for asset_evaluator.cpp

* changed an `assert()` to `FC_ASSERT()`
* replaced one `db.get(asset_id_type())` with `db.get_core_asset()`
* capture only required variables for lambda

* Improve update_expired_feeds performance #1093

* Change static refs to member pointers of db class

* Added getter for witness schedule object

* Added getter for core dynamic data object

* Use getters

* Removed unused variable

* Add comments for update_expired_feeds in db_block

* Minor refactory asset_create_evaluator::do_apply()

* Added FC_ASSERT for dynamic data id of core asset

* Added header inclusions in db_management.cpp

* fix global objects usage during replay

* Logging config parsing issue

* added new files

* compilation fix

* Simplified code in database::pay_workers()

* issue with withdrawl

* Added unit test for empty account history

* set extensions default values

* Update GPOS hardfork date and don't allow GPOS features before hardfork time

* refer to latest commit of latest-fc branch (#224)

* account name or id support in all database api

* asset id or name support in all asset APIs

* Fixed compilation issues

* Fixed alignment issues

* Externalized some API templates

* Externalize serialization of blocks, tx, ops

* Externalized db objects

* Externalized genesis serialization

* Externalized serialization in protocol library

* Undo superfluous change

* remove default value for extension parameter

* fix compilation issues

* GRPH-46-Quit_command_cliwallet

* removed multiple function definition

* Fixed chainparameter update proposal issue

* Move GPOS withdraw logic to have single transaction(also single fee) and update API

* Added log for authorization failure of proposal operations

* Votes consideration on GPOS activation

* bump fc version

* fix gpos tests

* Bump fc version

* Updated gpos/voting_tests

* Fixed withdraw vesting bug

* Added unit test

* Update hardfork date for TESTNET, sync fc module and update logs

* avoid wlog as it filling up space

* Beatrice hot fix(sync issue fix)

* gpos tests fix

* Set hardfork date to Jan5th on TESTNET

Co-authored-by: Peter Conrad <github.com@quisquis.de>
Co-authored-by: John M. Jones <jmjatlanta@gmail.com>
Co-authored-by: obucinac <obucinac@users.noreply.github.com>
Co-authored-by: Bobinson K B <bobinson@gmail.com>
Co-authored-by: Alfredo Garcia <oxarbitrage@gmail.com>
Co-authored-by: Miha Čančula <miha@noughmad.eu>
Co-authored-by: Abit <abitmore@users.noreply.github.com>
Co-authored-by: Roshan Syed <r.syed@pbsa.info>
Co-authored-by: Sandip Patel <sandip@knackroot.com>
Co-authored-by: RichardWeiYang <richard.weiyang@gmail.com>
Co-authored-by: gladcow <jahr@yandex.ru>
Co-authored-by: satyakoneru <satyakoneru.iiith@gmail.com>
2020-02-07 21:23:08 +05:30
satyakoneru
daf7ac5da8
SON214 - Request maintenance wallet commands (#280) 2020-02-07 11:19:16 +05:30
obucinac
a688bb93ed
son_wallet_object operations and multisig wallet recreation by RPC (#263)
* Extend GPO.active_sons to contain votes and all public keys

* Introduce son_wallet_object
* son_wallet_object operations
* Create son_wallet_object on new set of SONs, to initiate primary wallet recreation
* son_wallet_object API and cli wallet commands
* Send RPC command to bitcoin node to recreate multisig wallet
* Updating wallet info through operation instead through database.modify() for persistance
* Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp
* Update libraries/chain/include/graphene/chain/protocol/son_wallet.hpp
* Fix #include <graphene/chain/son_wallet_transfer_object.hpp>
* Refactor primary wallet recreation
* PW recreation refactoring, prevent duplicated recreations, update wallet address through proposal
* Quickfix for checking payer in evaluator
* Fix failing son_wallet_tests
- Check for son_btc_account is temporarely disabled
* Remove redundant file
Co-authored-by: gladcow <jahr@yandex.ru>
2020-02-04 19:31:45 +01:00
satyakoneru
80870749de SON199 - Fix Unit Test Failure (#268) 2020-01-21 21:39:54 +05:30
gladcow
11339c1734 [SON-202] Implement cli_wallet commands for maintenance mode (#261)
* Add stop_son_maintenance CLI call

* fix bug with SON activation

* son_maintenance_operation

* son_maintenance_operation tests

* cli test for son maintenance state

* start_son_maintenance CLI call

* keep maintenance state during active SON set changes
2020-01-18 02:00:45 +05:30
satyakoneru
5af31dd90d SON217 - SON Maintenance,Heartbeat state transition changes (#264)
* SON217 - SON Maintenance,Heartbeat state transition changes

* SON217 - SON Maintenance,Heartbeat state transition changes
2020-01-18 01:58:13 +05:30
satyakoneru
01fb1db6a6 SON194-SON195 - Report SON Down, addition of SON Account for sidechain consensus (#244)
* SON194-SON195 - Addition of SON BTC Account and report son down changes

* SON194-SON195 - SON BTC Account errors rectification

* SON194-SON195 - Adding Tests

* User sidechain address mappings (#240)

* WIP: Sidechain objects
* Revert "WIP: Sidechain objects"
This reverts commit 8676940a28.
* WIP: User sidechain address mappings
* Fix reflection problem
* Reflect missing members of sidechain_address_update_operation
* Add sidechain address operation tests
* Enable RPC calls
* Fix build errors due to merge conflict
* Fix RPC, add CLI wallet commands for sidechain addresses
* Improved peerplays_sidechain_plugin_impl
* Remove short param for son-id
* Fix crashing errors on bitcoin event received
* Code review changes

* SON207 - Introduce scheduling for SONs similar to witnesses (#251)

* Extend SON objects to contain sidechain public keys (#254)

Co-authored-by: obucinac <obucinac@users.noreply.github.com>
2020-01-06 18:29:35 +05:30
gladcow
bfa878f9b2 change ES index prefixes to Peerplays-specific 2020-01-01 14:51:25 +03:00
Alfredo Garcia
62247c543d Merge pull request #1725 from oxarbitrage/issue1682
elasticsearch history api #1682
2020-01-01 14:51:25 +03:00
Abit
c9583f4486 Merge pull request #1201 from oxarbitrage/elasticsearch_tests2
Elasticsearch refactor
2019-12-31 00:03:25 +03:00
Abit
e91e61e6cb Merge pull request #873 from pmconrad/585_fix_history_ids
Fix history ids
2019-12-30 23:20:31 +03:00
obucinac
31ec55514b
Extend SON objects to contain sidechain public keys (#254) 2019-12-23 19:20:26 +01:00
pbattu123
b6fc207160 gpos tests fix 2019-12-20 22:16:09 -04:00
pbattu123
054f06adc7 Beatrice hot fix(sync issue fix) 2019-12-20 21:55:45 -04:00
obucinac
6d5b86a8e5
User sidechain address mappings (#240)
* WIP: Sidechain objects
* Revert "WIP: Sidechain objects"
This reverts commit 8676940a28.
* WIP: User sidechain address mappings
* Fix reflection problem
* Reflect missing members of sidechain_address_update_operation
* Add sidechain address operation tests
* Enable RPC calls
* Fix build errors due to merge conflict
* Fix RPC, add CLI wallet commands for sidechain addresses
* Improved peerplays_sidechain_plugin_impl
* Remove short param for son-id
* Fix crashing errors on bitcoin event received
* Code review changes
2019-12-18 19:30:38 +01:00
Sandip Patel
e7af03a987 Added unit test 2019-12-13 13:11:03 +05:30
satyakoneru
1d5878db28 SON193-SON200- SON Heartbeats and maintenance mode changes (#241)
* SON193-SON200- SON Heartbeats and maintenance mode changes

* SON193-SON200- SON Heartbeats and maintenance tests
2019-12-12 18:36:38 +05:30
pbattu123
f1fef49373
Merge pull request #237 from peerplays-network/BLOCKBACK-183
BLOCKBACK-183 GPOS: Votes consideration on GPOS activation
2019-12-08 21:42:26 -04:00
gladcow
d03bfa81f7 [SON-199] Fix unit tests (#233)
* fix app_test

* fix son_delete_test
2019-12-08 12:13:05 +05:30
pbattu123
c98c7bcb94 Updated gpos/voting_tests 2019-12-07 23:41:22 -04:00
pbattu123
383b8d0b02 fix gpos tests 2019-12-07 17:06:48 -04:00
pbattu123
067fcd13f7 Votes consideration on GPOS activation 2019-12-06 11:26:49 -04:00
pbattu123
38bb9226ec Move GPOS withdraw logic to have single transaction(also single fee) and update API 2019-12-05 13:46:13 -04:00
Sandip Patel
7aeaa14bae account name or id support in all database api 2019-11-26 13:50:06 +05:30
Sandip Patel
ae47eb9390 Added unit test for empty account history 2019-11-22 11:49:33 +05:30
Alfredo Garcia
25ab039a58
Merge branch 'develop' into develop_gpos 2019-11-07 08:08:53 -03:00
gladcow
8c4eb579a7 unit test for list_active_sons 2019-11-07 13:38:24 +03:00
Sandip Patel
0bcfaa385b Improve account maintenance performance (#130)
* Improve account maintenance performance

* merge fixes

* Fixed merge issue

* Fixed indentations and extra ';'
2019-11-07 11:25:02 +05:30
satyakoneru
3e6b9196ce GRPH134- High CPU Issue, websocket changes (#213) 2019-11-06 20:15:15 +05:30
Alfredo Garcia
f831f9527f Merge branch 'qa_gpos_18.04' into develop_gpos 2019-11-05 14:34:04 -03:00
gladcow
e4eb3e6ce3 [SON-113] Fix several issues in update_son_votes call in wallet_api (#208)
* do not allow update votes with both empty lists

* fix error messages

* check number of sons against votes number in account_object

* Update error message
2019-11-01 22:26:00 +05:30
gladcow
a0e4ac59ff [SON-160] Fix create_vesting wallet_api call (#206)
* Fix create_vesting wallet_api call

* change type for vesting_type in create_vesting_balance
2019-11-01 19:13:34 +05:30
pbattu123
3a817e17ea
Merge pull request #202 from peerplays-network/BLOCKBACK-174
BLOCKBACK- 174 Roll in GPOS votes from 6th sub-period
2019-10-28 14:49:51 -03:00
pbattu123
3f8ac21b1e updated comments to the benefit of reviewer 2019-10-28 12:14:53 -03:00
pbattu123
5f1436b8be Fix to roll in GPOS rules, carry votes from 6th sub-period 2019-10-27 12:54:54 -03:00
Alfredo Garcia
7c1966247b adapt gpos_tests to changed flag 2019-10-27 09:10:53 -03:00
Alfredo Garcia
84f30926bc clean newlines gpos_tests 2019-10-27 08:54:37 -03:00
Alfredo Garcia
aef57f1720
Merge pull request #200 from peerplays-network/feature/BLOCKBACK-166
[BLOCKBACK-166] GPOS - dividend distribution for UIAs
2019-10-26 08:08:27 -03:00
pbattu123
8269c94601
Merge branch 'qa_gpos_18.04' into BLOCKBACK-155 2019-10-25 10:21:55 -03:00
Sandip Patel
a8423f167d Fixed dividend distribution issue and added test case 2019-10-25 16:41:34 +05:30
pbattu123
22e5dfa502 deleted GPOS specific test suite and updated gpos tests 2019-10-24 15:31:49 -03:00
pbattu123
78787c2a14 eliminate time gap between two consecutive vesting periods 2019-10-24 14:39:01 -03:00
pbattu123
f7d7f043ce delete unused variables 2019-10-23 23:18:44 -03:00
pbattu123
cf3b54ece4 unit test changes and also separated GPOS test suite 2019-10-23 23:13:23 -03:00
satyakoneru
666ced390e SON126 - Witness Proposals to deregister SONs (#192)
* SON126 - Witness Proposals to deregister SONs

* SON126 - Approval by witness, removal of son_proposal_object, commenting

* SON126 - Witness proposal tests and related fixes

* SON126 - Proper commenting
2019-10-23 22:16:04 +05:30
gladcow
f9f95cd242 [SON-113] Unit test for cli update_son_votes (#179)
* refactor cli tests

* update_son_votes tests

* list_sons test

* test changes in get_global_properties() result

* fix generate_block failure

* fix update_son_votes test

* improve update_son cli test

* fix linking errors

* refactor select_top_fifteen_sons test

* refactor other son cli tests to use son_test_helper

* create_vesting call in wallet_api

* test fix

* fix create_son in wallet_api and cli tests
2019-10-23 18:54:17 +05:30
Sandip Patel
8bbab4c113 Review changes 2019-10-23 18:25:33 +05:30
Sandip Patel
ccdea033f3 Added unit test for proxy voting 2019-10-23 17:41:16 +05:30
Alfredo Garcia
e0242bcf86 fix build error (#191)
* fix build error

* adapt son_pay_test to dormant vesting policy
2019-10-22 03:29:31 +05:30
obucinac
610490ef81
Active SONs, list up to 15, order by votes, add test (#185)
* Add test for selecting 15 SONs with highest votes
* Display up to 15 active SONs, SON ordering by total_votes
2019-10-21 15:44:09 +02:00
Alfredo Garcia
f84155a166
Merge branch 'feature/SONs-base' into son_vesting 2019-10-18 15:21:08 -03:00
Alfredo Garcia
dcaf55a184 remove not needed code from wallet son commands, add delete son test to cli (#181) 2019-10-18 15:49:38 +05:30
Alfredo Garcia
76120a5b76 abstraction of dormant vesting policy 2019-10-18 00:01:40 -03:00
Alfredo Garcia
8c188bd53f merge gpos to develop (#186)
* issue - 154: Don't allow to vote when vesting balance is 0

* changes to withdraw_vesting feature(for both cdd and GPOS)

* Comments update

* update to GPOS hardfork ref

* fix for get_vesting_balance API call

* braces update

* Create .gitlab-ci.yml

* fixing build errors (#150)

* fixing build errors

vest type correction

* fixing build errors

vest type correction

* fixes 

new Dockerfile

* vesting_balance_type correction

vesting_balance_type changed to normal

* gcc5 support to Dockerfile

gcc5 support to Dockerfile

* Changes to compiple with GCC 7(Ubuntu 18.04)

* changes to have separate methods and single withdrawl fee for multiple vest objects

* 163-fix, Return only non-zero vesting balances

* Revert "Revert "GPOS protocol""

This reverts commit 67616417b7.

* add new line needed to gpos hardfork file

* comment temporally cli_vote_for_2_witnesses until refactor or delete

* fix gpos tests

* fix gitlab-ci conflict
2019-10-17 22:09:44 +05:30
satyakoneru
ee7aae56da SON118-Add Budget for SON (#165)
* SON118-Add Budget for SON

* SON118 - Compilation errors fix

* SON118 - Proper commenting around pay_sons function

* SON118 - Comment correction, SON statistics object implementation type correction

* SON118 - Add missing index init and reflect enums

* SON118 - Correcting the indentation

* SON118 SON144 - Add unit test, code fixes and resolve failures for existing tests

* SON118 SON144 - Removing extra spaces added
2019-10-17 20:16:48 +05:30
Alfredo Garcia
032c4c7a99 add precision to son vesting amount 2019-10-16 14:59:49 -03:00
Alfredo Garcia
be8dc42d66 add dormant vesting policy for son 2019-10-15 21:55:48 -03:00
Alfredo Garcia
c94412cb7a add vesting balance type support 2019-10-15 20:28:04 -03:00
obucinac
b3b994c6ea
Add son_delete cli tests (#182)
* Add son_delete cli tests
2019-10-15 18:13:14 +02:00
Alfredo Garcia
6c8f4bf9d5
Merge pull request #176 from peerplays-network/feature/SON-142
[SON-142] Fix the failed tests in SONs-base
2019-10-14 20:34:05 -03:00
obucinac
d782687404 Add cli wallet tests for vote_for_son (#175) 2019-10-12 14:44:25 +05:30
gladcow
ae5075a657 [SON-110] get_son cli test (#173)
* get_son cli test

* update_son cli test
2019-10-12 00:55:59 +05:30
obucinac
fdf287c12a
SON-108 - Add cli wallet tests for create_son (#174)
* SON-108 - Add cli wallet tests for create_son

* Add info message at the beginning and end of the SON CLI tests

* Minor output message change

* Enable Boost test messages in unit tests
2019-10-11 19:25:43 +02:00
gladcow
777019241e fix affiliate tests 2019-10-11 11:33:26 +03:00
Sandip Patel
40534446da [GRPH-106] Added voting tests (#136)
* Added more voting tests

* Added additional option
2019-10-10 21:29:01 +05:30
Sandip Patel
ec33f0cc07 [GRPH-3] Additional cli tests (#155)
* Additional cli tests

* Compatible with latest fc changes

* Fixed Spacing issues
2019-10-10 21:24:12 +05:30
obucinac
e3548de34e
SON object, operations, cli_wallet commands and RPC (#160)
- create_son, update_son, delete_son, list_sons
- get_sons, get_son_by_account, lookup_son_accounts, get_son_count
- vote_for_son, update_son_votes
- claim_registered_son
- get_son in cli_wallet
- Updating global_property_object
- Decrease SON hardfork time for test purposes
- CLI Wallet tests imported from develop branch
2019-10-09 22:24:36 +02:00
gladcow
4bf90d0592 fix for cli test 2019-10-09 19:57:12 +03:00
Srdjan Obucina
944c2c1a4c Merge branch 'develop' into feature/SONs-base 2019-10-08 17:59:28 +02:00
Srdjan Obucina
9768d302be Revert "[SON-107] Merge develop branch to SONs-base (#166)"
This reverts commit 499e318199.
2019-10-08 15:44:13 +02:00
gladcow
499e318199 [SON-107] Merge develop branch to SONs-base (#166)
* fix rng and get_winner_numbers implemented

* coipied code for bitshares fixing 429 and 433 isuues

* ticket_purchase_operation implemented. added lottery_options to asset

* lottery end implemented

* minor logic changes. added db_api and cli_wallet methods

* fix reindex on peerplays network

* fix some tests. add gitlab-ci.yml

* add pull to gitlab-ci

* fix

* fix and comment some tests

* added owner to lottery_asset_options. commented async call in on_applied_block callback

* added get_account_lotteries method to db_api and cli, lottery end_date and ticket_price verification

* merge get_account_lotteries branch. fix create_witness test

* fix test genesis and end_date verification

* fixed indices sorting and lottery end checking by date

* update db_version for replay and removed duplicate include files

* Added ntp and upgraded boost version

* Revert "GPOS protocol"

* need to remove backup files

* virtual-op-fix for deterministic virtual_op number

* Merged beatrice into 5050

* Updated gitmodules, changes to allow voting on lottery fee

* Removed submodule libraries/fc

* Added libraries/fc

* added missing , in types.hpp

* Added sweeps parameters to parameter_extension

* added missing comma in operations.hpp, small changes to config.hpp

* fixed returntype in chain_parameters.hpp

* removed sweeps_parameter_extensions

* Changed fc library

* fixed asset_object

* Changed peerplays-fc submodule

* Changed fc submodule to ubuntu 18.04 upgrade

* Removed submodule libraries/fc

* Added fc library back

* fix casting in overloaded function

* Removed blind_sign and unblind_signature functions

* Added new lottery_asset_create_operation

* Changed sweeps hardfork time

* Removed redundant if from asset_evaluator and fixed db_notify

* fixed duplicate code in fee_tests

* removed redundant tgenesis file

* Enable building on Ubuntu 18.04 using GCC 7 compiler

* fix: is_benefactor_reward had the default value of true when not set

* Docker file for Ubuntu 18.04

Base image updated to Unbuntu 18.04
Prerequisite list updated
Basic configuration updated

* Quick fix: Added missing package pkg-config

* Docker file updates

* 5050 fee update and compilation error fix

* Dockerfile, set system locale

Prevents locale::facet::_S_create_c_locale name error

* Update README.md

Fix typo

* Update README.md

* Changed hardfork time for SWEEPS and Core-429

* revert master changes that were brought in previous commit

* Fixed error when account_history_object with id 0 doesnt exist

* Fixed error while loading object database

* test for zero id object in account history

* Reorder operations in Dockerfile, to make image creation faster

- Reorder prevents unnecessary building of Boost libraries

* Fix for irrelevant signature included issue

* fix copyrigth messages order

* remove double empty lines

* Backport fix for `get_account_history` from https://github.com/bitshares/bitshares-core/pull/628 and add additional account history test case

* NTP client back

* GRPH-53-Log_format_error

* Merge pull request #1036 from jmjatlanta/issue_730

Add fail_reason to proposal_object

* Unit test case fixes and prepared SONs base

* Use offsetof instead of custom macro

* Hide some compiler warnings

* Make all the tests compile

* Add nullptr check in api.cpp for easier testing

* Add test case for broadcast_trx_with_callback API

* Unit test case fixes and prepared SONs base

* Merge pull request #714 from pmconrad/json_fix

JSON fix

* Increase max depth for trx confirmation callback

* Adapt to variant API with `max_depth` argument

* Update fc submodule

* Created unit test for #325

* remove needless find()

* GRPH-4-CliWallet_crash_ctrlD

* fix copyright message

* Make all the tests compile

* increase delay for node connection

* Increase block creation timeout to 2500ms

* remove cache from cli get_account

* add cli tests framework

* Adjust newly merged code to new API

* Improved resilience of block database against corruption

* Merged changes from Bitshares PR 1036

* GRPH-76 - Short-cut long sequences of missed blocks

Fixes database::update_global_dynamic_data to speed up counting missed blocks.
(This also fixes a minor issue with counting - the previous algorithm would skip missed blocks for the witness who signed the first block after the gap.)

* Moved reindex logic into database / chain_database, make use of additional blocks in block_database

Fixed tests wrt db.open

* Enable undo + fork database for final blocks in a replay

Dont remove blocks from block db when popping blocks, handle edge case in replay wrt fork_db, adapted unit tests

* Log starting block number of replay

* Prevent unsigned integer underflow

* Fixed lock detection

* Dont leave _data_dir empty if db is locked

* Writing the object_database is now almost atomic

* Improved consistency check for block_log

* Cut back block_log index file if inconsistent

* Fixed undo_database

* Added test case for broken merge on empty undo_db

* Merge pull request #938 from bitshares/fix-block-storing

Store correct block ID when switching forks

* exclude second undo_db.enable() call in some cases

* Add missing change

* change bitshares to core in message

* Fixed integer overflow issue

* Fix for for history ID mismatch ( Bitshares PR #875 )

* Update the FC submodule with the changes for GRPH-4

* Fix #436 object_database created outside of witness data directory

* supplement more comments on database::_opened variable

* prevent segfault when destructing application obj

* Fixed duplicate ops returned from get_account_history

* minor performance improvement

* Added comment

* Merged Bitshares PR #1462 and compilation fixes

* Support/gitlab (#123)

* Updated gitlab process

* Fix undefined references in cli test

* Fixed test failures and compilation issue

* Fixed account_history_pagination test

* Fix compilation in debug mode

* Removed unrelated comment

* Skip auth check when pushing self-generated blocks

* Extract public keys before pushing a transaction

* Dereference chain_database shared_ptr

* Updated transaction::signees to mutable

and
* updated get_signature_keys() to return a const reference,
* get_signature_keys() will update signees on first call,
* modified test cases and wallet.cpp accordingly,
* no longer construct a new signed_transaction object before pushing

* Added get_asset_count API

* Allow sufficient space for new undo_session

* Throw for deep nesting

* No longer extract public keys before pushing a trx

and removed unused new added constructor and _get_signature_keys() function from signed_transaction struct

* Added cli_test to CI

* use random port numbers in app_test (#154)

* proposal fail_reason bug fixed (#157)

* Added Sonarcloud code_quality to CI (#159)

* Added sonarcloud analysis (#158)

* fix for lottery end

* fix declarations

* fix declarations

* fix boost integer

* fix compilation

* fix chain tests

* fix app_test

* try to fix cli test

* fix incorrect max_depth param

* working cli test

* correct fc version
2019-10-08 06:55:03 +05:30
gladcow
caa3d2468c use random port numbers in app_test (#154) 2019-09-27 10:58:49 -04:00
Bobinson K B
7fae375e0f
fixing build errors (#150)
* fixing build errors

vest type correction

* fixing build errors

vest type correction

* fixes 

new Dockerfile

* vesting_balance_type correction

vesting_balance_type changed to normal

* gcc5 support to Dockerfile

gcc5 support to Dockerfile
2019-09-26 11:41:28 -04:00
Bobinson K B
e377478c34
Merge pull request #139 from peerplays-network/feature/GRPH-94
Improve block generation performance
2019-09-24 13:51:46 -04:00
Miha Čančula
97f9875918
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2 2019-09-21 17:17:19 +02:00
abitmore
106824c62a No longer extract public keys before pushing a trx
and removed unused new added constructor and _get_signature_keys() function from signed_transaction struct
2019-09-20 16:27:26 +03:00
abitmore
2dfb67e16e Updated transaction::signees to mutable
and
* updated get_signature_keys() to return a const reference,
* get_signature_keys() will update signees on first call,
* modified test cases and wallet.cpp accordingly,
* no longer construct a new signed_transaction object before pushing
2019-09-20 14:10:24 +03:00
abitmore
56a6f8b732 Extract public keys before pushing a transaction 2019-09-20 13:44:15 +03:00
Bobinson K B
fba10888cc
Merge pull request #131 from peerplays-network/feature/GRPH-93-v2
index type addition for performance improvement, version 2
2019-09-20 06:36:30 -04:00
Miha Čančula
94157497bb
Merge branch 'develop' into feature/GRPH-93-v2 2019-09-18 18:19:17 +02:00
Miha Čančula
499a5fc33e
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2 2019-09-18 16:36:42 +02:00
Sandip Patel
5a00e4fab3 Removed unrelated comment 2019-09-18 10:17:44 +05:30
Sandip Patel
12ef667312 Fixed account_history_pagination test 2019-09-18 10:16:16 +05:30
Sandip Patel
dfba08536b Fixed duplicate ops returned from get_account_history 2019-09-18 10:16:16 +05:30
Alfredo Garcia
bada09d7d0
Merge branch 'develop' into GRPH-75 2019-09-17 21:10:20 -03:00
Alfredo Garcia
88d90c327b
Merge branch 'develop' into feature/GRPH-79 2019-09-17 20:19:37 -03:00
Alfredo Garcia
589005515b
Merge branch 'develop' into GRPH-73-fix-block-id-forks 2019-09-17 19:32:20 -03:00
Alfredo Garcia
4914e74770
Merge branch 'develop' into feature/GRPH-79 2019-09-17 17:38:37 -03:00
Alfredo Garcia
d911b3db69
Merge branch 'develop' into GRPH-75 2019-09-17 15:53:18 -03:00
Miha Čančula
4b5076b2e9
Merge branch 'develop' into GRPH-73-fix-block-id-forks 2019-09-16 18:51:53 +02:00
Miha Čančula
67362be337
Merge branch 'develop' into feature/GRPH-93 2019-09-16 10:15:40 +02:00
Alfredo Garcia
755383c121
Merge branch 'develop' into feature/GRPH-88 2019-09-12 16:07:36 -03:00
Ronak Patel
9fc07f191f Fixed test failures and compilation issue 2019-09-12 19:13:36 +05:30
obucinac
7553091d02
Peerplays SON plugin skeleton (#122)
* Peerplays SON plugin skeleton
* SON tests skeleton
2019-09-11 20:29:48 +02:00
Miha Čančula
8cd22ee6a0
Fix undefined references in cli test 2019-09-11 12:04:04 +02:00
Ronak Patel
646dc2e548 Merged Bitshares PR #1462 and compilation fixes 2019-09-10 18:56:27 +05:30
Miha Čančula
00a38c521e
Update the FC submodule with the changes for GRPH-4 2019-09-10 10:26:05 +02:00
Ronak Patel
3510704398 Fix for for history ID mismatch ( Bitshares PR #875 ) 2019-09-09 15:33:47 +05:30
Bobinson K B
b11edaa6a5
Merge pull request #69 from peerplays-network/WASM-49
get_account_history fix
2019-09-07 00:54:39 +05:30
Bobinson K B
64c05f9b3f
Merge pull request #70 from peerplays-network/GRPH-59-Proposal-failure-handling
Proposal failure handling
2019-09-07 00:52:02 +05:30
Bobinson K B
db8efafc62
Merge pull request #104 from peerplays-network/feature/GRPH-76
Short-cut long sequences of missed blocks
2019-09-07 00:51:12 +05:30
Bobinson K B
6563644264
Merge pull request #91 from peerplays-network/GRPH-51
unit test for bitshares issue #325
2019-09-07 00:50:33 +05:30
Bobinson K B
ef7fe58139
Merge pull request #98 from peerplays-network/cli_wallet_tests
Cli wallet tests framework
2019-09-07 00:42:58 +05:30
pbattu123
f998c4611a bring back all review fixes that were deleted with 50/50 merge 2019-09-04 11:29:16 -03:00
Ronak Patel
22eb42e3eb Fixed integer overflow issue 2019-09-04 15:14:18 +05:30
Abit
f732048a6e
Merge pull request #938 from bitshares/fix-block-storing
Store correct block ID when switching forks
2019-09-04 10:54:53 +02:00
Alfredo Garcia
1d1193e6d0 change bitshares to core in message 2019-09-03 14:13:42 -03:00
Peter Conrad
731338f03c Added test case for broken merge on empty undo_db 2019-09-02 17:19:21 +03:00
Peter Conrad
a0052d4bd3 Enable undo + fork database for final blocks in a replay
Dont remove blocks from block db when popping blocks, handle edge case in replay wrt fork_db, adapted unit tests
2019-09-02 17:19:21 +03:00
Peter Conrad
17417037c6 Moved reindex logic into database / chain_database, make use of additional blocks in block_database
Fixed tests wrt db.open
2019-09-02 17:19:21 +03:00
Srdjan Obucina
77dd8a9359 GRPH-76 - Short-cut long sequences of missed blocks
Fixes database::update_global_dynamic_data to speed up counting missed blocks.
(This also fixes a minor issue with counting - the previous algorithm would skip missed blocks for the witness who signed the first block after the gap.)
2019-09-02 15:03:00 +02:00
Ronak Patel
b751508404 Merged changes from Bitshares PR 1036 2019-09-02 18:23:19 +05:30
Miha Čančula
a797787f02
Merge branch 'develop' into GRPH-59-Proposal-failure-handling 2019-09-02 11:14:48 +02:00
Miha Čančula
43bfc3edc3
Adjust newly merged code to new API 2019-09-02 11:13:46 +02:00
Miha Čančula
1b4b5d7b24
Merge branch 'develop' into GRPH-50-network_broadcast_api-fix-v2 2019-09-02 10:27:33 +02:00
Alfredo Garcia
fcfe65acf8 add cli tests framework 2019-08-30 16:51:24 -03:00
gladcow
c5623fdabb increase delay for node connection 2019-08-30 15:54:00 +03:00
Srdjan Obucina
2ceb77f796 Fix building error for develop branch + test fix from PR 65 2019-08-30 12:06:41 +02:00
Peter Conrad
8b5182e53e Created unit test for #325 2019-08-28 22:36:36 +03:00
Miha Čančula
3c83b50fd3
Make all the tests compile 2019-08-28 17:09:53 +02:00
gladcow
15314faa9f fix copyright message 2019-08-28 17:00:35 +03:00
Miha Čančula
cb99aaa0cf
Adapt to variant API with max_depth argument 2019-08-28 15:42:21 +02:00
Abit
a49f8bf47c
Merge pull request #714 from pmconrad/json_fix
JSON fix
2019-08-28 15:42:21 +02:00
abitmore
b787d62d06
Add test case for broadcast_trx_with_callback API 2019-08-28 15:41:16 +02:00
pbattu123
a67453662d
missing files from dev branch 2019-08-28 15:41:15 +02:00
pbattu123
029d25ce64
Unit test case fixes and prepared SONs base 2019-08-28 15:41:15 +02:00
Miha Čančula
fd35f34ed0
Make all the tests compile 2019-08-28 15:37:52 +02:00
John M. Jones
b4bf247c21
Merge pull request #1036 from jmjatlanta/issue_730
Add fail_reason to proposal_object
2019-08-28 14:56:24 +02:00
pbattu123
6aae360f00
missing files from dev branch 2019-08-28 14:51:15 +02:00
pbattu123
d61c065fa0
Unit test case fixes and prepared SONs base 2019-08-28 14:51:14 +02:00
gladcow
5d38466f7d Backport fix for get_account_history from https://github.com/bitshares/bitshares-core/pull/628 and add additional account history test case 2019-08-28 15:49:33 +03:00
gladcow
bc05c320d3 remove double empty lines 2019-08-28 15:49:33 +03:00
gladcow
86b7a9a007 fix copyrigth messages order 2019-08-28 15:49:33 +03:00
gladcow
fd8a007e5e test for zero id object in account history 2019-08-28 15:49:33 +03:00
pbattu123
f9e46a31df
Merge branch 'beatrice' into qa_gpos_18.04_gcc7_fix 2019-08-20 15:42:03 -03:00
pbattu123
947b02bd57
Merge branch 'beatrice' into beatrice-5050-merge 2019-08-20 15:15:01 -03:00
pbattu123
2ccb62b797
Merge pull request #36 from peerplays-network/develop
Apply unit test fix from develop to beatrice
2019-08-20 14:53:47 -03:00
Prabhjot
c25d89ba92 fixed duplicate code in fee_tests 2019-08-12 11:19:03 -04:00
Prabhjot Singh
8caeb0ec18 merge 5050 into beatrice 2019-08-12 08:38:53 -04:00
Prabhjot
a0ae945f8d Added new lottery_asset_create_operation 2019-08-09 13:01:57 -04:00
Prabhjot
c278352713 removed sweeps_parameter_extensions 2019-08-02 09:47:32 -04:00
Prabhjot Singh
aa3128fe89 Merged beatrice into 5050 2019-07-30 11:43:31 -04:00
pbattu123
8678b677bb missing files from dev branch 2019-07-01 22:20:00 -03:00
pbattu123
dae7101364 Unit test case fixes and prepared SONs base 2019-06-14 17:26:42 +00:00
Alfredo
b3892d9fba comment transaction_invalidated_in_cache testcase 2019-06-03 14:48:56 +00:00
Alfredo
e0cb473a70 fix block interval test 2019-06-03 14:48:30 +00:00