Skip to content

Commit 7cca4f4

Browse files
authored
Merge pull request #65 from Leon1777/master
[Fix] Batch upstream merge
2 parents 2ace100 + 07c174d commit 7cca4f4

File tree

24 files changed

+632
-242
lines changed

24 files changed

+632
-242
lines changed

.github/workflows/deploy.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ jobs:
2424
uses: actions/checkout@v4
2525

2626
- name: Setup Go
27-
uses: actions/setup-go@v4
27+
uses: actions/setup-go@v5
2828
with:
29-
go-version: 1.21
29+
go-version: 1.23.1
3030

3131
- name: Update sources
3232
if: matrix.TARGET == 'linux/aarch64' || matrix.TARGET == 'windows/x64'

.github/workflows/tests.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ jobs:
3636
swap-size-gb: 12
3737

3838
- name: Setup Go
39-
uses: actions/setup-go@v4
39+
uses: actions/setup-go@v5
4040
with:
41-
go-version: 1.21
41+
go-version: 1.23.1
4242

4343
- name: Test
4444
shell: bash
@@ -59,9 +59,9 @@ jobs:
5959
swap-size-gb: 12
6060

6161
- name: Setup Go
62-
uses: actions/setup-go@v4
62+
uses: actions/setup-go@v5
6363
with:
64-
go-version: 1.21
64+
go-version: 1.23.1
6565

6666
- name: Checkout
6767
uses: actions/checkout@v4
@@ -91,9 +91,9 @@ jobs:
9191
uses: actions/checkout@v4
9292

9393
- name: Setup Go
94-
uses: actions/setup-go@v4
94+
uses: actions/setup-go@v5
9595
with:
96-
go-version: 1.21
96+
go-version: 1.23.1
9797

9898
- name: Delete the stability tests from coverage
9999
run: rm -r stability-tests

app/rpc/rpchandlers/submit_transaction.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ func HandleSubmitTransaction(context *rpccontext.Context, _ *router.Router, requ
2828
}
2929

3030
log.Debugf("Rejected transaction %s: %s", transactionID, err)
31-
errorMessage := &appmessage.SubmitTransactionResponseMessage{}
31+
// Return the ID also in the case of error, so that clients can match the response to the correct transaction submit request
32+
errorMessage := appmessage.NewSubmitTransactionResponseMessage(transactionID.String())
3233
errorMessage.Error = appmessage.RPCErrorf("Rejected transaction %s: %s", transactionID, err)
3334
return errorMessage, nil
3435
}

changelog.txt

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,55 @@
1+
Karlsend v2.2.1 - 2024-09-19
2+
============================
3+
4+
* Wallet-related improvements and fixes
5+
6+
Karlsend v2.2.0 - 2024-09-03
7+
============================
8+
9+
* Critical bug fix for difficulty adjustment after hardfork block
10+
11+
* Adjust difficulty managment between rusty and golang nodes during the first block window
12+
* fix for integration test diff manager signature
13+
* difficulty adjustment window fix
14+
* Hardfork in devnet and simnet after the difficulty adjustment window
15+
* Fix simnet pruning test
16+
17+
Karlsend v2.1.0 - 2024-08-29
18+
============================
19+
20+
* Fishhash plus implementation with hard fork procedure
21+
* hard fork procedure from `khashv1` to `khashv2`
22+
* HF procedure with diff adjustment
23+
* Mainnet HFDAAScore set to 26962009 to switch to `khashv2`
24+
25+
* First `fishhash` tests
26+
* refresh seeder url
27+
* add minor version
28+
* fix logging
29+
* Fix issue on word32 usage in kernel mixing step
30+
* Fix the dataset and light cache generation
31+
* Code cleanup and dag generation correct logging
32+
* Added lock on mainnet connection
33+
* Remove blocking tests on block version because node contains both algorithm
34+
* fix critical bug in matrix generation
35+
* align with rusty block version test
36+
* Removed periodic race detection workflow
37+
* Added `HFDAAScore` to `simnet` to pass tests
38+
* Fixed pruning_test in `simnet` and `devnet` genesis from Rust node
39+
* Fixed remaining integration tests and Go modules update
40+
* Use 4-char abbreviation as rest of KLS logging system (POW->POWK)
41+
* Increase windows runner pagefile to 32gb
42+
* Remove Go cache in test workflow due to its constant failures
43+
* Increase code coverage timeout to 120m due to `khashv2`
44+
* Increase timeout in integration tests and sequential execution
45+
* Fixed `BlockVersionKHashV2` in debug output and removed linebreak
46+
* Moving `khashv2` pre-computed dag file during stability tests
47+
* Give orphans stability test more time to process blocks
48+
* Increase Linux swapfile size in GitHub runner to avoid OOM
49+
* Increase swap size for code coverage to support `khashv2`
50+
* Version bump to 2.1.0 for `khashv2`
51+
* Updated README.md and added `khashv2` paragraph
52+
153
Karlsend v1.2.0 - 2024-03-07
254
============================
355

