Commit Graph

889 Commits

Author SHA1 Message Date
woodser
0c5ed84996 fix npe with offer details volume before prices loaded 2024-05-22 08:34:30 -04:00
woodser
b66e6b1c12 remove download url from mandatory update message 2024-05-21 18:00:23 -04:00
woodser
9cd28a6bde fix connection to custom node on startup #945 2024-05-21 18:00:23 -04:00
woodser
1150d929af maker selects arbitrator (breaking change) 2024-05-21 18:00:14 -04:00
woodser
6df5296dcd deduplicate trade history before may 31, 2024 2024-05-20 15:04:48 -04:00
woodser
80db207a98
fix issues scheduling offer with exact input amount (#934) 2024-05-19 09:59:34 -04:00
woodser
7df40580a3 remove incorrect withdraw screen translations #74 2024-05-19 09:19:22 -04:00
woodser
b4369fbb9f fix default monero port in custom node input #928 2024-05-18 11:45:13 -04:00
woodser
bee93bf45f reset internal state and popup warning if main wallet swapped 2024-05-18 10:11:34 -04:00
woodser
82b8f58579 show popup with message on error starting monero wallet 2024-05-18 10:11:34 -04:00
woodser
ea0ce9b449 deduplicate early trades due to bug 2024-05-17 13:08:20 -04:00
woodser
36e2f8675c only republish seller trades 2024-05-17 12:40:02 -04:00
woodser
76859f822e ignore failure after task runner canceled 2024-05-17 06:52:28 -04:00
woodser
58cead6035 do not log error polling wallet within 3m of success 2024-05-17 06:52:28 -04:00
woodser
1aa62863f4 move DEFAULT_APP_NAME to HavenoExecutable 2024-05-15 09:33:54 -04:00
woodser
7e3d89797e recover from failed payout tx 2024-05-15 09:33:54 -04:00
nsec1
1b864368e1
Update p2p package #756 (#884) 2024-05-15 06:52:36 -04:00
woodser
091ffd98eb set trade wallet sync tolerance to 5 blocks 2024-05-13 07:11:59 -04:00
woodser
a9f7a06e1f make configurable if arbitrator assigns trade fee address 2024-05-11 11:20:47 -04:00
woodser
3cdd88b569 support --ignoreLocalXmrNode startup flag 2024-05-09 18:39:55 -04:00
woodser
f4de560764 process payout tx if not confirmed, send deposit responses once 2024-05-08 18:08:25 -04:00
woodser
f1b8cd1e2e thaw reserved inputs and re-freeze offer inputs on create tx errors 2024-05-08 09:12:35 -04:00
woodser
5d7991e4f7 repeat refresh offer on TTL error 2024-05-08 09:12:35 -04:00
woodser
203386f03d wait to observe published tx on error with payment received 2024-05-08 09:12:35 -04:00
woodser
d64ee42154 skip processing payout tx if already published 2024-05-08 09:12:35 -04:00
woodser
adf7348515 bump reprocessing delay to 5s 2024-05-08 09:12:35 -04:00
woodser
0ea056104c support invalid offer state 2024-05-08 09:12:35 -04:00
woodser
7887c450c7 arbitrator sends deposit responses on error or timeout 2024-05-08 09:12:35 -04:00
woodser
a6d827c369 latch trade awaits trade initialization 2024-05-08 09:12:35 -04:00
woodser
4ec5339e5d release wallet lock processing payout tx 2024-05-08 09:12:35 -04:00
woodser
b179203dd2 repeat wallet attempts after 2s 2024-05-08 09:12:35 -04:00
woodser
4761b71105 remove repeated popups on offer taken error 2024-05-08 09:12:35 -04:00
woodser
399d4e0512 thaw outputs off main thread on cancel offer 2024-05-08 09:12:35 -04:00
woodser
78ec06b851 add trade init steps and reset timeout 2024-05-07 21:37:49 -04:00
woodser
6fb846d783 refactor trade protocol error handling and wallet deletion 2024-05-07 21:37:49 -04:00
woodser
78ae449e18 use dns seed nodes from MainNetParams on stagenet 2024-05-05 11:30:22 -04:00
woodser
f99fab8515 repeat try withdraw tx and fix amount details 2024-05-05 08:33:49 -04:00
woodser
ceff34672d recover from deleted wallet cache 2024-05-04 09:16:01 -04:00
woodser
b50238a805 log cleanup 2024-05-04 09:16:01 -04:00
woodser
e96b875232 use more cached wallet state instead of direct queries 2024-05-04 09:16:01 -04:00
woodser
a5883d7bcd arbitrator assigns trade fee address 2024-05-04 09:16:01 -04:00
woodser
eefcf0191f trade step timeout is 60s on testnet 2024-04-30 15:34:51 -04:00
woodser
2341e73da2 defer dispute payout tx if awaiting peer ack or closed 2024-04-30 13:52:04 -04:00
woodser
f8480a1a4d remove unused import 2024-04-30 13:07:36 -04:00
woodser
e2f19c280e defer dispute payout tx if awaiting peer ack 2024-04-30 12:53:12 -04:00
woodser
467b678ea7 check if dispute payout published on submit failure, thread fixes 2024-04-30 11:18:04 -04:00
woodser
a3f2cd875c update balances on same thread 2024-04-30 11:18:04 -04:00
woodser
5531d4eea1 increase max tx attempts to 5 2024-04-29 11:22:49 -04:00
woodser
8e24ebfc23 import multisig hex locks on daemon due to refresh call 2024-04-29 11:22:49 -04:00
woodser
bd1be1041a increase timeout for sign offer request ack to 30s 2024-04-29 11:22:49 -04:00
woodser
d1e5910502 non-mature currencies have chargeback risk too 2024-04-29 11:22:49 -04:00
woodser
94ab3c1f9b show reserved amount in maker's offer details 2024-04-29 11:22:49 -04:00
woodser
e63141279c refactoring based on congestion testing
retry creating and processing trade txs on failure
do not use connection manager polling to reduce requests
use global daemon lock for wallet sync operations
sync wallets on poll if behind
use local util to get payment uri to avoid blocking
all peers share multisig hex on deposits confirmed
import multisig hex when needed
2024-04-29 11:22:49 -04:00
woodser
895acc9d7c do not fetch trade txs directly from daemon 2024-04-27 17:14:21 -04:00
woodser
6455171dea disable payment sent/received buttons until acked 2024-04-22 04:56:49 -04:00
woodser
3a66c9cd24 import multisig hex off main thread on payment sent message 2024-04-22 04:56:49 -04:00
woodser
e4b80ef14b do not update from pool on shared wallet sync 2024-04-22 04:56:49 -04:00
woodser
adccf27385 set deposit tx confirmations from wallet instead of daemon request 2024-04-22 04:56:49 -04:00
woodser
f0862b7aeb synchronize reserving funds for open offer to fix race condition 2024-04-22 04:56:49 -04:00
woodser
9d9635ff50 refactor wallet poll loops to further minimize requests 2024-04-22 04:56:49 -04:00
woodser
5c0d9a1ae5 remove timeout confirming payment sent/received & revert state on error 2024-04-21 06:27:30 -04:00
woodser
0ead6d8f83 adjust public and provided monero nodes 2024-04-21 06:27:30 -04:00
woodser
b08d6833a8 public nodes option entails provided nodes 2024-04-21 06:27:30 -04:00
woodser
8097b0f499 use cached txs in xmr wallet service instead of querying wallet 2024-04-21 06:27:30 -04:00
woodser
a107acbdb4 add more mainnet nodes for diversity and reliability 2024-04-18 14:19:52 -04:00
woodser
ca2d7704ab fixes from congestion testing
- refactor main wallet polling
- restart main wallet if connection changes before initial sync
- use cached wallet state throughout app
- avoid rescanning spent outputs until payout tx expected
- allow payment sent/received buttons to be clicked until arrived
- apply timeout to payment sent/received buttons
- load DepositView asynchronously
- remove separate timeout from OpenOffer
- tolerate error importing multisig hex until necessary
2024-04-18 14:19:52 -04:00
woodser
f7ac9ae37a show sync progress before sync starts on startup 2024-04-13 10:28:50 -04:00
woodser
b86e916dcb invoke error handler once on trade failure 2024-04-13 10:28:50 -04:00
woodser
9062bc9159 log error initializing main wallet 2024-04-13 10:28:50 -04:00
woodser
ccf2757418 increase trade protocol step timeout to 2m 2024-04-13 10:28:50 -04:00
woodser
2ba37d98fe shut down XmrWalletService with timeout 2024-04-13 10:28:50 -04:00
woodser
3e112485ba warn if trade wallet is more than 10 blocks behind monerod 2024-04-08 08:00:42 -04:00
woodser
b3ec46e769 register multiple pub keys for alerts and private notifications 2024-04-08 08:00:42 -04:00
woodser
fd328ceeea update sync progress in realtime with native wallet 2024-04-07 15:24:30 -04:00
woodser
7d7660414a trade fees are adjustable and persisted in offer payload 2024-04-07 08:33:39 -04:00
woodser
59fbd805a5 update offer state on same thread to fix blocking 2024-04-07 08:33:39 -04:00
woodser
60d82520c0 handle closing, stopping, deleting native and rpc wallet 2024-04-05 06:29:51 -04:00
woodser
01dd6a8af9 support using monero native libraries (experimental) 2024-04-01 19:28:00 -04:00
woodser
7eabde63f3
stop trade protocol if timeout while creating reserve or deposit tx 2024-03-25 10:31:36 -04:00
woodser
db12f1c2cb apply timeout for arbitrator to sign offer and init trade 2024-03-23 10:37:07 -04:00
woodser
10a5b55dfe check for trade timeout after arbitrator request and reserve tx 2024-03-23 10:37:07 -04:00
woodser
9661e6fba8 log details on invalid maker signature 2024-03-23 10:37:07 -04:00
woodser
897c010e0c save wallet on multisig import and create tx 2024-03-23 10:37:07 -04:00
woodser
60c2c12a95 show address for display with onion or localhost 2024-03-21 11:13:32 -04:00
woodser
1647a582f5 update chat views from upstream, support sending logs
Co-authored-by: jmacxx <47253594+jmacxx@users.noreply.github.com>
2024-03-21 11:13:32 -04:00
woodser
3c7841ae28
fix chat message listeners by returning source observable list (#830) 2024-03-18 10:47:43 -04:00
woodser
216260da85 cancel offer waits for result 2024-03-15 11:17:29 -04:00
woodser
4a57b26469 get txs after sync to update from pool 2024-03-15 11:17:29 -04:00
woodser
8d7bb250c5 get updated balances from Balances.java 2024-03-15 11:17:29 -04:00
napoly
82eb081089
Create task to generate key pairs (#823) 2024-03-14 12:12:42 -04:00
woodser
307689d372
fix build warning for trade.getChatMessages() (#807) 2024-03-09 17:50:08 -05:00
napoly
c777133d36
Support for open JDK 21 by updating dependencies (#647) 2024-03-09 10:36:37 -05:00
woodser
623196bcb0 fix trade wallet name 2024-02-28 06:58:26 -05:00
woodser
0c9a3ac0a4 rename trade wallets with short id and short uid 2024-02-27 12:09:44 -05:00
woodser
1dc2e8337c documentation fixes 2024-02-27 08:00:25 -05:00
woodser
98ffb5f34c remove trade after cleared and shut down 2024-02-26 11:23:06 -05:00
woodser
2c0275e336 do not sync trade wallet on deletion if deposit not requested 2024-02-26 11:23:06 -05:00
woodser
be90b317f2 advance trade state on payment sent ack 2024-02-25 08:22:56 -05:00
woodser
23db847065 shut down open offer pool off ui thread to avoid blocking 2024-02-19 16:50:53 -05:00
woodser
eaf096adeb cache wallet state to avoid requests on main thread 2024-02-19 16:50:53 -05:00
woodser
7346ced337 increase trade fees to 0.15% for maker and 0.75% for taker 2024-02-18 07:43:50 -05:00
woodser
98129c70ed add mainnet welcome message with release warning 2024-02-17 07:20:43 -05:00
woodser
36f6dd7ade update translations for sell limits within release windows 2024-02-16 07:10:36 -05:00
woodser
a20f251258 update translations to reserve only funds needed 2024-02-16 07:10:36 -05:00
woodser
8171299de3 revert bisq licenses and add haveno licenses 2024-02-15 07:45:35 -05:00
woodser
f91f213cd2 limit sell offers to unsigned buy limit then warn within release windows 2024-02-15 07:45:35 -05:00
woodser
a63118d5eb increase trade limits to 3, 6, 12, 96 2024-02-12 10:22:33 -05:00
woodser
cc34ff8168 update description to reserve only the funds needed 2024-02-11 08:07:57 -05:00
woodser
548cae004d synchronize chat messages to avoid concurrency exception 2024-02-11 08:07:57 -05:00
woodser
dc015ad83d show offer funding address entries in receive view 2024-02-11 08:07:57 -05:00
woodser
d1d6576986 update clearnet pricenode address to port 8078 2024-02-04 12:51:17 -05:00
woodser
c908294250 set payment sent message state after sending message 2024-02-02 06:16:41 -05:00
woodser
fabec9d396 open offer manager completes shut down after thread pool 2024-02-02 06:16:41 -05:00
woodser
1a0fab8c47 validate sender hostname and update address on dispute opened message 2024-02-02 06:16:41 -05:00
woodser
6f51d333ec resend payment sent & received messages from trade thread on startup 2024-02-02 06:16:41 -05:00
woodser
1a5a754f18 set mailbox message comparator in trade manager to fix npe 2024-01-29 08:41:04 -05:00
woodser
481b6c871a backup wallets on shut down, skip when open on windows 2024-01-29 08:41:04 -05:00
woodser
8600c0cb0d shut down http connections with 5s timeout 2024-01-28 06:45:05 -05:00
woodser
64aa052d83 decrease trade and offer manager shut down timeout to 60s 2024-01-27 09:07:46 -05:00
woodser
eb323f6d65 force restart trade wallet on connection refused during poll 2024-01-27 09:07:46 -05:00
woodser
2a2eb0c82f check if trade shut down started within lock 2024-01-27 09:07:46 -05:00
woodser
33bd4587c4 remove offers from books off user thread 2024-01-27 09:07:46 -05:00
woodser
41290a1f3f remove stacktrace on error polling trade wallet 2024-01-27 09:07:46 -05:00
woodser
221a63077c do not backup trade wallet if arbitrator for space saving 2024-01-27 09:07:46 -05:00
woodser
8776fecef0 use wallet lock with xmr address entries 2024-01-27 09:07:46 -05:00
woodser
821d949fa7 check offer availability off user thread 2024-01-25 12:29:32 -05:00
woodser
29a488d3af update balances off user thread 2024-01-25 12:29:32 -05:00
woodser
40650103d9 get wallet height off user thread 2024-01-25 12:29:32 -05:00
woodser
d0a489198b delete trade wallet backup if empty and payout unlocked, else schedule 2024-01-25 12:29:32 -05:00
woodser
19d3e2853d skip trade protocol message processing if shutting down 2024-01-23 20:45:20 -05:00
woodser
e4e8f5d311 fix npe syncing wallet normally for duration 2024-01-23 20:45:20 -05:00
woodser
6dc9842253 open dispute on trade thread 2024-01-23 20:45:20 -05:00
woodser
892eaa440a fix trade initialization error handling and run off trade thread 2024-01-22 05:21:29 -05:00
woodser
ea4359d164 run arbitrator protocol on trade thread 2024-01-22 05:21:29 -05:00
woodser
847e9e8701 save trade wallet on shutdown with timeout 2024-01-22 05:21:29 -05:00
woodser
b88bec580e update translations for wallet seed backup 2024-01-21 05:25:22 -05:00
woodser
a6b8723ebe persist wallet creation date when created 2024-01-21 05:25:22 -05:00
woodser
036f40e861 remove lock synchronization in connection service to avoid blocking 2024-01-21 05:25:22 -05:00
woodser
93c87462c6 fix CI tests by skipping daemon sync check for local testnet 2024-01-19 10:29:38 -05:00
woodser
e956114239 shut down OpenOfferManager thread pool before completing shut down 2024-01-19 05:45:46 -05:00
woodser
7beae49dd2 cancel pending price request on select new provider 2024-01-19 05:45:46 -05:00
woodser
75e85179b4 fixes for local monerod 2024-01-19 05:45:46 -05:00
woodser
947caca647 do not resend payment sent message to arbitrator after ack 2024-01-17 10:17:50 -05:00
woodser
857179f42d do not reprocess dispute closed message after illegal argument exception 2024-01-17 10:17:50 -05:00
woodser
7383ece7b3 delete backup wallets ~5 days after trade wallet 2024-01-15 10:44:43 -05:00
woodser
df27902577 add HavenoUtils.isSeedNode() 2024-01-15 10:44:43 -05:00
woodser
022028bb41 fix npe cleaning up arbitrator's mailbox messages 2024-01-13 07:28:03 -05:00
woodser
ad77912171 fix invalid pub key warning on process mailbox messages 2024-01-13 07:28:03 -05:00
woodser
2966f8461c update balances on freeze/thaw, register open offer before processing 2024-01-13 07:28:03 -05:00
woodser
036ddef52c update only buyer's payment sent message state property on startup 2024-01-13 07:28:03 -05:00
woodser
bcb951ca40 do not check best connection when connection is fixed 2024-01-13 07:28:03 -05:00
woodser
5c28428436 do not re-complete task to send deposits confirmed message 2024-01-12 06:52:01 -05:00
woodser
2b9d0ef5a6 fix payment sent message state property after improper shut down 2024-01-12 06:52:01 -05:00
woodser
db155283be repeatedly acquire lock on trade shut down and fix timeout 2024-01-10 09:35:25 -05:00
woodser
d26ddac5c0 rename proto type from CONFIRMED_IN_UI* to CONFIRMED* 2024-01-10 09:35:25 -05:00
woodser
6c83fc4cf8 avoid fetching wallet subaddresses individually by caching 2024-01-09 06:59:45 -05:00
woodser
c28ffb70ff update state from wallet notifications on UserThread 2024-01-09 06:59:45 -05:00
woodser
a6f6f5c00a protocols skip resending payment sent/received if shut down 2024-01-09 06:59:45 -05:00
woodser
c06a85b929 clear and shut down inactive trades, move more to trade threads 2024-01-06 12:52:21 -05:00
woodser
c14f37b595 invoke main wallet listeners in thread pool 2024-01-06 12:52:21 -05:00
woodser
52a44d020e update trades on UserThread in TradeManager to fix npe 2024-01-06 12:52:21 -05:00
woodser
0d60df2aa7 refactor trade and connection threading to new ThreadUtils 2024-01-06 12:52:21 -05:00
woodser
497de47965 do not set daemon connection to null on disconnect 2024-01-06 12:52:21 -05:00
woodser
ba8a9ae21d await external prices on startup 2024-01-06 12:52:21 -05:00
woodser
f8d9c827ea skip wallet initialization if shut down started 2024-01-06 12:52:21 -05:00
woodser
2ee2b747f9 check for balance before deleting trade wallet 2024-01-06 12:52:21 -05:00
woodser
e7371d1299 process trade state notifications off UserThread 2024-01-04 14:54:15 -05:00
woodser
43bbb29384 try syncing main wallet when height > target height on startup 2024-01-04 14:54:15 -05:00
woodser
0a3736bba0 reprocess trade messages off UserThread 2024-01-04 14:54:15 -05:00
woodser
5d88936600 start main wallet when daemon synced with improved UserThread 2024-01-01 09:05:04 -05:00
woodser
5466689857 set progress listener state in same thread 2024-01-01 09:05:04 -05:00
woodser
7f3fd0af08 finish open offer manager tasks before shut down 2024-01-01 09:05:04 -05:00
woodser
342c212ba8 remove global error handler for taking offer 2024-01-01 09:05:04 -05:00
woodser
fdb24ba9f8 arbitrator sends nack if trade already taken 2024-01-01 09:05:04 -05:00
woodser
c6b1d03283 set price feed state in UserThread 2024-01-01 09:05:04 -05:00
woodser
c55fb927f2 rely on trade state to delete wallet 2023-12-31 10:14:13 -05:00
woodser
3aab3f57b1 set offer state on UserThread 2023-12-31 10:14:13 -05:00
woodser
e160499d30 sync main wallet outside lock on connection changed 2023-12-31 10:14:13 -05:00
woodser
bc4d8fc8c2 split output tx is null while awaiting scheduled tx 2023-12-31 10:14:13 -05:00
woodser
2e86d4a62a check local connection before switching 2023-12-31 10:14:13 -05:00
woodser
6c2f3ea154 improve trade state reliability
update trade state atomically on UserThread
nullify error handling on deposits confirmed message
set trade state before deposit request and relay
add checks before deleting wallet
UserThread.await() detects if on UserThread
2023-12-27 11:20:16 -05:00
woodser
3de4264c4b increase offer reliability with TTL, refresh period, max attempts 2023-12-24 11:55:47 -05:00
woodser
0d33959eeb republish offers on dedicated thread for open offer manager 2023-12-22 09:58:29 -05:00
woodser
a1f8f942fc poll daemon and trade wallets in dedicated lock and prevent queuing 2023-12-22 09:58:29 -05:00
woodser
1dab218d7e do not shut down connection pool in case account is re-recreated 2023-12-20 07:32:40 -05:00
woodser
c7b8571842 reset timeout timer on progress creating offer 2023-12-20 07:32:40 -05:00
woodser
1df2ab4389 replace AppSetupWithP2PAndDAO with AppSetupWithP2P 2023-12-20 07:32:40 -05:00
woodser
01a57c18f7 support setting custom node in UI with localhost running 2023-12-20 07:32:40 -05:00
woodser
f162cad439 handle connection change on dedicated thread, other thread improvements 2023-12-20 07:32:40 -05:00
woodser
b1f8411641 check local connection after setting 2023-12-20 07:32:40 -05:00
woodser
dffb676f4e reset address entries for open offer on error taking offer 2023-12-20 07:32:40 -05:00
woodser
30e199c56e shut down trades before main wallet to finish processing 2023-12-20 07:32:40 -05:00
woodser
e6775f3b58 move processing off UserThread for smoother experience 2023-12-18 13:45:04 -05:00
woodser
e11d65c038 check and extend timeout after taker creates reserve tx 2023-12-18 13:45:04 -05:00
woodser
48d902b58d close trader dispute ticket on payout published 2023-12-18 13:45:04 -05:00
woodser
c42471191a refactor trade state TRADE_COMPLETED to boolean 2023-12-18 13:45:04 -05:00
woodser
fd4e4d3917 remove warning that wallet is not synced when idling 2023-12-16 15:20:36 -05:00
woodser
66a152c888 close open dispute on preparing payment received message 2023-12-16 15:20:36 -05:00
woodser
26ea53883c republish offers awaits prices and runs off UserThread 2023-12-16 15:20:36 -05:00
woodser
dbd8db0e88 set open offer's reserve tx fields once known and repost if invalid 2023-12-16 15:20:36 -05:00