Skip to content

Commit

Permalink
Merge pull request #2038 from greymistcube/bump/libplanet-to-3.1.0
Browse files Browse the repository at this point in the history
⬆️ Bump libplanet to 3.1.0
  • Loading branch information
greymistcube authored Jul 28, 2023
2 parents 4612bb7 + 0df2b13 commit ec8dc52
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 10 deletions.
12 changes: 3 additions & 9 deletions .Lib9c.Benchmarks/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ static void Main(string[] args)
Console.WriteLine("Total elapsed\t{0}", ended - started);
}

// Copied from BlockChain<T>.SetStates().
// Copied from BlockChain.DetermineBlockStateRootHash().
private static void SetStates(
Guid chainId,
IStore store,
Expand All @@ -162,18 +162,12 @@ private static void SetStates(
bool buildStateReferences
)
{
IImmutableSet<Address> stateUpdatedAddresses = actionEvaluations
.SelectMany(a => a.OutputState.Delta.StateUpdatedAddresses)
.ToImmutableHashSet();
IImmutableSet<(Address, Currency)> updatedFungibleAssets = actionEvaluations
.SelectMany(a => a.OutputState.Delta.UpdatedFungibleAssets)
.ToImmutableHashSet();
IImmutableDictionary<KeyBytes, IValue> totalDelta = actionEvaluations.GetRawTotalDelta();

if (!stateStore.ContainsStateRoot(block.StateRootHash))
{
HashDigest<SHA256>? prevStateRootHash = store.GetStateRootHash(block.PreviousHash);
var totalDelta = GetTotalDelta(actionEvaluations, ToStateKey, ToFungibleAssetKey);
stateStore.Commit(prevStateRootHash, totalDelta);
ITrie stateRoot = stateStore.Commit(prevStateRootHash, totalDelta);
}
}

Expand Down
2 changes: 1 addition & 1 deletion .Libplanet
Submodule .Libplanet updated 40 files
+0 −2 .github/workflows/lint.yml
+1 −1 @planetarium/account-web3-secret-storage/test/TtyPassphraseEntry.test.ts
+50 −0 CHANGES.md
+2 −2 Libplanet.Action.Tests/Common/DumbAction.cs
+39 −0 Libplanet.Action.Tests/State/KeyConvertersTest.cs
+2 −1 Libplanet.Action/ActionEvaluationsExtensions.cs
+1 −7 Libplanet.Action/ActionEvaluator.cs
+1 −1 Libplanet.Action/Libplanet.Action.csproj
+6 −5 Libplanet.Action/State/AccountDeltaExtensions.cs
+0 −38 Libplanet.Action/State/AccountStateDeltaExtensions.cs
+8 −12 Libplanet.Action/State/BlockState.cs
+83 −10 Libplanet.Action/State/KeyConverters.cs
+0 −94 Libplanet.Common/EnumerableMeasurement.cs
+0 −55 Libplanet.Common/KeyValuePairExtensions.cs
+3 −3 Libplanet.Crypto/Libplanet.Crypto.csproj
+1 −1 Libplanet.Explorer.Tests/GraphQLTestUtils.cs
+1 −1 Libplanet.Explorer.ruleset
+1 −1 Libplanet.Explorer/GraphTypes/ActionType.cs
+7 −6 Libplanet.Extensions.Cocona.Tests/Commands/MptCommandTest.cs
+4 −2 Libplanet.Extensions.Cocona/Commands/MptCommand.cs
+1 −1 Libplanet.Net/Consensus/GossipConsensusMessageCommunicator.cs
+1 −1 Libplanet.Net/Transports/NetMQTransport.cs
+3 −3 Libplanet.Store/Libplanet.Store.csproj
+5 −36 Libplanet.Store/StateStoreExtensions.cs
+23 −6 Libplanet.Store/Trie/KeyBytes.cs
+0 −10 Libplanet.Store/Trie/TrieExtensions.cs
+1 −1 Libplanet.Tests.ruleset
+0 −79 Libplanet.Tests/EnumerableMeasurementTest.cs
+3 −3 Libplanet.Tests/Fixtures/IntegerSet.cs
+1 −1 Libplanet.Tests/KeyStore/Kdfs/KdfTest.cs
+0 −58 Libplanet.Tests/KeyValuePairExtensionsTest.cs
+23 −17 Libplanet.Tests/Store/StateStoreExtensionsTest.cs
+2 −3 Libplanet.Tests/Store/Trie/KeyBytesTest.cs
+38 −31 Libplanet.Tests/Store/TrieStateStoreTest.cs
+7 −6 Libplanet.Tests/Tx/TxSuccessTest.cs
+3 −3 Libplanet.Types/Libplanet.Types.csproj
+1 −1 Libplanet.ruleset
+1 −1 Libplanet/Blockchain/BlockChain.Evaluate.cs
+3 −3 Libplanet/Libplanet.csproj
+14 −0 _typos.toml

0 comments on commit ec8dc52

Please sign in to comment.