Revert "[CONTRACTS] Contracts branch update for 1.80 (#718)"

This reverts commit cdd63fb565.
This commit is contained in:
yeastplume
2024-09-19 09:05:44 +00:00
parent cdd63fb565
commit 7ac35f134b
78 changed files with 220 additions and 10170 deletions
+4 -4
View File
@@ -1,6 +1,6 @@
[package]
name = "grin_wallet_config"
version = "5.4.0-contracts.0"
version = "5.4.0-alpha.1"
authors = ["Grin Developers <mimblewimble@lists.launchpad.net>"]
description = "Configuration for grin wallet , a simple, private and scalable cryptocurrency implementation based on the MimbleWimble chain format."
license = "Apache-2.0"
@@ -16,13 +16,13 @@ serde_derive = "1"
toml = "0.5"
dirs = "2.0"
grin_wallet_util = { path = "../util", version = "5.4.0-contracts.0" }
grin_wallet_util = { path = "../util", version = "5.4.0-alpha.1" }
##### Grin Imports
# For Release
# grin_core = "5.4.0-contracts.0"
# grin_util = "5.4.0-contracts.0"
# grin_core = "5.4.0-alpha.1"
# grin_util = "5.4.0-alpha.1"
# For beta release
+1 -21
View File
@@ -28,9 +28,6 @@ pub struct WalletConfig {
pub chain_type: Option<ChainTypes>,
/// The port this wallet will run on
pub api_listen_port: u16,
/// Listen interface for the owner API, should be hidden from config by default
#[serde(skip_serializing)]
pub owner_api_listen_interface: Option<String>,
/// The port this wallet's owner API will run on
pub owner_api_listen_port: Option<u16>,
/// Location of the secret for basic auth on the Owner API
@@ -64,7 +61,6 @@ impl Default for WalletConfig {
WalletConfig {
chain_type: Some(ChainTypes::Mainnet),
api_listen_port: 3415,
owner_api_listen_interface: Some(WalletConfig::default_owner_api_listen_interface()),
owner_api_listen_port: Some(WalletConfig::default_owner_api_listen_port()),
api_secret_path: Some(".owner_api_secret".to_string()),
node_api_secret_path: Some(".foreign_api_secret".to_string()),
@@ -86,11 +82,6 @@ impl WalletConfig {
format!("127.0.0.1:{}", self.api_listen_port)
}
/// Default listener port
pub fn default_owner_api_listen_interface() -> String {
"127.0.0.1".to_string()
}
/// Default listener port
pub fn default_owner_api_listen_port() -> u16 {
3420
@@ -101,13 +92,6 @@ impl WalletConfig {
500_000
}
/// Use value from config file, defaulting to sensible value if missing.
pub fn owner_api_listen_interface(&self) -> String {
self.owner_api_listen_interface
.clone()
.unwrap_or_else(|| WalletConfig::default_owner_api_listen_interface())
}
/// Use value from config file, defaulting to sensible value if missing.
pub fn owner_api_listen_port(&self) -> u16 {
self.owner_api_listen_port
@@ -116,11 +100,7 @@ impl WalletConfig {
/// Owner API listen address
pub fn owner_api_listen_addr(&self) -> String {
format!(
"{}:{}",
self.owner_api_listen_interface(),
self.owner_api_listen_port()
)
format!("127.0.0.1:{}", self.owner_api_listen_port())
}
/// Accept fee base