Skip to content

Releases: dahlia/libplanet

Libplanet 0.28.2

16 Mar 02:14
0.28.2
36d1904
Compare
Choose a tag to compare

Released on March 15, 2022.

  • (Libplanet.RocksDBStore) RocksDBStore.GetBlockDigest() became to silently return null with no misleading error log when it's asked a non-existent block hash. [#1500, [planetarium#1852]]

[#1500]: planetarium#1500 [[planetarium#1852]]: planetarium#1852

Libplanet 0.23.1

10 Dec 06:18
0.23.1
8c5e573
Compare
Choose a tag to compare

Released on December 10, 2021.

  • Fixed TrieStateStore.PruneStates() method's bug that it had thrown ArgumentOutOfRangeException. [#1653, #1654]

Libplanet 0.9.3

14 Jul 13:17
Compare
Choose a tag to compare

Released on May 29, 2020.

  • Fixed a Swarm<T>.PreloadAsync() method's bug that had hanged in a state downloading block hashes and finally unexpectedly terminated when a peer's chain had gotten reorged. [#880, #884]

Libplanet 0.9.5

13 Jul 20:25
Compare
Choose a tag to compare

Released on June 12, 2020.

  • Fixed a bug that had not properly received block hashes after the chain had reorged. [#880, #905]

Libplanet 0.9.2

13 Jul 20:16
Compare
Choose a tag to compare

Released on May 20, 2020.

  • (Libplanet.RocksDBStore) Fixed a memory leak bug in RocksDBStore. [#870]

Libplanet 0.9.1

13 Jul 19:57
Compare
Choose a tag to compare

Released on May 7, 2020.

  • Fixed a bug where the canonical chain had changed if any actions had thrown an exception during Swarm<T>.PreloadAsync(). [#862]
  • Fixed a Swarm<T>.PreloadAsync() method's bug that it had hung forever and raised InvalidOperationException. [#847, #864]

Libplanet 0.9.4

07 Oct 08:48
0.9.4
45b057a
Compare
Choose a tag to compare

Released on June 2, 2020.

  • (Libplanet.RocksDBStore) Fixed a bug that RocksDBStore.DeleteChainId() method had thrown KeyNotFoundException when there's no such chain ID. [#891]
  • (Libplanet.RocksDBStore) Fixed a bug that RocksDBStore had written logs into the incorrect context DefaultContext, not RocksDBStore the correct one. [#891]

Libplanet 0.6.0

01 Oct 07:16
7ed4b0a
Compare
Choose a tag to compare

Released on October 1, 2019.

Backward-incompatible interface changes

  • BlockChain<T>.MineBlock() is now async and became to throw OperationCanceledException if BlockChain<T>'s tip index is changed while mining. [#460, #517]
  • Users became able to give a cancellation token to Block<T>.Mine() and Hashcash.Answer() to cancel the operation. [#460, #517]
  • Replaced UnexpectedlyTerminatedTxRehearsalException with UnexpectedlyTerminatedActionException. [#498]
  • The following methods became to throw UnexpectedlyTerminatedActionException with having its InnerException during actions being evaluated if any action of them throws an exception: [#498]
    • Transaction<T>.EvaluateActions()
    • Transaction<T>.EvaluateActionsGradually()
    • Block<T>.EvaluateActionsPerTx()
    • Block<T>.Evaluate()
    • BlockChain<T>.GetStates(completeStates: true)
  • The concept of "namespaces" in IStore was replaced by "chain IDs" to be consistent with BlockChain<T>. [#483, #486]
    • Renamed IStore.ListNamespaces() method to ListChainIds().
    • Renamed IStore.DeleteNamespace() method to DeleteChainId().
    • Renamed IStore.GetCanonicalNamespace() method to GetCanonicalChainId().
    • Renamed IStore.SetCanonicalNamespace(string) method to SetCanonicalChainId(Guid).
    • Replaced namespace/sourceNamespace/destinationNamespace parameters taking string of methods in IStore and StoreExtension with chainId/sourceChainId/destinationChainId taking Guid.
    • Renamed NamespaceNotFoundException to ChainIdNotFoundException.
    • Replaced NamespaceNotFoundException(string, string) constructor with ChainIdNotFoundException(Guid, string) constructor.
    • Replaced NamespaceNotFoundException.Namespace property with ChainIdNotFoundException.ChainId property.
  • IStore.StoreStateReference<T>(string, IImmutableSet<Address>, Block<T>) method became replaced by StoreStateReference(Guid, IImmutableSet<Address>, HashDigest<SHA256>, long) method so that it takes hash and index of a block instead of an entire block. [#420]
  • Added IStore.ForkBlockIndexes() method. [#420]
  • Removed addressesToStrip parameter from IStore.ForkStateReferences<T>() method. [#454, #467, #509, #522]
  • Removed the concept of "staged transactions that should not be broadcasted," because its primary usage had been to make a transaction of a reward action for a candidate for block miner, and the case became achieved through IBlockPolicy<T>.BlockAction property which was introduced at 0.5.0. All staged transactions became broadcasted. [#319, #470]
    • BlockChain<T>.StageTransactions(IDictionary<Transaction<T>, bool>) method became replaced by StageTransactions(IImmutableSet<Transaction<T>>).
    • Removed toBroadcast parameter from IStore.IterateStagedTransactionIds(bool) method.
    • IStore.StageTransactionIds(IDictionary<TxId, bool>) method became replaced by StageTransactionIds(IImmutableSet<TxId>().
  • Removed Swarm<T>.AddPeersAsync() method. To connect with seed peers, use Swarm<T>.BootstrapAsync() method instead. [#353]
  • Peer with endpoints should be typed as BoundPeer which is inherited from Peer. [#353]
  • Removed IActionContext.NewGuid() method. To get a randomly generated Guid, use RandomExtension.GenerateRandomGuid() which implements RFC 4122 instead. [#508]

Added interfaces

  • Added BlockChain<T>.TipChanged event which is invoked with an argument of BlockChain<T>.TipChangedEventArgs when BlockChain<T>.Tip is changed. [#517, #526]
  • Added BlockChain<T>.TipChangedEventArgs class. [#526]
  • Added Swarm<T>.PrepareAsync() method. The method should be called before calling Swarm<T>.BootstrapAsync(), Swarm<T>.PreloadAsync() and Swarm<T>.StartAsync(). [#353]
  • Added Swarm<T>.BootstrapAsync() method to connect with seed peers. [#353]
  • Added RandomExtension static class. [#508]
  • TxId class became to implement IComparable<TxId> and IComparable interfaces. [#244, #511]

Behavioral changes

  • Swarm<T> now broadcasts transactions as soon as new transactions are received. [#463, #496]
  • Swarm<T> now ignores block hashes which already exists. [#461, #484]
  • Swarm<T>.PreloadAsync() method became to download precalculated states of blocks from a likely branchpoint instead of a genesis block from a trusted peer (i.e., trustedStateValidators) where there are branches between peers. [#465, #481]
  • Swarm<T>'s internal GetRecentStates message became to take BlockLocator, an internal data type to approximates a path of a chain of blocks for heuristics to search a likely branchpoint, instead of HashDigest<SHA256>. [#465, #481]
  • NetMQ instances are now initialized at Swarm<T>.StartAsync() instead of Swarm<T>(). [#353]
  • Peers now connected via Kademlia protocol. Peers are now selectively connected to each peer. [#353]
  • TxIds and Blocks are now broadcasted to selected peers from routing table of the host peer. [#353]
  • PolymorphicAction<T>.ToString() method became to show the runtime type of its InnerAction for the sake of easier debugging. [#512]
  • The order of Block<T>.Transactions became to be determined by both a Block<T>.Hash and a Transaction<T>.Id, so that signers cannot predict the order of transactions in a block before it's mined. If there are multiple transactions signed by the same signer in a block these transactions become grouped together and the order is determined by a Block<T>.Hash and a fingerprint derived from all these transactions, and transactions in each group (per signer) are ordered by Transaction<T>.Nonce. [#244, #355, #511, #520]
  • LiteDBStore() became to create the database in memory if the path parameter is null. [#521]

Bug fixes

  • Fixed a bug that Swarm<T> hadn't released its TURN related resources on Swarm<T>.StopAsync(). [#450]
  • Fixed a bug that IActionContext.Random had been possible to generated equivalent results between actions of different transactions in a Block<T>. [#519]
  • Fixed a bug where a forked chain would not be deleted when an exception occurred during fetching block from other peers. [#527, #537, #540]