Skip to content

Commit 0281ad1

Browse files
committed
Merge branch 'master' into rc-v2
* master: (43 commits) Fix `GetAndChange` warnings (neo-project#3702) `Murmur3` should not be cryptographic hash algorithm (neo-project#3668) Test: add tests for native contract id (neo-project#3697) Update nugets (neo-project#3692) [Core P2P] fix the bug (neo-project#3695) Add hardfork HF_Echidna (neo-project#3454) Fix: add lock for RocksDbStore.Snapshot to keep same behavior as MemoryStore and LevelDbStore (neo-project#3689) Nullable rocks db (neo-project#3686) Nullable leveldb (neo-project#3685) Enforcement Compiler Warnings (neo-project#3687) [`Update`] Dotnet & Compiler Version (neo-project#3684) [`Add`]: LevelDB Benchmarks (neo-project#3667) [`Fix`]: Behavior when `keyPrefix` is null in different `IStore.Seek` impls. (neo-project#3682) Improve calculatenetworkfee (neo-project#3674) more 2025 (neo-project#3678) Nullable in Storage classes (neo-project#3670) readonly (neo-project#3676) [Fix] Set max entries for `VerifyProof` in `statePlugin` (neo-project#3675) Neo.json.benchmarks (neo-project#3673) Happy new year 2025 (neo-project#3677) ... # Conflicts: # src/Neo/Neo.csproj # src/Neo/ProtocolSettings.cs # src/Neo/SmartContract/ApplicationEngine.cs # src/Neo/SmartContract/Native/NeoToken.cs # src/Neo/SmartContract/Native/RoleManagement.cs # tests/Neo.UnitTests/SmartContract/Native/UT_NativeContract.cs
2 parents 95f6535 + 805678d commit 0281ad1

File tree

947 files changed

+8552
-2148
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

947 files changed

+8552
-2148
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# https://github.com/dotnet/dotnet-docker/blob/main/README.sdk.md
22
# https://mcr.microsoft.com/en-us/artifact/mar/dotnet/sdk/tags <-- this shows all images
3-
FROM mcr.microsoft.com/dotnet/sdk:9.0.101-noble
3+
FROM mcr.microsoft.com/dotnet/sdk:9.0.102-noble
44

55
# Install the libleveldb-dev package
66
RUN apt-get update && apt-get install -y libleveldb-dev

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ dotnet_naming_symbols.all_members.applicable_kinds = *
171171

172172
dotnet_naming_style.pascal_case_style.capitalization = pascal_case
173173

174-
file_header_template = Copyright (C) 2015-2024 The Neo Project.\n\n{fileName} file belongs to the neo project and is free\nsoftware distributed under the MIT software license, see the\naccompanying file LICENSE in the main directory of the\nrepository or http://www.opensource.org/licenses/mit-license.php\nfor more details.\n\nRedistribution and use in source and binary forms with or without\nmodifications are permitted.
174+
file_header_template = Copyright (C) 2015-2025 The Neo Project.\n\n{fileName} file belongs to the neo project and is free\nsoftware distributed under the MIT software license, see the\naccompanying file LICENSE in the main directory of the\nrepository or http://www.opensource.org/licenses/mit-license.php\nfor more details.\n\nRedistribution and use in source and binary forms with or without\nmodifications are permitted.
175175

176176
# Require file header
177177
dotnet_diagnostic.IDE0073.severity = error

.github/workflows/main.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,15 +69,15 @@ jobs:
6969
run: |
7070
brew install leveldb
7171
dotnet build
72-
cp -vp /opt/homebrew/Cellar/leveldb/1.23_1/lib/libleveldb.dylib ./tests/Neo.Plugins.Storage.Tests/bin/Debug/net9.0/
73-
dotnet test --blame-hang --blame-crash --no-build
72+
cp -vp /opt/homebrew/Cellar/leveldb/1.23_2/lib/libleveldb.dylib ./tests/Neo.Plugins.Storage.Tests/bin/Debug/net9.0/
73+
dotnet test --no-build
7474
7575
- name: Test (windows)
7676
if: matrix.os == 'windows-latest'
7777
run: |
7878
dotnet sln neo.sln remove ./tests/Neo.Plugins.Storage.Tests/Neo.Plugins.Storage.Tests.csproj
7979
dotnet build
80-
dotnet test --blame-hang --blame-crash --no-build
80+
dotnet test --no-build
8181
8282
- name: Test for coverall
8383
if: matrix.os == 'ubuntu-latest'

README.md

Lines changed: 15 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -114,23 +114,21 @@ An overview of the project folders can be seen below.
114114

115115
|Folder|Content|
116116
|---|---|
117-
|/src/neo/Consensus/| Classes used in the dBFT consensus algorithm, including the `ConsensusService` actor.|
118-
|/src/neo/Cryptography/|General cryptography classes including ECC implementation.|
119-
|/src/neo/IO/|Data structures used for caching and collection interaction.|
120-
|/src/neo/Ledger/|Classes responsible for the state control, including the `MemoryPool` and `Blockchain` classes.|
121-
|/src/neo/Network/|Peer-to-peer protocol implementation classes.|
122-
|/src/neo/Persistence/|Classes used to allow other classes to access application state.|
123-
|/src/neo/Plugins/|Interfaces used to extend Neo, including the storage interface.|
124-
|/src/neo/SmartContract/|Native contracts, `ApplicationEngine`, `InteropService` and other smart-contract related classes.|
125-
|/src/neo/VM/|Helper methods used to interact with the VM.|
126-
|/src/neo/Wallet/|Wallet and account implementation.|
127-
|/src/Neo.CLI/| `neo-cli` console application for the running a _FULL_ node.|
128-
|/src/Neo.Extensions/| Extensions class to expand the existing functionality.|
129-
|/src/Neo.Json/| Neo's JSON Specification classes.|
130-
|/src/Neo.VM/|Neo base class virtual machine.|
131-
|/src/plugins/| Include `ApplicationLogs`, `LevelDBStore`, `RpcServer`, `OracleService`, `DBFTPlugin` and more.|
132-
|/tests/|All unit tests.|
133-
117+
|[/src/neo/Cryptography/](https://github.com/neo-project/neo/tree/master/src/Neo/Cryptography)|General cryptography implementation, including ECC.|
118+
|[/src/neo/IO/](https://github.com/neo-project/neo/tree/master/src/Neo/IO)|Data structures used for caching and collection interaction.|
119+
|[/src/neo/Ledger/](https://github.com/neo-project/neo/tree/master/src/Neo/Ledger)|Classes responsible for the state control, including the `MemoryPool` and `Blockchain`.|
120+
|[/src/neo/Network/](https://github.com/neo-project/neo/tree/master/src/Neo/Network)|Peer-to-peer protocol implementation.|
121+
|[/src/neo/Persistence/](https://github.com/neo-project/neo/tree/master/src/Neo/Persistence)|Classes used to allow other classes to access application state.|
122+
|[/src/neo/Plugins/](https://github.com/neo-project/neo/tree/master/src/Neo/Plugins)|Interfaces used to extend Neo, including the storage interface.|
123+
|[/src/neo/SmartContract/](https://github.com/neo-project/neo/tree/master/src/Neo/SmartContract)|Native contracts, `ApplicationEngine`, `InteropService` and other smart-contract related classes.|
124+
|[/src/neo/VM/](https://github.com/neo-project/neo/tree/master/src/Neo/VM)|Helper methods used to interact with the VM.|
125+
|[/src/neo/Wallets/](https://github.com/neo-project/neo/tree/master/src/Neo/Wallets)|Wallet and account implementation.|
126+
|[/src/Neo.CLI/](https://github.com/neo-project/neo/tree/master/src/Neo.CLI)| `neo-cli` console application for running a _FULL_ node.|
127+
|[/src/Neo.Extensions/](https://github.com/neo-project/neo/tree/master/src/Neo.Extensions)| Extensions to expand the existing functionality.|
128+
|[/src/Neo.Json/](https://github.com/neo-project/neo/tree/master/src/Neo.Json)| Neo's JSON specification.|
129+
|[/src/Neo.VM/](https://github.com/neo-project/neo/tree/master/src/Neo.VM)|Neo virtual machine.|
130+
|[/src/plugins/](https://github.com/neo-project/neo/tree/master/src/Plugins)| Include `ApplicationLogs`, `LevelDBStore`, `RpcServer`, `OracleService`, `DBFTPlugin` and more.|
131+
|[/tests/](https://github.com/neo-project/neo/tree/master/tests)|All unit tests.|
134132

135133
## Related projects
136134
Code references are provided for all platform building blocks. That includes the base library, the VM, a command line application and the compiler.

benchmarks/Directory.Build.props

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33

44
<PropertyGroup>
5+
<LangVersion>latest</LangVersion>
56
<IsPackable>false</IsPackable>
7+
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
8+
<WarningLevel>4</WarningLevel>
9+
<AnalysisLevel>latest</AnalysisLevel>
610
</PropertyGroup>
711

812
</Project>

benchmarks/Neo.Benchmarks/Benchmarks.Hash.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2015-2024 The Neo Project.
1+
// Copyright (C) 2015-2025 The Neo Project.
22
//
33
// Benchmarks.Hash.cs file belongs to the neo project and is free
44
// software distributed under the MIT software license, see the

benchmarks/Neo.Benchmarks/Benchmarks.POC.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2015-2024 The Neo Project.
1+
// Copyright (C) 2015-2025 The Neo Project.
22
//
33
// Benchmarks.POC.cs file belongs to the neo project and is free
44
// software distributed under the MIT software license, see the

benchmarks/Neo.Benchmarks/Benchmarks.UInt160.cs

Lines changed: 1 addition & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (C) 2015-2024 The Neo Project.
1+
// Copyright (C) 2015-2025 The Neo Project.
22
//
33
// Benchmarks.UInt160.cs file belongs to the neo project and is free
44
// software distributed under the MIT software license, see the
@@ -15,77 +15,8 @@ namespace Neo.Benchmark
1515
{
1616
public class Benchmarks_UInt160
1717
{
18-
static readonly OldUInt160 s_oldUInt160 = new([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]);
1918
static readonly UInt160 s_newUInt160 = new([0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1]);
2019

21-
[Benchmark]
22-
public void TestOldUInt160Gernerator1()
23-
{
24-
_ = new OldUInt160();
25-
}
26-
27-
[Benchmark]
28-
public void TestOldUInt160Gernerator2()
29-
{
30-
_ = new OldUInt160(new byte[20]);
31-
}
32-
33-
[Benchmark]
34-
public void TestOldUInt160CompareTo()
35-
{
36-
OldUInt160.Zero.CompareTo(OldUInt160.Zero);
37-
OldUInt160.Zero.CompareTo(s_oldUInt160);
38-
s_oldUInt160.CompareTo(OldUInt160.Zero);
39-
}
40-
41-
[Benchmark]
42-
public void TestOldUInt160Equals()
43-
{
44-
OldUInt160.Zero.Equals(OldUInt160.Zero);
45-
OldUInt160.Zero.Equals(s_oldUInt160);
46-
s_oldUInt160.Equals(null);
47-
}
48-
49-
[Benchmark]
50-
public void TestOldUInt160Parse()
51-
{
52-
_ = OldUInt160.Parse("0x0000000000000000000000000000000000000000");
53-
_ = OldUInt160.Parse("0000000000000000000000000000000000000000");
54-
}
55-
56-
[Benchmark]
57-
public void TestOldUInt160TryParse()
58-
{
59-
OldUInt160.TryParse(null, out _);
60-
OldUInt160.TryParse("0x0000000000000000000000000000000000000000", out var temp);
61-
OldUInt160.TryParse("0x1230000000000000000000000000000000000000", out temp);
62-
OldUInt160.TryParse("000000000000000000000000000000000000000", out _);
63-
}
64-
65-
[Benchmark]
66-
public void TestOldUInt160OperatorLarger()
67-
{
68-
_ = s_oldUInt160 > OldUInt160.Zero;
69-
}
70-
71-
[Benchmark]
72-
public void TestOldUInt160OperatorLargerAndEqual()
73-
{
74-
_ = s_oldUInt160 >= OldUInt160.Zero;
75-
}
76-
77-
[Benchmark]
78-
public void TestOldUInt160OperatorSmaller()
79-
{
80-
_ = s_oldUInt160 < OldUInt160.Zero;
81-
}
82-
83-
[Benchmark]
84-
public void TestOldUInt160OperatorSmallerAndEqual()
85-
{
86-
_ = s_oldUInt160 <= OldUInt160.Zero;
87-
}
88-
8920
[Benchmark]
9021
public void TestGernerator1()
9122
{

benchmarks/Neo.Benchmarks/Neo.Benchmarks.csproj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,9 @@
99
</PropertyGroup>
1010

1111
<ItemGroup>
12-
<PackageReference Include="System.IO.Hashing" Version="9.0.0" />
12+
<PackageReference Include="System.IO.Hashing" Version="9.0.1" />
1313
<ProjectReference Include="..\..\src\Neo\Neo.csproj" />
14+
<ProjectReference Include="..\..\src\Plugins\LevelDBStore\LevelDBStore.csproj" />
1415
<PackageReference Include="BenchmarkDotNet" Version="0.14.0" />
1516
</ItemGroup>
1617

benchmarks/Neo.Benchmarks/OldUInt160.cs

Lines changed: 0 additions & 184 deletions
This file was deleted.

0 commit comments

Comments
 (0)