Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
151 changes: 9 additions & 142 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ members = [
"packages/rs-drive",
"packages/rs-platform-value",
"packages/rs-drive-abci",
"packages/rs-drive-nodejs",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might want to keep this, after all bindings for node-js are a good thing to have, even if we don't use them in our own project.

"packages/dashpay-contract",
"packages/withdrawals-contract",
"packages/masternode-reward-shares-contract",
Expand Down
4 changes: 1 addition & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,14 +59,12 @@
"packages/wallet-lib",
"packages/js-dash-sdk",
"packages/dapi",
"packages/js-drive",
"packages/dashmate",
"packages/platform-test-suite",
"packages/masternode-reward-shares-contract",
"packages/dash-spv",
"packages/wasm-dpp",
"packages/withdrawals-contract",
"packages/rs-drive-nodejs"
"packages/withdrawals-contract"
],
"resolutions": {
"elliptic": "^6.5.4",
Expand Down
2 changes: 1 addition & 1 deletion packages/dashmate/configs/schema/configFileJsonSchema.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
$schema: 'https://schema.dash.org/dpp-0-4-0/meta/data-contract#',
$schema: 'http://json-schema.org/draft-07/schema#',
type: 'object',
properties: {
configFormatVersion: {
Expand Down
2 changes: 1 addition & 1 deletion packages/dashmate/configs/schema/configJsonSchema.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const { NETWORKS } = require('../../src/constants');

module.exports = {
$schema: 'https://schema.dash.org/dpp-0-4-0/meta/data-contract#',
$schema: 'http://json-schema.org/draft-07/schema#',
type: 'object',
definitions: {
docker: {
Expand Down
2 changes: 1 addition & 1 deletion packages/dashmate/docker-compose.platform.build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ services:
drive_abci:
build:
context: ${PLATFORM_SOURCE_PATH:?err}
dockerfile: ${PLATFORM_SOURCE_PATH:?err}/packages/js-drive/Dockerfile
dockerfile: ${PLATFORM_SOURCE_PATH:?err}/packages/rs-drive-abci/Dockerfile
image: drive:local
stop_grace_period: 30s

Expand Down
17 changes: 5 additions & 12 deletions packages/dashmate/docker-compose.platform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ services:
depends_on:
- core
volumes:
- drive_abci_data:/platform/packages/js-drive/db
- ${PLATFORM_DRIVE_ABCI_LOG_PRETTY_DIRECTORY_PATH:?err}:/var/log/pretty
- ${PLATFORM_DRIVE_ABCI_LOG_JSON_DIRECTORY_PATH:?err}:/var/log/json
- drive_abci_data:/var/lib/dash/rs-drive-abci
environment:
- BLOCK_SPACING_MS=3000 # TODO: sync with tenderdash
- CHAIN_ID=devnet # TODO: sync with tenderdash chain id
- CORE_JSON_RPC_USERNAME=${CORE_RPC_USER:?err}
- CORE_JSON_RPC_PASSWORD=${CORE_RPC_PASSWORD:?err}
- CORE_JSON_RPC_HOST=core
Expand All @@ -27,17 +27,10 @@ services:
- MASTERNODE_REWARD_SHARES_SECOND_PUBLIC_KEY=${PLATFORM_MASTERNODE_REWARD_SHARES_SECOND_PUBLIC_KEY}
- WITHDRAWALS_MASTER_PUBLIC_KEY=${PLATFORM_WITHDRAWALS_MASTER_PUBLIC_KEY}
- WITHDRAWALS_SECOND_PUBLIC_KEY=${PLATFORM_WITHDRAWALS_SECOND_PUBLIC_KEY}
- NODE_ENV=${ENVIRONMENT:?err}
- LOG_STDOUT_LEVEL=${PLATFORM_DRIVE_ABCI_LOG_STDOUT_LEVEL:?err}
- LOG_PRETTY_FILE_LEVEL=${PLATFORM_DRIVE_ABCI_LOG_PRETTY_FILE_LEVEL:?err}
- LOG_PRETTY_FILE_PATH=/var/log/pretty/${PLATFORM_DRIVE_ABCI_LOG_PRETTY_FILE_NAME:?err}
- LOG_JSON_FILE_LEVEL=${PLATFORM_DRIVE_ABCI_LOG_JSON_FILE_LEVEL:?err}
- LOG_JSON_FILE_PATH=/var/log/json/${PLATFORM_DRIVE_ABCI_LOG_JSON_FILE_NAME:?err}
- INITIAL_CORE_CHAINLOCKED_HEIGHT=${PLATFORM_DRIVE_TENDERDASH_GENESIS_INITIAL_CORE_CHAIN_LOCKED_HEIGHT:-1}
- VALIDATOR_SET_LLMQ_TYPE=${PLATFORM_DRIVE_ABCI_VALIDATOR_SET_LLMQ_TYPE:?err}
- QUORUM_SIZE=5 # TODO: sync with Tenderdash
- QUORUM_TYPE=${PLATFORM_DRIVE_ABCI_VALIDATOR_SET_LLMQ_TYPE:?err}
- NETWORK=${NETWORK}
- TENDERDASH_P2P_PORT=${PLATFORM_DRIVE_TENDERDASH_P2P_PORT}
command: yarn workspace @dashevo/drive abci
stop_grace_period: 30s

drive_tenderdash:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ describe('Masternode Reward Shares', () => {
await dpp.initialize();

client = await createClientWithFundedWallet(
8000000,
10000000,
);

const masternodeRewardSharesContract = await client.platform.contracts.get(
Expand Down Expand Up @@ -89,7 +89,10 @@ describe('Masternode Reward Shares', () => {
// Masternode identity should exist
expect(masternodeOwnerIdentity).to.exist();

await client.platform.identities.topUp(masternodeOwnerIdentity.getId(), 1900000);
await client.platform.identities.topUp(masternodeOwnerIdentity.getId(), 2000000);

// Additional wait time to mitigate testnet latency
await waitForSTPropagated();

// Since we cannot create "High" level key for masternode Identities automatically,
// (this key is used to sign state transitions, other than "update")
Expand Down Expand Up @@ -154,6 +157,9 @@ describe('Masternode Reward Shares', () => {
await client.platform.broadcastStateTransition(
stateTransition,
);

// Additional wait time to mitigate testnet latency
await waitForSTPropagated();
});

it('should be able to create reward shares with existing identity', async () => {
Expand Down
Loading