Skip to content

Commit

Permalink
bump: Bump libplanet to 5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
s2quake committed Jul 3, 2024
1 parent 0ccec38 commit 7a7e677
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
</ItemGroup>

<PropertyGroup>
<LibplanetSolutionPath>$(SolutionDir).libplanet\</LibplanetSolutionPath>
<RootPath Condition="'$(SolutionDir)' != ''">$(SolutionDir)</RootPath>
<RootPath Condition="'$(SolutionDir)' == ''">$(MSBuildThisFileDirectory)\</RootPath>
<LibplanetVersion>5.0.0</LibplanetVersion>
<UseRidGraph>true</UseRidGraph>
</PropertyGroup>

Expand Down
3 changes: 1 addition & 2 deletions src/common/LibplanetConsole.Common/BlockChainUtility.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ public static BlockChain CreateBlockChain(
timestamp: DateTimeOffset.MinValue);
var transactions = ImmutableList.Create(transaction);
var genesisBlock = BlockChain.ProposeGenesisBlock(
actionEvaluator: actionEvaluator,
privateKey: genesisKey,
transactions: transactions,
timestamp: DateTimeOffset.MinValue);
Expand Down Expand Up @@ -133,7 +132,7 @@ public static Block AppendNew(
lastCommit: lastCommit);
var blockContent = new BlockContent(blockMetadata, [transaction]);
var preEvaluationBlock = blockContent.Propose();
var stateRootHash = blockChain.DetermineBlockStateRootHash(preEvaluationBlock, out _);
var stateRootHash = blockChain.DetermineNextBlockStateRootHash(blockChain.Tip, out _);
var height = blockChain.Count;
var round = 0;
var block = preEvaluationBlock.Sign(privateKey, stateRootHash);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@

<!-- $(LibplanetDirectory) does not exist. -->
<ItemGroup Condition="!Exists('$(LibplanetDirectory)')">
<PackageReference Include="Libplanet" Version="4.4.1" />
<PackageReference Include="Libplanet.Net" Version="4.4.1" />
<PackageReference Include="Libplanet.Crypto" Version="4.4.1" />
<PackageReference Include="Libplanet.Store" Version="4.4.1" />
<PackageReference Include="Libplanet.RocksDBStore" Version="4.4.1" />
<PackageReference Include="Libplanet" Version="$(LibplanetVersion)" />
<PackageReference Include="Libplanet.Net" Version="$(LibplanetVersion)" />
<PackageReference Include="Libplanet.Crypto" Version="$(LibplanetVersion)" />
<PackageReference Include="Libplanet.Store" Version="$(LibplanetVersion)" />
<PackageReference Include="Libplanet.RocksDBStore" Version="$(LibplanetVersion)" />
</ItemGroup>

<!-- $(CommandsDirectory) exists. -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@

<!-- $(LibplanetDirectory) does not exist. -->
<ItemGroup Condition="!Exists('$(LibplanetDirectory)')">
<PackageReference Include="Libplanet.Net" Version="4.4.1" />
<PackageReference Include="Libplanet.Crypto" Version="4.4.1" />
<PackageReference Include="Libplanet.Net" Version="$(LibplanetVersion)" />
<PackageReference Include="Libplanet.Crypto" Version="$(LibplanetVersion)" />
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit 7a7e677

Please sign in to comment.