cmd/karlsenwallet/config.go

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ const (
2222
newAddressSubCmd = "new-address"
2323
dumpUnencryptedDataSubCmd = "dump-unencrypted-data"
2424
startDaemonSubCmd = "start-daemon"
25+
versionSubCmd = "version"
26+
getDaemonVersionSubCmd = "get-daemon-version"
2527
)
2628

2729
const (
@@ -30,6 +32,7 @@ const (
3032
)
3133

3234
type configFlags struct {
35+
ShowVersion bool `short:"V" long:"version" description:"Display version information and exit"`
3336
config.NetworkFlags
3437
}
3538

@@ -57,9 +60,9 @@ type sendConfig struct {
5760
Password string `long:"password" short:"p" description:"Wallet password"`
5861
DaemonAddress string `long:"daemonaddress" short:"d" description:"Wallet daemon server to connect to"`
5962
ToAddress string `long:"to-address" short:"t" description:"The public address to send Karlsen to" required:"true"`
60-
FromAddresses []string `long:"from-address" short:"a" description:"Specific public address to send Karlsen from. Use multiple times to accept several addresses" required:"false"`
63+
FromAddresses []string `long:"from-address" short:"a" description:"Specific public address to send Karlsen from. Repeat multiple times (adding -a before each) to accept several addresses" required:"false"`
6164
SendAmount string `long:"send-amount" short:"v" description:"An amount to send in Karlsen (e.g. 1234.12345678)"`
62-
IsSendAll bool `long:"send-all" description:"Send all the Karlsen in the wallet (mutually exclusive with --send-amount)"`
65+
IsSendAll bool `long:"send-all" description:"Send all the Karlsen in the wallet (mutually exclusive with --send-amount). If --from-address was used, will send all only from the specified addresses."`
6366
UseExistingChangeAddress bool `long:"use-existing-change-address" short:"u" description:"Will use an existing change address (in case no change address was ever used, it will use a new one)"`
6467
Verbose bool `long:"show-serialized" short:"s" description:"Show a list of hex encoded sent transactions"`
6568
config.NetworkFlags
@@ -130,6 +133,13 @@ type dumpUnencryptedDataConfig struct {
130133
config.NetworkFlags
131134
}
132135

136+
type versionConfig struct {
137+
}
138+
139+
type getDaemonVersionConfig struct {
140+
DaemonAddress string `long:"daemonaddress" short:"d" description:"Wallet daemon server to connect to"`
141+
}
142+
133143
func parseCommandLine() (subCommand string, config interface{}) {
134144
cfg := &configFlags{}
135145
parser := flags.NewParser(cfg, flags.PrintErrors|flags.HelpFlag)
@@ -186,6 +196,9 @@ func parseCommandLine() (subCommand string, config interface{}) {
186196
Listen: defaultListen,
187197
}
188198
parser.AddCommand(startDaemonSubCmd, "Start the wallet daemon", "Start the wallet daemon", startDaemonConf)
199+
parser.AddCommand(versionSubCmd, "Get the wallet version", "Get the wallet version", &versionConfig{})
200+
getDaemonVersionConf := &getDaemonVersionConfig{DaemonAddress: defaultListen}
201+
parser.AddCommand(getDaemonVersionSubCmd, "Get the wallet daemon version", "Get the wallet daemon version", getDaemonVersionConf)
189202

190203
_, err := parser.Parse()
191204
if err != nil {
@@ -291,6 +304,9 @@ func parseCommandLine() (subCommand string, config interface{}) {
291304
printErrorAndExit(err)
292305
}
293306
config = startDaemonConf
307+
case versionSubCmd:
308+
case getDaemonVersionSubCmd:
309+
config = getDaemonVersionConf
294310
}
295311

296312
return parser.Command.Active.Name, config

0 commit comments

Comments
 (0)