Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix release build on 18.04, fc::smart_ref_* removed #394

Merged
merged 202 commits into from
Oct 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
202 commits
Select commit Hold shift + click to select a range
8f317e9
Fix building on Ubuntu 18.04 with GCC 7
obucina Sep 11, 2019
d1a2ea1
Merge pull request #124 from peerplays-network/feature/SONs-base-buil…
bobinson Sep 11, 2019
7553091
Peerplays SON plugin skeleton (#122)
Sep 11, 2019
f8da541
Part two of SON-83 - plugins option in command line and config file (…
Sep 13, 2019
b853a82
SON11 - Add chain extension parameter to set SON count
sierra19XX Sep 18, 2019
324923b
Merge pull request #135 from peerplays-network/SON11
bobinson Sep 23, 2019
499e318
[SON-107] Merge develop branch to SONs-base (#166)
gladcow Oct 8, 2019
9768d30
Revert "[SON-107] Merge develop branch to SONs-base (#166)"
obucina Oct 8, 2019
944c2c1
Merge branch 'develop' into feature/SONs-base
obucina Oct 8, 2019
940a620
Fix build error, add missing GRAPHENE_MAX_NESTED_OBJECTS parameter
obucina Oct 8, 2019
e90735a
Plugin description added, SON plugin params example
Oct 8, 2019
4bf90d0
fix for cli test
Oct 9, 2019
e3548de
SON object, operations, cli_wallet commands and RPC (#160)
Oct 9, 2019
7770192
fix affiliate tests
Oct 11, 2019
fdf287c
SON-108 - Add cli wallet tests for create_son (#174)
Oct 11, 2019
ae5075a
[SON-110] get_son cli test (#173)
gladcow Oct 11, 2019
d782687
Add cli wallet tests for vote_for_son (#175)
Oct 12, 2019
342099f
fix insert object processing in indexes, son_delete is working
Oct 12, 2019
9201e0d
Fix segfault when using delete_son from cli_wallet (#177)
Oct 14, 2019
f3150d4
Fix segfault when using list_sons from cli_wallet (#178)
Oct 14, 2019
6c8f4bf
Merge pull request #176 from peerplays-network/feature/SON-142
oxarbitrage Oct 14, 2019
b3b994c
Add son_delete cli tests (#182)
Oct 15, 2019
c02a33a
add son vesting config options
oxarbitrage Oct 15, 2019
c94412c
add vesting balance type support
oxarbitrage Oct 15, 2019
be8dc42
add dormant vesting policy for son
oxarbitrage Oct 16, 2019
032c4c7
add precision to son vesting amount
oxarbitrage Oct 16, 2019
ee7aae5
SON118-Add Budget for SON (#165)
sierra19XX Oct 17, 2019
76120a5
abstraction of dormant vesting policy
oxarbitrage Oct 18, 2019
d29e433
force son create vesting balance to have dormant policy
oxarbitrage Oct 18, 2019
dcaf55a
remove not needed code from wallet son commands, add delete son test …
oxarbitrage Oct 18, 2019
f84155a
Merge branch 'feature/SONs-base' into son_vesting
oxarbitrage Oct 18, 2019
4121779
Merge pull request #183 from peerplays-network/son_vesting
oxarbitrage Oct 20, 2019
610490e
Active SONs, list up to 15, order by votes, add test (#185)
Oct 21, 2019
e0242bc
fix build error (#191)
oxarbitrage Oct 21, 2019
f9f95cd
[SON-113] Unit test for cli `update_son_votes` (#179)
gladcow Oct 23, 2019
666ced3
SON126 - Witness Proposals to deregister SONs (#192)
sierra19XX Oct 23, 2019
11e9830
fix son_delete_operation reflection
gladcow Oct 30, 2019
0bbe7f6
Merge pull request #203 from peerplays-network/feature/SON-142
oxarbitrage Oct 31, 2019
a0e4ac5
[SON-160] Fix create_vesting wallet_api call (#206)
gladcow Nov 1, 2019
e4eb3e6
[SON-113] Fix several issues in update_son_votes call in wallet_api …
gladcow Nov 1, 2019
22f76a0
list_active_sons api call implementation
Nov 6, 2019
8c4eb57
unit test for list_active_sons
Nov 7, 2019
62f973c
fix code style
Nov 11, 2019
dbf6be0
use assert instead of checking condition with low possibility
Nov 11, 2019
ae781e4
Fixed betting tests (#217)
srpatel19590 Nov 11, 2019
36c93a5
Merge pull request #215 from peerplays-network/feature/SON-150
oxarbitrage Nov 17, 2019
76b9572
removed unrelated parameter description from delete_son
srpatel19590 Nov 21, 2019
749fc2f
Add Bitcoin network listener to a SON plugin (#196)
Dec 4, 2019
d03bfa8
[SON-199] Fix unit tests (#233)
gladcow Dec 8, 2019
876bbc8
Add peerplays account for a SON in a config/command line options (#231)
Dec 11, 2019
1d5878d
SON193-SON200- SON Heartbeats and maintenance mode changes (#241)
sierra19XX Dec 12, 2019
6d5b86a
User sidechain address mappings (#240)
Dec 18, 2019
a347e97
SON207 - Introduce scheduling for SONs similar to witnesses (#251)
sierra19XX Dec 23, 2019
31ec555
Extend SON objects to contain sidechain public keys (#254)
Dec 23, 2019
01fb1db
SON194-SON195 - Report SON Down, addition of SON Account for sidechai…
sierra19XX Jan 6, 2020
59a02b1
SON206 - Plugin SON Heartbeat changes (#250)
sierra19XX Jan 6, 2020
47eafcf
Wallet recreation on new set of SONs voted in (#256)
Jan 13, 2020
6fe0acb
Fix build errors
obucina Jan 13, 2020
77927da
SON212-SON213 - Add Sidechain Plugin Code to report and approve SON D…
sierra19XX Jan 14, 2020
5d7ab51
SON212-SON213 - Fix Build Error (#262)
sierra19XX Jan 15, 2020
691468d
Updated gitlab CI to sync submodules (#265)
Jan 17, 2020
5af31dd
SON217 - SON Maintenance,Heartbeat state transition changes (#264)
sierra19XX Jan 17, 2020
11339c1
[SON-202] Implement cli_wallet commands for maintenance mode (#261)
gladcow Jan 17, 2020
e0e427a
Quick fix for list_active_sons
obucina Jan 20, 2020
8087074
SON199 - Fix Unit Test Failure (#268)
sierra19XX Jan 21, 2020
7139b4a
Quickfix for update_sidechain_address and delete_sidechain_address cl…
obucina Jan 23, 2020
61c6d7f
SON206_Plugin_CrashFix_Reorg - Plugin Changes (#272)
sierra19XX Jan 28, 2020
21c8337
SON165 - Keys mapping missing from wallet data (#274)
sierra19XX Jan 29, 2020
b952522
SON232 - Avoid duplicate proposals from sidechain plugin (#275)
sierra19XX Jan 31, 2020
6e61d6b
SON233 - Provide correct downtime metrics to user (#278)
sierra19XX Feb 3, 2020
a688bb9
son_wallet_object operations and multisig wallet recreation by RPC (#…
Feb 4, 2020
daf7ac5
SON214 - Request maintenance wallet commands (#280)
sierra19XX Feb 7, 2020
116be75
SON wallet transfer object and operations (#279)
Feb 11, 2020
a8eb422
Support multiple SON nodes per software instance (#282)
Feb 19, 2020
544112c
[SON-209] Create P2SH address with custom redeemScript (#271)
gladcow Feb 19, 2020
a968ec9
add ability to gather signatures before signing (#290)
gladcow Feb 21, 2020
a9cfadc
[SON-242] fix list_active_sons call after deleting an active son (#292)
gladcow Feb 23, 2020
13d2b27
[SON-260] Sidechain Token withdrawal (#286)
Feb 23, 2020
f859d61
SON261 - Bitcoin deposit, withdrawal, PW transfer (#287)
sierra19XX Feb 24, 2020
47c98c2
[SON-264] Integrating deposit/withdrawals with bitcoin transactions (…
Feb 24, 2020
477aa03
SON200 - SON Down proposal broken after latest merges (#294)
sierra19XX Feb 27, 2020
abeae4e
SON269 - Move SON deregistration to Plugin from witness (#298)
sierra19XX Feb 27, 2020
d6e6bed
Various SON improvements (#297)
Mar 2, 2020
11718af
Merge develop into SONS
pbattu123 Mar 3, 2020
dbf7350
SON118 - Add tx sign metrics for SON rewards (#302)
sierra19XX Mar 4, 2020
da4954c
resolved compilation issues and other conflicts
pbattu123 Mar 5, 2020
2e8c074
SON202 - Maintenance improvements (#303)
sierra19XX Mar 6, 2020
85b81cb
Quickfix, remove dead code, return result from wallet withdraw do_eva…
obucina Mar 10, 2020
d2f5cde
Merge branch 'feature/SONs-base' of https://github.com/peerplays-netw…
obucina Mar 10, 2020
f1e5171
SON275 - ZMQ Crash on application exit (#306)
sierra19XX Mar 11, 2020
ea0be26
need to assign both name and id to stats id
pbattu123 Mar 13, 2020
d225446
fix unit test case failures(add gpos vesting before voting)
pbattu123 Mar 13, 2020
cc7b47c
SON276 - Fix SON proposal exceptions - I (#307)
sierra19XX Mar 14, 2020
ff7e1ba
Add SON statistic for tracking reported sidechain transactions (#308)
obucina Mar 14, 2020
3ffcd4f
Allow voting for son, only if GPOS vesting balance available
pbattu123 Mar 16, 2020
c0d515b
notifications of SONS should get restrict to sons functionality
pbattu123 Mar 17, 2020
8a90e70
update GPOS hardfork date to sons branch
pbattu123 Mar 17, 2020
ed4ebfd
SON127 - Add son parameter extensions to genesis, push proposal fix (…
sierra19XX Mar 17, 2020
1d66b85
update GPOS HF to fall in before SONS HF, remove check
pbattu123 Mar 18, 2020
78c17c0
updated unit test cases to reflect GPOS vesting and update account id…
pbattu123 Mar 18, 2020
275315e
gpos, graphene updates
pbattu123 Mar 19, 2020
096af5e
[SON-24] - SON Rewards missing serialisations and end to end testing …
sierra19XX Mar 20, 2020
955893b
Merge pull request #312 from peerplays-network/sons_gpos_merge_mar19
obucina Mar 20, 2020
19a34e9
Revert "Merge develop branch changes(GPOS+graphene updates) into SONs…
obucina Mar 21, 2020
c2ee4f0
Merge pull request #315 from peerplays-network/revert-312-sons_gpos_m…
obucina Mar 21, 2020
964aed0
[SON-122] - SON Statistics improvements and consensus account creatio…
sierra19XX Mar 25, 2020
0f97241
Replace raw with psbt transactions to support parital tx signing (#311)
obucina Mar 25, 2020
e170676
[SON-312] Refactor create_son to assign owner account public key as a…
obucina Mar 27, 2020
5439034
[SON-271] Merge recent develop branch changes(both GPOS and graphene …
obucina Mar 27, 2020
13bc59a
Parallelizing sidechain transaction signing (#319)
obucina Mar 27, 2020
770ccdb
[SON-321, SON-323] Deposit/Withdraw object creation refactoring (#320)
obucina Mar 27, 2020
26f6252
[SON-318_SON-319] - Add approval checks for son down, deregister prop…
sierra19XX Mar 27, 2020
1e76a23
[SON-311] Add try_create_son call without explicit deposit params (#324)
gladcow Mar 29, 2020
dc5a8da
Hotfix - Fix build error
obucina Mar 29, 2020
bccba76
Quickfix - change GPOS and SON hardfork times
obucina Mar 30, 2020
f3a0827
[SON-332] Check gitlab building process for dirty build (#327)
obucina Mar 30, 2020
210e72f
update son-account parameters (#328)
pbattu123 Mar 30, 2020
d710615
[SON-329] Hotfix - Enable test test_update_dividend_interval
obucina Mar 31, 2020
27f401d
[SON-313] - Limit SON functionality when min no. of sons are not pres…
sierra19XX Apr 1, 2020
8aaa379
[SON-307] Create PBTC asset (#326)
gladcow Apr 1, 2020
5bf245e
SON-297_SON-336 - SON vesting functionality broken after graphene mer…
sierra19XX Apr 2, 2020
efa7436
Hotfix - add initialization values to extension params, remove traili…
obucina Apr 2, 2020
b6dc7dc
Merge branch 'feature/SONs-base' of https://github.com/peerplays-netw…
obucina Apr 2, 2020
e1a487c
[SON-305, SON-308, SON-310] Use BTC asset in bitcoin deposits and wit…
gladcow Apr 3, 2020
1542a9a
[SON-339] - SON Schedule crash (#334)
sierra19XX Apr 4, 2020
52d7ebc
[SON-291,SON-328] - SON Configuration invalid, PW creation issues (#335)
sierra19XX Apr 4, 2020
17bf51e
[SON-322, SON-324] Approval checks for processing deposit/withdrawal …
obucina Apr 4, 2020
be4b55c
[SON-320] Added check for approving son_wallet_update_operation (#336)
obucina Apr 6, 2020
bd1bd84
[SON-325] Added check for approving sidechain_transaction_create_oper…
obucina Apr 6, 2020
c345369
[SON-341, SON-342] Fix issue with deposits number (#339)
gladcow Apr 6, 2020
4f72269
[SON-344] BTC asset is created with wrong quote asset id, Fixed (#341)
obucina Apr 8, 2020
44db4f5
[SON-346] Sidechain transaction marked as complete even though curren…
obucina Apr 8, 2020
7988236
[SON-348] Transaction hash not saved in object after Bitcoin transact…
obucina Apr 9, 2020
6a8cd25
[SON-337] - Prevent update_son_votes without GPOS vesting (#344)
sierra19XX Apr 10, 2020
b857603
Merge pull request #340 from peerplays-network/feature/nh5050_winner_id
pbattu123 Apr 10, 2020
dd8abfe
[SON-353] Refactor PW processing, PW transfer fixed (#347)
obucina Apr 14, 2020
5305757
[SON-354] Fix son_info compare function (#350)
obucina Apr 17, 2020
fbb4bbd
check object's id (#351)
gladcow Apr 17, 2020
b436b79
SON Weighted Multi Signature Signing (#349)
sierra19XX Apr 18, 2020
453772d
[SON-349] Delay BTC asset issue/reserve until tx confirmed on sidchai…
obucina Apr 19, 2020
e7099fb
Hotfix - remove importing sidechain addresses
obucina Apr 20, 2020
5030c11
Hotfix - remove redundant deposit sidechain address recreation
obucina Apr 20, 2020
a4c922c
private-key option update
pbattu123 Apr 20, 2020
d3385b2
Use decoderawtraction json for proposal approvals (#352)
sierra19XX Apr 20, 2020
d8ca4d4
Merge pull request #353 from peerplays-network/issue_a_gitlab
pbattu123 Apr 20, 2020
4db9e3a
Prevent incorrect signatures to be added to transaction (#354)
sierra19XX Apr 21, 2020
746b71f
Hotfix - use getrawtransaction for approvals and settling (#355)
obucina Apr 21, 2020
9db4615
[SON-135] Add timelock to user deposit address (#356)
gladcow Apr 21, 2020
8d7e574
Hotfix - fix threshold_weight calculation in redeem scripts
obucina Apr 22, 2020
072906b
fix broken peerplays_sidechain tests (#357)
gladcow Apr 22, 2020
984000f
Hotfix - Save deposit address redeem and witness script into sidechai…
obucina Apr 23, 2020
be53861
[SON-359] - Fix Errors processing to-be-refunded deposits (#358)
sierra19XX Apr 23, 2020
6797cdc
[SON-363] - Remove son deletion (#359)
sierra19XX May 4, 2020
4896e48
[SON-314] - Weighted Rewards and equal weighted son-account (#360)
sierra19XX May 5, 2020
129d5eb
Bitcoin network type deduction (#361)
sierra19XX May 5, 2020
cf8f1d9
chore: changed building to debug mode
RoshanSyed Jun 12, 2020
23d2ce0
ci: update .gitlab-ci.yml
RoshanSyed Jun 16, 2020
490a332
ci: update .gitlab-ci.yml
RoshanSyed Jul 9, 2020
75b87b3
chore: updated Dockerfile with dnsutils
RoshanSyed Jul 16, 2020
a5aa7c2
GPOS2 HF - Handle rolling period on missing blocks (#369)
sierra19XX Jul 30, 2020
c36d4c9
Mainnet chain halt 5050 Issue (#370)
sierra19XX Jul 30, 2020
ecd14b8
Peerplays Marketplace + NFT (#367)
sierra19XX Aug 10, 2020
bfdecbb
Son deposit address enhancements (#362)
sierra19XX Aug 14, 2020
ae3edc6
Ws updates
pravblockc Aug 29, 2020
adb2229
Merge branch 'ws-updates' into 'develop'
bobinson Aug 29, 2020
c46e899
Fix for custom operation authority checking (BTS Issue #210) (#382)
sierra19XX Sep 8, 2020
c6c26a7
Merge branch 'develop' into feature/SONs-base
serkixenos Sep 22, 2020
2264aa0
Cleanup changes for pretier diff
serkixenos Sep 22, 2020
318b992
Cleanup changes for prettier diff
serkixenos Sep 22, 2020
213a188
NFT Permissions (#380)
sierra19XX Sep 22, 2020
ec74e7f
Merge branch 'develop' into feature/SONs-base
serkixenos Sep 23, 2020
e79995b
Cleanup changes for prettier diff
serkixenos Sep 23, 2020
0359193
Fix failing saving_keys_wallet_test
serkixenos Sep 24, 2020
b43d523
Fix failing saving_keys_wallet_test
serkixenos Sep 24, 2020
c2a3467
Align submodule versions
serkixenos Sep 25, 2020
2582b82
Add missing break
serkixenos Sep 25, 2020
3e6c812
Increase tests log_level, some cleanup
serkixenos Sep 25, 2020
808ecf6
Decrease log level for tests
serkixenos Sep 28, 2020
e173705
Fix block_tests/maintenance_interval test
serkixenos Sep 29, 2020
12e07fa
Merge branch 'feature/SONs-base' of https://github.com/peerplays-netw…
serkixenos Sep 29, 2020
64b4b8f
Fix son_operation_tests/son_pay_test test
serkixenos Sep 29, 2020
62bea3f
Merge branch 'beatrice' into develop
serkixenos Sep 30, 2020
bba9c3a
Remove base_uri length checks
serkixenos Oct 1, 2020
cbb8cbe
Fix HF info
serkixenos Oct 1, 2020
ed44efd
Sidechain Operating Node
serkixenos Oct 1, 2020
7121da7
Merge branch 'develop' of https://github.com/peerplays-network/peerpl…
serkixenos Oct 1, 2020
dcc84ae
Merge branch 'develop' into merge/develop2beatrice
serkixenos Oct 1, 2020
abe1786
Merge beatrice only changes into develop
serkixenos Oct 5, 2020
b31b402
hotfix - chain params variable overflow, rbac hf check (#387)
sierra19XX Oct 9, 2020
a20be87
hotfix - son max count fix (#389)
sierra19XX Oct 12, 2020
a086b13
Release build fix, missing includes
serkixenos Oct 16, 2020
088b07d
Fix release build on 18.04, fc::smart_ref_* removed
serkixenos Oct 18, 2020
7a721f8
Gitlab will build Debug and Release versions
serkixenos Oct 18, 2020
fd6d910
Merge branch 'hotfix/remove_fc_smart_ref' into develop
serkixenos Oct 18, 2020
854cc41
Revert "Gitlab will build Debug and Release versions"
serkixenos Oct 18, 2020
a9afe47
Gitlab will build Release version only
serkixenos Oct 18, 2020
e3edce2
Merge branch 'hotfix/remove_fc_smart_ref' into develop
serkixenos Oct 18, 2020
d332c00
Merge pull request #392 from peerplays-network/hotfix/release_build_f…
serkixenos Oct 19, 2020
6767b34
Merge branch 'develop' of https://github.com/peerplays-network/peerpl…
serkixenos Oct 19, 2020
890079c
Hotfix/remove smart ref (#396)
sierra19XX Oct 22, 2020
e6386ce
Merge branch 'develop' of https://github.com/peerplays-network/peerpl…
serkixenos Oct 23, 2020
cf12afc
#endif
serkixenos Oct 23, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ build:
- rm -rf build
- mkdir build
- cd build
- cmake ..
- cmake -DCMAKE_BUILD_TYPE=Release ..
- make -j$(nproc)
artifacts:
untracked: true
Expand Down
1 change: 0 additions & 1 deletion libraries/app/api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
#include <graphene/chain/tournament_object.hpp>

#include <fc/crypto/hex.hpp>
#include <fc/smart_ref_impl.hpp>
#include <fc/rpc/api_connection.hpp>
#include <fc/thread/future.hpp>

Expand Down
4 changes: 1 addition & 3 deletions libraries/app/application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@
#include <graphene/utilities/key_conversion.hpp>
#include <graphene/chain/worker_evaluator.hpp>

#include <fc/smart_ref_impl.hpp>

#include <fc/io/fstream.hpp>
#include <fc/rpc/api_connection.hpp>
#include <fc/rpc/websocket_api.hpp>
Expand Down Expand Up @@ -80,7 +78,7 @@ namespace detail {
auto nathan_key = fc::ecc::private_key::regenerate(fc::sha256::hash(string("nathan")));
dlog("Allocating all stake to ${key}", ("key", utilities::key_to_wif(nathan_key)));
genesis_state_type initial_state;
initial_state.initial_parameters.current_fees = fee_schedule::get_default();//->set_all_fees(GRAPHENE_BLOCKCHAIN_PRECISION);
initial_state.initial_parameters.current_fees = std::make_shared<fee_schedule>(fee_schedule::get_default());
initial_state.initial_active_witnesses = GRAPHENE_DEFAULT_MIN_WITNESS_COUNT;
initial_state.initial_timestamp = time_point_sec(time_point::now().sec_since_epoch() /
initial_state.initial_parameters.block_interval *
Expand Down
1 change: 0 additions & 1 deletion libraries/app/database_api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
#include <graphene/chain/pts_address.hpp>

#include <fc/bloom_filter.hpp>
#include <fc/smart_ref_impl.hpp>

#include <fc/crypto/hex.hpp>
#include <fc/rpc/api_connection.hpp>
Expand Down
1 change: 1 addition & 0 deletions libraries/chain/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ add_library( graphene_chain
protocol/assert.cpp
protocol/account.cpp
protocol/transfer.cpp
protocol/chain_parameters.cpp
protocol/committee_member.cpp
protocol/witness.cpp
protocol/market.cpp
Expand Down
2 changes: 0 additions & 2 deletions libraries/chain/account_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
* THE SOFTWARE.
*/

#include <fc/smart_ref_impl.hpp>

#include <graphene/chain/account_evaluator.hpp>
#include <graphene/chain/buyback.hpp>
#include <graphene/chain/buyback_object.hpp>
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/betting_market_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
* THE SOFTWARE.
*/
#define DEFAULT_LOGGER "betting"
#include <fc/smart_ref_impl.hpp>

#include <graphene/chain/betting_market_evaluator.hpp>
#include <graphene/chain/betting_market_object.hpp>
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/block_database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
#include <graphene/chain/block_database.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <fc/io/raw.hpp>
#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {

Expand Down
2 changes: 0 additions & 2 deletions libraries/chain/committee_member_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@
#include <graphene/chain/protocol/vote.hpp>
#include <graphene/chain/transaction_evaluation_state.hpp>

#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {

void_result committee_member_create_evaluator::do_evaluate( const committee_member_create_operation& op )
Expand Down
2 changes: 0 additions & 2 deletions libraries/chain/confidential_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@
#include <graphene/chain/fba_accumulator_id.hpp>
#include <graphene/chain/hardfork.hpp>

#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {

void_result transfer_to_blind_evaluator::do_evaluate( const transfer_to_blind_operation& o )
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#include <fc/smart_ref_impl.hpp>
#include "db_balance.cpp"
#include "db_bet.cpp"
#include "db_block.cpp"
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/db_block.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
#include <graphene/chain/witness_schedule_object.hpp>
#include <fc/crypto/digest.hpp>

#include <fc/smart_ref_impl.hpp>

namespace {

Expand Down
4 changes: 1 addition & 3 deletions libraries/chain/db_getter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@
#include <graphene/chain/son_object.hpp>
#include <graphene/chain/son_proposal_object.hpp>

#include <fc/smart_ref_impl.hpp>

#include <ctime>
#include <algorithm>

Expand Down Expand Up @@ -68,7 +66,7 @@ const dynamic_global_property_object& database::get_dynamic_global_properties()

const fee_schedule& database::current_fee_schedule()const
{
return get_global_properties().parameters.current_fees;
return std::ref( *get_global_properties().parameters.current_fees );
}

time_point_sec database::head_block_time()const
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/db_init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@

#include <graphene/chain/protocol/fee_schedule.hpp>

#include <fc/smart_ref_impl.hpp>
#include <fc/uint128.hpp>
#include <fc/crypto/digest.hpp>

Expand Down
1 change: 0 additions & 1 deletion libraries/chain/db_maint.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@

#include <boost/multiprecision/integer.hpp>

#include <fc/smart_ref_impl.hpp>
#include <fc/uint128.hpp>

#include <graphene/chain/database.hpp>
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/fork_database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
#include <graphene/chain/fork_database.hpp>
#include <graphene/chain/exceptions.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {
fork_database::fork_database()
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/genesis_state.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
#include <graphene/chain/genesis_state.hpp>

// these are required to serialize a genesis_state
#include <fc/smart_ref_impl.hpp> // required for gcc in release mode
#include <graphene/chain/protocol/fee_schedule.hpp>

namespace graphene { namespace chain {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
* THE SOFTWARE.
*/
#pragma once
#include <memory>
#include <graphene/chain/protocol/base.hpp>
#include <graphene/chain/protocol/ext.hpp>
#include <graphene/chain/protocol/types.hpp>
#include <fc/smart_ref_fwd.hpp>

#include <graphene/chain/hardfork.hpp>
#include <../hardfork.d/GPOS.hf>
Expand Down Expand Up @@ -72,8 +72,13 @@ namespace graphene { namespace chain {

struct chain_parameters
{
chain_parameters();
chain_parameters(const chain_parameters& other);
chain_parameters(chain_parameters&& other);
chain_parameters& operator=(const chain_parameters& other);
chain_parameters& operator=(chain_parameters&& other);
/** using a smart ref breaks the circular dependency created between operations and the fee schedule */
smart_ref<fee_schedule> current_fees; ///< current schedule of fees
std::shared_ptr<fee_schedule> current_fees; ///< current schedule of fees
uint8_t block_interval = GRAPHENE_DEFAULT_BLOCK_INTERVAL; ///< interval in seconds between blocks
uint32_t maintenance_interval = GRAPHENE_DEFAULT_MAINTENANCE_INTERVAL; ///< interval in sections between blockchain maintenance events
uint8_t maintenance_skip_slots = GRAPHENE_DEFAULT_MAINTENANCE_SKIP_SLOTS; ///< number of block_intervals to skip at maintenance time
Expand Down Expand Up @@ -207,6 +212,8 @@ namespace graphene { namespace chain {
inline uint16_t maximum_son_count()const {
return extensions.value.maximum_son_count.valid() ? *extensions.value.maximum_son_count : GRAPHENE_DEFAULT_MAX_SONS;
}
private:
static void safe_copy(chain_parameters& to, const chain_parameters& from);
};

} } // graphene::chain
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
* THE SOFTWARE.
*/
#pragma once
#include <fc/smart_ref_fwd.hpp>
#include <graphene/chain/protocol/operations.hpp>

namespace graphene { namespace chain {
Expand Down Expand Up @@ -84,6 +83,10 @@ namespace graphene { namespace chain {

} } // graphene::chain

namespace fc {
template<> struct get_typename<std::shared_ptr<graphene::chain::fee_schedule>> { static const char* name() { return "shared_ptr<fee_schedule>"; } };
}

FC_REFLECT_TYPENAME( graphene::chain::fee_parameters )
FC_REFLECT( graphene::chain::fee_schedule, (parameters)(scale) )

Expand Down
1 change: 0 additions & 1 deletion libraries/chain/include/graphene/chain/protocol/types.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
#include <fc/io/raw_fwd.hpp>
#include <fc/uint128.hpp>
#include <fc/static_variant.hpp>
#include <fc/smart_ref_fwd.hpp>

#include <memory>
#include <vector>
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/market_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
#include <graphene/chain/protocol/market.hpp>

#include <fc/uint128.hpp>
#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {
void_result limit_order_create_evaluator::do_evaluate(const limit_order_create_operation& op)
Expand Down
2 changes: 0 additions & 2 deletions libraries/chain/proposal_evaluator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@
#include <graphene/chain/exceptions.hpp>
#include <graphene/chain/hardfork.hpp>

#include <fc/smart_ref_impl.hpp>

namespace graphene { namespace chain {

struct proposal_operation_hardfork_visitor
Expand Down
92 changes: 92 additions & 0 deletions libraries/chain/protocol/chain_parameters.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
#include <graphene/chain/protocol/chain_parameters.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>

namespace graphene { namespace chain {
chain_parameters::chain_parameters() {
current_fees = std::make_shared<fee_schedule>();
}

// copy constructor
chain_parameters::chain_parameters(const chain_parameters& other)
{
current_fees = std::make_shared<fee_schedule>(*other.current_fees);
safe_copy(*this, other);
}

// copy assignment
chain_parameters& chain_parameters::operator=(const chain_parameters& other)
{
if (&other != this)
{
current_fees = std::make_shared<fee_schedule>(*other.current_fees);
safe_copy(*this, other);
}
return *this;
}

// copies the easy stuff
void chain_parameters::safe_copy(chain_parameters& to, const chain_parameters& from)
{
to.block_interval = from.block_interval;
to.maintenance_interval = from.maintenance_interval;
to.maintenance_skip_slots = from.maintenance_skip_slots;
to.committee_proposal_review_period = from.committee_proposal_review_period;
to.maximum_transaction_size = from.maximum_transaction_size;
to.maximum_block_size = from.maximum_block_size;
to.maximum_time_until_expiration = from.maximum_time_until_expiration;
to.maximum_proposal_lifetime = from.maximum_proposal_lifetime;
to.maximum_asset_whitelist_authorities = from.maximum_asset_whitelist_authorities;
to.maximum_asset_feed_publishers = from.maximum_asset_feed_publishers;
to.maximum_witness_count = from.maximum_witness_count;
to.maximum_committee_count = from.maximum_committee_count;
to.maximum_authority_membership = from.maximum_authority_membership;
to.reserve_percent_of_fee = from.reserve_percent_of_fee;
to.network_percent_of_fee = from.network_percent_of_fee;
to.lifetime_referrer_percent_of_fee = from.lifetime_referrer_percent_of_fee;
to.cashback_vesting_period_seconds = from.cashback_vesting_period_seconds;
to.cashback_vesting_threshold = from.cashback_vesting_threshold;
to.count_non_member_votes = from.count_non_member_votes;
to.allow_non_member_whitelists = from.allow_non_member_whitelists;
to.witness_pay_per_block = from.witness_pay_per_block;
to.witness_pay_vesting_seconds = from.witness_pay_vesting_seconds;
to.worker_budget_per_day = from.worker_budget_per_day;
to.max_predicate_opcode = from.max_predicate_opcode;
to.fee_liquidation_threshold = from.fee_liquidation_threshold;
to.accounts_per_fee_scale = from.accounts_per_fee_scale;
to.account_fee_scale_bitshifts = from.account_fee_scale_bitshifts;
to.max_authority_depth = from.max_authority_depth;
to.witness_schedule_algorithm= from.witness_schedule_algorithm;
to.min_round_delay = from.min_round_delay;
to.max_round_delay = from.max_round_delay;
to.min_time_per_commit_move = from.min_time_per_commit_move;
to.max_time_per_commit_move = from.max_time_per_commit_move;
to.min_time_per_reveal_move = from.min_time_per_reveal_move;
to.max_time_per_reveal_move = from.max_time_per_reveal_move;
to.rake_fee_percentage = from.rake_fee_percentage;
to.maximum_registration_deadline = from.maximum_registration_deadline;
to.maximum_players_in_tournament = from.maximum_players_in_tournament;
to.maximum_tournament_whitelist_length = from.maximum_tournament_whitelist_length;
to.maximum_tournament_start_time_in_future= from.maximum_tournament_start_time_in_future;
to.maximum_tournament_start_delay = from.maximum_tournament_start_delay;
to.maximum_tournament_number_of_wins = from.maximum_tournament_number_of_wins;
to.extensions = from.extensions;
}

// move constructor
chain_parameters::chain_parameters(chain_parameters&& other)
{
current_fees = std::move(other.current_fees);
safe_copy(*this, other);
}

// move assignment
chain_parameters& chain_parameters::operator=(chain_parameters&& other)
{
if (&other != this)
{
current_fees = std::move(other.current_fees);
safe_copy(*this, other);
}
return *this;
}
}}
1 change: 0 additions & 1 deletion libraries/chain/protocol/committee_member.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#include <fc/smart_ref_impl.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <graphene/chain/protocol/committee_member.hpp>

Expand Down
15 changes: 0 additions & 15 deletions libraries/chain/protocol/fee_schedule.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,28 +23,13 @@
*/
#include <algorithm>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <fc/smart_ref_impl.hpp>

namespace fc
{
// explicitly instantiate the smart_ref, gcc fails to instantiate it in some release builds
//template graphene::chain::fee_schedule& smart_ref<graphene::chain::fee_schedule>::operator=(smart_ref<graphene::chain::fee_schedule>&&);
//template graphene::chain::fee_schedule& smart_ref<graphene::chain::fee_schedule>::operator=(U&&);
//template graphene::chain::fee_schedule& smart_ref<graphene::chain::fee_schedule>::operator=(const smart_ref&);
//template smart_ref<graphene::chain::fee_schedule>::smart_ref();
//template const graphene::chain::fee_schedule& smart_ref<graphene::chain::fee_schedule>::operator*() const;
}

#include <fc/io/raw.hpp>

#define MAX_FEE_STABILIZATION_ITERATION 4

namespace graphene { namespace chain {

typedef fc::smart_ref<fee_schedule> smart_fee_schedule;

static smart_fee_schedule tmp;

fee_schedule::fee_schedule()
{
}
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/protocol/operations.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#include <fc/smart_ref_impl.hpp>
#include <graphene/chain/protocol/operations.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <fc/io/raw.hpp>
Expand Down
1 change: 0 additions & 1 deletion libraries/chain/protocol/proposal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
*/
#include <graphene/chain/protocol/operations.hpp>
#include <graphene/chain/protocol/fee_schedule.hpp>
#include <fc/smart_ref_impl.hpp>

#include <fc/io/raw.hpp>

Expand Down
1 change: 0 additions & 1 deletion libraries/chain/protocol/small_ops.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
* THE SOFTWARE.
*/

#include <fc/smart_ref_impl.hpp>
#include <graphene/chain/protocol/balance.hpp>
#include <graphene/chain/protocol/buyback.hpp>
#include <graphene/chain/protocol/fba.hpp>
Expand Down
Loading