It has been a while since I last provided an update on the open-source libraries I have developed for the Blurt blockchain. Given that I have recently created a new library and updated some existing ones, I believe it is the opportune time to write a dedicated post addressing these developments.
Let's save the best for last, i.e. the Blurt Voting Trail Bot that I've just created, and focus first on updates to existing libraries.
Blurt RPC nodes checker version 1.1.2
Your library for ensuring fault tolerance of RPC nodes on the Blurt blockchain in your dApp. Moreover, it offers the ability to connect your users to the RPC node with the lowest latency and fastest call response time.
- Gitlab: https://gitlab.com/beblurt/blurt-nodes-checker
- Npm: https://www.npmjs.com/package/@beblurt/blurt-nodes-checker
- License: GPL-3.0-or-later
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/6fcbdf40cb8f5040e6dd465f6d2b9cf8c3675994.png)
Updates:
- The nexus option is now set as true by default
- Add Nexus tests get_account_posts, get_discussion, get_ranked_posts
- Add Condenser tests get_account_history, lookup_accounts
Usage example on BeBlurt:
On BeBlurt, the Blurt RPC Nodes Checker library is employed not only to display the status of RPC nodes on the Blurt blockchain but also in conjunction with the dBlurt library. This combination ensures blockchain calls are made with minimal latency from your device while excluding RPC nodes encountering errors. Availability tests and response time tests of RPC nodes are conducted at five-minute intervals.
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/30db06f40a12b7e8f2ec02410f88aace8c0dab0e.png)
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/ee253f505c12795fbf2b69c46a7fa719493e1601.png)
dBlurt version 0.9.29
I've just realized that it has been three months since my last post about dBlurt updates, but since then I've updated dBlurt seventeen times (updating repositories at the same time) and forgot to make a post about it hahaha.
Written in Typescript, dBlurt allows frontend/backend developers to connect to the Blurt blockchain to perform queries or broadcast operations through the JSON remote procedure call protocol JSON-RPC. dBlurt is an adaption for the Blurt blockchain of the dSteem library from Johan Nordberg created in 2017.
- Gitlab: https://gitlab.com/beblurt/dblurt
- Npm: https://www.npmjs.com/package/@beblurt/dblurt
- Documentation: https://dblurt.beblurt.com
- License: BSD-3-Clause-No-Military-License
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/44b79ead75a593043ebfc3f76c341e91d2bd269c.png)
Updates (non-exhaustive list):
- Addition of Proposals interfaces and serializers for broadcast operations
- Fixing some missing serializers and properties
- Creation of Nexus interfaces
- Add pagination to
list_subscribers
- refactor the NexusPost type definition
- TransferToVestingOperation
- Account History API with bitmask
- Condenser lookup_accounts & lookup_witness_accounts
Usage example:
Thanks to @saboin's implementation of filters on the condenser_api.get_account_history
and account_history_api.enum_virtual_ops
methods. This significant update allows for filtering based on operations and virtual operations. His effort in carrying out this complex update is highly appreciated. To provide you with a better understanding, I believe offering a brief example of these two cases would be beneficial.
Get Account History
Let's consider a scenario where we need to retrieve the history of recent rewards (author rewards, curation rewards, beneficiary rewards) as well as transfers for an account. Below is the code that can be utilized for this purpose:
const rpc = ['https://rpc.beblurt.com']
const account = 'nalexadre'
import { Client, utils } from "@beblurt/dblurt"
const client = new Client(rpc, { timeout: 1500 })
const op = utils.operationOrders
const bitMaskFilter = utils.makeBitMaskFilter([
op.author_reward,
op.comment_benefactor_reward,
op.curation_reward,
op.transfer
])
console.log(rpc, '[bitMaskFilter]', bitMaskFilter)
client.condenser.getAccountHistory(account, -1, 400, bitMaskFilter)
.then(async accountHistory => {
for await (const history of accountHistory) {
console.log(history[1]?.op)
}
})
.catch(e => console.log(e))
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/dbe6d17c23dd308b7d59bfd2dcddec33a37b0ced.png)
Enum Virtual Operations
Let's assume we want to retrieve payment on proposals as well as operation fees from block 32015120 to 32015200. Below is the code that can be utilized for this purpose:
const rpc = ['https://rpc.blurt.world']
import { Client, utils } from "@beblurt/dblurt"
const client = new Client(rpc, { timeout: 1500 })
const vop = utils.virtualOps
const bitwiseFilter = utils.makeBitwiseFilter([
vop.proposal_pay,
vop.fee_pay
])
console.log()
console.log(rpc, '[bitwiseFilter]', bitwiseFilter)
client.accountHistory.enumVirtualOps({
block_range_begin: 32015120,
block_range_end: 32015200,
include_reversible: false,
limit: 4,
filter: bitwiseFilter
})
.then(async enumVirtualOps => {
console.log('next_block_range_begin:', enumVirtualOps.next_block_range_begin)
console.log('next_operation_begin:', enumVirtualOps.next_operation_begin)
for await (const op of enumVirtualOps.ops) {
console.log(op)
}
})
.catch(e => console.log(e))
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/91e598af24752e9558381471e6214e46bfa9df2d.png)
Blurt Tools CMD
Blurt Blockchain Operation tools in common interactive command line user interfaces (Inquirer). It allows you to create accounts, make transfers...
- Gitlab: https://gitlab.com/beblurt/blurt-tools-cmd
- License: GPL-3.0-or-later
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/2cd51070415f3ed28901a2e0ec59d9b9e7cc5dfd.png)
I haven't made any changes since my post about the TESTNET, but I thought it would be a good idea to provide a brief refresh on its existence here.
Blurt Voting Trail Bot
As an author, I'm not particularly fond of curation trails due to a trauma from my experience with the Curie curation group and its 500 accounts automatically following its upvotes. While receiving significant curation is indeed gratifying, being read and upvoted by real individuals holds considerable value for me, and it's something I truly appreciate here on Blurt. Some time ago a Blurtian user of a trail bot made for Steem 5 years ago encountered problems with it, so I decided to make one for Blurt using my dBlurt and Blurt RPC nodes checker libraries.
- Gitlab: https://gitlab.com/beblurt/blurt-voting-trail-bot
- License: GPL-3.0-or-later
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/cd47d3900891ed4130a77491ef617f34a82d7a03.png)
Overview
Resilient Restart: The bot features a resilient restart capability, allowing you to resume processing from the last block processed. This is made possible by the
START_BLOCK
configuration parameter, which is continually updated after each block processing. This ensures that the bot seamlessly picks up where it left off, even if there's an interruption.Adaptive Upvote Weights: With the
TYPE
configuration set to 'coeff', the bot provides you with adaptive upvote weights. Unlike fixed-percentage upvotes, the 'coeff' type allows your upvote weight to dynamically adjust based on the upvotes made by the accounts you follow. For instance, if the accounts you follow upvote with a total weight of 50%, your upvote will be 25% (ifVALUE
is set to 0.5).Smart Upvote Logic: The bot incorporates intelligent logic to protect against redundant upvotes. If a curator from the 'CURATORS' list has already upvoted a post or comment, any subsequent upvotes from the bot are skipped to avoid duplication.
Voting Power Safety: The Blurt Voting Trail Bot includes a safety feature to prevent the depletion of all your voting mana. The
MIN_POWER
parameter ensures that the bot only performs upvotes when your voting power is above the specified threshold. This helps you maintain a balanced voting strategy and avoid overcommitting your voting resources.Customization for Posts and Comments: The Blurt Voting Trail Bot offers granular control over upvote behavior for posts and comments. You can specify different
POST_TYPE
,POST_VALUE
,COMMENT_TYPE
, andCOMMENT_VALUE
parameters for posts and comments individually. For instance, you can set a higher upvote value for posts using coefficient-based curation while assigning a fixed percentage-based upvote for comments.Fault Tolerance Management: The bot utilizes the
@beblurt/blurt-nodes-checker
library for fault tolerance management. By providing multiple RPC nodes in theRPC_NODE_LIST
, the bot ensures uninterrupted communication with the Blurt blockchain. This robust approach helps prevent disruptions and ensures continuous operation.
Configuration
Customize the configuration parameters to match your preferences. The available options include:
RPC_NODE_LIST
: List of RPC nodes for the Blurt blockchain.RPC_NODE_TIMEOUT
: Timeout for JSON RPC calls in milliseconds.TRAIL
: List of accounts to trail and track their votes.EXCLUDED_AUTHORS
: List of authors to exclude from upvotes.EXCLUDED_VOTERS
: List of voters of the post preventing from upvoting.CURATORS
: List of curators with their account details and preferences.ACCOUNT
: The Blurt account of the curator.POSTING_KEY
: The posting key of the curator's account.POST_TYPE
: The type of curation for posts: '%' for percentage-based or 'coeff' for coefficient-based.POST_VALUE
: The curation value for posts, either a percentage or coefficient, based on the TYPE.COMMENT_TYPE
: The type of curation for comments: '%' for percentage-based or 'coeff' for coefficient-based.COMMENT_VALUE
: The curation value for comments, either a percentage or coefficient, based on the TYPE.MIN_POWER
: The minimum voting power required for the curator to upvote.
DEBUG_NODE_CHECKER
: Enable/disable debug mode for node checker.DEBUG_BLOCK
: Enable/disable debug mode for block processing.DEBUG_VOTE
: Enable/disable debug mode for voting operations.START_BLOCK
: Start processing from a specific block number (optional, can be null).
Difference between TYPE
"%"
& "coeff"
When choosing "%"
for TYPE
, the weight of your upvote will remain the same for all your upvotes. On the other hand, if you choose "coeff"
and set the VALUE
to, for example, 0.5
, it means that for each upvote made by the account you follow, your upvote will be half of their upvote. If the account you follow upvotes by 50%, your upvote will be 25%.
![image](https://imgp.blurt.world/0x0/https://img.blurt.world/blurtimage/beblurt/0b876ce7a799e4e964271bc09c3cf21d6f7be6c8.gif)
Markus Spiske on Unsplash
Thank you for your continued support through a vote on my witness or a Delegation to the BeBlurt Delegation program. Together, let's continue to thrive within the Blurt blockchain ecosystem.
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/nalexadre/d271000b5d01cb9e62ad0f0a993a065cb8d074eb.jpg)
![image](https://imgp.blurt.world/768x0/https://img.blurt.world/blurtimage/beblurt/f9ef6fcdcca32011ae256db69110b20088a1ba93.png)
Thanks for the updates @nalexadre! I may not know understand the technicalities but I appreciate the effort given to the platform. Thank you!♥️
I am totally clueless about operating curation bots unless it has a website frontend so I normally manually curate right from the start as my preference. But as I see it, this bot encourages engagement which is one of its fantastic features @nalexandre.
I know that is impossible to read so many articles posted here so a curation bot is necessary to help support users whom we follow using some set of parameters to use our voting power rather effectively for a maximal utility of our voting power.
Thank you and for the rest of Blurt developers for continually supporting this one community which aims to solve human problems with the enjoyment of freedom to do so. 😀👍
I'm testing your bot
Congratulations, your post has been curated by @r2cornell-curate. Also, find us on Discord
Felicitaciones, su publication ha sido votado por @r2cornell-curate. También, encuéntranos en Discord
Honestly, I don't really understand the technical things you discussed. What I understand is that you are doing things that will make the blurt ecosystem better than before and bring lots of benefits to people.
Big thanks to you and also the developers who are working hard to make blurt a better ecosystem.
Congratulations! 🏆
You have recieved a coconutty upvote! 🥥
Thank you for contributing to the Blurt Blockchain!
Keep up the great work!
Curated by @outofthematrix!
A little reminder: I am a top 20 Blurt witness, sooo please help me stay there!
Please consider taking a moment to vote for my witness, if you haven't already done so!
You can do this by logging into your wallet with your active key! 🗳️
It only takes a few seconds and doesn't cost a cent!
https://blurtwallet.com/~witnesses?highlight=outofthematrix
It would be interesting to promote all these applications that are beginning to be part of the Blurt universe so that they can be more easily tracked by Google and its search engine.
Thank you very much for letting us know the update. We benefited a lot from the update. Be well and be healthy. Take care of your family and yourself.
We have the same interests based on the opensource estimate @nalexadre. Good luck with the project. When everything in Linux works well I will make a post entirely dedicated to this beautiful frontend.
I just believe one thing that blurt is going to grow so big ! Because it has a lot of genuine and good people working so hard to see it grow to the moon 🚀 @nalexadre thanks for all you do
We’ll believe in blurt 🥰🚀🌎
verry goods