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
140 changes: 70 additions & 70 deletions Cargo.lock

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,5 @@ members = [

[workspace.package]

version = "3.0.0-rc.3"
version = "3.0.0"
rust-version = "1.92"
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/platform",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"private": true,
"scripts": {
"setup": "yarn install && yarn run build && yarn run configure",
Expand Down
2 changes: 1 addition & 1 deletion packages/bench-suite/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@dashevo/bench-suite",
"private": true,
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Dash Platform benchmark tool",
"scripts": {
"bench": "node ./bin/bench.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/dapi-grpc/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/dapi-grpc",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "DAPI GRPC definition file and generated clients",
"browser": "browser.js",
"main": "node.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/dapi/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@dashevo/dapi",
"private": true,
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "A decentralized API for the Dash network",
"scripts": {
"api": "node scripts/api.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/dash-spv/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/dash-spv",
"version": "4.0.0-rc.3",
"version": "4.0.0",
"description": "Repository containing SPV functions used by @dashevo",
"main": "index.js",
"scripts": {
Expand Down
110 changes: 39 additions & 71 deletions packages/dashmate/configs/getConfigFileMigrationsFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -1266,10 +1266,35 @@ export default function getConfigFileMigrationsFactory(homeDir, defaultConfigs)

return configFile;
},
'2.2.0-dev.0': (configFile) => {
'3.0.0': (configFile) => {
Object.entries(configFile.configs)
.forEach(([name, options]) => {
const defaultConfig = getDefaultConfigByNameOrGroup(name, options.group);
const isLocal = options.network === NETWORK_LOCAL || name === 'local';
const isTestnet = options.network === NETWORK_TESTNET || name === 'testnet';

// --- ZMQ configuration ---
if (!options.core.zmq) {
options.core.zmq = lodash.cloneDeep(defaultConfig.get('core.zmq'));
} else {
options.core.zmq = lodash.cloneDeep(options.core.zmq);
}

if (typeof options.core.zmq.port === 'undefined') {
options.core.zmq.port = defaultConfig.get('core.zmq.port');
}

const configuredZmqPort = Number(options.core.zmq.port);
if (isLocal && configuredZmqPort === 29998) {
options.core.zmq.port = 49998;
} else if (isTestnet && configuredZmqPort === 29998) {
options.core.zmq.port = 39998;
}

if (!options.platform?.dapi) {
return;
}
Comment on lines +1294 to +1296
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major

Avoid short‑circuiting non‑DAPI migrations.

If a config omits platform.dapi, the early return skips later 3.0.0 migrations (gateway/drive/quorumList/core RPC), leaving those configs stale. Consider guarding only the DAPI‑specific block while still running the rest.

🔧 Proposed fix (scope DAPI-only logic)
-            if (!options.platform?.dapi) {
-              return;
-            }
-
-            if (!options.platform.dapi.rsDapi) {
-              options.platform.dapi.rsDapi = lodash.cloneDeep(defaultConfig.get('platform.dapi.rsDapi'));
-            }
-
-            const defaultMetrics = defaultConfig.get('platform.dapi.rsDapi.metrics');
-            ...
-            if (options.platform?.dapi?.deprecated) {
-              delete options.platform.dapi.deprecated;
-            }
+            if (!options.platform) {
+              return;
+            }
+
+            if (options.platform.dapi) {
+              if (!options.platform.dapi.rsDapi) {
+                options.platform.dapi.rsDapi = lodash.cloneDeep(defaultConfig.get('platform.dapi.rsDapi'));
+              }
+
+              const defaultMetrics = defaultConfig.get('platform.dapi.rsDapi.metrics');
+              ...
+              if (options.platform.dapi.deprecated) {
+                delete options.platform.dapi.deprecated;
+              }
+            }
🤖 Prompt for AI Agents
In `@packages/dashmate/configs/getConfigFileMigrationsFactory.js` around lines
1292 - 1294, The early `return` that checks `if (!options.platform?.dapi) {
return; }` short-circuits all subsequent 3.0.0 migrations; instead, remove that
global return and wrap only the DAPI-specific migration code in a conditional
(e.g., `if (options.platform?.dapi) { /* dapi-only migrations */ }`) so
gateway/drive/quorumList/core RPC and other non‑DAPI migrations still run;
update the block in the getConfigFileMigrationsFactory migration sequence to
scope the guard to DAPI logic rather than exiting the whole function.


if (!options.platform.dapi.rsDapi) {
options.platform.dapi.rsDapi = lodash.cloneDeep(defaultConfig.get('platform.dapi.rsDapi'));
}
Expand All @@ -1284,55 +1309,37 @@ export default function getConfigFileMigrationsFactory(homeDir, defaultConfigs)
options.platform.dapi.rsDapi.metrics.enabled = defaultMetrics.enabled;
}

if (!options.core.zmq) {
options.core.zmq = lodash.cloneDeep(defaultConfig.get('core.zmq'));
} else {
options.core.zmq = lodash.cloneDeep(options.core.zmq);
}

if (typeof options.core.zmq.port === 'undefined') {
options.core.zmq.port = defaultConfig.get('core.zmq.port');
}

if (typeof options.platform.dapi.rsDapi.metrics.port === 'undefined') {
options.platform.dapi.rsDapi.metrics.port = defaultMetrics.port;
}

const configuredMetricsPort = Number(options.platform.dapi.rsDapi.metrics.port);
const configuredZmqPort = Number(options.core.zmq.port);
const isLocal = options.network === NETWORK_LOCAL || name === 'local';
const isTestnet = options.network === NETWORK_TESTNET || name === 'testnet';

if (isLocal && configuredMetricsPort === 9091) {
options.platform.dapi.rsDapi.metrics.port = 29091;
} else if (isTestnet && configuredMetricsPort === 9091) {
options.platform.dapi.rsDapi.metrics.port = 19091;
}

if (isLocal && configuredZmqPort === 29998) {
options.core.zmq.port = 49998;
} else if (isTestnet && configuredZmqPort === 29998) {
options.core.zmq.port = 39998;
}
});
if (options.platform.dapi.api) {
const { waitForStResultTimeout } = options.platform.dapi.api;

return configFile;
},
'3.0.0-dev.1': (configFile) => {
Object.entries(configFile.configs)
.forEach(([name, options]) => {
const defaultConfig = getDefaultConfigByNameOrGroup(name, options.group);
if (typeof waitForStResultTimeout === 'number'
&& typeof options.platform.dapi.rsDapi.waitForStResultTimeout === 'undefined') {
options.platform.dapi.rsDapi.waitForStResultTimeout = waitForStResultTimeout;
}

options.platform.drive.abci.docker.image = 'dashpay/drive:3';
if (options.platform?.dapi?.api) {
options.platform.dapi.api.docker.image = 'dashpay/dapi:3';
delete options.platform.dapi.api;
}

if (typeof options.platform.dapi.rsDapi.waitForStResultTimeout === 'undefined') {
options.platform.dapi.rsDapi.waitForStResultTimeout = defaultConfig.get('platform.dapi.rsDapi.waitForStResultTimeout');
}
options.platform.dapi.rsDapi.docker.image = 'dashpay/rs-dapi:3';

if (options.platform?.dapi?.deprecated) {
delete options.platform.dapi.deprecated;
}

// --- Gateway upstreams migration ---
if (options.platform?.gateway?.upstreams) {
const { upstreams } = options.platform.gateway;
const defaultUpstreams = defaultConfig.get('platform.gateway.upstreams');
Expand Down Expand Up @@ -1360,31 +1367,6 @@ export default function getConfigFileMigrationsFactory(homeDir, defaultConfigs)
delete upstreams.dapiCoreStreams;
}

if (!options.platform?.dapi) {
return;
}

if (!options.platform.dapi.rsDapi) {
options.platform.dapi.rsDapi = lodash.cloneDeep(defaultConfig.get('platform.dapi.rsDapi'));
}

const { rsDapi } = options.platform.dapi;

if (options.platform.dapi.api) {
const { waitForStResultTimeout } = options.platform.dapi.api;

if (typeof waitForStResultTimeout === 'number'
&& typeof rsDapi.waitForStResultTimeout === 'undefined') {
rsDapi.waitForStResultTimeout = waitForStResultTimeout;
}

delete options.platform.dapi.api;
}

if (typeof rsDapi.waitForStResultTimeout === 'undefined') {
rsDapi.waitForStResultTimeout = defaultConfig.get('platform.dapi.rsDapi.waitForStResultTimeout');
}

if (options.platform?.drive?.abci?.docker
&& defaultConfig.has('platform.drive.abci.docker.image')) {
options.platform.drive.abci.docker.image = defaultConfig.get('platform.drive.abci.docker.image');
Expand All @@ -1394,14 +1376,6 @@ export default function getConfigFileMigrationsFactory(homeDir, defaultConfigs)
&& defaultConfig.has('platform.dapi.rsDapi.docker.image')) {
options.platform.dapi.rsDapi.docker.image = defaultConfig.get('platform.dapi.rsDapi.docker.image');
}
});

return configFile;
},
'3.0.0-dev.6': (configFile) => {
Object.entries(configFile.configs)
.forEach(([name, options]) => {
const defaultConfig = getDefaultConfigByNameOrGroup(name, options.group);

if (!options.platform.quorumList) {
options.platform.quorumList = lodash.cloneDeep(defaultConfig.get('platform.quorumList'));
Expand All @@ -1412,14 +1386,8 @@ export default function getConfigFileMigrationsFactory(homeDir, defaultConfigs)
defaultConfig.get('core.rpc.users.quorum_list'),
);
}
});

return configFile;
},
'3.0.0-rc.3': (configFile) => {
Object.entries(configFile.configs)
.forEach(([, options]) => {
// Add letsencrypt provider config if it doesn't exist
// --- Letsencrypt provider config ---
if (options.platform?.gateway?.ssl?.providerConfigs
&& !options.platform.gateway.ssl.providerConfigs.letsencrypt) {
options.platform.gateway.ssl.providerConfigs.letsencrypt = {
Expand Down
2 changes: 1 addition & 1 deletion packages/dashmate/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dashmate",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Distribution package for Dash node installation",
"scripts": {
"lint": "eslint .",
Expand Down
2 changes: 1 addition & 1 deletion packages/dashpay-contract/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/dashpay-contract",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Reference contract of the DashPay DPA on Dash Evolution",
"scripts": {
"lint": "eslint .",
Expand Down
2 changes: 1 addition & 1 deletion packages/dpns-contract/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/dpns-contract",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "A contract and helper scripts for DPNS DApp",
"scripts": {
"lint": "eslint .",
Expand Down
2 changes: 1 addition & 1 deletion packages/feature-flags-contract/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/feature-flags-contract",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Data Contract to store Dash Platform feature flags",
"scripts": {
"build": "",
Expand Down
2 changes: 1 addition & 1 deletion packages/js-dapi-client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/dapi-client",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Client library used to access Dash DAPI endpoints",
"main": "lib/index.js",
"contributors": [
Expand Down
2 changes: 1 addition & 1 deletion packages/js-dash-sdk/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dash",
"version": "6.0.0-rc.3",
"version": "6.0.0",
"description": "Dash library for JavaScript/TypeScript ecosystem (Wallet, DAPI, Primitives, BLS, ...)",
"main": "build/index.js",
"unpkg": "dist/dash.min.js",
Expand Down
2 changes: 1 addition & 1 deletion packages/js-evo-sdk/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/evo-sdk",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"type": "module",
"main": "./dist/evo-sdk.module.js",
"types": "./dist/sdk.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion packages/js-grpc-common/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/grpc-common",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Common GRPC library",
"main": "index.js",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion packages/keyword-search-contract/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/keyword-search-contract",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "A contract that allows searching for contracts",
"scripts": {
"lint": "eslint .",
Expand Down
2 changes: 1 addition & 1 deletion packages/masternode-reward-shares-contract/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dashevo/masternode-reward-shares-contract",
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "A contract and helper scripts for reward sharing",
"scripts": {
"lint": "eslint .",
Expand Down
2 changes: 1 addition & 1 deletion packages/platform-test-suite/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@dashevo/platform-test-suite",
"private": true,
"version": "3.0.0-rc.3",
"version": "3.0.0",
"description": "Dash Network end-to-end tests",
"scripts": {
"test": "yarn exec bin/test.sh",
Expand Down
4 changes: 2 additions & 2 deletions packages/rs-dapi/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ prometheus = "0.14"
once_cell = "1.19"

# Dash Core RPC client
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce" }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce" }
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0" }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0" }

rs-dash-event-bus = { path = "../rs-dash-event-bus" }

Expand Down
10 changes: 5 additions & 5 deletions packages/rs-dpp/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,18 @@ chrono = { version = "0.4.35", default-features = false, features = [
] }
chrono-tz = { version = "0.8", optional = true }
ciborium = { version = "0.2.2", optional = true }
dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", features = [
dashcore = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", features = [
"std",
"secp-recovery",
"rand",
"signer",
"serde",
"eddsa",
], default-features = false }
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", optional = true }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", optional = true }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", optional = true }
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", optional = true }
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", optional = true }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", optional = true }
dash-spv = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", optional = true }
dashcore-rpc = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", optional = true }

env_logger = { version = "0.11" }
getrandom = { version = "0.2", features = ["js"] }
Expand Down
12 changes: 6 additions & 6 deletions packages/rs-drive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,12 @@ enum-map = { version = "2.0.3", optional = true }
intmap = { version = "3.0.1", features = ["serde"], optional = true }
chrono = { version = "0.4.35", optional = true }
itertools = { version = "0.13", optional = true }
grovedb = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b", optional = true, default-features = false }
grovedb-costs = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b", optional = true }
grovedb-path = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b" }
grovedb-storage = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b", optional = true }
grovedb-version = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b" }
grovedb-epoch-based-storage-flags = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b" }
grovedb = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0", optional = true, default-features = false }
grovedb-costs = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0", optional = true }
grovedb-path = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0" }
grovedb-storage = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0", optional = true }
grovedb-version = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0" }
grovedb-epoch-based-storage-flags = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0" }

[dev-dependencies]
criterion = "0.5"
Expand Down
2 changes: 1 addition & 1 deletion packages/rs-platform-version/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ license = "MIT"
thiserror = { version = "2.0.12" }
bincode = { version = "=2.0.0-rc.3" }
versioned-feature-core = { git = "https://github.com/dashpay/versioned-feature-core", version = "1.0.0" }
grovedb-version = { git = "https://github.com/dashpay/grovedb", rev = "86562f65d9ec08bea28dc9981663cd2a63dc7f3b" }
grovedb-version = { git = "https://github.com/dashpay/grovedb", tag = "v4.1.0" }
once_cell = "1.19.0"

[features]
Expand Down
6 changes: 3 additions & 3 deletions packages/rs-platform-wallet/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ description = "Platform wallet with identity management support"
dpp = { path = "../rs-dpp" }

# Key wallet dependencies (from rust-dashcore)
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce" }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce", optional = true }
key-wallet = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0" }
key-wallet-manager = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0", optional = true }

# Core dependencies
dashcore = { git = "https://github.com/dashpay/rust-dashcore", rev = "e7792c431c55c0d28efb0344b3a1948f576be5ce" }
dashcore = { git = "https://github.com/dashpay/rust-dashcore", tag = "v0.41.0" }

# Standard dependencies
thiserror = "1.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/rs-platform-wallet/examples/basic_usage.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ fn main() -> Result<(), PlatformWalletError> {
{
use key_wallet_manager::wallet_manager::WalletManager;

let _wallet_manager = WalletManager::<PlatformWalletInfo>::new();
let _wallet_manager = WalletManager::<PlatformWalletInfo>::new(network);
println!("Platform wallet successfully integrated with wallet managers!");
}

Expand Down
Loading
Loading