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

Miner issues fix #19

Merged
merged 5 commits into from
Mar 17, 2024
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
2 changes: 1 addition & 1 deletion ansible/install-dash-node/install-dash-node-ubuntu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@
daemon=1
externalip={{ hostvars[inventory_hostname]['ansible_default_ipv4']['address'] }}
[test]
port=19999
port=18168
when: dashnode_testnet
become_user: "{{ dashuser }}"
when: not dash_conf_exists.stat.exists
Expand Down
2 changes: 1 addition & 1 deletion src/app_main_view_wdg.py
Original file line number Diff line number Diff line change
Expand Up @@ -1185,7 +1185,7 @@ def mn_name_exists(name: str):
mn_template = src_masternode.name + '-Clone'
else:
if self.app_config.is_testnet:
new_mn.tcp_port = 19999
new_mn.tcp_port = 18186
mn_template = 'MN'
force_append_numbers = True
name_found = None
Expand Down
2 changes: 1 addition & 1 deletion src/dash_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@

DEFAULT_SENTINEL_VERSION = 0x010001 # sentinel version before implementation of nSentinelVersion in CMasternodePing
DEFAULT_DAEMON_VERSION = 120200 # daemon version before implementation of nDaemonVersion in CMasternodePing
MASTERNODE_TX_MINIMUM_CONFIRMATIONS = 15
MASTERNODE_TX_MINIMUM_CONFIRMATIONS = 2
DASH_PLATFORM_DEFAULT_P2P_PORT = 26656
DASH_PLATFORM_DEFAULT_HTTP_PORT = 443

Expand Down
11 changes: 3 additions & 8 deletions src/dashd_intf.py
Original file line number Diff line number Diff line change
Expand Up @@ -1436,19 +1436,14 @@ def decoderawtransaction(self, rawtx):
else:
raise Exception('Not connected')

@control_rpc_call(allow_switching_conns=False)
@control_rpc_call
def sendrawtransaction(self, tx, use_instant_send):
if self.open():
ni = self.rpc_call(False, False, 'getnetworkinfo')
if ni.get('version', 180000) >= 180000:
fee = 0
else:
fee = False

return self.proxy.sendrawtransaction(tx, fee, use_instant_send)
return self.proxy.sendrawtransaction(tx, False)
else:
raise Exception('Not connected')


@control_rpc_call
def getcurrentvotes(self, hash):
if self.open():
Expand Down
2 changes: 1 addition & 1 deletion src/hw_intf.py
Original file line number Diff line number Diff line change
Expand Up @@ -1166,7 +1166,7 @@ def connect_hardware_wallet_main_th(self, reload_devices: bool = False) -> Optio

if not found_testnet_support:
url = get_note_url('DMT0002')
msg = f'Your hardware wallet device does not support Dash TESTNET ' \
msg = f'Your hardware wallet device does not support FIRO TESTNET ' \
f'(<a href="{url}">see details</a>).'
try:
self.disconnect_hardware_wallet()
Expand Down
14 changes: 1 addition & 13 deletions src/hw_intf_trezor.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
from common import CancelException, HwNotInitialized
from hw_common import ask_for_pass_callback, ask_for_pin_callback, \
ask_for_word_callback, HWSessionBase, HWType
from dash_tx import DashTxType, serialize_cbTx, serialize_Lelantus, serialize_Spark
import logging
import wallet_common
from wnd_utils import WndUtils
Expand Down Expand Up @@ -324,19 +325,6 @@ def json_to_tx(tx_json):
t = btc.from_json(tx_json)
dip2_type = tx_json.get("type", 0)

t.inputs =[]
for vin in tx_json["vin"]:
if "scriptSig" in vin and vin["scriptSig"]["hex"] == "c9":
i = messages.TxInputType()
i.prev_hash = b"\0" * 32
i.prev_index = vin["sequence"]
i.script_sig = bytes.fromhex(vin["scriptSig"]["hex"])
i.sequence = vin["sequence"]
t.inputs.append(i)
else:
t.inputs.append(_json_to_input(tx_json, vin))
t.bin_outputs = [_json_to_bin_output(tx_json, vout) for vout in tx_json["vout"]]

if t.version == 3 and dip2_type != 0:
if dip2_type == DashTxType.SPEC_CB_TX:
tx_json["extraPayload"] = serialize_cbTx(tx_json)
Expand Down
2 changes: 0 additions & 2 deletions src/masternode_details_wdg.py
Original file line number Diff line number Diff line change
Expand Up @@ -1388,8 +1388,6 @@ def apply_utxo(utxo):

if self.masternode.masternode_type == MasternodeType.REGULAR:
dash_value_to_find = 1000
else:
dash_value_to_find = 4000

address = self.edtCollateralAddress.text()
if self.edtCollateralTxHash.text():
Expand Down
4 changes: 1 addition & 3 deletions src/reg_masternode_dlg.py
Original file line number Diff line number Diff line change
Expand Up @@ -505,8 +505,6 @@ def apply_utxo(utxo):

if self.masternode_type == MasternodeType.REGULAR:
dash_value_to_find = 1000
else:
dash_value_to_find = 4000

if self.edtCollateralTx.text():
# If there is any value in the collateral tx edit box, don't automatically apply the possible
Expand Down Expand Up @@ -1382,7 +1380,7 @@ def on_msg_link_activated(link: str):

except Exception as e:
res = self.query_dlg('Cannot verify the collateral transaction due to the following error: ' + str(e) +
'\n\nDo you rally want to continue?',
'\n\nDo you really want to continue?',
buttons=QMessageBox.Yes | QMessageBox.Cancel,
default_button=QMessageBox.Cancel, icon=QMessageBox.Warning)
if res == QMessageBox.Cancel:
Expand Down
2 changes: 1 addition & 1 deletion src/wallet_dlg.py
Original file line number Diff line number Diff line change
Expand Up @@ -685,7 +685,7 @@ def on_btnSend_clicked(self):
total_satoshis_inputs += utxo.satoshis
if utxo.is_collateral:
if self.query_dlg(
"Warning: you are going to transfer masternode's collateral (1000/4000 Dash) "
"Warning: you are going to transfer masternode's collateral (1000 Firo) "
"transaction output. Proceeding will result in broken masternode.\n\n"
"Do you really want to continue?",
buttons=QMessageBox.Yes | QMessageBox.Cancel,
Expand Down
Loading